Rivier/ Reference/ voice

Walk a call flow without placing a call

post/calls/flows/simulate

Walk a call flow without placing a call: give the flow and what the caller presses or says at each question, and get back what the line would say and do, and the question it waits at next. Uses the same checks and routing as a real call.

Before you call

Credential
Authorization: Bearer $KEY
Scope
voice:write
Mcp
rivier_call_flow_simulate
Graphql
Mutation.voiceCallFlowSimulateCreate
Sdk
calls.flows.simulate
Cli
calls flow-simulate

Request bodyapplication/json, required

  • flow
    The flow to walk, as it would be stored
  • answerslist of string
    What the caller did at each question, in order: a key such as 1, a spoken word, an empty string for nothing; at a transfer answered or no-answer; at a recording notice agree or decline
  • varsobject
    Values the flow can speak, used as {{name}}
  • hoursstring
    For opening hours: use the clock, or pretend the call comes inside or outside them One of: now, open, closed.

Responses

  • 200application/json
    Success
    • 400application/json
      The request was malformed
      • errorstringrequired
      • messagestring
    • 401application/json
      No valid credential
      • errorstringrequired
      • messagestring
    • 403application/json
      The credential lacks the scope, origin or address
      • errorstringrequired
      • messagestring
    • 429application/json
      Over the key's rate limit; see Retry-After
      • errorstringrequired
      • messagestring

    This page as Markdown