2026 年 6 月 15 日,Anthropic 會改變無頭 Claude 的成本結構。claude -p、Claude Agent SDK 呼叫、Claude Code GitHub Actions,以及建立在 Agent SDK 上的第三方應用程式,將不再消耗一般 Claude 訂閱額度,而是改用獨立的每月 Agent SDK credit(Anthropic Help Center)。
這聽起來像帳單註腳。其實不是。如果你有 cron jobs、CI reviewers、本機 scripts、Zed 風格的 agent integrations,或包在 claude -p 外面的 wrapper CLIs,這就是「包含在我的方案裡」變成「以美元 credit 計量」的分界線。
我的看法:這個產品邊界是對的,但 Anthropic 的推出方式,讓太多開發者只能透過壞掉的心智模型和 Reddit 討論串才弄懂。互動式 coding 和自動化 agents 是不同工作負載。本來就不該共用同一個 quota。但如果你的團隊默默把 automation 建在用訂閱登入的 Claude Code 之上,6 月 15 日是遷移期限,不是價格公告。

到底哪些會移到新 credit
Anthropic 的說明文章對邊界講得很明確。從 6 月 15 日開始,Claude 訂閱方案上的 Agent SDK 和 claude -p 使用量,會改從新的每月 Agent SDK credit 扣除,並與互動式使用限制分開(Anthropic Help Center)。Agent SDK docs 在 overview 頁面頂端也重複同樣警告(Claude Docs)。
會被新 credit 涵蓋的項目:
| Workflow | Counts against Agent SDK credit? | Notes |
|---|---|---|
claude -p "..." | 是 | Print mode,非互動式 |
| Python 或 TypeScript Claude Agent SDK | 是 | 使用訂閱方案的 Agent SDK credit 時 |
| Claude Code GitHub Actions | 是 | Anthropic 表示此整合建立在 Agent SDK 上 |
| 建立在 Agent SDK 上、並透過你的 Claude 訂閱驗證的第三方應用程式 | 是 | 工具整合最容易踩雷的地方 |
| 終端機或 IDE 裡的互動式 Claude Code | 否 | 仍使用一般訂閱限制 |
| Claude web、desktop、mobile chat | 否 | 仍使用一般訂閱限制 |
| Claude Cowork | 否 | 不屬於這個 credit |
| 使用 Claude Platform API key 的 Agent SDK | 無變化 | Pay-as-you-go 照舊 |
方案 credit 以美元計價:
| Plan | Monthly Agent SDK credit |
|---|---|
| Pro | $20 |
| Max 5x | $100 |
| Max 20x | $200 |
| Team Standard seats | $20 |
| Team Premium seats | $100 |
| Enterprise usage-based | $20 |
| Enterprise seat-based Premium seats | $200 |
Anthropic 也說明,credits 是按使用者分配、不是共用池;會隨帳單週期刷新;未使用 credit 不會展延;而且 credit 必須先領取一次,之後才會自動刷新(Anthropic Help Center)。
最後這點對團隊很重要。一個有 20 位符合資格工程師的 Team 帳號,不會得到一個共享 automation bucket。每個人各自有自己的 credit。如果某個共用 GitHub Action 是用同一位使用者驗證,那那位使用者的 credit 就是瓶頸。
實際斷點:claude -p 不再只是「CLI 使用」
最會讓人意外的指令是 claude -p。
Anthropic 的 CLI reference 把 --print / -p 描述為「Print response without interactive mode」,並提供 --output-format json、--output-format stream-json、--max-turns、--json-schema、--max-budget-usd 這類適合 automation 的 flags(Claude Code CLI reference)。這讓它成為 scripts 的完美膠水:
git diff --staged |
claude -p "Review this diff for security issues. Return JSON." \
--output-format json \
--max-turns 3 \
--max-budget-usd 2
6 月 15 日之後,這在用訂閱驗證的帳號上就是 Agent SDK-credit usage。它不是互動式 Claude Code usage。不是一般 chat usage。也不是通往你方案 quota 的免費側門。
這就是為什麼社群反應這麼尖銳。在目前一個 r/ClaudeCode 討論串裡,開發者正在問 credit 是否按 token/model 計算、$200 實際上能撐多遠、是否必須 opt-in、prompt caching 怎麼算,以及 GitHub Actions 是否包含在內(Reddit)。其中一位留言者說「oh… I didn’t realise it was GH actions too」,這正是風險所在:人們把這次變更理解成 SDK libraries,而不是所有無頭 Claude Code 工作流程。
token 問題的答案基本上是:是。Anthropic 說,超過 credit 的使用量,如果 usage credits 已啟用,就會以標準 API rates 轉到 usage credits。Claude API pricing 目前列出的價格是 Fable 5 每百萬 tokens $10 input / $50 output,Opus 4.8 為 $5 / $25,Sonnet 4.6 為 $3 / $15,Haiku 4.5 為 $1 / $5(Claude API pricing)。實際消耗取決於 model、turns、tool use、cache reads、cache writes,以及 agent 載入了多少 repository context。
不要把 $20 或 $200 換算成「小時」。那是錯的單位。請把你的實際 jobs 轉成 token 和 cost traces。
GitHub Actions:同一份 YAML,不同預算
Claude Code GitHub Actions 明確在範圍內。Anthropic 的 GitHub Actions docs 說,這個 action 建立在 Claude Agent SDK 之上,可以回應 @claude mentions、建立 PRs、實作 features、修 bugs,或執行自訂 automation(Claude Code GitHub Actions docs)。文件也提醒,每次 Claude interaction 都會消耗 API tokens,並建議使用 --max-turns、timeouts 和 concurrency controls 來管理成本。
現在這個建議更重要了。
像這樣的每日排程報告:
name: Daily Claude Report
on:
schedule:
- cron: "0 9 * * *"
jobs:
report:
runs-on: ubuntu-latest
steps:
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
prompt: "Summarize yesterday's commits and open issues"
claude_args: "--model sonnet --max-turns 3"
有兩種可能的計費故事:
- 如果它使用 Claude Platform API key,Anthropic 說沒有任何改變。它仍是一般 pay-as-you-go API billing。
- 如果它使用的是以訂閱驗證的 Agent SDK credit,現在會先消耗每位使用者的 Agent SDK credit,若已啟用 usage credits,之後再扣 usage credits。
action setup docs 仍然強調用 ANTHROPIC_API_KEY 做直接 API usage,以及 Bedrock 和 Vertex AI 的 cloud-provider options(Claude Code GitHub Actions docs)。對 production CI 來說,這比把 repo 的 automation 綁在某個真人訂閱上乾淨多了。Anthropic 在 admin guidance 裡也說同樣的事:大規模 production automation 應使用 Claude Platform 搭配 API key,以取得可預期的 pay-as-you-go billing(Anthropic Help Center)。
我的建議:如果某個 workflow 可以 merge code、在 PRs 留言,或在無人看管的 schedule 上執行,就把它放到有明確 budgets 的 API key 上。把訂閱的 Agent SDK credit 留給個人 automation、實驗和本機工具。

第三方代理工具:Zed 風格問題
最容易混淆的是第三方 tooling。開發者在問:如果某個 editor、本機 harness,或 coding assistant 透過 Agent SDK 整合,並讓我用 Claude 訂閱驗證,它會使用新的 credit 嗎?
Anthropic 的說明文章表示,credit 涵蓋「透過 Agent SDK 使用你的 Claude 訂閱驗證的第三方應用程式」(Anthropic Help Center)。Agent SDK overview 也說,Anthropic 一般不允許第三方開發者提供 claude.ai login 或 rate limits,除非先前已獲批准,並告訴開發者應改用 API-key authentication methods(Claude Docs)。
這給出一條實用規則:
- 如果工具使用你的 Claude Platform API key,這次變更不會給它免費的每月 credit。它仍是 API billing。
- 如果工具是已核准、以訂閱驗證的 Agent SDK app,它會消耗 Agent SDK credit。
- 如果工具試圖透過 Claude Code login、OAuth tokens、hidden PTYs,或 Anthropic 未核准的方式鑽訂閱限制,請把它視為脆弱方案。
社群已經在這個模糊地帶上動手了。一篇 r/ClaudeCode 貼文描述了一個 hook-based「drop-in -p replacement」,把工作留在互動式 Claude Code 裡,並宣稱能避開 SDK credits(Reddit)。另一篇 r/ClaudeAI 貼文介紹 clarp,一個本機 CLI,會在底層啟動互動式 Claude Code 來模仿 claude -p output(Reddit)。作者把它說成是本機相容性方案,但留言馬上提出 account-risk questions。
這才是真正的爭議:這是合理保留本機 workflow,還是把 quota bypass 包裝成 tooling?我不會把公司基礎設施建在這類 wrappers 上。就算它們今天能用,也把 Anthropic 正在努力移除的 billing assumption 寫進了系統裡。
今天就該怎麼稽核自己的工作流程
不要等 job 失敗才做這件事。
首先,搜尋 claude -p 和 Agent SDK imports:
rg 'claude\s+(-p|--print)|@anthropic-ai/claude-agent-sdk|claude_agent_sdk' .
接著搜尋 CI:
rg 'claude-code-action|ANTHROPIC_API_KEY|claude_args|@claude' .github .gitlab .circleci
把每個 hit 分類:
| Class | Example | Recommended action |
|---|---|---|
| 個人一次性 | 本機 claude -p helper | 保留,加上 --max-budget-usd 和 logging |
| 個人排程 | cron job、launchd、systemd timer | 改用 API key,或強力設限 |
| 團隊 CI | PR review、issue triage | 使用 Claude Platform API key、repo secrets、concurrency |
| 第三方 editor/tool | Agent SDK integration | 確認 auth mode 和 billing path |
| Wrapper 或 bypass | hidden PTY、hook loop、OAuth relay | 避免用於 production;檢查 policy risk |
SDK 使用者要把 cost tracking 接到 result stream。Anthropic 的 cost-tracking docs 說,total_cost_usd 和 costUSD 是 client-side estimates,不是正式 billing data,但對開發觀察很有用(Claude Docs)。同一頁也說 SDK 會暴露 per-step token usage、per-model usage、cache read tokens、cache creation tokens,以及 cumulative totals。
用它建立 burn profile:
import { query } from "@anthropic-ai/claude-agent-sdk";
for await (const message of query({
prompt: "Review this repo for flaky tests",
options: { maxTurns: 3 },
})) {
if (message.type === "result") {
console.log({
estimatedCostUsd: message.total_cost_usd,
modelUsage: message.modelUsage,
});
}
}
不要用 client-side cost estimates 向你自己的使用者計費。Anthropic 明確表示,正式 billing 應使用 Usage and Cost API 或 Claude Console(Claude Docs)。
也要加上硬性停損。對 claude -p,使用 --max-turns 和 --max-budget-usd。對 GitHub Actions,使用 workflow timeouts、GitHub concurrency controls 和更窄的 prompts。對 SDK agents,限制 tools。一個 read-only reviewer 不該預設擁有 Bash、Edit 和 Write。

Opt-In 和超額問題
最重要、但尚未完全釐清的營運問題是 opt-in。Anthropic 說 credit 是一次性 opt-in,透過你的 Claude account 領取一次後,之後會自動刷新。對 Team 和 Enterprise admins 來說,符合資格的使用者原本會在 2026 年 6 月 15 日前收到包含細節和指示的 email(Anthropic Help Center)。
目前一個 r/Anthropic 討論串正在問最明顯的追問:如果你不 opt in 會怎樣?claude -p 會繼續用一般訂閱限制、在你領取前停止,還是 fallback 到 usage credits?文章沒有把 fallback 說清楚(Reddit)。
所以不要把設計建立在猜測的 fallback 上。如果你符合資格,就去領 credit。如果你是 admin,告訴使用者要去哪裡領,以及哪些 automations 可以使用它。如果你跑 shared workflows,把它們移到 API key。
關於超額,Anthropic 說得比較清楚。Agent SDK usage 會先消耗每月 credit。之後,只有在 usage credits 已啟用時,使用量才會以標準 API rates 轉到 usage credits。如果 usage credits 沒有啟用,Agent SDK requests 會停止,直到 credit 刷新(Anthropic Help Center)。
從 spend-control 的角度看,這很好。這也代表你的 automation 可能會 fail closed。請為此設計。CI 應把「Agent SDK credit exhausted」呈現為 billing/configuration failure,而不是 flaky model error。本機 scripts 應印出清楚訊息並以 non-zero 結束。Long-running agents 應在每個昂貴 turn 前 checkpoint 工作。
給開發者的結論
這次變更不是 claude -p 的末日。它終結的是:假裝無頭 agent loop 跟坐在 IDE 前的人類有相同成本結構。
對個人開發者來說,新的 credit 有用。Pro 使用者每月有 $20 的 script 空間。Max 20x 使用者有 $200。這足夠做有節制的 automation,但不是無限 always-on agents。
對團隊來說,答案很無聊,也很正確:production automation 用 API keys。訂閱的 Agent SDK credits 留給個人。加上 cost logging。限制 turns。不需要 frontier model 的任務,優先用 Haiku 或 Sonnet。把繞過新邊界的 wrapper tools 當成實驗,不要當成 infrastructure。
6 月 15 日這次切分解決了一個真問題:你的 nightly script 不該悄悄吃掉你互動式 coding 需要的同一份 quota。它也創造了另一個問題:只要 Claude 在沒有人類參與的情況下執行,開發者現在就得像 API 使用者一樣思考。
這是合理的交換。但前提是你要在計量開始咬人之前完成稽核。

想親自試用 Claude Fable 5 的讀者,可以透過 OneHop 使用:一個 drop-in endpoint,約比牌價低 30%,新帳號有 $10 免費額度且不需信用卡。請看 Claude Fable 5 on OneHop 或 start with $10 free。