To enable the Compliance API, see the setup guide.
Set up the Compliance APIMessages
Retrieve remote session messages
GET/v1/compliance/apps/sessions/remote/{claude_remote_session_id}/messages
Retrieve one remote session's transcript: user prompts, assistant responses, and tool calls and results. Thinking blocks and images are not included.