v27

latestOpenAPI 3.1.0raw.githubusercontent.com2026-07-2193427579.9 KB
Responses

Compact a conversation. [alpha]

[alpha] Compresses conversation history into a smaller representation while preserving context. This endpoint is in alpha and may change without notice.

post/v1/responses/compact

Request body

instructionsstring nullable

Instructions to guide the compaction.

previous_response_idstring nullable

ID of a previous response whose history to compact.

prompt_cache_keystring nullable

A key to use when reading from or writing to the prompt cache.

parallel_tool_callsboolean nullable

Whether to enable parallel tool calls. Accepted for compatibility but not used during compaction.

Response

Successful Response

idstring required
created_atinteger required
object'response.compaction'