← All articles
Ecosystem

Claude Agent SDK Credit: What Changes for claude -p, GitHub Actions, and Third-Party Agent Tools on June 15

A cream-background editorial illustration of a developer workflow split into two lanes: interactive Claude Code on one s

On June 15, 2026, Anthropic changes the economics of headless Claude. claude -p, Claude Agent SDK calls, Claude Code GitHub Actions, and third-party apps built on the Agent SDK stop drawing from normal Claude subscription limits and start drawing from a separate monthly Agent SDK credit instead (Anthropic Help Center).

That sounds like a billing footnote. It is not. If you have cron jobs, CI reviewers, local scripts, Zed-style agent integrations, or wrapper CLIs around claude -p, this is the line where “included in my plan” becomes “metered against a dollar credit.”

My take: this is the right product boundary, but Anthropic’s rollout leaves too many developers discovering it through broken mental models and Reddit threads. Interactive coding and automated agents are different workloads. They should not share the same quota. But if your team has quietly built automation around subscription-authenticated Claude Code, June 15 is a migration deadline, not a pricing announcement.

A before-and-after flow diagram showing pre-June 15 usage where interactive Claude Code, claude -p, Agent SDK, and GitHu

What Actually Moves to the New Credit

Anthropic’s help article is explicit about the boundary. Starting June 15, Agent SDK and claude -p usage on Claude subscription plans draw from a new monthly Agent SDK credit, separate from interactive usage limits (Anthropic Help Center). The Agent SDK docs repeat the same warning at the top of the overview page (Claude Docs).

Covered by the new credit:

WorkflowCounts against Agent SDK credit?Notes
claude -p "..."YesPrint mode, non-interactive
Python or TypeScript Claude Agent SDKYesWhen used with subscription-plan Agent SDK credit
Claude Code GitHub ActionsYesAnthropic says this integration is built on the Agent SDK
Third-party apps built on Agent SDK and authenticated through your Claude subscriptionYesThe hot spot for tool integrations
Interactive Claude Code in terminal or IDENoStill uses normal subscription limits
Claude web, desktop, mobile chatNoStill uses normal subscription limits
Claude CoworkNoNot part of this credit
Agent SDK with a Claude Platform API keyNo changePay-as-you-go continues as before

The plan credits are dollar-denominated:

PlanMonthly 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 also says credits are per user, not pooled; they refresh with the billing cycle; unused credit does not roll over; and the credit must be claimed once, then refreshes automatically (Anthropic Help Center).

That last part matters for teams. A Team account with 20 eligible engineers does not get one shared automation bucket. Each person gets their own credit. If a shared GitHub Action is authenticated as one user, that one user’s credit is the bottleneck.

The Practical Break: claude -p Is No Longer “Just CLI Usage”

The command that will surprise people is claude -p.

Anthropic’s CLI reference describes --print / -p as “Print response without interactive mode,” with automation-friendly flags like --output-format json, --output-format stream-json, --max-turns, --json-schema, and --max-budget-usd (Claude Code CLI reference). That made it perfect glue for scripts:

git diff --staged |
  claude -p "Review this diff for security issues. Return JSON." \
  --output-format json \
  --max-turns 3 \
  --max-budget-usd 2

After June 15, that is Agent SDK-credit usage on a subscription-authenticated account. It is not interactive Claude Code usage. It is not normal chat usage. It is not a free side door into your plan quota.

This is why the community reaction is sharp. In a current r/ClaudeCode thread, developers are asking whether the credit is token/model based, how far $200 realistically goes, whether opt-in is required, how prompt caching is counted, and whether GitHub Actions are included (Reddit). One commenter’s “oh… I didn’t realise it was GH actions too” is exactly the risk: people mapped this change to SDK libraries, not every headless Claude Code workflow.

The answer to the token question is effectively yes: Anthropic says over-credit usage flows to usage credits at standard API rates if usage credits are enabled. The current Claude API pricing page lists Fable 5 at $10 input / $50 output per million tokens, Opus 4.8 at $5 / $25, Sonnet 4.6 at $3 / $15, and Haiku 4.5 at $1 / $5 (Claude API pricing). The exact burn depends on model, turns, tool use, cache reads, cache writes, and how much repository context the agent loads.

Do not convert $20 or $200 into “hours.” That is the wrong unit. Convert your actual jobs into token and cost traces.

GitHub Actions: Same YAML, Different Budget

Claude Code GitHub Actions is squarely in scope. Anthropic’s GitHub Actions docs say the action is built on top of the Claude Agent SDK and can respond to @claude mentions, create PRs, implement features, fix bugs, or run custom automation (Claude Code GitHub Actions docs). The docs also warn that each Claude interaction consumes API tokens and recommend --max-turns, timeouts, and concurrency controls for cost management.

That guidance matters more now.

A scheduled daily report like this:

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"

has two possible billing stories:

  1. If it uses a Claude Platform API key, Anthropic says nothing changes. It remains normal pay-as-you-go API billing.
  2. If it is using subscription-authenticated Agent SDK credit, it now drains the per-user Agent SDK credit first, then usage credits if enabled.

The action setup docs still emphasize ANTHROPIC_API_KEY for direct API usage, and cloud-provider options for Bedrock and Vertex AI (Claude Code GitHub Actions docs). For production CI, that is cleaner than tying a repo’s automation to a single human subscription. Anthropic says the same thing in admin guidance: production automation at scale should use Claude Platform with an API key for predictable pay-as-you-go billing (Anthropic Help Center).

My recommendation: if a workflow can merge code, comment on PRs, or run unattended on a schedule, put it on an API key with explicit budgets. Save subscription Agent SDK credit for personal automation, experiments, and local tooling.

A CI architecture sketch showing GitHub issue comments, pull requests, and scheduled workflows flowing into Claude Code

Third-Party Agent Tools: The Zed-Style Question

The confusing case is third-party tooling. Developers are asking: if an editor, local harness, or coding assistant integrates through the Agent SDK and lets me authenticate with my Claude subscription, does it use the new credit?

Anthropic’s help article says the credit covers “third-party apps that authenticate with your Claude subscription through the Agent SDK” (Anthropic Help Center). The Agent SDK overview also says Anthropic generally does not allow third-party developers to offer claude.ai login or rate limits unless previously approved, and tells developers to use API-key authentication methods instead (Claude Docs).

That gives a practical rule:

  • If the tool uses your Claude Platform API key, this change does not give it a free monthly credit. It is still API billing.
  • If the tool is an approved subscription-authenticated Agent SDK app, it draws from the Agent SDK credit.
  • If the tool is trying to tunnel through Claude Code login, OAuth tokens, hidden PTYs, or subscription limits in ways Anthropic has not approved, treat it as fragile.

The community is already building around that ambiguity. One r/ClaudeCode post describes a hook-based “drop-in -p replacement” that keeps work inside interactive Claude Code and claims to avoid SDK credits (Reddit). Another r/ClaudeAI post describes clarp, a local CLI that launches interactive Claude Code under the hood to mimic claude -p output (Reddit). The author frames it as local compatibility, while commenters immediately raise account-risk questions.

That is the real debate: is this legitimate local workflow preservation, or quota bypass dressed up as tooling? I would not build company infrastructure on these wrappers. Even if they work today, they encode a billing assumption Anthropic is actively trying to remove.

How to Audit Your Own Workflows Today

Do this before you wait for a failed job.

First, search for claude -p and Agent SDK imports:

rg 'claude\s+(-p|--print)|@anthropic-ai/claude-agent-sdk|claude_agent_sdk' .

Then search CI:

rg 'claude-code-action|ANTHROPIC_API_KEY|claude_args|@claude' .github .gitlab .circleci

Classify each hit:

ClassExampleRecommended action
Personal one-shotlocal claude -p helperKeep, add --max-budget-usd and logging
Personal scheduledcron job, launchd, systemd timerMove to API key or cap aggressively
Team CIPR review, issue triageUse Claude Platform API key, repo secrets, concurrency
Third-party editor/toolAgent SDK integrationConfirm auth mode and billing path
Wrapper or bypasshidden PTY, hook loop, OAuth relayAvoid for production; check policy risk

For SDK users, wire cost tracking into the result stream. Anthropic’s cost-tracking docs say total_cost_usd and costUSD are client-side estimates, not authoritative billing data, but they are useful for development insight (Claude Docs). The same page says the SDK exposes per-step token usage, per-model usage, cache read tokens, cache creation tokens, and cumulative totals.

Use that to create a 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,
    });
  }
}

Do not use client-side cost estimates to bill your own users. Anthropic explicitly says to use the Usage and Cost API or the Claude Console for authoritative billing (Claude Docs).

Also add hard stops. For claude -p, use --max-turns and --max-budget-usd. For GitHub Actions, use workflow timeouts, GitHub concurrency controls, and narrow prompts. For SDK agents, restrict tools. A read-only reviewer should not have Bash, Edit, and Write by default.

A compact audit checklist graphic with five rows: local scripts, SDK imports, CI workflows, third-party tools, and share

The Opt-In and Overage Questions

The most important unresolved operational question is opt-in. Anthropic says the credit is a one-time opt-in, claimed through your Claude account once, then refreshed automatically. For Team and Enterprise admins, eligible users were to receive an email with details and instructions before June 15, 2026 (Anthropic Help Center).

A current r/Anthropic thread is asking the obvious follow-up: what happens if you do not opt in? Does claude -p keep working against normal subscription limits, stop until you claim, or fail into usage credits? The article does not state that fallback clearly (Reddit).

So do not design around a guessed fallback. Claim the credit if you are eligible. If you are an admin, tell users where to claim it and which automations are allowed to use it. If you run shared workflows, move them to an API key.

For overage, Anthropic is clearer. Agent SDK usage drains the monthly credit first. After that, usage moves to usage credits at standard API rates only if usage credits are enabled. If usage credits are not enabled, Agent SDK requests stop until the credit refreshes (Anthropic Help Center).

That is good from a spend-control standpoint. It also means your automation may fail closed. Build for that. CI should surface “Agent SDK credit exhausted” as a billing/configuration failure, not as a flaky model error. Local scripts should print a clear message and exit non-zero. Long-running agents should checkpoint work before each expensive turn.

The Bottom Line for Developers

This change is not the death of claude -p. It is the end of pretending a headless agent loop has the same cost profile as a human sitting in an IDE.

For individual developers, the new credit is useful. A Pro user gets $20 of monthly room for scripts. A Max 20x user gets $200. That is enough for thoughtful automation, not unlimited always-on agents.

For teams, the answer is boring and correct: use API keys for production automation. Keep subscription Agent SDK credits personal. Add cost logging. Cap turns. Prefer Haiku or Sonnet when the task does not need a frontier model. Treat wrapper tools that route around the new boundary as experiments, not infrastructure.

The June 15 split solves one real problem: your nightly script should not silently eat the same quota you need for interactive coding. It creates another: developers now need to think like API users whenever Claude runs without a human in the loop.

That is a fair trade. But it only works if you audit before the meter starts biting.

A small decision-tree diagram titled visually by icons only: “interactive,” “headless local,” “CI,” and “third-party too

Readers who want to try Claude Fable 5 themselves can use it through OneHop: a drop-in endpoint, about 30% under list price, with $10 free for new accounts and no card required. See Claude Fable 5 on OneHop or start with $10 free.

Further reading: Getting started with Claude Fable 5.