Modelsanthropicclaude-opus-4-8
provideranthropic /

claude-opus-4-8

1750 DZD in 8750 DZD out/ 1M tokens

Claude Opus 4.8 answers directly unless asked to think — the opposite default from the generation that replaced it, and the reason some integrations still prefer it. A plain request returns text immediately, with no reasoning blocks ahead of the answer and no deliberation budget to account for. Adaptive thinking is available per request when a task needs it, and switching it off works at any effort level rather than only below a threshold. It carries a million-token context window with a 128,000-token output ceiling, reads text and images, and offers a fast mode that runs at roughly two and a half times normal speed through a research preview.

PublicJSONStreaming
claude-opus-4-8
Capabilities
ToolsVisionReasoningStructured output
ArchitectureProprietary
Context Window1M

Claude Opus 4.8

An Opus-tier model where reasoning is opt-in. Released 28 May 2026.


The Default Runs the Other Way

This is the difference that matters, and it cuts against the generation above.

A plain request here runs without any reasoning pass. The response opens with text. Nothing deliberates first. On Claude Opus 5, the same request reasons unless you stop it.

Two consequences follow, and both favour this model in specific situations.

Positional access to content still works. No thinking block occupies the first slot, so integrations written before reasoning defaults existed behave as their authors expected.

Latency tracks input and output size, not how difficult the model judged the question. For an interactive endpoint, that consistency is sometimes worth more than a better answer arriving after a variable pause.

Adaptive thinking is available whenever a task needs it:

JSON
{ "thinking": { "type": "adaptive" } }

And turning it off works at any effort level. On the following generation, disabling thinking above high effort returns an error. Here the two settings are independent — max effort with thinking disabled is a valid request.


Fast Mode

A research preview on the Claude API: the model runs at roughly 2.5× normal speed.

Availability is restricted to organisations in the preview programme rather than open to all accounts, so treat it as something to arrange rather than something to enable.

Where it fits: latency-bound paths that still need Opus-tier capability. Where it does not: anything running at volume where the speed is not the binding constraint.


Effort

Five levels, defaulting to high on every surface — the API, Claude Code, and the consumer apps alike.

Anthropic's framing for this release is unusually plain: they describe it as a modest but tangible improvement over its predecessor, fixing comment verbosity and tool-calling issues seen in the version before. That honesty is worth reading as guidance — this is an incremental release, and the effort ladder behaves conventionally rather than as the decisive lever it became in the next generation.

Thinking tokens count toward max_tokens when thinking is enabled. With it off, the ceiling covers the answer alone, which makes budgeting simpler than on a model that always reasons.


Specifications

Model IDanthropic/claude-opus-4-8
Context window1,000,000 tokens — default
Max output128,000 tokens
ThinkingAdaptive — off unless requested
Default efforthigh
Input → outputText and images → text
Reliable knowledge cutoffJanuary 2026
Training data cutoffJanuary 2026
Released28 May 2026
Minimum cacheable prompt1,024 tokens
StatusActive (legacy)

Anthropic publishes no parameter counts, architecture, or weights for Claude models.


Capabilities

CapabilityValue
input_typestext, image
output_typestext
audio_inputNot supported
video_inputNot supported
context_window1000000
max_output_tokens128000
reasoningAdaptive — opt-in
effort_levelslow, medium, high, xhigh, max
thinking_disableSupported at any effort level
streamingSupported
tool_callingSupported
structured_outputSupported
prompt_cachingSupported — 1,024-token minimum
requires_promptYes — text prompt required, image optional

Honesty as a Named Improvement

Anthropic highlighted this specifically at release, and it shows up in measurement rather than in marketing copy.

Independent benchmarking found this model had the lowest incorrect-answer rate among the models tested on every benchmark run — and, notably, it achieved that by abstaining on questions it was uncertain about rather than by answering more questions correctly.

That is a meaningful distinction for anything factual. A model that declines when unsure produces fewer confident wrong answers, which are the expensive kind: they pass review, reach a system of record, and surface much later.

How to use that property. Give it permission to decline explicitly in the system prompt, and treat an "I don't know" as a successful outcome rather than a failure to retry. A model willing to abstain is only useful if your pipeline lets it.


Using Claude Opus 4.8 on DEVUP AI

Base URL: https://api.devupai.com/v1 · Model ID: anthropic/claude-opus-4-8

A direct answer — cURL

No configuration, no reasoning pass.

BASH
curl https://api.devupai.com/v1/chat/completions \
  -H "Authorization: Bearer $DEVUP_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "anthropic/claude-opus-4-8",
    "messages": [
      {
        "role": "user",
        "content": "Our SMS gateway returns 200 for messages that are never delivered. What should we log so the gap becomes visible?"
      }
    ],
    "max_tokens": 8192
  }'

Turning reasoning on — Python

PYTHON
import os
from openai import OpenAI

client = OpenAI(
    api_key=os.environ["DEVUP_API_KEY"],
    base_url="https://api.devupai.com/v1",
)

reply = client.chat.completions.create(
    model="anthropic/claude-opus-4-8",
    messages=[{"role": "user", "content": hard_question}],
    max_tokens=32768,  # reasoning and answer now share this
    extra_body={"thinking": {"type": "adaptive"}},
)

message = reply.choices[0].message

trace = getattr(message, "reasoning_content", None)
if trace:
    logger.debug("reasoning: %d characters", len(trace))

print(message.content)

The ceiling rises from 8,192 to 32,768 between these two examples for one reason: reasoning consumes part of the same budget once enabled. Leaving it where a direct-answer path had it is how a request gets cut off mid-thought.

Routing by task — Python

The shape this model's opt-in default makes natural.

PYTHON
def ask(prompt: str, *, think: bool = False, max_tokens: int | None = None) -> str:
    """Send a request, enabling reasoning only where it changes the answer."""
    payload = {
        "model": "anthropic/claude-opus-4-8",
        "messages": [{"role": "user", "content": prompt}],
        "max_tokens": max_tokens or (32768 if think else 4096),
    }

    if think:
        payload["extra_body"] = {"thinking": {"type": "adaptive"}}

    return client.chat.completions.create(**payload).choices[0].message.content


# Mechanical work — no reasoning, tight ceiling.
ask(f"Summarise this ticket in one sentence:\n\n{ticket}", max_tokens=256)

# Analysis — reasoning on, room to use it.
ask("Why would the same query plan change between staging and production with identical data?", think=True)

On a model where reasoning is the default, this pattern requires the inverse work: remembering to switch it off everywhere it adds nothing.

Giving it room to abstain — Python

Using the property described above rather than fighting it.

PYTHON
GROUNDED = (
    "Answer from the material provided. Where it does not contain the answer, say so plainly and "
    "stop — do not estimate or reach for general knowledge. 'The source does not address this' is "
    "a complete and correct answer."
)

reply = client.chat.completions.create(
    model="anthropic/claude-opus-4-8",
    messages=[
        {"role": "system", "content": GROUNDED},
        {"role": "user", "content": f"{sources}\n\nQuestion: {question}"},
    ],
    max_tokens=8192,
)

This model abstains more readily than most. Permitting it explicitly turns a tendency into a guarantee, and stops a downstream retry loop from grinding at a question that has no answer in the material.

Whole-corpus work — Python

The million-token window, used for what it is there for.

PYTHON
from pathlib import Path

corpus = "\n\n---\n\n".join(
    f"### {path.name}\n{path.read_text(encoding='utf-8')}"
    for path in sorted(Path("agreements").glob("*.txt"))
)

reply = client.chat.completions.create(
    model="anthropic/claude-opus-4-8",
    messages=[
        {
            "role": "system",
            "content": (
                "Review this set of supplier agreements. Find every obligation that appears in one "
                "document and contradicts an obligation in another. Quote both clauses and name "
                "both files. Report only conflicts you can quote."
            ),
        },
        {"role": "user", "content": corpus},
    ],
    max_tokens=32768,
    extra_body={"thinking": {"type": "adaptive"}},
)

Reasoning is enabled here deliberately. Cross-document contradiction is exactly the kind of work where a deliberation pass earns its cost, and exactly the kind where a direct answer misses the relationships the window was holding.

A tool loop — Python

PYTHON
import json

TOOLS = [
    {
        "type": "function",
        "function": {
            "name": "check_delivery",
            "description": "Return delivery status and carrier events for a tracking number.",
            "parameters": {
                "type": "object",
                "properties": {"tracking": {"type": "string"}},
                "required": ["tracking"],
            },
        },
    },
]


def check_delivery(tracking: str) -> dict:
    """Replace with your real carrier integration."""
    raise NotImplementedError


HANDLERS = {"check_delivery": check_delivery}

thread = [{"role": "user", "content": "The customer says parcel DZ4471182 never arrived but the system shows delivered. Find out what happened."}]

CEILING = 15

for step in range(CEILING):
    reply = client.chat.completions.create(
        model="anthropic/claude-opus-4-8",
        messages=thread,
        tools=TOOLS,
        max_tokens=16384,
    )

    message = reply.choices[0].message
    thread.append(message)

    if not message.tool_calls:
        print(message.content)
        break

    for call in message.tool_calls:
        handler = HANDLERS.get(call.function.name)
        if handler is None:
            outcome = {"error": "unknown tool", "name": call.function.name}
        else:
            try:
                outcome = handler(**json.loads(call.function.arguments or "{}"))
            except Exception as exc:
                # Hand the failure back as data rather than ending the run.
                outcome = {"error": type(exc).__name__, "detail": str(exc)}

        thread.append({"role": "tool", "tool_call_id": call.id, "content": json.dumps(outcome)})
else:
    print(f"Stopped at {CEILING} steps without resolving it.")

CEILING is what ends a run that will not end on its own.

Reading a document — Python

PYTHON
import base64

with open("delivery_note.jpg", "rb") as handle:
    encoded = base64.b64encode(handle.read()).decode("utf-8")

reply = client.chat.completions.create(
    model="anthropic/claude-opus-4-8",
    messages=[
        {
            "role": "user",
            "content": [
                {"type": "image_url", "image_url": {"url": f"data:image/jpeg;base64,{encoded}"}},
                {
                    "type": "text",
                    "text": (
                        "List every item and quantity on this delivery note. Where handwriting is "
                        "unclear, mark the entry uncertain rather than choosing a reading."
                    ),
                },
            ],
        }
    ],
    max_tokens=4096,
)

Node.js — DEVUP AI SDK

BASH
npm install devupai
JAVASCRIPT
import DevupAI from "devupai";

const client = new DevupAI({
  apiKey: process.env.DEVUP_API_KEY,
});

const reply = await client.chat.completions.create({
  model: "anthropic/claude-opus-4-8",
  messages: [
    {
      role: "system",
      content:
        "Review this pull request. Raise only changes that would break in production, " +
        "each with the file, the line, and the smallest correct fix.",
    },
    { role: "user", content: diff },
  ],
  max_tokens: 16384,
});

console.log(reply.choices[0]?.message?.content);

Streaming

PYTHON
stream = client.chat.completions.create(
    model="anthropic/claude-opus-4-8",
    messages=[{"role": "user", "content": "Explain when a queue with no dead-letter policy becomes a data-loss problem."}],
    max_tokens=8192,
    stream=True,
)

for chunk in stream:
    if not chunk.choices:
        if getattr(chunk, "usage", None):
            print(f"\n\nin {chunk.usage.prompt_tokens} · out {chunk.usage.completion_tokens}")
        continue

    piece = chunk.choices[0].delta
    if getattr(piece, "content", None):
        print(piece.content, end="", flush=True)

With reasoning off, the first token arrives promptly. That is the behaviour that keeps this model usable in interfaces where a model that always deliberates feels stalled.


Prompt Caching

The minimum cacheable prompt is 1,024 tokens — twice the threshold of the following generation. Short system prompts that would cache on Opus 5 may fall below the line here.

Order the request so the stable material comes first — system instructions, reference documents, schemas — with variable content after it, making the cacheable prefix as long as possible.


Moving to the Next Generation

If you are weighing the upgrade, three things change and two of them break code.

Reasoning becomes the default. Responses may begin with thinking blocks, so positional access to the first content block stops being safe.

Disabling thinking becomes conditional. Above high effort it returns an error rather than working as it does here.

Knowledge moves four months forward, from January to May 2026.

The context window and output ceiling are unchanged, so capacity is not a reason to move. There is also a prompting change worth knowing: verification instructions that help here cause over-verification on the newer model, and should be removed as part of the migration rather than carried across.


Choosing This Model

It fits when predictable behaviour matters more than peak capability — an integration written before reasoning defaults existed, an interactive path where consistent latency is the product, or a downstream system tuned against this model's output.

It also fits where honesty under uncertainty is the priority. Measured abstention on questions it cannot answer is a real property, and for factual or regulated work it is worth more than a marginal capability gain.

Move up when reasoning depth is the limiting factor, or when a knowledge cutoff four months more recent would change your answers.


Limitations

Reasoning is off unless requested. A hard question asked plainly gets a quicker, shallower answer than the model can produce.

Reliable knowledge reaches January 2026. Anything later needs retrieval or a search tool.

Cache threshold is 1,024 tokens, higher than the following generation — short prompts may not qualify.

Text and images only. No audio, no video, no image generation.

Fast mode is a restricted preview, not a setting you can simply enable.

Marked legacy by Anthropic, with a current model available in the same tier.

Internals are undisclosed — no parameter count, no architecture, no weights.

A fast answer is not a checked answer. Verify anything that will act on a system of record.