← Back to home

Generate Images on Your Subscription Quota: Have Claude Code Drive Codex, Pay Nothing in API Fees

Long-Form Video · EP0053 June 30, 2026 5:34
What this episode covers

Building decks, shipping demos, illustrating web pages—going through the API means paying per image, and it adds up fast. My last deck ran fifty or sixty pages and image generation alone was heading toward a few hundred yuan.

But if you're already paying for a ChatGPT/Codex subscription, that quota already includes a built-in image tool. I turned that into a Claude Code skill.

Companion files · Drop them into Claude Code

Building decks, shipping demos, illustrating web pages—going through the API means paying per image, and it adds up fast. My last deck ran fifty or sixty pages and image generation alone was heading toward a few hundred yuan. For an ordinary user, that isn’t cheap.

But if you’re already paying for a ChatGPT or Codex subscription, that quota already includes a built-in image tool, running on GPT Image 2. Meaning you don’t pay again for every single image the way you do with the API. The membership fee is already spent—you might as well use every bit of that quota.

So I turned it into a Claude Code skill.

Why “have CC drive Codex” instead of generating in Codex directly

A lot of people are like me, running Claude Code and Codex side by side. Codex has GPT Image 2 on subscription quota, which is the cheap part. But when I actually need stable, batch generation, I’d rather take the detour and let Claude Code drive Codex than click around in Codex myself.

Two reasons. One, I’m used to orchestrating inside the Claude Code system—it holds more of my context and memory. Two, the Claude Code model really is a bit smarter: without me hovering over it, it works out what I’m after and writes a complete structured prompt on its own. I’ll even let it run in bypass mode and take the whole flow unattended, then eyeball the results at the end. With Codex I don’t dare let go like that. The judgment calls that matter still have to be mine.

What the skill actually does

It standardizes “CC drives codex to generate images” into a pipeline:

  • translates your ask into a structured prompt (purpose → subject → detail → constraints);
  • drives codex exec via script to call the built-in image tool;
  • checks its own output when it’s done, and regenerates if something’s off.

There’s one trap in the middle you have to plug: codex can be pretty dumb sometimes. You ask for an image and it may just draw you one in SVG, which comes out looking like a stick figure with no aesthetic sense whatsoever. So the skill hard-bans codex from drawing with code or SVG; it has to go through the built-in image tool and produce real pixels. Once that’s shut down, the results hold up: photorealistic lifestyle shots, 3D renders, flat paper-cut, vector illustration, specific cinematic looks—all of it.

The limits: don’t treat it as 4K

A few things to get straight so you don’t get burned:

  • Standard definition only. Square means 1024×1024, and the short edge is permanently capped at 1024—not 4K. Real 4K means going through the API (and paying per image again). But honestly, for demos and decks, 1024 is completely fine.
  • You’ve probably seen plenty of third-party relays selling dirt-cheap GPT Image 2 generation. Almost all of them are wired in this exact way, and they’re capped at standard definition too. Some upscale with another model and pass it off as 4K to charge you more, which is a bit shameless.
  • Quota: Plus ($20/month) gets you roughly 50 images every 5 hours; but don’t forget there’s a weekly cap too, so if you’re maxing it out daily it works out to about 30 images a day.
  • It doesn’t parallelize well, so I usually orchestrate one job and let it generate continuously overnight. If you want a full deck generated fast with multi-threaded concurrency, that’s still an API job.
  • It can also do transparent backgrounds (cutouts) and edit existing images (pass in a reference)—but in practice the cutouts are mediocre, so don’t set your expectations high.

A quick word on account bans

I opened with a couple of minutes on the recent Claude Code account bans. After the 1.9.1 update on June 22, a lot of accounts started throwing 401s and asking people to log in again. Personal accounts mostly ended up on hold—entitlements suspended, cloud data still exportable, and some people got theirs back on appeal. Harsher cases: entire organizations, or accounts registered in bulk through certain channels, taken out wholesale. It comes down to one line: if you want to run Claude Code reliably over the long haul, put real work into a solid ban-proofing setup. Don’t wait until you get hit to think about it.


Today’s skill is fully open source and free; the repo is at github.com/xntj-ai/codex-image. Hand the URL to Claude Code, say “take a look at how this skill works,” and it installs itself.

I'm already paying for the Codex membership, so I might as well use every bit of that quota.