CLAUDE LABJP
BILLING — 1 day to the Jun 15 change: Agent SDK, headless runs, GitHub Actions, and third-party agents move to separate monthly credits ($20/$100/$200) metered at full API rates, no rolloverFABLE5 — Claude Fable 5, a Mythos-class model billed as Anthropic's most capable generally available release, is usable in Claude Code v2.1.170+ (launched Jun 9)SUBAGENTS — Claude Code sub-agents can now spawn their own sub-agents, with smarter model and region handlingENTERPRISE — Custom roles gain admin permissions, letting members reach billing and privacy settings without Owner accessPLUGINS — New plugin search plus better Chrome, VSCode, and terminal workflows; session, memory, and permission bugs fixedUI — New setting disables mouse-wheel scroll acceleration in fullscreen; the /model picker now shows model families correctlyBILLING — 1 day to the Jun 15 change: Agent SDK, headless runs, GitHub Actions, and third-party agents move to separate monthly credits ($20/$100/$200) metered at full API rates, no rolloverFABLE5 — Claude Fable 5, a Mythos-class model billed as Anthropic's most capable generally available release, is usable in Claude Code v2.1.170+ (launched Jun 9)SUBAGENTS — Claude Code sub-agents can now spawn their own sub-agents, with smarter model and region handlingENTERPRISE — Custom roles gain admin permissions, letting members reach billing and privacy settings without Owner accessPLUGINS — New plugin search plus better Chrome, VSCode, and terminal workflows; session, memory, and permission bugs fixedUI — New setting disables mouse-wheel scroll acceleration in fullscreen; the /model picker now shows model families correctly
Articles/Claude Code
Claude Code/2026-06-14Advanced

Before Per-PR CI Burns Through Your Monthly Credits: A Three-Layer Guard for Claude Code GitHub Actions

From June 15, Claude Code GitHub Actions bills against non-rolling monthly credits. Run a review on every PR and you can drain the month in the first week. Here is a three-layer guard — when to run, how heavy one run can get, and making spend visible — with working workflows.

Claude Code150GitHub Actions11CI/CD15Monthly CreditsCost ControlProduction16

Premium Article

Early in June I was scrolling the morning notifications and noticed my credit balance had already dropped below half. The month was three days old. The cause was easy to spot: the night before, twelve dependency-update PRs had landed at once, and the code-review workflow had fired on every single one of them.

As an indie developer I keep several app repositories, and I wire Claude Code review into their CI. Until now that ran inside my subscription, so I never watched the run count closely. The billing change on June 15 removes that cushion. Here are the three layers of guards I added to keep CI running while bringing the spend back under control — with the workflows that actually run.

What Changes on June 15: CI Leaves the Subscription

From June 15, 2026, the Claude Agent SDK, headless claude -p, Claude Code GitHub Actions, and third-party agents move onto monthly credits that sit outside your subscription limit. Credits are granted per plan (roughly $20 / $100 / $200 worth), consumed at the full API rate, and — critically — they do not roll over.

That last property is the one that bites. Leaving credits unused at month end is a loss, but spending them all in the first week means no automated CI review for the rest of the month. Under the subscription, "running too often" was still flat-rate; from now on, every run carves directly into the pool.

I wrote up the full scope of the change, and which steps are worth keeping headless, in how headless execution changes with the June 15 Claude Code billing update. This article drills into the piece that gets overlooked: GitHub Actions.

Spend Is "Number of Runs × Weight per Run"

Boiled down, credit spend is a product of two things:

  1. How many runs fired — how often the workflow started
  2. How heavy each run was — tokens read and written per run

The first number was what had broken. In my repos, review fired on both on: pull_request and on: push, and it covered everything without exception — bot dependency PRs, docs-only edits, even draft PRs. Fewer than half of the monthly CI starts were meaningful as human code review.

The second can't be ignored either. A refactor PR with several thousand changed lines loads the whole diff into context, costing tens of times the tokens of a normal run. Even after trimming the count, one "heavy run" like that can take a big bite out of the month.

So I worked in this order: cut the count with run conditions (layer 1), cap how heavy one run can be (layer 2), and make spend visible (layer 3).

Thank you for reading this far.

Continue Reading

What follows includes implementation code, benchmarks, and practical content we hope you'll find useful. This site runs without ads — server and development costs are supported entirely by members like you. If it's been helpful, we'd be truly grateful for your support.

WHAT YOU'LL LEARN
Cut roughly 60% of the CI runs that were burning your monthly credits in the first week, using path/label/draft run conditions — without losing any human-facing review coverage
Build a diff-size and token ceiling into the workflow so a single massive PR can no longer swallow a large slice of the month's credits
Log each run's token spend to the job summary so you can decide, mid-month, how many runs you have left in plain numbers
Secure payment via Stripe · Cancel anytime

Unlock This Article

Get full access to the rest of this article. Buy once, read anytime. This site is ad-free — your support goes directly toward keeping it running.

or
Unlock all articles with Membership →
Share

Thank You for Reading

Claude Lab is ad-free, supported entirely by members like you. We publish practical guides daily with implementation code, benchmarks, and production-ready patterns. If you've found it useful, we'd love to have you on board.

  • Copy-paste ready implementation code
  • New advanced guides published daily
  • $5/mo or $10 for lifetime access
View Membership →

Related Articles

Claude Code2026-05-04
Build a Pipeline Where Docs Update Automatically Every Time Your Code Changes
Build a CI/CD pipeline that auto-generates README, CHANGELOG, and API docs whenever code changes. Use Claude Haiku 4.5 for cost-efficient classification and Sonnet 4.6 for quality output — cutting API costs by up to 70% while keeping documentation accurate.
Claude Code2026-05-04
Setting Up Claude Code's GitHub PR Trigger for Automated Code Review
A step-by-step guide to configuring Claude Code's GitHub PR trigger, writing effective CLAUDE.md review policies, and what two weeks of real usage taught me about keeping the signal-to-noise ratio high.
Claude Code2026-04-09
Claude Code × Docker — DevContainers, Multi-Stage Builds, and Production Deployment
A practical guide to production-grade development workflows combining Claude Code and Docker. From DevContainer setup and multi-stage build optimization to GitHub Actions CI/CD and Kubernetes deployment — with practical code examples throughout.
📚RECOMMENDED BOOKS
Build a Large Language Model (From Scratch)
Sebastian Raschka
LLM Dev
Prompt Engineering for LLMs
Berryman & Ziegler
Prompting
AI Engineering
Chip Huyen
AI Eng
* Contains affiliate links
See all →