[
  {
    "provider": "anthropic",
    "object": "Message",
    "kind": "response",
    "description": "Response of POST /v1/messages (and message_start payload).",
    "fields": {
      "id": "string (msg_…)",
      "type": "'message'",
      "role": "'assistant'",
      "model": "string (resolved id)",
      "content": "ContentBlock[]",
      "stop_reason": "StopReason|null (null only in message_start)",
      "stop_sequence": "string|null",
      "stop_details": "RefusalStopDetails|null (null unless refusal)",
      "container": "Container|null {id, expires_at, skills[]}",
      "usage": "Usage",
      "context_management (beta)": "{applied_edits: []}",
      "diagnostics (beta)": "cache-miss reasons",
      "input_transformations (beta)": "thinking_dropped|thinking_mismatch_allowed[]"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": {
      "model": "claude-haiku-4-5-20251001",
      "id": "msg_011CfBxdcZj7KMHsf2wSPauQ",
      "type": "message",
      "role": "assistant",
      "content": [
        {
          "type": "text",
          "text": "OK."
        }
      ],
      "container": null,
      "stop_reason": "end_turn",
      "stop_sequence": null,
      "stop_details": null,
      "usage": {
        "input_tokens": 11,
        "cache_creation_input_tokens": 0,
        "cache_read_input_tokens": 0,
        "cache_creation": {
          "ephemeral_5m_input_tokens": 0,
          "ephemeral_1h_input_tokens": 0
        },
        "output_tokens": 5,
        "service_tier": "standard",
        "inference_geo": "not_available"
      }
    },
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "Usage",
    "kind": "response",
    "description": "Billing/rate-limit usage. Total input = input_tokens + cache_creation_input_tokens + cache_read_input_tokens. output_tokens is non-zero even for empty text (except max_tokens=0 pre-warm: 0).",
    "fields": {
      "input_tokens": "int",
      "output_tokens": "int",
      "cache_creation_input_tokens": "int|null",
      "cache_read_input_tokens": "int|null",
      "cache_creation": "{ephemeral_5m_input_tokens, ephemeral_1h_input_tokens}|null",
      "output_tokens_details": "{thinking_tokens}|null (present when thinking ran)",
      "server_tool_use": "{web_search_requests, web_fetch_requests}|null",
      "service_tier": "'standard'|'priority'|'batch'|null",
      "inference_geo": "string|null — live value 'not_available' on Haiku 4.5 (value not enumerated in docs)",
      "iterations (beta)": "per-iteration usage entries type message|compaction|advisor_message|fallback_message",
      "speed (beta)": "'standard'|'fast'|null",
      "fallback_credit (beta)": "{token, status}"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "MessageDeltaUsage",
    "kind": "streaming",
    "description": "Cumulative usage in message_delta.",
    "fields": {
      "input_tokens": "int|null",
      "output_tokens": "int",
      "cache_creation_input_tokens": "int|null",
      "cache_read_input_tokens": "int|null",
      "output_tokens_details": "{thinking_tokens}|null",
      "server_tool_use": "ServerToolUsage|null"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "StopReason",
    "kind": "enum",
    "description": "Why generation stopped. In streaming: null in message_start, set in message_delta.",
    "fields": {
      "end_turn": "natural end — use the response (empty 2–3-token end_turn responses can follow tool results)",
      "max_tokens": "hit max_tokens or model max — raise max_tokens / continue; truncated tool_use blocks must be regenerated",
      "stop_sequence": "one of stop_sequences emitted — read `stop_sequence`; matched text excluded from content",
      "tool_use": "model calls client tool(s) — run them, return tool_result blocks (only) in the next user message; a server_tool_use without result finishes later",
      "pause_turn": "server-tool loop hit its iteration limit (default 10) — resend the assistant content as-is to continue",
      "refusal": "safety classifier stopped the response (HTTP 200) — read stop_details.category, retry on a fallback model",
      "model_context_window_exceeded": "output filled the context window — treat as truncated (Sonnet 4.5+ without beta; older models need model-context-window-exceeded-2025-08-26)",
      "compaction (beta)": "stopped after producing a compaction block (compact_20260112 with pause_after_compaction / compaction param)"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/build-with-claude/handling-stop-reasons",
    "live_observed": [
      "end_turn",
      "max_tokens",
      "stop_sequence",
      "tool_use"
    ]
  },
  {
    "provider": "anthropic",
    "object": "RefusalStopDetails",
    "kind": "response",
    "description": "stop_details when stop_reason=refusal.",
    "fields": {
      "type": "'refusal'",
      "category": "'cyber'|'bio'|'frontier_llm'|'reasoning_extraction'|'general_harms'|null",
      "explanation": "string|null (unstable text)"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "Container",
    "kind": "response",
    "description": "Code-execution container info.",
    "fields": {
      "id": "string",
      "expires_at": "date-time",
      "skills": "[{type: anthropic|custom, skill_id, version}]|null"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages",
    "live_note": "null on every plain request"
  },
  {
    "provider": "anthropic",
    "object": "ModelInfo",
    "kind": "response",
    "description": "GET /v1/models item.",
    "fields": {
      "type": "'model'",
      "id": "string",
      "display_name": "string",
      "created_at": "RFC3339",
      "max_input_tokens": "int|null",
      "max_tokens": "int|null",
      "capabilities": "{batch, citations, code_execution, context_management{clear_tool_uses_20250919, clear_thinking_20251015, compact_20260112}, effort{low..max}, image_input, pdf_input, structured_outputs, thinking{types{enabled, adaptive}}} each {supported: bool}"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": {
      "type": "model",
      "id": "claude-haiku-4-5-20251001",
      "display_name": "Claude Haiku 4.5",
      "created_at": "2025-10-15T00:00:00Z",
      "max_input_tokens": 200000,
      "max_tokens": 64000
    },
    "source": "https://platform.claude.com/docs/en/api/models/list"
  },
  {
    "provider": "anthropic",
    "object": "Completion (legacy)",
    "kind": "response",
    "description": "POST /v1/complete response.",
    "fields": {
      "type": "'completion'",
      "id": "compl_…",
      "completion": "string (up to, excluding, the stop sequence)",
      "model": "string",
      "stop_reason": "'stop_sequence'|'max_tokens'|null"
    },
    "status": [
      "DOCUMENTED",
      "LEGACY",
      "DEPRECATED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/completions"
  },
  {
    "provider": "anthropic",
    "object": "ErrorResponse",
    "kind": "error",
    "description": "All errors: JSON with top-level error{type,message} and request_id (mirrors the request-id header). Streaming errors omit request_id.",
    "fields": {
      "type": "'error'",
      "error.type": "invalid_request_error|authentication_error|billing_error|permission_error|not_found_error|conflict_error|request_too_large|rate_limit_error|api_error|timeout_error|overloaded_error",
      "error.message": "string",
      "request_id": "req_…"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": {
      "type": "error",
      "error": {
        "type": "not_found_error",
        "message": "model: claude-does-not-exist"
      },
      "request_id": "req_011CfBxeBpDojVzndwYnobEw"
    },
    "source": "https://platform.claude.com/docs/en/api/errors"
  },
  {
    "provider": "anthropic",
    "object": "MessageTokensCount",
    "kind": "response",
    "description": "POST /v1/messages/count_tokens response.",
    "fields": {
      "input_tokens": "int (estimate; system-added tokens included but not billed)"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": {
      "input_tokens": 11
    },
    "source": "https://platform.claude.com/docs/en/api/messages/count_tokens"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:text",
    "kind": "content_block (request+response)",
    "description": "Plain text; response may carry citations[].",
    "fields": {
      "type": "'text'",
      "text": "string",
      "citations": "TextCitation[]|null",
      "cache_control (request)": "CacheControlEphemeral|null"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": {
      "type": "text",
      "text": "OK."
    },
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:image",
    "kind": "content_block (request)",
    "description": "Image input: base64 (jpeg/png/gif/webp), url, or Files API file. Optional transformations.oversized_image downsize|error.",
    "fields": {
      "type": "'image'",
      "source": "{type: base64, media_type, data} | {type: url, url} | {type: file, file_id}",
      "transformations": "{oversized_image}|null",
      "cache_control": "…"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages",
    "live_note": "1x1 PNG counted 5 extra tokens via count_tokens"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:document",
    "kind": "content_block (request)",
    "description": "Document input: base64 PDF, plain text, custom content blocks, url, or file; optional title/context/citations.enabled.",
    "fields": {
      "type": "'document'",
      "source": "{type: base64, media_type: application/pdf, data} | {type: text, media_type: text/plain, data} | {type: content, content} | {type: url, url} | {type: file, file_id}",
      "title": "string|null",
      "context": "string|null",
      "citations": "{enabled: bool}|null",
      "cache_control": "…"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages",
    "live_note": "text document + citations.enabled counted 562 tokens via count_tokens (11 without) — citations add fixed overhead"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:search_result",
    "kind": "content_block (request)",
    "description": "Your own search results with citations support.",
    "fields": {
      "type": "'search_result'",
      "source": "string",
      "title": "string",
      "content": "TextBlockParam[]",
      "citations": "{enabled}|null",
      "cache_control": "…"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:thinking",
    "kind": "content_block (request+response)",
    "description": "Reasoning block; replay unchanged (signature verified).",
    "fields": {
      "type": "'thinking'",
      "thinking": "string",
      "signature": "string"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:redacted_thinking",
    "kind": "content_block (request+response)",
    "description": "Encrypted reasoning; replay `data` unchanged.",
    "fields": {
      "type": "'redacted_thinking'",
      "data": "string"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:tool_use",
    "kind": "content_block (request+response)",
    "description": "Client tool call.",
    "fields": {
      "type": "'tool_use'",
      "id": "toolu_…",
      "name": "string",
      "input": "object",
      "caller": "{type: direct}|{type: code_execution_2025…, tool_id}",
      "toolset_name": "string|null"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": {
      "type": "tool_use",
      "id": "toolu_01S85RZWHSCzo537XxQrQw9e",
      "name": "get_weather",
      "input": {
        "city": "Paris"
      },
      "caller": {
        "type": "direct"
      }
    },
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:tool_result",
    "kind": "content_block (request)",
    "description": "Result for a tool_use; content string or blocks (text, image, search_result, document, tool_reference, browser_state).",
    "fields": {
      "type": "'tool_result'",
      "tool_use_id": "string",
      "content": "string|Block[]",
      "is_error": "bool",
      "toolset_name": "string|null",
      "cache_control": "…"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages",
    "live_note": "missing tool_result → 400 'tool_use ids were found without tool_result blocks immediately after'"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:server_tool_use",
    "kind": "content_block (request+response)",
    "description": "Server tool call (web_search, web_fetch, code_execution, bash_code_execution, text_editor_code_execution, tool_search_tool_regex, tool_search_tool_bm25; beta adds advisor).",
    "fields": {
      "type": "'server_tool_use'",
      "id": "srvtoolu_…",
      "name": "enum",
      "input": "object",
      "caller": "…"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:web_search_tool_result",
    "kind": "content_block (request+response)",
    "description": "Server web search result.",
    "fields": {
      "type": "'web_search_tool_result'",
      "tool_use_id": "srvtoolu_…",
      "content": "web_search_result[] {type, url, title, encrypted_content, page_age} | {type: web_search_tool_result_error, error_code}",
      "error_code enum": "invalid_tool_input|unavailable|max_uses_exceeded|too_many_requests|query_too_long|request_too_large"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:web_fetch_tool_result",
    "kind": "content_block (request+response)",
    "description": "Server web fetch result.",
    "fields": {
      "type": "'web_fetch_tool_result'",
      "tool_use_id": "srvtoolu_…",
      "content": "{type: web_fetch_result, url, content: document, retrieved_at} | {type: web_fetch_tool_result_error, error_code}",
      "error_code enum": "invalid_tool_input|url_too_long|url_not_allowed|url_not_in_prior_context|url_not_accessible|unsupported_content_type|too_many_requests|max_uses_exceeded|unavailable|content_too_large"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:code_execution_tool_result",
    "kind": "content_block (request+response)",
    "description": "Code execution result.",
    "fields": {
      "type": "'code_execution_tool_result'",
      "tool_use_id": "srvtoolu_…",
      "content": "{type: code_execution_result, stdout, stderr, return_code, content: code_execution_output[] {file_id}} | {type: code_execution_tool_result_error, error_code}",
      "error_code enum": "invalid_tool_input|unavailable|too_many_requests|execution_time_exceeded"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:bash_code_execution_tool_result",
    "kind": "content_block (request+response)",
    "description": "Bash execution result (code_execution_20250825+).",
    "fields": {
      "type": "'bash_code_execution_tool_result'",
      "content": "{type: bash_code_execution_result, stdout, stderr, return_code, content[]} | error",
      "error_code enum": "invalid_tool_input|unavailable|too_many_requests|execution_time_exceeded|output_file_too_large"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:text_editor_code_execution_tool_result",
    "kind": "content_block (request+response)",
    "description": "Text editor in container result.",
    "fields": {
      "type": "'text_editor_code_execution_tool_result'",
      "content": "view_result {content, file_type, num_lines, start_line, total_lines} | create_result {is_file_update} | str_replace_result {lines, new_lines, new_start, old_lines, old_start} | error",
      "error_code enum": "invalid_tool_input|unavailable|too_many_requests|execution_time_exceeded|file_not_found"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:tool_search_tool_result",
    "kind": "content_block (request+response)",
    "description": "Tool search result.",
    "fields": {
      "type": "'tool_search_tool_result'",
      "content": "{type: tool_search_tool_search_result, tool_references: tool_reference[]} | {type: tool_search_tool_result_error, error_code}",
      "error_code enum": "invalid_tool_input|unavailable|too_many_requests|execution_time_exceeded"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:container_upload",
    "kind": "content_block (request+response)",
    "description": "File placed into the code-execution container.",
    "fields": {
      "type": "'container_upload'",
      "file_id": "string"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:tool_reference",
    "kind": "content_block (request (inside tool_result))",
    "description": "Reference to a deferred tool (tool search).",
    "fields": {
      "type": "'tool_reference'",
      "tool_name": "string"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:browser_state",
    "kind": "content_block (request (inside tool_result))",
    "description": "Browser toolset state (browser_toolset_20260801).",
    "fields": {
      "type": "'browser_state'",
      "…": "tabs, changes, screenshot"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:mcp_tool_use",
    "kind": "content_block (response (beta))",
    "description": "Call to a remote MCP server tool.",
    "fields": {
      "type": "'mcp_tool_use'",
      "id": "string",
      "name": "string",
      "server_name": "string",
      "input": "object"
    },
    "status": [
      "DOCUMENTED",
      "BETA"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/beta/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:mcp_tool_result",
    "kind": "content_block (response (beta))",
    "description": "Result from a remote MCP tool.",
    "fields": {
      "type": "'mcp_tool_result'",
      "tool_use_id": "string",
      "is_error": "bool",
      "content": "string|TextBlock[]"
    },
    "status": [
      "DOCUMENTED",
      "BETA"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/beta/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:advisor_tool_result",
    "kind": "content_block (response (beta))",
    "description": "Advisor tool result (advisor-tool-2026-03-01).",
    "fields": {
      "type": "'advisor_tool_result'",
      "tool_use_id": "string",
      "content": "advisor_result | advisor_redacted_result | error"
    },
    "status": [
      "DOCUMENTED",
      "BETA"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/beta/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:compaction",
    "kind": "content_block (request+response (beta))",
    "description": "Signed summary replacing earlier messages; round-trip verbatim (null content = failed compaction, treated as no-op).",
    "fields": {
      "type": "'compaction'",
      "content": "string|null",
      "encrypted_content": "string|null",
      "signature": "string|null"
    },
    "status": [
      "DOCUMENTED",
      "BETA"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/beta/messages"
  },
  {
    "provider": "anthropic",
    "object": "ContentBlock:fallback",
    "kind": "content_block (response (beta))",
    "description": "Boundary where one model's output gives way to a fallback model (streams as start/stop pair without deltas).",
    "fields": {
      "type": "'fallback'",
      "from": "{model}",
      "to": "{model}",
      "trigger": "{type: refusal, …}"
    },
    "status": [
      "DOCUMENTED",
      "BETA"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/beta/messages"
  },
  {
    "provider": "anthropic",
    "object": "TextCitation",
    "kind": "response",
    "description": "Citation variants inside text.citations[] / citations_delta.",
    "fields": {
      "char_location": "{cited_text, document_index, document_title, start_char_index, end_char_index, file_id}",
      "page_location": "{…, start_page_number, end_page_number}",
      "content_block_location": "{…, start_block_index, end_block_index}",
      "web_search_result_location": "{cited_text, url, title, encrypted_index}",
      "search_result_location": "{cited_text, source, title, search_result_index, start_block_index, end_block_index}"
    },
    "status": [
      "DOCUMENTED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  },
  {
    "provider": "anthropic",
    "object": "CacheControlEphemeral",
    "kind": "request",
    "description": "Cache breakpoint marker.",
    "fields": {
      "type": "'ephemeral'",
      "ttl": "'5m' (default) | '1h'"
    },
    "status": [
      "DOCUMENTED",
      "LIVE_VERIFIED"
    ],
    "example": null,
    "source": "https://platform.claude.com/docs/en/api/messages"
  }
]
