Omniscio

OmniscioGuidesNo response from API

No response from API: the first byte never arrived

Last checked against Anthropic's documentation on November 20, 2026. By the Omniscio team. Updated .

What is the exact message?

API Error: No response from API (waited 3m, then 10m on the retry). If a proxy or gateway on your network holds responses until they complete, raise API_TIMEOUT_MS or CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS to wait longer.

The minutes in the brackets are not a countdown you missed. They are a record of the two waits that just ran out, and they change with your settings — 3m and 10m are examples of the defaults, not fixed values.

What does it mean?

Claude Code sent a streaming request and the API returned no response headers within the deadline for the first byte. Anthropic documents that Claude Code aborts such a request rather than wait for the full API_TIMEOUT_MS request timeout, and sends it again if the retry budget allows. When the deadline passes for the retry too, the turn ends with this message.

This is not the same as a stream that opens and then goes quiet. The byte-level watchdog starts only once the response headers arrive, so a response that stops sending bytes after that follows the stalled-stream rules instead — that case is a stream idle timeout.

Why are there two different waits?

Because the first attempt and the retry are given different deadlines, for different reasons.

  • First attempt: CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS when you set it to 1 or more, clamped to between 10 seconds and 30 minutes. Otherwise Claude Code uses the byte-level watchdog timeout, so the variables that change that timeout change this wait too. Either way, Claude Code adds one second for every 32KB of request body.
  • Retry: one second less than API_TIMEOUT_MS, just under 10 minutes by default, so the retry can outlast a proxy or gateway that holds the response until generation completes.
  • On Amazon Bedrock: the retry uses the same deadline as the first attempt, which is why the message shows one duration instead of two.
  • With API_TIMEOUT_MS set to 0 (except on Bedrock): the retry waits 10 minutes plus one second per 32KB, or as long as the first attempt if that is longer.

Two limits matter when you tune this. Neither wait exceeds one second less than a positive API_TIMEOUT_MS, and a positive API_TIMEOUT_MS under 11 seconds turns the deadline off entirely.

How do I fix it?

  1. Send the message again. Anthropic's first step. Your original message is still in the conversation, so for a long prompt you can type try again instead of pasting the whole thing.
  2. If it repeats, treat it as a network or proxy problem. That is Anthropic's own instruction, and the checks live on the connection errors page. To see whether a proxy is even configured, check all four variables — env | grep -i proxy, or Get-ChildItem Env:*proxy* in PowerShell — and the env block of your settings file, since Anthropic documents that Claude Code uses whichever of https_proxy, HTTPS_PROXY, http_proxy and HTTP_PROXY is set first.
  3. If a proxy or gateway holds responses until they complete, raise API_TIMEOUT_MS so the retry waits longer than the hold. Set it in the shell that launches Claude Code, for example export API_TIMEOUT_MS=900000 on macOS or Linux, or $env:API_TIMEOUT_MS = "900000" in PowerShell, then start claude from that shell.
  4. If the first attempt keeps timing out and the retry then succeeds, raise CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS the same way, so the first attempt waits long enough too.
  5. On Amazon Bedrock, raise both, because there the retry shares the first attempt's deadline.

Watch the floor on API_TIMEOUT_MS: Anthropic documents that a positive value under 11 seconds turns the deadline off rather than shortening it, so a small number is worse than no change at all. In an unattended session, setting CLAUDE_CODE_RETRY_WATCHDOG makes Claude Code keep retrying within the retry budget instead of ending the turn.

Which connections run this deadline?

Anthropic's watchdog table lists a first-byte deadline on the direct Anthropic API and on Claude Platform on AWS, including through an HTTPS proxy, but not when ANTHROPIC_BASE_URL or ANTHROPIC_AWS_BASE_URL routes them through a gateway. It is opt-in for a Claude apps gateway session, and on Amazon Bedrock it runs with CLAUDE_ENABLE_BYTE_WATCHDOG_BEDROCK=1. It does not run on Google Cloud's Agent Platform or Microsoft Foundry.

The default is 180 seconds on the direct Anthropic API and 300 seconds on Claude Platform on AWS or Amazon Bedrock, plus one second per 32KB of request body. In a Claude apps gateway session the deadline runs only when you turn it on by setting CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS to 1 or more.

How do I know it is fixed?

  • The turn finishes and Claude's reply streams normally, so the message stops appearing on that prompt.
  • On a turn that used to fail, the reply starts arriving well inside the new wait you set.
  • If you raised the wait and the error still comes back, the hop is not merely slow — work through the network checks rather than raising the timeout again.

Where these answers come from

  • The message, both deadlines, the Bedrock single-duration case, the API_TIMEOUT_MS limits, CLAUDE_CODE_RETRY_WATCHDOG and the four fix steps: Anthropic's error reference, read November 20, 2026.
  • The watchdog table — where the first-byte deadline runs, its 180-second and 300-second defaults, and the byte-level watchdog starting only after the headers: Anthropic's network configuration page, read November 20, 2026.
  • The retry budget and the variables that change it: Anthropic's retry tuning table, read November 20, 2026.

Common questions

What do the two durations in the message mean?

They are how long each attempt waited for the response headers: the first attempt and the retry. Anthropic documents that the retry waits one second less than API_TIMEOUT_MS, just under ten minutes by default, so that it can outlast a proxy that holds a response until generation finishes.

Should I raise API_TIMEOUT_MS or CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS?

API_TIMEOUT_MS is what lengthens the retry's wait. CLAUDE_STREAM_FIRST_BYTE_TIMEOUT_MS lengthens the first attempt, so raise it when the first attempt keeps timing out and the retry then succeeds. On Amazon Bedrock, raise both, because there the retry uses the same deadline as the first attempt.

Will it keep retrying on its own?

Yes, if CLAUDE_CODE_RETRY_WATCHDOG is set: Anthropic documents that Claude Code then keeps retrying within the retry budget instead of ending the turn.

Is this the same as a timeout?

Not quite. API_TIMEOUT_MS is the ceiling on the whole wait for response headers; this message means the shorter first-byte deadline ran out twice before any header arrived. A warning that reads Request timed out is the wider request timeout, which Anthropic documents separately.