Claude Opus 4.8 API

anthropic/claude-opus-4.8
1M tokens · 800 input / 4000 output credits / 1M tokens

Claude Opus 4.8 turns text and image context into code, analysis, and detailed answers for complex agent work, with a 1M-token context window and 128K-token maximum output. Give it the relevant files, constraints, and evidence so it can trace decisions across a long task and return reviewable results.

Claude Opus 4.8

Anthropic · messages

Chat with Claude Opus 4.8

Each model has its own conversation. Switching never sends another model's history, and switching back resumes where you left off. Requests are billed from actual token usage.

Ctrl / ⌘ + Enter to send0 / 32,000

Continue with

Claude Opus 4.8

Claude Opus 4.8 uses ordered conversation messages to produce code, analysis, and text responses. Its 1M-token context supports extensive source files and documents; Claude Messages also accepts image content in a message. Vidgo provides Claude Messages and Chat Completions for synchronous JSON or streamed SSE responses.

Why Choose Claude Opus 4.8?

  • Long-horizon codingKeep connected requirements, source files, and tool results in view while working through a multi-step coding change.

  • Self-checking and issue spottingReview intermediate results, flag possible code flaws or uncertain claims, and correct course before presenting a conclusion.

  • Long-context analysisExamine related reports, repository context, and instructions together in a 1M-token context window to trace a complex decision.

  • Image and document reasoningConnect diagrams, charts, and other image evidence with written context to answer focused questions about the material.

Parameters

ParameterRequirementDescription
modelRequired

Use anthropic/claude-opus-4.8 with either protocol.

messagesRequired

A non-empty ordered array of conversation messages. Each message provides role and content.

max_tokensRequired for Claude Messages

A positive integer setting the output limit; the model maximum is 128,000 tokens. Chat Completions accepts this field optionally.

systemOptional for Claude Messages

System instructions as a string or structured text blocks.

toolsOptional

Definitions of tools available during the model response.

streamOptional

Choose a complete JSON response or an SSE event stream.

Defaultfalsetrue

How to Use

  1. Define the deliverableDescribe the requested code, analysis, or answer together with the constraints and review criteria.

  2. Provide relevant contextAdd source files, conversation history, documents, or image blocks that the task depends on.

  3. Choose the API protocolUse Claude Messages for Claude-compatible requests or Chat Completions for OpenAI-style clients. Set max_tokens to a positive integer for Claude Messages.

  4. Review the resultInspect generated content and token usage, then provide follow-up evidence for the next turn.

Pricing

Vidgo AI measures input and output tokens separately. Each rate below applies per 1M tokens.

UsageRateDetails
Input$4.00 · 800 credits / 1M tokensRequest input tokens.
Output$20.00 · 4000 credits / 1M tokensTokens generated in the response.

Best Use Cases

  • Connected codebase changesUse architecture rules, implementation files, and test evidence to plan and review a multi-file change.

  • Long-document reviewCompare related reports, requirements, and source material to produce a traceable analysis.

  • Visual evidence analysisCombine image content and a focused question to examine a chart, interface, or diagram.

Pro Tips

  • Supply the goal, constraints, relevant files, and acceptance criteria together for connected coding tasks.
  • Ask for findings tied to specific passages or files when analyzing extensive context.
  • Pair an image block with a clear question about the details that matter to the decision.

Usage Notes

  • Claude Opus 4.8 has a 1,000,000-token context window and a 128,000-token maximum API output.
  • The on-page Playground sends Claude Messages requests and offers a 256–8,192-token output control.
  • Use anthropic/claude-opus-4.8 with /v1/messages or /v1/chat/completions.

Related Models

Claude Opus 4.8 API frequently asked questions

What is the Claude Opus 4.8 API?

Claude Opus 4.8 is an Anthropic model for complex coding, long-context analysis, and agent workflows. It turns conversation text and image context into code, explanations, and structured findings. Its 1M-token context window helps carry relevant files and evidence across connected steps, while instructions and tools guide the work. You can call it programmatically or try it from the playground above.

How can Claude Opus 4.8 handle long-running coding tasks?

Give Claude Opus 4.8 the target behavior, relevant source files, constraints, and test results. It can use that context to connect implementation steps and review its output against the stated criteria.

How much context can Claude Opus 4.8 analyze?

Claude Opus 4.8 has a 1,000,000-token context window. Include the files, reports, and conversation turns needed to compare related evidence across the task.

How do I use images with Claude Opus 4.8 Messages?

Place supported image blocks alongside text in messages.content, then ask a focused question about the chart, diagram, or scene. Claude Opus 4.8 can use that visual evidence in its text response.

How do tools help Claude Opus 4.8 agent workflows?

Define available tools in the API request and state when their results should be checked. The model can return tool calls for your application to execute and continue the conversation with the results.

What output limit applies to Claude Opus 4.8?

The model supports up to 128,000 output tokens through the API. For Claude Messages, set max_tokens to a positive integer; the on-page Playground offers a separate 256–8,192-token control for interactive trials.

What does Claude Opus 4.8 cost on Vidgo AI?

Vidgo AI charges 800 credits ($4.00) per 1M input tokens and 4000 credits ($20.00) per 1M output tokens for Claude Opus 4.8. Review the token usage in the API response and the rates in this page's Pricing section.