Archives a session: sets status to the terminal state terminated, populates archived_at with the archive time, and event history remains queryable.
Prerequisites
Endpoint and authentication configured. For details, see Overview and authentication.
Endpoint
POST /sessions/{session_id}/archive
Request example
Response fieldsThe response is a Session object with the following fields:idstringSession IDtypestringAlways sessionstatusstringSet to terminated (terminal state) after archivingagentobjectAgent configuration snapshotenvironment_idstringThe bound environment IDtitle / metadatastring / objectSession title and business metadataarchived_atstringArchive time, ISO 8601; this field is always non-null in responses from the archive endpointcreated_at / updated_atstringCreation/last update timerequest_idstringUnique identifier for this request | Response exampleReturns the full session object withstatus set to terminated and archived_at populated with the archive time. |