FruxonDocs
ApiEmbed widget

Sends a visitor turn.

The run is queued; the agent's reply arrives asynchronously on the stream (SSE) or messages (poll) endpoints. Requires the session bearer token; a token that doesn't match the route session is rejected (403).

POST
/v1/embed/sessions/{session}/turns

Path Parameters

session*string

The session id from open.

The turn text, and optionally the client's own id for the turn.

text?string
turnId?string|null

The client's own id for this turn, echoed as turnId on the turn's row in the messages listing. A client that drew the turn when it sent it uses that to recognise the row as the same message after a reconnect, rather than drawing it twice. Optional; at most 64 letters, digits, hyphens or underscores.

[key: string]?never

Response Body

curl -X POST "https://api.fruxon.com/v1/embed/sessions/string/turns" \  -H "Content-Type: application/json" \  -d '{}'
Empty
{
  "type": "string",
  "title": "string",
  "status": 0,
  "detail": "string",
  "instance": "string",
  "property1": null,
  "property2": null
}
{
  "type": "string",
  "title": "string",
  "status": 0,
  "detail": "string",
  "instance": "string",
  "property1": null,
  "property2": null
}