API URL: https://platform.blits.ai/api/external/messages/<YOUR_CONVERSATION_ID>/speech
With this POST request a message can be send to the bot. Please follow the following steps to do so.
Conversation ID
This is the output of the POST Conversation ID API. Please put the value between two forward slashes so that <YOUR_CONVERSATION_ID> is replaced.
Authorization
To set this up, the above API URL is need together with the authorization header. The header should have the following format:
Bearer <key>
The key can be obtained from the API settings on the settings page of your bot under the JSON Web Token:
Body
The body should contain the audio document on .WAV format.
Response
The APIs .JSON response should look like this:
{
"conversationToken": "c3fb84f4-848e-47fc-8969-c3f33b9fcb71",
"expectUserResponse": true,
"response": [
{
"items": [
{
"simpleResponse": {
"displayText": "Send your document",
"textToSpeech": "Send your document"
}
}
],
"suggestions": []
}
]
}