Rewind a chat session to before a specific user message — restores both the document and the conversation in one call.
Rewinds a chat session to the state immediately before a specific user message. The document, conversation history, and supporting context all snap back to that point. The text of the reverted message is returned (compose_text) so the caller can edit and resend it. Messages from the reverted turn forward are soft-archived: hidden from active reads but retained for audit. The original conversation is preserved server-side; the restored conversation becomes the active timeline. Rejects with 409 if the session has a chat job in progress or awaiting approval — wait for the job to settle before reverting. Returns 422 (code 'turn_has_no_restore_point') when the turn recorded no restore point — typically because the message before it did not finish normally; the response carries revertable_turns, a possibly-empty list of turns that can be rewound to.
Request
- Base URL: https://api.superdocs.app
- URL: https://api.superdocs.app/v1/sessions/{session_id}/revert
- Auth: HTTP bearer
Path parameters
Headers
Request body
Response
Successful Response
Changes
No recorded changes to this operation across all 1 revision of this API.