Vapi
12/13/2024, 10:36 AMVapi
12/13/2024, 10:36 AMKavish
12/13/2024, 10:37 AMVapi
12/13/2024, 10:37 AMVapi
12/13/2024, 10:39 AMKavish
12/13/2024, 10:39 AMVapi
12/13/2024, 10:39 AMjson
{
"analysisPlan": {
"successEvaluationPlan": {
"rubric": "AutomaticRubric",
"enabled": false,
"messages": []
},
"summaryPlan": {
"messages": [
{
"content": "Your summary message here"
}
]
},
"structuredDataPlan": {}
},
"monitorPlan": {
"listenEnabled": true,
"controlEnabled": true
},
"server": {
"url": "https://make.com"
},
"name": "my assistant"
}
Make sure to replace "Your summary message here"
with the actual summary message you want to include. Once you have your complete JSON payload, you can make the POST request like this:
bash
curl -X POST https://api.vapi.ai/assistant \
-H "Authorization: Bearer 7c3d8578e463aed" \
-H "Content-Type: application/json" \
-d '{
"analysisPlan": {
"successEvaluationPlan": {
"rubric": "AutomaticRubric",
"enabled": false,
"messages": []
},
"summaryPlan": {
"messages": [
{
"content": "Your summary message here"
}
]
},
"structuredDataPlan": {}
},
"monitorPlan": {
"listenEnabled": true,
"controlEnabled": true
},
"server": {
"url": "https://make.com"
},
"name": "my assistant"
}'
If you encounter any issues or need further assistance, please let me know!Kavish
12/13/2024, 10:42 AMKavish
12/13/2024, 10:43 AMVapi
12/13/2024, 10:43 AMjson
{
"prompt": "This is the first line.\n\
This is the second line.\n\
This is the third line."
}
Using newline characters within a single string:
json
{
"prompt": "This is the first line.\nThis is the second line.\nThis is the third line."
}
In both cases, the \n
represents a newline character, which will create a multiline prompt when the JSON is parsed. When you're writing this inside a curl
command, make sure to wrap your JSON data with single quotes '
to avoid any issues with shell interpretation of the newline characters.
Here's how it would look in a curl
command:
bash
curl -X POST https://api.vapi.ai/assistant \
-H "Authorization: Bearer 7c3d8578e463aed" \
-H "Content-Type: application/json" \
-d '{
"prompt": "This is the first line.\nThis is the second line.\nThis is the third line."
}'
Remember to replace the URL and the authorization token with your actual endpoint and token. If you have any further questions or need additional assistance, feel free to ask!Kavish
12/13/2024, 10:50 AMVapi
12/13/2024, 10:50 AMcurl
request, you should wrap it in single quotes and make sure there are no stray backticks at the end. Here's how you can structure your curl
command:
bash
curl -X POST https://api.vapi.ai/assistant \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"summaryPlan": {
"messages": [
{
"role": "system",
"content": "You are an AI assistant helping summarize phone conversations for business purposes. Your task is to generate a professional summary of the call based on the transcript provided.\n\nInstructions:\n1. Summarize the main purpose of the call.\n2. Highlight key topics or points discussed.\n3. Note any questions asked by the caller and the responses provided.\n4. Identify any action items or next steps mentioned.\n5. Provide the tone of the conversation (e.g., friendly, professional, urgent).\n\nHere is the transcript of the call:\n[Insert transcript here]\n\nYour output should be concise, clear, and formatted like this:\n\n- Call Purpose: [Brief description]\n- Key Discussion Points:\n 1. [Point 1]\n 2. [Point 2]\n- Questions Asked:\n - [Question 1]: [Response]\n- Action Items/Next Steps:\n - [Item 1]\n - [Item 2]\n- Call Tone: [Tone description]"
}
]
},
"structuredDataPlan": {},
"monitorPlan": {
"listenEnabled": true,
"controlEnabled": true
},
"server": {
"url": "https://make.com"
},
"name": "my assistant",
"forwardingPhoneNumber": "+918980579954"
}'
Make sure to replace YOUR_ACCESS_TOKEN
with your actual VAPI access token. If you have any further questions or need additional assistance, feel free to ask!Kavish
12/13/2024, 10:51 AMVapi
12/13/2024, 10:51 AMcurl
request and carefully read the API response for any error messages or indications of what might be wrong.
If you've gone through these steps and the issue persists, it might be best to reach out to the API support team for further assistance. They can provide more detailed guidance based on the specifics of their system. If you can share the error message or response you're receiving from the API, I might be able to offer more targeted advice.