Live-call functions
With live call functions, your agent can access external systems during an ongoing call.
The connection is made via an MCP server. MCP stands for Model Context Protocol and is a standardized interface through which AI agents can communicate with external services.
When are live call functions useful?
Live call functions are suitable when the agent should retrieve current data during the conversation, validate inputs, or perform actions in external systems.
Typical examples are:
Retrieve customer data
Check or book appointments
Create tickets
Validate inputs
Calculate rules, e.g. date limits or number formats
Calculations and validations should be handled by the MCP server, not by the AI agent. For example, if a customer number must be exactly 13 digits long or a date must not be in the past, the MCP server should perform this check and return a clear result.
Step 1: Add MCP server

Open the overview of the desired AI agent in app.sipgate.com.
Click on the AI agent card and then select Tools it.
In the live call functions section, click Add.
Fill out the form:
Name (optional): An internal display name for the server.
URL: The HTTPS address of your MCP server.
Token (optional): An authentication token if your server requires protection.
Click Save. sipgate automatically connects to the server and checks the connection.
Step 2: Check MCP server tools
After a successful connection, sipgate displays the tools provided by the server in the overview. Check there:
Tool name: May be at most 28 characters long. Longer names are marked as errors in the overview and can cause the AI agent to use the tool unreliably.
Tool descriptions: The descriptions are received from the MCP server and adopted. The more precise the description, the better the AI agent can recognize when to use the tool. If possible, adjust the tool description on the MCP server side.
Parameters: Each parameter should also have a meaningful description. The information about which format (string, array, etc.) the MCP server expects for it and whether it is optional or required is crucial for successful exchange between the agent and the MCP server.
Step 3: Integrate MCP server into your playbook integrate

The AI agent works goal-oriented. In the playbook, describe, what it should achieve — not how it should proceed step by step.
Good: “Determine the caller's customer number based on their phone number get_customer and greet them by name get_name."
Less good: “1. Call the tool get_customer 2. Save the ID. 3. Then call get_name it …"
The AI agent decides for itself which tools it uses and in what order to achieve the goal.
Example: playbook-Structure for an appointment booking
Condition for the playbook: If the user wants to book an appointment or asks about available appointments.
1
Ask for time of day
Ask the user which part of the day they prefer for the appointment. The four options are: morning, midday, afternoon or evening. Remember the response as preferred_timeslot for all further tool calls.
✅
2
Get appointment suggestions
Call get_next_suggestions with the remembered preferred_timeslot and present the returned appointment suggestions to the user with date and time.
❌
3
Confirm slot or alternative
Ask the user: Does one of the suggestions fit? Does he want to name a specific day? Or does none of the suggestions fit? • Slot selected → save appointment, continue to Task 5 (capture first name) • Specific day → continue to Task 4 (ask for day & day suggestions) '• None fit → back to Task 2 (get appointment suggestions)
✅
4
Ask for day & day suggestions
Ask for the desired date. Call get_suggestions_for_day and present the suggestions. Return to the logic of Task 3.
Error handling:
• invalid date format → Explain to the user that the date was not recognized, and ask again for a valid date (format: DD.MM.YYYY)
• date too far in the future → Inform the user that booking is only possible up to 2 months in advance, and ask for a closer date
• Other error → Explain the problem and return to Task 3 (confirm slot or alternative), so the user can choose another day or request new suggestions
❌
5
Capture first name
IF the first name is not yet known: ask specifically for it. IF already known: skip this task.
✅
6
Capture last name
IF the last name is not yet known: ask specifically for it. IF already known: skip this task.
✅
7
Capture phone number
The caller's phone number is in the context under “User with phone number: …” — use this directly, DO NOT ask for it. Only if this entry is missing or the caller is anonymous: ask specifically for the phone number.
✅
8
Confirm contact details
Read out the first name, last name, and phone number again and ask for confirmation. If the user makes a correction: apply the correction and read the data out again.
❌
9
Book appointment
Call book_appointment with the appointment data (start, end) and the contact details (firstname, lastname, phone). IF booking successful (success: true): Confirm the booking with date and time and continue with Task 10 (thank & say goodbye).
Error handling:
• Slot taken (409 / “no longer available”) → Inform the user that the slot has meanwhile been taken, and return to Task 2 (get appointment suggestions)
• Other error → Briefly explain to the user that something went wrong, and ask whether they would like to choose another appointment (back to Task 3 – confirm slot or alternative) or whether they would like to try again later
✅
10
Thank & say goodbye
Thank the user for the conversation and wish them a nice day. Do not make any further offers.
❌
Refresh connection
If you have updated your MCP server, for example added new tools, open the overview of the agent's live call functions under Integrations. There, click on Refresh. The current list of tools will then be retrieved again.
Test live call functions
Manual test calls are recommended, with the playbook being actively used.
Check the following:
Is the agent triggering the right tools?
Are the parameters filled in correctly?
Does the agent reliably ask for missing parameters?
Are inputs validated by the MCP server?
Does the agent give sensible feedback for invalid data?
Does the agent respond sensibly to server error messages?
Security notes
When setting up your MCP server, note the following general technical recommendations. Which protective measures are appropriate depends on the specific use case, the data being processed, and the systems connected.
Access to the MCP server: Define who may communicate with your MCP server. Public tool calls should only be used for non-critical functions, for example simple checks or processes that correspond to a public online form. As soon as personal or sensitive data is returned or actions with an impact on a system are performed, access should be additionally protected, for example through authentication, security tokens, or other suitable access controls.
Access rights of the MCP server: Grant only the permissions that the MCP server needs for the respective purpose. For example, if the MCP server is to write data to a third-party system, it should not automatically receive full read and write access to all data in that system. Regularly check whether the permissions granted are still necessary.
Identity verification: As a rule, assume that a caller is initially not reliably identified. Before sensitive data is returned or actions are carried out, the MCP server should check whether the caller is authorized to do so. Depending on the use case, additional verification features such as a parcel number, a code word, a one-time code, or a password can be used. The transmitted phone number alone should not be used as reliable identity verification.
Input validation: Validate all inputs on the server side. Do not rely on an AI agent always recognizing or checking values correctly. Formal checks, for example lengths, number formats, required fields, or check digits, should be handled by the MCP server.
Data transfer and data minimization
Return only the data required for the current process. The MCP server should be designed so that no information is disclosed to unauthorized callers. In particular, for personal or confidential data, check whether the output is necessary for the respective purpose.
Last updated

