Answer: Set the environment variables in ~/.claude/settings.json, including ANTHROPIC_BASE_URL set to https://opencode.ai/inference/anthropic and ANTHROPIC_AUTH_TOKEN set to your oc_sk_... token, and map the opus, sonnet, and haiku aliases to Console models. Leave off the /v1/messages path since Claude Code appends it, and run /status to confirm the base URL and token are active. Status: Confirmed Entry: tool/opencode/settings/configure-claude-code-console Revision: 2 Digest: sha256:2bcfd06f6328f0d9 (changes whenever the content changes) Timeline: Created: 2026-11-13T03:57:01Z Last changed: 2026-11-19T13:36:05Z (verification command: — → /status) Last verified: 2026-11-20T13:46:15Z Next check: 2026-11-21T13:46:15Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of settings file | ~/.claude/settings.json | [1] | 2026-11-20 base URL | https://opencode.ai/inference/anthropic | [1] | 2026-11-20 auth token variable | ANTHROPIC_AUTH_TOKEN | [1] | 2026-11-20 opus model | claude-opus-5-5 | [1] | 2026-11-20 sonnet model | claude-sonnet-5-5 | [1] | 2026-11-20 haiku model | claude-haiku-5-5 | [1] | 2026-11-20 path note | /v1/messages | [1] | 2026-11-20 verification command | /status | [1] | 2026-11-20 Sources: [1] opencode. "Claude Code | OpenCode". https://opencode.ai/docs/console/harnesses/claude-code/ Role: primary. Accessed: 2026-11-20T13:46:15Z Quote: "Set the variables in ~/.claude/settings.json to use Console in every session." (Supports: settings file) Quote: ""ANTHROPIC_BASE_URL" : "https://opencode.ai/inference/anthropic"" (Supports: base URL) Quote: "Use ANTHROPIC_AUTH_TOKEN , not ANTHROPIC_API_KEY ." (Supports: auth token variable) Quote: ""ANTHROPIC_DEFAULT_OPUS_MODEL" : "claude-opus-5-5"" (Supports: opus model) Quote: ""ANTHROPIC_DEFAULT_SONNET_MODEL" : "claude-sonnet-5-5"" (Supports: sonnet model) Quote: ""ANTHROPIC_DEFAULT_HAIKU_MODEL" : "claude-haiku-5-5"" (Supports: haiku model) Quote: "Claude Code appends /v1/messages to the base URL, so leave that path off." (Supports: path note) Quote: "Run /status to confirm the base URL and token are active." (Supports: verification command) Snapshot SHA-256: bceabd41b4350f1e8b5be6ed32bab03417739d27e895a6e4d7b590861ee95032 (captured 2026-11-19T13:36:05Z) Verification: Method: Automated extraction from [1] with deepseek-flash (JSON output, thinking disabled). Every value was checked by code to appear verbatim in a quoted passage of [1]. On this check the text of [1] was unchanged since 2026-11-19T13:36:05Z, so the values verified then were kept. Cross-check: not-available at 2026-11-20T13:46:15Z. No independent second source is configured for this entry Last successful check: 2026-11-20T13:46:15Z Last attempt: 2026-11-20T13:46:15Z Notes and limitations: Extracted automatically from a single official source (section "Configure"). Related: https://latestn.com/tool/opencode/settings/configure-cli-plugins How do I configure plugins for the opencode CLI in cli.json? https://latestn.com/tool/opencode/settings/configure-instructions How do I configure custom instruction files in opencode? https://latestn.com/tool/opencode/settings/configure-proxy How do I configure a proxy for opencode using HTTP_PROXY, HTTPS_PROXY, and NO_PROXY? https://latestn.com/tool/opencode/settings/compaction-buffer-setting How do I configure the compaction buffer setting in opencode? https://latestn.com/tool/opencode/settings/config-file-locations Where does opencode look for its config file and in what locations? https://latestn.com/tool/opencode/settings/config-variables How do I set environment variables or reference files in opencode config? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-19T13:36:05Z | changed | verification command: — → /status | [1] 2026-11-19T13:36:05Z | changed | logout step: /logout → — | [1] 2026-11-13T03:57:01Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/opencode/settings/configure-claude-code-console/latest Challenge this entry: Open challenges: None How: If a value here is wrong or out of date, send what is wrong and a link to evidence. Challenges are queued and checked against the evidence; they do not change the entry by themselves. If the entry changes as a result, the change log says so. Form: https://latestn.com/dispute/tool/opencode/settings/configure-claude-code-console POST: https://latestn.com/dispute/tool/opencode/settings/configure-claude-code-console with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/opencode/settings/configure-claude-code-console?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). How do I configure Claude Code to use OpenCode Console? Revision 2, last verified 2026-11-20T13:46:15Z. https://latestn.com/tool/opencode/settings/configure-claude-code-console (accessed 2026-11-21T09:52:28Z). @misc{LatestN_tool_opencode_settings_configure_claude_code_console_r2, title = {How do I configure Claude Code to use OpenCode Console?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/opencode/settings/configure-claude-code-console}}, note = {Revision 2; digest sha256:2bcfd06f6328f0d9; last verified 2026-11-20T13:46:15Z; accessed 2026-11-21T09:52:28Z} } Reuse: License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) Attribution: Copying and adapting are allowed, including commercially, if you credit LatestN and link to the entry you used. Each entry ends with a ready-made citation. URL: https://latestn.com/tool/opencode/settings/configure-claude-code-console