Skip to main content
Append an item to a thread session object.

POST /revisions/:id/data/command (Command: post_session_thread_item)

Request Body

ParameterTypeRequiredDescription
enginestringYesMust be workflow_blobhub.
commandstringYesMust be post_session_thread_item.
session_idstringYesThe ID of the session that owns the thread envelope.
aliasstringYesAlias of the thread session object.
contentarray of objectYesArray of content blocks. Each block must have a type field ("text" or "json"), plus a text string or a json value respectively.
parent_idstringNoOptional parent item id. Stored only.
metadataobjectNoOptional arbitrary JSON.

Response

Returns the persisted item with server-stamped id, created_at, user_id, and the original/derived fields.
ParameterTypeDescription
itemobjectThe persisted thread item, including server-stamped id, created_at, user_id, and revision_id.

Errors

  • invalid_thread_envelope — the alias does not exist or its value.type is not "thread".
  • thread_item_too_large — the serialized item exceeds the server-side size cap.

Example

{
  "engine": "workflow_blobhub",
  "command": "post_session_thread_item",
  "session_id": "sess_001",
  "alias": "onboarding_thread",
  "content": [
    { "type": "text", "text": "Hello, world." }
  ]
}
{
  "item": {
    "id": "itm_01H...",
    "session_id": "sess_001",
    "revision_id": "rev_001",
    "alias": "onboarding_thread",
    "created_at": "2026-05-22T22:00:00.000000+00:00",
    "user_id": "usr_001",
    "content": [
      { "type": "text", "text": "Hello, world." }
    ]
  }
}

See also