AnalysisPlan API not correct
# support
a
The analysisPlan api is not working. In the docs and using the server-sdk (typescript). It tells you to use: Docs:
Copy code
ts
analysisPlan: {
  structuredDataPlan: {
    enabled: true,
    schema: {
      type: 'object',
      properties: {
            wasVoicemail: { type: 'boolean', description: 'Did we get a voicemail?' },
            wasRecorded: { type: 'boolean', description: 'Was the call recorded?'},
          }
    }
  }
}
But does not populate the analysisPlan for the assistant in the dashboard. However, if I manually populate it in the dashboard. Then I run getAssistant via the API (either manually or via the server-sdk). Then I get the following when I log assistant.analysisPlan :
Copy code
ts
structuredDataSchema: {
  type: 'object',
  properties: {
    receivedVoicemail: {
      description: 'Whether the assistant encountered a voicemail',
      type: 'boolean'
    }
  }
}
Which basically means I cant in reliable way programmatically create analysisPlans via the API.
v
@Amanski I understand the issue you're facing with the
analysisPlan
API not working as expected when using the server SDK or following the documentation. It seems there might be a discrepancy between the documentation and the actual behavior of the API. To address this, I recommend reaching out to the support team with the details of the discrepancy you've encountered. They will be able to provide you with the correct usage pattern or update the documentation accordingly. Additionally, they can investigate if there's a bug or an issue with the API that needs to be resolved. In the meantime, if you need to programmatically create
analysisPlans
and the current method isn't working, the support team may be able to offer a workaround or an alternative method to achieve your goal. Please ask support for more info on this, as they will be able to assist you further with this specific issue.
You can continue this conversation by mentioning me in the message.
s
@Amanski sorry for the late response. What do you mean by this? (This would really help me figure out what's going wrong for you!) > But does not populate the analysisPlan for the assistant in the dashboard.
Because of no response closing this ticket.