Calls

Push Call Context

Push context into a LIVE relay-mode call (mid-call context injection).

A call.utterance or call.task.open event means a live caller is waiting. Do the work, then push the facts; they reach the call immediately. The hosted voice phrases them in its own words (it never reads your text aloud) and keeps them for the rest of the call.

Body fields (send as arguments next to call_id):

  • context: the facts, e.g. "John emailed yesterday about an invoice." Aliases: summary, answer, response, reply, text, result, message.
  • disposition: partial (one real fact so far; spoken now, task stays open), progress (a note, not spoken, task stays open), done (default), failed or noop (settle the task; noop needs no context), or facts (call facts at any time without turn_id, e.g. a call-start briefing).
  • turn_id, push_token: as the parameters below.

Auth: pass the event's push_token as token. An AgentLine API key as Authorization: Bearer also works; OAuth tokens do not.

Returns {"delivered": true, "status", "call_id", "turn_id"}; status "duplicate" means an identical retry was already accepted. HTTP 409: the turn is stale or cancelled, so do not reuse this context. HTTP 410: the call ended; stop working on this request.

post/v1/calls/{call_id}/context

Request

  • Base URL: https://api.agentline.cloud
  • URL: https://api.agentline.cloud/v1/calls/{call_id}/context
  • Auth: none declared

Path parameters

call_idstring required

ID (call_...) of the live call, from the call.utterance or call.task.open event.

Query parameters

tokenstring nullable

The push_token from the call.utterance or call.task.open event. Authorizes this push for that call; same as the X-Push-Token header or a push_token body field.

turn_idstring nullable

The exact turn_id from the event, identifying the question being answered. Can also be sent in the body. Required except for disposition=facts.

Headers

X-Push-Tokenstring nullable
authorizationstring nullable

Request body

object required

Response

Successful Response

unknown required

Changes

No recorded changes to this operation across all 1 revision of this API.