StructuredDataPlan
# support
i
When I create my agent in Dashboard, I get the structureddataplan in the call log details - callID: 59a8faf3-a8ce-45ec-83bb-f23f9d4d4195 But when I create my agent using API, I do not get the structureddataplan in the call log details - callID: 908d6540-afdd-41ad-8b9e-b140f62a6f8a.
This is my body request:
@User can you please help investigate why is it something to do with the request am sending via api?
c
Hey ivy, I wanted to let you know that we're managing a high volume of support requests at the moment, so our response time might be a bit slower than usual. I truly appreciate your understanding and will get back to you as soon as possible!  Thanks again for your patience!
s
You are passing the wrong structured data plan that's why there is no structured data generated for your second call. You can check how to pass the correct structured data plan by looking over here. https://docs.vapi.ai/api-reference/assistants/create#response.body.analysisPlan.structuredDataPlan https://cdn.discordapp.com/attachments/1395003771557249174/1395912609521336422/image.png?ex=687c2c6c&is=687adaec&hm=799eac1173cd6ca837657efcb11fec538842f4eb9d973751e313d7eab387e5e8&
i
Hi @Gilang can you please have a look at this asap?
Hi @Shubham Bajaj can you please inform or direct us to how we have done it wrongly? Im looking at the api and i cant see what is wrong exactly. Thanking you in advance.
s
Looking into it.
fixed_strctured_data_plan
Copy code
json
{
  "structuredDataPlan": {
    "enabled": true,
    "messages": [
      {
        "content": "You are an expert data extractor. You will be given a transcript of a call. Extract structured data per the JSON Schema. DO NOT return anything except the structured data.\n\nExtract the following information:\n1) appointmentType - The type of appointment being discussed\n2) serviceProvider - The name or identifier of the service provider\n\nJSON Schema:\n{{schema}}\n\nOnly respond with the JSON.",
        "role": "system"
      },
      {
        "role": "user", 
        "content": "Here is the transcript:\n\n{{transcript}}\n\n"
      }
    ],
    "schema": {
      "type": "object",
      "properties": {
        "appointmentType": {
          "type": "string",
          "description": "The type of appointment being scheduled or discussed"
        },
        "serviceProvider": {
          "type": "string", 
          "description": "The name or identifier of the service provider"
        }
      },
      "required": ["appointmentType", "serviceProvider"]
    },
    "timeoutSeconds": 5
  }
}
broken_structured_data_plan
Copy code
json
          "structuredDataPlan": {
            "enabled": true,
            "messages": [
              {
                "content": "Extract the following information:\n1) Which type of appointment\n2) Which service provider",
                "role": "system"
              }
            ],
            "schema": {
              "properties": {
                "Which service provider": {"type": "string"},
                "Which type of appointment ": {"type": "string"}
              },
              "type": "object"
            },
            "timeoutSeconds": 5
          }
whats_fixed
1. **Fixed property names**: -
"Which type of appointment "
→
"appointmentType"
(removed trailing space, used camelCase) -
"Which service provider"
→
"serviceProvider"
(removed spaces, used camelCase) 2. **Added required fields**: Specified that both fields are required in the
required
array 3. **Added descriptions**: Each property now has a clear description for better LLM understanding 4. **Improved system message**: - More specific instructions about what to extract - Clearer mapping between requirements and schema properties - Follows the established pattern from the codebase 5. **Added user message**: Following the standard pattern with template variables for transcript injection
g
Thank You. I will check it up
c
Hi, First off, we want to sincerely apologize for the delay in getting back to you. We understand how frustrating it is to wait - especially when you're counting on us - and we owe you a clear explanation of what’s been happening and how we’re addressing it. Over the past few weeks, we've seen a significant increase in support requests. While this reflects exciting growth, it has also stretched our small team and exposed some real challenges in scaling our support operations. To improve your experience, we’ve taken a step back to reassess our approach. Here’s what we’re implementing: - Smarter Support Through Automation: We’re investing in our AI support systems to help you resolve issues more efficiently. Soon, our support bot will offer expanded capabilities, making it easier to access accurate, instant help—particularly for common or repetitive queries. - Expanding the Support Team: To meet growing demand, we’re adding 2–3 new team members focused on managing support volume and improving response times. - Prioritized SLAs for High-Usage Accounts: We’re introducing service level improvements for users who are growing with us: - Accounts with usage over 1,000 minutes/month will receive prioritized support. - For all general inquiries, we’re establishing a standardized 48-hour response time. We’re confident these steps will lead to faster, more reliable support and help us better serve you as you grow with us. Also, in case you still need help with this ongoing ticket, do let us know, and we will help you get this resolved as soon as possible. Thank you for your continued patience and for being part of our journey. Warm regards, Vapi Team
g
We adjust the structures and its working now. Thank you
c
Hey, I'm closing this ticket now. Let me know if you need anything else.
2 Views