projects

Export workspace messages (Preview)

Plan: Enterprise

Allows workspace admins and owners to start a one-off export of user-authored messages from the current main chat history of projects visible to them. Project and user filters may be combined; when both are supplied, only messages matching both are exported. The export defaults to the preceding 90 days and is delivered as a ZIP containing JSONL. Poll the returned export ID; completed files expire after seven days. Filter options and delivery metadata may change before graduation.

This operation is in public preview (beta) and served under /v1beta. Request and response shapes may change before it graduates to the stable /v1 surface.

post/v1beta/workspaces/{workspace_id}/message-exports

Path parameters

workspace_idstring required

Workspace ID

Workspace ID

Request body

end_datestring

Exclusive RFC3339 end time. Defaults to the request time.

project_idstring

Export only messages from this project. The project must be visible to the caller. May be combined with user_id; both filters must match.

start_datestring

Inclusive RFC3339 start time. Defaults to 90 days before end_date.

user_idstring

Export only messages sent by this user. May be combined with project_id; both filters must match.

Example request

{
  "end_date": "2026-02-01T00:00:00Z",
  "project_id": "prj_01jw3k9m2xq8r5v0c7d4e6f2gh",
  "start_date": "2026-01-01T00:00:00Z",
  "user_id": "Xy7Kd2Lm9Qp4Rt6Vw8Zc1Bn3Fh5"
}

Response

Accepted

export_idstring required

Export ID used to poll status.

status'running' required

Initial export status (running).

Example response

{
  "export_id": "0195b2c3-6a7d-4f3e-9a1b-2c3d4e5f6a7b"
}

Changes