curl -X POST https://api.whatabot.app/api/v1/sessions/flows/{flowId}/create \
-H "X-Api-Key: wh_your_api_key"
curl -X POST https://api.whatabot.app/api/v1/sessions/flows/{flowId}/create \
-H "X-Api-Key: wh_your_api_key" \
-H "Content-Type: application/json" \
-d '{"variables": {"userName": "Claudio", "plan": "premium"}}'
{
"sessionId": "550e8400-e29b-41d4-a716-446655440000",
"status": "active",
"expiresAt": "2025-01-15T10:30:00.000Z"
}
Sessions
Create Session
Create a new conversation session for a flow.
POST
/
v1
/
sessions
/
flows
/
{flowId}
/
create
curl -X POST https://api.whatabot.app/api/v1/sessions/flows/{flowId}/create \
-H "X-Api-Key: wh_your_api_key"
curl -X POST https://api.whatabot.app/api/v1/sessions/flows/{flowId}/create \
-H "X-Api-Key: wh_your_api_key" \
-H "Content-Type: application/json" \
-d '{"variables": {"userName": "Claudio", "plan": "premium"}}'
{
"sessionId": "550e8400-e29b-41d4-a716-446655440000",
"status": "active",
"expiresAt": "2025-01-15T10:30:00.000Z"
}
Create a new conversation session for the specified flow. The flow engine begins processing from the Start node and delivers the initial response to the callback URL configured on the API key.
string
required
Your API key (prefixed with
wh_).string
required
The UUID of the flow to start.
Body
object
Initial values for flow variables. Keys must match variable names created in the editor.
Show Example
Show Example
any
Each key is the variable name and the value can be a string, number, boolean, or object.
curl -X POST https://api.whatabot.app/api/v1/sessions/flows/{flowId}/create \
-H "X-Api-Key: wh_your_api_key"
curl -X POST https://api.whatabot.app/api/v1/sessions/flows/{flowId}/create \
-H "X-Api-Key: wh_your_api_key" \
-H "Content-Type: application/json" \
-d '{"variables": {"userName": "Claudio", "plan": "premium"}}'
{
"sessionId": "550e8400-e29b-41d4-a716-446655440000",
"status": "active",
"expiresAt": "2025-01-15T10:30:00.000Z"
}
The flow response is not returned in the HTTP response body. It is delivered asynchronously to the
callbackUrl configured on your API key via Webhook.