Skip to main content
POST /api/v1/forward/sessions/{session_id} Updates stable session fields. Runtime configuration cannot be changed after session creation.

Headers

HeaderRequiredDescription
AuthorizationYesBearer <PAT>
Content-TypeYesapplication/json
Idempotency-KeyNoOptional idempotency key for unsafe requests.

Path parameters

ParameterTypeRequiredDescription
session_idstringYesSession ID.

Body parameters

ParameterTypeRequiredDescription
titlestringNoNew session title.
metadataobjectNoMetadata merge patch. Provided keys overwrite existing keys; omitted keys remain unchanged.

Example request

curl -s -X POST 'https://api.qoder.com/api/v1/forward/sessions/sess_xxx' \
  -H "Authorization: Bearer $QODER_PAT" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Updated session title",
    "metadata": {
      "source": "mobile",
      "biz_id": "ticket_123"
    }
  }'

Example response

HTTP 200 OK
{
  "id": "sess_xxx",
  "type": "session",
  "identity_id": "idn_xxx",
  "template": {
    "id": "tmpl_support",
    "type": "template",
    "name": "Support assistant",
    "model": "ultimate",
    "version": 3
  },
  "source_type": "api",
  "status": "idle",
  "title": "Updated session title",
  "metadata": {
    "source": "mobile",
    "biz_id": "ticket_123"
  },
  "stats": {
    "active_seconds": 30,
    "duration_seconds": 3600
  },
  "usage": {
    "credits": 12.7
  },
  "archived_at": null,
  "created_at": "2026-06-22T10:00:00Z",
  "updated_at": "2026-06-22T12:00:00Z"
}

Response fields

Returns the updated Session object.

Errors

HTTPTypeCodeTrigger
400invalid_request_errorinvalid_requestInvalid update body.
401authentication_errorauthentication_requiredPAT invalid or expired.
404not_found_errorsession_not_foundSession does not exist.
409conflict_errorsession_archivedSession is archived.

Notes

  • config, resources, and incremental_streaming_enabled are create-time settings and cannot be changed here.

Get a session

Archive a session