Analyzing Tool Use and Successful Execution
# support
g
Hello! I want to analyze if a tool call was made during a conversation. And look if the tool executed successfully or not. I am particularly looking for API, SMS, and callTransfer tools. I tried getting the "messages" dynamic variable in the AnalysisPlan to generate a success evaluation but it's not available for use. What alternatives do I have?
v
You can extract tool call usage and success by customizing your assistant's
analysisPlan
with a structured data prompt and schema. For example:
Copy code
json
{
  "structuredDataPrompt": "Extract all tool calls (API, SMS, callTransfer) and their success status from the call transcript.",
  "structuredDataSchema": {
    "type": "object",
    "properties": {
      "toolCalls": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "toolType": { "type": "string" },
            "success": { "type": "boolean" }
          }
        }
      }
    }
  }
}
This will let you programmatically analyze tool calls and their outcomes in each call record's analysis results. Source: - [Call analysis documentation](https://docs.vapi.ai/assistants/call-analysis)
v
Message marked as helpful by @geramalagon! 🎉
g
Thank you! you have resolved my issue
c
Glad it solved
4 Views