#Agent failed before reply

1 messages · Page 1 of 1 (latest)

astral crescent
#

Why am I getting this error, even though my Quota is not reached in Claude Max? Already reconnected.

⚠️ Agent failed before reply: All models failed (2): anthropic/claude-opus-4-6: Provider anthropic is in cooldown (all profiles unavailable) (rate_limit) | anthropic/claude-haiku-4-5: Provider anthropic is in cooldown (all profiles unavailable) (rate_limit).
Logs: openclaw logs --follow

royal jettyBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> âś… Mark Solution

desert smeltBOT
#

That error isn’t about “monthly quota reached” — it’s rate limiting / short-window limits, and OpenClaw is backing off.

  • rate_limit = Anthropic returned a 429 (too many requests / concurrency / window exhausted).
  • Provider anthropic is in cooldown (all profiles unavailable) = OpenClaw marked all your Anthropic auth profiles as temporarily unusable and won’t even try them until the cooldown expires. Reconnecting doesn’t clear that; it clears automatically after a bit (can grow up to ~1h if it keeps failing repeatedly).

Also: Claude Max (claude.ai) “quota” ≠ Anthropic API limits. Even with a Max subscription (setup-token path), you can still hit 429-style limits for the current window.

What to do / what to paste so we can confirm quickly:

  1. Check version (matters for cooldown behavior):
openclaw --version
  1. See exactly what’s in cooldown:
#
openclaw models status --json

Look for auth.unusableProfiles / cooldownUntil.

  1. Tail logs and find the first 429 (the line before the cooldown starts):
openclaw logs --follow

Common causes:

  • Multiple agents / heartbeats / crons firing in parallel (hits RPM/concurrency).
  • Spamming messages quickly in a thread (OpenClaw will try to keep up → 429).
  • Shared Anthropic credential used by more than one OpenClaw instance.

Mitigations:

  • Wait for the cooldown to expire, then retry.
astral crescent
#

09:19:25 info gateway/channels/whatsapp/outbound {"subsystem":"gateway/channels/whatsapp/outbound"} Sent reaction "đź‘€" -> message 3B86B5FF797F25E60B02
09:19:25 info web-outbound {"module":"web-outbound","correlationId":"4a170926-6570-491e-a0eb-e99073ab1962","chatJid":"sha256:a31218e534d2","messageId":"3B86B5FF797F25E60B02"} {"chatJid":"sha256:a31218e534d2","messageId":"3B86B5FF797F25E60B02","emoji":"đź‘€"} sent reaction
09:19:25 error Embedded agent failed before reply: All models failed (2): anthropic/claude-opus-4-6: Provider anthropic is in cooldown (all profiles unavailable) (rate_limit) | anthropic/claude-haiku-4-5: Provider anthropic is in cooldown (all profiles unavailable) (rate_limit)
09:19:25 debug gateway/channels/whatsapp/outbound {"subsystem":"gateway/channels/whatsapp/outbound"} Sent chunk 1/1 to +491701825380 (24ms)
09:19:25 info web-auto-reply {"module":"web-auto-reply","runId":"3a886813-c7ff-4678-8dcf-38fe299a37dc"} {"correlationId":"3B86B5FF797F25E60B02","connectionId":"923b15c7-8006-4edd-9ba8-6c0ee9363190","to":"+491701825380","from":"+84905701642","text":"⚠️ Agent failed before reply: All models failed (2): anthropic/claude-opus-4-6: Provider anthropic is in cooldown (all profiles unavailable) (rate_limit) | anthropic/claude-haiku-4-5: Provider anthropic is in cooldown (all profiles unavaila… (truncated 47 chars)","mediaUrl":null,"mediaSizeBytes":null,"mediaKind":null,"durationMs":27} auto-reply sent (text)
09:19:25 info gateway/channels/whatsapp/outbound {"subsystem":"gateway/channels/whatsapp/outbound"} Auto-replied to +491701825380

desert smeltBOT
#

That message is not “your Claude Max monthly quota is used up” — it’s rate limiting (HTTP 429), and then OpenClaw’s circuit-breaker kicks in:

  • Anthropic returned a rate_limit error at some point (often from burst/concurrency limits, not monthly quota).
  • OpenClaw then marks your Anthropic auth profile(s) as temporarily unusable and reports:
    Provider anthropic is in cooldown (all profiles unavailable).
  • Switching from Opus → Haiku doesn’t help here because it’s the same provider, and the cooldown is applied at the provider/profile level.

Why it can happen even if Claude Max shows quota left:

  • Claude Max UI limits ≠ API / setup-token rate limits. You can have “quota left” but still hit short-window 429s (requests/minute, concurrent requests, burst limits), especially if you have multiple chats/agents/heartbeats/crons firing.

How to confirm + what to do:

  1. Run this and check auth.unusableProfiles (it shows how long until it’s usable again):
openclaw models status --json
  1. In your logs, scroll a bit further up and find the first 429 / rate_limit_error line (that’s the trigger). What you pasted is already the after-effect (cooldown).
astral crescent
#

"unusableProfiles": [
{
"profileId": "anthropic:default",
"provider": "anthropic",
"kind": "cooldown",
"until": 1772013537062,
"remainingMs": 2228512
}
],

#

Can we skip this or turn this off?

desert smeltBOT
#

That snippet answers it: OpenClaw has put your Anthropic auth profile into a timed cooldown.

  • remainingMs: 2228512 = ~37 minutes left
  • until: 1772013537062 = Wed Feb 25 09:58:57 UTC (when it should become eligible again)

So even if Claude Max shows “quota left”, you can still hit short-window 429 rate limits (burst/concurrency/RPM). OpenClaw then backs off and skips Anthropic entirely until that timer expires. Reconnecting won’t clear it, and repeatedly retrying can actually extend/backoff the cooldown.

What I’d do:

  1. Wait until the remainingMs hits ~0 (run openclaw models status --json again to confirm).
  2. If you want to confirm recovery right when it expires, you can do a live check (this is a real request, so don’t spam it):
openclaw models status --probe --probe-provider anthropic

If this keeps happening, the usual cause is multiple parallel requests (heartbeats/crons, multiple chats firing at once, or two OpenClaw instances using the same setup-token). Adding a fallback to a different provider is the pragmatic way to keep replies working during Anthropic cooldowns.

#

Two separate things are happening here:

1) The Anthropic cooldown (rate_limit)

That one you generally don’t want to “turn off”. It’s OpenClaw’s backoff/circuit-breaker after Anthropic returns 429s. If you forcibly bypass it, you’ll usually just keep hammering Anthropic and get more 429s (and longer backoffs).

Best fix is: wait out the cooldown or add a fallback to a different provider (so you still get replies while Anthropic is cooling down).

2) The "[Queued messages while agent was busy]" wrapper

This is configurable. It happens when your queue mode is collect (default), and multiple inbound messages arrive while a run is in-flight, so OpenClaw coalesces them into one follow-up prompt.

If you want to avoid that wrapper, switch queue mode away from collect:

Quick (per-session, from chat)

Send as a standalone message:

  • /queue followup → process each message separately (no “Queued …” bundle)
  • /queue steer → inject new messages into the current run
  • /queue interrupt → abort the current run and run the newest message
#

Reset back to defaults:

  • /queue default (or /queue reset)

Persistent (config)

{
  messages: {
    queue: {
      // global default:
      mode: "followup",

      // or per channel:
      byChannel: {
        whatsapp: "followup",
        // discord: "followup",
      },
#
    },
  },
}

Heads up: switching to followup can increase the number of model calls (and can make rate limits more likely). If you’re already hitting Anthropic 429s, collect is usually the least rate-limit-y mode.

Docs: https://docs.openclaw.ai/concepts/queue

astral crescent
#

But why still cooldown if the model is reachable again?

desert smeltBOT
#

Because the “cooldown” is OpenClaw’s local backoff timer, not a live “is Anthropic reachable?” check.

What typically happens:

  • You hit an Anthropic 429 rate_limit (often burst/concurrency, not “monthly quota”).
  • OpenClaw marks the auth profile (here anthropic:default) as cooldownUntil = now + backoff (exponential: 1m → 5m → 25m → max ~1h if it keeps failing).
  • While that timer is active, OpenClaw will skip using Anthropic to avoid hammering the provider again — even if you can successfully reach Claude again with a light test.

Two extra gotchas:

  • “Reachable again” via a small probe doesn’t mean your real agent run won’t 429 again (real runs often have more tokens / longer context).
  • openclaw models status --probe is a diagnostic; it doesn’t necessarily clear the cooldown state. The cooldown is cleared when it expires (or after a real successful use marks the profile good).

How to tell if something is still re-triggering the cooldown:

  • Run openclaw models status --json twice a couple minutes apart.
    • If until keeps moving forward / remainingMs jumps back up, something (heartbeat/cron/another chat) is still causing 429s in the background.

Fastest practical workaround: add a fallback to a different provider so you still get replies while Anthropic is cooling down (or add a second Anthropic profile so OpenClaw can rotate to a non-cooled-down one).

astral crescent
#

I just upgraded my Anthropic plan and ran openclaw config again do authorize, but it's showing rate limit still

#

@desert smelt

#

⚠️ Agent failed before reply: All models failed (3): anthropic/claude-sonnet-4-6: ⚠️ API rate limit reached. Please try again later. (rate_limit) | openrouter/moonshotai/kimi-k2.5: No API key found for provider "openrouter". Auth store: /home/molt/.openclaw/agents/main/agent/auth-profiles.json (agentDir: /home/molt/.openclaw/agents/main/agent). Configure auth for this agent (openclaw agents add <id>) or copy auth-profiles.json from the main agentDir. (auth) | openrouter/minimax/minimax-m2.1: No API key found for provider "openrouter". Auth store: /home/molt/.openclaw/agents/main/agent/auth-profiles.json (agentDir: /home/molt/.openclaw/agents/main/agent). Configure auth for this agent (openclaw agents add <id>) or copy auth-profiles.json from the main agentDir. (auth).

desert smeltBOT
#

That error is coming from Anthropic API rate limiting, not “Claude Max chat quota”.

In OpenClaw, “Provider anthropic is in cooldown (all profiles unavailable)” means Anthropic returned 429s recently, so OpenClaw put every Anthropic auth profile it knows about into a temporary backoff window. Re-running auth doesn’t instantly clear that window (and if the upstream window hasn’t reset, you’ll just get 429 again).

What to do:

  1. Confirm what credential type you’re using
  • Claude subscription (Max/Pro) via setup-token (supported), or
  • Anthropic API key (separate billing/limits from Claude Max)

Docs: https://docs.openclaw.ai/help/faq#why-am-i-seeing-http-429-ratelimiterror-from-anthropic

  1. Inspect the actual cooldown + reason
    Run:
openclaw models status --json
#

Look for auth.unusableProfiles (it’ll show which anthropic:* profiles are cooling down / disabled and usually why).

Docs: https://docs.openclaw.ai/providers/anthropic#no-available-auth-profile-all-in-cooldownunavailable

  1. If you upgraded Claude Max and are using setup-token
    It can help to generate a fresh setup-token after plan changes:
claude setup-token
# then on the gateway host:
openclaw models auth paste-token --provider anthropic

(or openclaw models auth setup-token --provider anthropic on the gateway host)

  1. If you’re using an Anthropic API key
    Claude Max upgrades won’t affect API limits. You’ll need to check Anthropic Console usage/limits for that org/key (or add another profile/key for rotation).

If you paste the 429 line(s) from openclaw logs --follow (the ones before it says “in cooldown”) + your openclaw --version, I can tell you whether it’s plain RPM/TPM throttling vs the “Extra usage required for long context requests” case.

#

That message is not about your “Claude Max quota” UI — it’s Anthropic returning HTTP 429 (rate limit), so OpenClaw puts all Anthropic auth profiles into a temporary cooldown and then both Opus + Haiku fail with:

Provider anthropic is in cooldown (all profiles unavailable) (rate_limit)

To debug the real cause, please paste:

  1. openclaw --version
  2. The first 429 line(s) you see in:
openclaw logs --follow
  1. Output of:
openclaw models status --json

(look for auth.unusableProfiles — it’ll show which anthropic:* profiles are cooling down and until when)

#

The newer error dump actually answers it:

  1. Anthropic is genuinely rate-limiting you

anthropic/claude-sonnet-4-6: API rate limit reached … (rate_limit)

That’s a 429 / per-window rate limit (RPM/TPM/concurrency), and it can happen even when your “Claude Max quota” page doesn’t look exhausted. OpenClaw then marks Anthropic as in cooldown, which is why you see:

Provider anthropic is in cooldown (all profiles unavailable)

Docs: https://docs.openclaw.ai/help/faq#why-am-i-seeing-http-429-ratelimiterror-from-anthropic

  1. Your fallback models are OpenRouter, but OpenRouter isn’t configured

openrouter/...: No API key found for provider "openrouter"

So when Anthropic cools down, OpenClaw tries your OpenRouter fallbacks and they also fail because there’s no OPENROUTER_API_KEY.

Fix options:

  • Configure OpenRouter (recommended if you want those fallbacks):
#
  openclaw onboard --auth-choice apiKey --token-provider openrouter --token "$OPENROUTER_API_KEY"

Docs: https://docs.openclaw.ai/providers/openrouter

  • Or remove/replace the OpenRouter fallback models so it doesn’t try providers you haven’t authenticated.

If you paste openclaw models status --json (especially the auth.unusableProfiles part), I can tell you how long the Anthropic cooldown is and whether it’s bouncing between “cooldown” vs “disabled (billing/credits)”.

astral crescent
#

"unusableProfiles": [
{
"profileId": "anthropic:default",
"provider": "anthropic",
"kind": "cooldown",
"until": 1773128733400,
"remainingMs": 3590901
}
],

desert smeltBOT
#

Yep — that remainingMs: 3590901 means OpenClaw has put your anthropic:default profile into a ~60 minute cooldown.

That’s expected behavior after repeated 429s: OpenClaw uses exponential backoff 1 min → 5 min → 25 min → 1 hour (cap) for rate-limit/timeouts/auth failures, and stores it in auth-profiles.json under usageStats. Docs: https://docs.openclaw.ai/concepts/model-failover#cooldowns

So right now you’ve basically got two options:

  • Wait ~1 hour for the cooldown to expire, then try again (and ideally reduce how hard you hit Anthropic: fewer parallel requests / smaller prompts).
  • Make sure your fallbacks actually work, because otherwise you’re dead in the water whenever Anthropic throttles:

If you tell me whether you’re authenticating Anthropic via setup-token (Claude Max/Pro) or API key, I can suggest the best “don’t get rate-limited constantly” setup for that path.

astral crescent
#

I just sent a message in Discord and it reset to 59 minutes. How can I force this to be turned off? There is no actual quota limit now

desert smeltBOT
#

You can’t “turn off” that cooldown in any meaningful way — it’s OpenClaw protecting you (and Anthropic) after it actually received a 429.

What’s happening:

  • You send a message → OpenClaw tries Anthropic → Anthropic returns rate_limit (429) → OpenClaw applies exponential backoff (caps at 1 hour) and records it in the auth profile.
  • When you try again before Anthropic is truly ready, you get another 429, so the timer goes right back to ~59 minutes.

So the cooldown isn’t the cause — it’s the symptom that Anthropic is still throttling that credential.

What to do instead (real fixes):

  1. Use a working fallback provider
    Your earlier log showed OpenClaw tried OpenRouter fallbacks but you had no OpenRouter API key, so everything fails when Anthropic throttles.
    Set up OpenRouter (or another provider you have keys for), then the agent can keep replying during Anthropic cooldowns:
    https://docs.openclaw.ai/providers/openrouter

  2. Switch to an Anthropic API key (if you need stable limits)

#

Claude Max subscription (“setup-token”) is supported, but it’s not a guarantee of high/consistent API throughput.
https://docs.openclaw.ai/providers/anthropic#option-a-anthropic-api-key

  1. Wait for the upstream limit window to reset
    Even if Claude.ai shows “quota ok”, the API/subscription token can still be in a separate rate-limit bucket.

Last-resort / not recommended:

  • You can manually delete the stored cooldown from auth-profiles.json, but if Anthropic is still returning 429, it’ll just snap back to 59 minutes again (and you risk hammering the provider).

If you paste the exact 429 line from openclaw logs --follow right before it resets, it’ll usually reveal whether this is plain RPM/TPM throttling vs some other 429 variant.

astral crescent
#

How do I manually delete the Cooldown?

desert smeltBOT
#

To manually clear it you have to edit the auth profile state file (there isn’t a CLI “clear cooldown” command right now).

Important: this file contains secrets/tokens — don’t paste it into Discord. Also: if Anthropic is still returning 429, the cooldown will just come right back.

Steps (safe-ish)

  1. Stop the gateway (so it doesn’t rewrite the file while you edit)
openclaw gateway stop
  1. Back up the auth store
cp ~/.openclaw/agents/main/agent/auth-profiles.json \
   ~/.openclaw/agents/main/agent/auth-profiles.json.bak.$(date +%s)
#
  1. Edit the file
nano ~/.openclaw/agents/main/agent/auth-profiles.json
# (or vim)
  1. Find the "usageStats" section and remove the entry for your profile (likely anthropic:default) or at least delete the cooldownUntil / reset counters.

It’ll look roughly like:

"usageStats": {
  "anthropic:default": {
    "cooldownUntil": 1773...,
    "errorCount": 3,
    ...
  }