Daco
05/23/2025, 1:45 AMDaco
05/23/2025, 1:54 AM{
"id": "8339651a-9ba5-4603-a94b-54b72d23f382",
"createdAt": "2025-05-22T23:15:12.323Z",
"updatedAt": "2025-05-23T01:32:16.719Z",
"type": "function",
"function": {
"name": "sendEmail",
"strict": true,
"description": "This tool is to be triggered after the call; it's an email to our sales team, only the emailBody parameter should be sent, this parameter should contain the captured callers details as well as a brief summary of what they are enquiring about.\nEnsure the content is formatted for JSON, like replacing line breaks with \\n",
"parameters": {
"type": "object",
"properties": {
"emailBody": {
"description": "This is the body content of the email",
"type": "string"
}
},
"required": [
"emailBody"
]
}
},
"orgId": "62c50b68-c08c-4ab3-bbe4-6c52392d0e66",
"server": {
"url": "REDACTED",
"timeoutSeconds": 30,
"headers": {
"Authorization": "REDACTED"
}
},
"async": true
}
Kyle
05/23/2025, 12:37 PMDaco
05/26/2025, 10:43 AMVapi Support Bot
05/26/2025, 10:44 AMemailBody
before sending it to PipeDream or SendGrid. For example, in Node.js/Express:
js
app.post('/your-endpoint', (req, res) => {
const emailBody = req.body?.message?.toolCallList?.[0]?.function?.arguments?.emailBody;
// Now use emailBody with SendGrid or PipeDream
});
This ensures only the relevant data is processed further.
Source:
- [Custom Tools Request Format](https://docs.vapi.ai/tools/custom-tools#request-format-understanding-the-tool-call-request)Kyle
05/27/2025, 3:32 AM