DescribeConversationFlow
Describes the visual representation of a conversation flow for an intent. Note that this API is not part of the SDKs. See Visual conversation builder for more details.
Request Syntax
GET /bots/botId
/botversions/botVersion
/botlocales/localeId
/intents/intentId
/conversationflow HTTP/1.1
URI Request Parameters
The request uses the following URI parameters.
- botId
-
The identifier of the bot containing the intent whose conversation flow is to be described.
Length Constraints: Fixed length of 10.
Pattern:
^[0-9a-zA-Z]+$
Required: Yes
- botVersion
-
The version of the bot containing the intent whose conversation flow is to be described.
Length Constraints: Minimum length of 1. Maximum length of 5.
Pattern:
^(DRAFT|[0-9]+)$
Required: Yes
- intentId
-
The identifier of the intent whose conversation flow is to be described.
Length Constraints: Fixed length of 10.
Pattern:
^[0-9a-zA-Z]+$
Required: Yes
- localeId
-
The locale of the bot containing the intent whose conversation flow is to be described.
Required: Yes
Request Body
The request does not have a request body.
Response Syntax
HTTP/1.1 200
Content-type: application/json
{
"botId": "string",
"botVersion": "string",
"creationDateTime": number,
"flowDefinition": "string",
"intentId": "string",
"lastUpdatedDateTime": number,
"localeId": "string"
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
- botId
-
The identifier of the bot containing the intent whose conversation flow is being described.
Type: String
Length Constraints: Fixed length of 10.
Pattern:
^[0-9a-zA-Z]+$
- botVersion
-
The version of the bot containing the intent whose conversation flow is being described.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 5.
Pattern:
^(DRAFT|[0-9]+)$
- creationDateTime
-
The date and time when this conversation flow was created.
Type: Timestamp
- flowDefinition
-
A JSON-formatted string containing the positional data for blocks and edges in the conversation flow of the intent. See examples below for more details.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 2097152.
- intentId
-
The identifier of the intent whose conversation flow is being described.
Type: String
Length Constraints: Fixed length of 10.
Pattern:
^[0-9a-zA-Z]+$
- lastUpdatedDateTime
-
The date and time when this conversation flow was last updated.
Type: Timestamp
- localeId
-
The locale of the bot containing the intent whose conversation flow is being described.
Type: String
Errors
For information about the errors that are common to all actions, see Common Errors.
- InternalServerException
-
The service encountered an unexpected condition. Try your request again.
HTTP Status Code: 500
- PreconditionFailedException
-
Your request couldn't be completed because one or more request fields aren't valid. Check the fields in your request and try again.
HTTP Status Code: 412
- ResourceNotFoundException
-
You asked to describe a resource that doesn't exist. Check the resource that you are requesting and try again.
HTTP Status Code: 404
- ServiceQuotaExceededException
-
You have reached a quota for your bot.
HTTP Status Code: 402
- ThrottlingException
-
Your request rate is too high. Reduce the frequency of requests.
HTTP Status Code: 429
- ValidationException
-
One of the input parameters in your request isn't valid. Check the parameters and try your request again.
HTTP Status Code: 400
Examples
Example
The following response shows a conversation flow consisting of a Start
block and a Wait For User Input
block:
Sample Response
{
"botId": "BOTID12345",
"botVersion": "DRAFT",
"creationDateTime": 1.670358230862E9,
"flowDefinition": {
"metadata": {
"schemaVersion": "1",
"dataFormat": "JSON"
},
"blocks": [
{
"blockId": "startintent",
"blockType": "StartIntent",
"dataLocations": [
"intent/StartIntent_"
],
"coordinate": {
"x": "200",
"y": "400"
}
},
{
"blockId": "dm-node-ecceeba6-fa93-4e2e-82fc-11c5daafa22c",
"blockType": "WaitForUserInput",
"dataLocations": [
"intent/StartIntent_/WaitForUserInput_InitialResponse"
],
"coordinate": {
"x": "525",
"y": "400"
}
}
],
"edges": [
{
"edgeLocation": "intent/StartIntent_/WaitForUserInput_InitialResponse",
"destinationBlockId": "dm-node-ecceeba6-fa93-4e2e-82fc-11c5daafa22c",
"destinationBlockPort": "WaitForUserInput",
"originBlockId": "startintent",
"originBlockPort": "InitialResponse",
"vertices": [
{
"x": "455",
"y": "560"
},
{
"x": "525",
"y": "560"
},
{
"x": "525",
"y": "490"
},
{
"x": "525",
"y": "422"
},
{
"x": "510",
"y": "422"
}
]
}
]
},
"intentId": "INTENTID12",
"lastUpdatedDateTime": 1.670358230862E9,
"localeId": "en_US"
}
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: