HTTP models: SessionMessageConditions – SessionUsageEndpointContract
Exact OpenAPI component declarations. $ref values identify other components in the complete schema.
SessionMessageConditions
Section titled “SessionMessageConditions”{ "properties": { "source": { "anyOf": [ { "$ref": "#/components/schemas/SessionMessageSource" }, { "type": "null" } ] }, "target": { "anyOf": [ { "$ref": "#/components/schemas/SessionMessageTarget" }, { "type": "null" } ] }, "expires_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Expires At" } }, "additionalProperties": false, "type": "object", "title": "SessionMessageConditions", "description": "Optional provenance and delivery constraints; never ordinary metadata."}SessionMessageCursor
Section titled “SessionMessageCursor”{ "properties": { "session_instance_id": { "type": "string", "maxLength": 512, "minLength": 1, "title": "Session Instance Id" }, "through_ordering_key": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "Through Ordering Key" }, "after_priority": { "type": "integer", "maximum": 2.0, "minimum": 0.0, "title": "After Priority" }, "after_ordering_key": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "After Ordering Key" } }, "additionalProperties": false, "type": "object", "required": [ "session_instance_id", "through_ordering_key", "after_priority", "after_ordering_key" ], "title": "SessionMessageCursor", "description": "Incarnation-bound position within a fixed admission high-water mark.\n\nPriority is NEXT_TURN (0), ON_IDLE (1), then unreadable modes (2).\nThe cursor is pagination input, never application access authority."}SessionMessageDeliveryMode
Section titled “SessionMessageDeliveryMode”{ "type": "string", "enum": [ "next_turn", "on_idle" ], "title": "SessionMessageDeliveryMode"}SessionMessageInspection
Section titled “SessionMessageInspection”{ "properties": { "session_id": { "type": "string", "maxLength": 512, "minLength": 1, "title": "Session Id" }, "session_instance_id": { "type": "string", "maxLength": 512, "minLength": 1, "title": "Session Instance Id" }, "records": { "items": { "$ref": "#/components/schemas/SessionMessageInspectionRecord" }, "type": "array", "maxItems": 100, "title": "Records", "default": [] }, "next_cursor": { "anyOf": [ { "$ref": "#/components/schemas/SessionMessageCursor" }, { "type": "null" } ] } }, "additionalProperties": false, "type": "object", "required": [ "session_id", "session_instance_id" ], "title": "SessionMessageInspection", "description": "One protected delivery-priority page and its exact session instance."}SessionMessageInspectionRecord
Section titled “SessionMessageInspectionRecord”{ "properties": { "queue_id": { "type": "string", "maxLength": 512, "minLength": 1, "title": "Queue Id" }, "ordering_key": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 1.0, "title": "Ordering Key" }, "revision": { "type": "string", "pattern": "^[0-9a-f]{64}$", "title": "Revision" }, "status": { "anyOf": [ { "$ref": "#/components/schemas/SessionMessageQueueStatus" }, { "type": "null" } ] }, "validity": { "type": "string", "enum": [ "valid", "unreadable" ], "title": "Validity" }, "message": { "anyOf": [ { "$ref": "#/components/schemas/SessionQueuedMessage" }, { "type": "null" } ] }, "terminal_event_id": { "anyOf": [ { "type": "string", "maxLength": 512, "minLength": 1 }, { "type": "null" } ], "title": "Terminal Event Id" } }, "additionalProperties": false, "type": "object", "required": [ "queue_id", "ordering_key", "revision", "status", "validity" ], "title": "SessionMessageInspectionRecord", "description": "Safe row envelope: unreadable content never becomes deliverable input."}SessionMessageQueueStatus
Section titled “SessionMessageQueueStatus”{ "type": "string", "enum": [ "queued", "delivered", "withdrawn", "quarantined", "stale", "expired" ], "title": "SessionMessageQueueStatus"}SessionMessageSource
Section titled “SessionMessageSource”{ "properties": { "session_id": { "type": "string", "maxLength": 512, "minLength": 1, "title": "Session Id" }, "session_instance_id": { "type": "string", "maxLength": 512, "minLength": 1, "title": "Session Instance Id" }, "run_epoch": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "Run Epoch" }, "transcript_cursor": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "Transcript Cursor" }, "transcript_sha256": { "anyOf": [ { "type": "string", "pattern": "^[0-9a-f]{64}$" }, { "type": "null" } ], "title": "Transcript Sha256" }, "checkpoint_sha256": { "anyOf": [ { "type": "string", "pattern": "^[0-9a-f]{64}$" }, { "type": "null" } ], "title": "Checkpoint Sha256" } }, "additionalProperties": false, "type": "object", "required": [ "session_id", "session_instance_id", "run_epoch", "transcript_cursor" ], "title": "SessionMessageSource", "description": "Exact source observation, checked by the store before first acceptance.\n\nSource observations are historical after admission: identical retries do not\nreinterpret them against a newer source. A copied observation is not access\nauthority; the application must independently authorize the source session."}SessionMessageSourceBody
Section titled “SessionMessageSourceBody”{ "properties": { "include_transcript_digest": { "type": "boolean", "title": "Include Transcript Digest", "default": false }, "include_checkpoint_digest": { "type": "boolean", "title": "Include Checkpoint Digest", "default": false } }, "additionalProperties": false, "type": "object", "title": "SessionMessageSourceBody"}SessionMessageTarget
Section titled “SessionMessageTarget”{ "properties": { "session_instance_id": { "type": "string", "maxLength": 512, "minLength": 1, "title": "Session Instance Id" }, "run_epoch": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "Run Epoch" }, "transcript_cursor": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "Transcript Cursor" } }, "additionalProperties": false, "type": "object", "required": [ "session_instance_id", "run_epoch", "transcript_cursor" ], "title": "SessionMessageTarget", "description": "Expected target immediately before this message's transcript append.\n\nThe instance prevents deletion/recreation from satisfying an old request.\nBoth epoch and permanent transcript cursor must match exactly. Earlier\ndelivered messages advance that cursor; terminal rejection does not. This\ndefinition is independent of the store's delivery batch size."}SessionOperationalSnapshot
Section titled “SessionOperationalSnapshot”{ "properties": { "as_of": { "type": "string", "format": "date-time", "title": "As Of" }, "total_count": { "type": "string", "pattern": "^(0|[1-9]\\d*)$", "title": "Total Count" }, "counts_by_status": { "$ref": "#/components/schemas/SessionStatusCounts" }, "accuracy": { "$ref": "#/components/schemas/AggregateAccuracy" } }, "additionalProperties": false, "type": "object", "required": [ "as_of", "total_count", "counts_by_status", "accuracy" ], "title": "SessionOperationalSnapshot", "description": "Exact current session counts captured by one store-local read snapshot."}SessionOrder
Section titled “SessionOrder”{ "type": "string", "enum": [ "created_at_asc", "created_at_desc", "updated_at_asc", "updated_at_desc", "last_activity_at_asc", "last_activity_at_desc" ], "title": "SessionOrder"}SessionQueuedMessage
Section titled “SessionQueuedMessage”{ "properties": { "queue_id": { "type": "string", "title": "Queue Id" }, "session_id": { "type": "string", "title": "Session Id" }, "idempotency_key": { "type": "string", "title": "Idempotency Key" }, "content": { "type": "string", "title": "Content" }, "message": { "anyOf": [ { "$ref": "#/components/schemas/Message" }, { "type": "null" } ] }, "delivery_mode": { "$ref": "#/components/schemas/SessionMessageDeliveryMode" }, "status": { "$ref": "#/components/schemas/SessionMessageQueueStatus" }, "ordering_key": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 1.0, "title": "Ordering Key" }, "accepted_run_epoch": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "Accepted Run Epoch" }, "accepted_transcript_cursor": { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0, "title": "Accepted Transcript Cursor" }, "accepted_event_id": { "type": "string", "title": "Accepted Event Id" }, "accepted_at": { "type": "string", "format": "date-time", "title": "Accepted At" }, "requested_by": { "anyOf": [ { "$ref": "#/components/schemas/ResolutionActor" }, { "type": "null" } ] }, "delivered_run_epoch": { "anyOf": [ { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0 }, { "type": "null" } ], "title": "Delivered Run Epoch" }, "delivered_transcript_cursor": { "anyOf": [ { "type": "integer", "maximum": 9.223372036854776e+18, "minimum": 0.0 }, { "type": "null" } ], "title": "Delivered Transcript Cursor" }, "delivered_event_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Delivered Event Id" }, "delivered_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Delivered At" }, "conditions": { "$ref": "#/components/schemas/SessionMessageConditions" } }, "additionalProperties": false, "type": "object", "required": [ "queue_id", "session_id", "idempotency_key", "content", "delivery_mode", "status", "ordering_key", "accepted_run_epoch", "accepted_transcript_cursor", "accepted_event_id", "accepted_at" ], "title": "SessionQueuedMessage", "description": "One durable queued user message and its delivery state."}SessionStateResponse
Section titled “SessionStateResponse”{ "properties": { "session_id": { "type": "string", "title": "Session Id" }, "status": { "type": "string", "enum": [ "pending", "running", "interrupting", "completed", "failed", "interrupted" ], "title": "Status" }, "updated_at": { "type": "string", "title": "Updated At" }, "last_activity_at": { "type": "string", "title": "Last Activity At" }, "interruption_cascade": { "type": "string", "enum": [ "none", "pending", "failed" ], "title": "Interruption Cascade" }, "provider_operation": { "$ref": "#/components/schemas/ApiProviderOperationInspection" }, "execution": { "$ref": "#/components/schemas/SessionExecutionState" } }, "additionalProperties": false, "type": "object", "required": [ "session_id", "status", "updated_at", "last_activity_at", "interruption_cascade", "provider_operation", "execution" ], "title": "SessionStateResponse"}SessionStatus
Section titled “SessionStatus”{ "type": "string", "enum": [ "pending", "running", "interrupting", "completed", "failed", "interrupted" ], "title": "SessionStatus"}SessionStatusCounts
Section titled “SessionStatusCounts”{ "properties": { "pending": { "type": "string", "pattern": "^(0|[1-9]\\d*)$", "title": "Pending" }, "running": { "type": "string", "pattern": "^(0|[1-9]\\d*)$", "title": "Running" }, "interrupting": { "type": "string", "pattern": "^(0|[1-9]\\d*)$", "title": "Interrupting" }, "completed": { "type": "string", "pattern": "^(0|[1-9]\\d*)$", "title": "Completed" }, "failed": { "type": "string", "pattern": "^(0|[1-9]\\d*)$", "title": "Failed" }, "interrupted": { "type": "string", "pattern": "^(0|[1-9]\\d*)$", "title": "Interrupted" } }, "additionalProperties": false, "type": "object", "required": [ "pending", "running", "interrupting", "completed", "failed", "interrupted" ], "title": "SessionStatusCounts", "description": "Complete current-session counts for every lifecycle status."}SessionSummaryResponse
Section titled “SessionSummaryResponse”{ "properties": { "session": { "$ref": "#/components/schemas/ApiSession" }, "events": { "$ref": "#/components/schemas/ApiEventSummary" }, "transcript": { "$ref": "#/components/schemas/TranscriptSummary" }, "outcome": { "$ref": "#/components/schemas/ApiSessionOutcome" }, "usage": { "$ref": "#/components/schemas/SessionUsageSummary" } }, "additionalProperties": false, "type": "object", "required": [ "session", "events", "transcript", "outcome", "usage" ], "title": "SessionSummaryResponse"}SessionTopologyRequest
Section titled “SessionTopologyRequest”{ "properties": { "expanded_parent_ids": { "items": { "type": "string", "maxLength": 1024, "minLength": 1 }, "type": "array", "maxItems": 50, "title": "Expanded Parent Ids" }, "child_cursors": { "additionalProperties": { "type": "string", "maxLength": 4096, "minLength": 1 }, "propertyNames": { "maxLength": 1024, "minLength": 1 }, "type": "object", "maxProperties": 50, "title": "Child Cursors" }, "ancestor_depth_limit": { "type": "integer", "maximum": 32.0, "minimum": 1.0, "title": "Ancestor Depth Limit", "default": 32 }, "child_limit": { "type": "integer", "maximum": 100.0, "minimum": 1.0, "title": "Child Limit", "default": 25 }, "linked_task_session_ids": { "items": { "type": "string", "maxLength": 1024, "minLength": 1 }, "type": "array", "maxItems": 50, "title": "Linked Task Session Ids" }, "task_session_cursors": { "additionalProperties": { "type": "string", "maxLength": 4096, "minLength": 1 }, "propertyNames": { "maxLength": 1024, "minLength": 1 }, "type": "object", "maxProperties": 50, "title": "Task Session Cursors" }, "expanded_task_parent_ids": { "items": { "type": "string", "maxLength": 1024, "minLength": 1 }, "type": "array", "maxItems": 50, "title": "Expanded Task Parent Ids" }, "task_child_cursors": { "additionalProperties": { "type": "string", "maxLength": 4096, "minLength": 1 }, "propertyNames": { "maxLength": 1024, "minLength": 1 }, "type": "object", "maxProperties": 50, "title": "Task Child Cursors" }, "task_session_limit": { "type": "integer", "maximum": 100.0, "minimum": 1.0, "title": "Task Session Limit", "default": 25 }, "task_child_limit": { "type": "integer", "maximum": 100.0, "minimum": 1.0, "title": "Task Child Limit", "default": 25 }, "max_result_bytes": { "type": "integer", "maximum": 4194304.0, "minimum": 1024.0, "title": "Max Result Bytes", "default": 1048576 } }, "additionalProperties": false, "type": "object", "title": "SessionTopologyRequest"}SessionTopologyResponse
Section titled “SessionTopologyResponse”{ "properties": { "scope": { "type": "string", "const": "session_focus", "title": "Scope", "default": "session_focus" }, "observed_at": { "type": "string", "format": "date-time", "title": "Observed At" }, "cross_store_atomic": { "type": "boolean", "const": false, "title": "Cross Store Atomic" }, "focus": { "$ref": "#/components/schemas/ApiSessionTopologyNode" }, "ancestors": { "items": { "$ref": "#/components/schemas/ApiSessionTopologyNode" }, "type": "array", "maxItems": 32, "title": "Ancestors" }, "expanded_parents": { "items": { "$ref": "#/components/schemas/ApiSessionTopologyNode" }, "type": "array", "maxItems": 50, "title": "Expanded Parents" }, "branches": { "items": { "$ref": "#/components/schemas/ApiSessionTopologyBranch" }, "type": "array", "maxItems": 50, "title": "Branches" }, "unique_node_count": { "type": "integer", "maximum": 500.0, "minimum": 1.0, "title": "Unique Node Count" }, "task_projection": { "$ref": "#/components/schemas/ApiTaskTopologyProjection" }, "edges": { "items": { "$ref": "#/components/schemas/ApiExecutionTopologyEdge" }, "type": "array", "maxItems": 1500, "title": "Edges" } }, "additionalProperties": false, "type": "object", "required": [ "observed_at", "cross_store_atomic", "focus", "ancestors", "expanded_parents", "branches", "unique_node_count", "task_projection", "edges" ], "title": "SessionTopologyResponse"}SessionTranscriptResponse
Section titled “SessionTranscriptResponse”{ "properties": { "session_id": { "type": "string", "title": "Session Id" }, "messages": { "items": { "$ref": "#/components/schemas/ApiTranscriptMessage" }, "type": "array", "title": "Messages" }, "offset": { "type": "integer", "minimum": 0.0, "title": "Offset" }, "next_offset": { "type": "integer", "minimum": 0.0, "title": "Next Offset" }, "has_more": { "type": "boolean", "title": "Has More" }, "total_messages": { "type": "integer", "minimum": 0.0, "title": "Total Messages" } }, "additionalProperties": false, "type": "object", "required": [ "session_id", "messages", "offset", "next_offset", "has_more", "total_messages" ], "title": "SessionTranscriptResponse"}SessionUsageEndpointContract
Section titled “SessionUsageEndpointContract”{ "properties": { "supported": { "type": "boolean", "title": "Supported" }, "method": { "type": "string", "const": "GET", "title": "Method", "default": "GET" }, "path": { "type": "string", "title": "Path" }, "response_schema": { "type": "string", "const": "SessionUsageSummary", "title": "Response Schema", "default": "SessionUsageSummary" }, "etag_header": { "type": "string", "const": "ETag", "title": "Etag Header", "default": "ETag" }, "conditional_request_header": { "type": "string", "const": "If-None-Match", "title": "Conditional Request Header", "default": "If-None-Match" }, "not_modified_status": { "type": "integer", "const": 304, "title": "Not Modified Status", "default": 304 }, "session_list_include": { "type": "string", "const": "usage", "title": "Session List Include", "description": "Pass as `include` on the session list to embed each session's usage.", "default": "usage" } }, "additionalProperties": false, "type": "object", "required": [ "supported", "path" ], "title": "SessionUsageEndpointContract", "description": "Exact session token usage, maintained incrementally by the session store."}