YouMind
Sign in

How to Run Paid Ads from Claude Code: The Mega Guide

@MichLieben
ENGLISHJun 29, 2026
260K
245
24
218
914

TL;DR

This guide outlines a system of 12 AI-powered skills for Claude Code that allow growth teams to manage high-volume ad spend across major platforms directly from the terminal.

Our head of growth, Ivan Falco, runs $300K a month in ad spend across Google, Meta, and LinkedIn without opening a single ad manager. He does it from a terminal, in plain English, inside Claude Code.

He spent 200+ hours turning that into 12 skills, and then he put the whole thing in a public repo. We're laying out exactly how it works below, so anyone trying to do this can get it running without guessing. If you'd rather just have the files handed to you, comment "ads" and we'll send the repo over.

A few parts take patience, and we'll flag them as we go. By the end you'll know what this is, what it can't do, the exact prompts to run, and the order to turn it on so you don't blow up a live account on day one. This is the full playbook, so work through it in order.

Michel Lieben - inline image

The four-phase rollout: clone and onboard, connect accounts, read before write, hand over the keys

What you're installing

Michel Lieben - inline image

System map: Claude Code at the center, the four skills and the foundations layer

First, the thing that trips most people up.

This runs in Claude Code on your own computer, which is the claude command in your terminal or the Claude Code desktop app set to Local. It does not run in the chat app at claude.ai. The chat app lives in the cloud and can't run scripts on your machine, read your API keys, or talk to your ad accounts. Run it in the chat app by mistake and nothing works, and you'll think the repo is broken when it isn't.

What you're installing is a set of skills.

A skill is a folder that teaches Claude Code one job: what to do, how to do it, and when to do it. Each one carries strategy files that hold the frameworks and benchmarks, Python scripts that call the ad platform APIs directly, and routing logic that tells Claude which knowledge to load for the task in front of it.

The scripts are the automation layer, the part that pulls a report or pushes a bulk edit.

The knowledge base is the strategy layer, the part that knows how to run B2B paid. The scripts save you time. The knowledge base is where the real edge is, because it's the difference between an agent that executes a dumb instruction and one that executes the right one.

The whole thing is built on the 5-Stage Demand Engine we run across our accounts, which replaces the old TOFU, MOFU, BOFU funnel and allocates budget by stage and channel.

What you need before you start

Three things. Claude Code installed. Python 3.10 or newer, since the scripts run on it. And API access for each ad platform you want to manage.

That last one is the part that takes patience.

Reading the strategy and asking for audits needs no setup at all, you can do that the minute you clone the repo. To let the agent pull live reports and make real edits, each platform needs API credentials, and the approvals move at different speeds. Meta and Google are quick. LinkedIn's Advertising API can take a day or two to get approved, so if LinkedIn is your main channel, request that access first and go do something else while it clears.

Phase one: clone it and meet the agent

The opening moves are three commands.

  • git clone the repo, then cd into the folder.
  • Run claude to open Claude Code inside it.
  • Type /onboarding.

Onboarding is a five-minute interactive setup.

It checks you're in the right place, asks which platforms you run, and walks you through credentials one platform at a time instead of dumping a wall of instructions at you. You can also skip it and just start asking.

The agent loads the right skill for whatever you typed.

Phase two: connect your ad accounts

This is the one fiddly part, so here's what each platform actually asks for.

For LinkedIn, you create an app in the LinkedIn developer portal, then request the Advertising API under the Products tab. That request is the slow one.

While you wait, you grab your Client ID and Client Secret from the Auth tab, run the included OAuth script, and it catches the token automatically. Your last piece is the Ad Account ID, which is the number sitting in your Campaign Manager URL.

For Meta, you make an app, add the Marketing API product, and generate a token with ads management and read permissions.

The first token Meta gives you dies in an hour, so the agent helps you exchange it for a long-lived one that lasts about two months. Then you grab your Ad Account ID, the one that starts with act_.

For Google, you need a developer token from the API Center, which usually means having a manager account set up first. That token plus your account ID is what the scripts authenticate with.

None of this is hard, but it is the kind of setup people abandon halfway through. Do it once, slowly, one platform at a time. If you'd rather not wrangle it, Ivan runs a free teardown and can help, but most people get through it fine on their own.

Phase three: read before you write

Here's the order that keeps you safe.

Do not point this at a live account and start letting it make edits on the first day. Start in read-only, where every prompt reads your account and hands back a finding without touching anything.

This is also where you learn what the agent is good at.

Run the audits, compare them to what you'd have concluded yourself, and only graduate to edits once they consistently line up. Here are the exact starter prompts we run on each platform.

On Google, where wasted spend hides in plain sight:

"Pull my search terms from the last 30 days and flag every query that spent money with zero conversions."

"Audit my quality scores and show me where I'm overpaying or missing demand."

"Compare this month to last and tell me exactly what shifted and why."

On Meta, where creative quietly dies:

"Pull my active ads and flag anything where the click-through rate is dropping."

"Check every campaign for audience oversaturation and tell me what to rotate."

"Review my ad copy against the voice-of-customer framework in the knowledge base."

On LinkedIn, where the clicks are most expensive:

"Audit my account against the 35-item checklist and rank the fixes by impact."

"Pull demographics on my top campaign and show me which job titles and company sizes actually convert."

"Show me my bid strategy across campaigns and where I'm leaving efficiency on the table."

Every one of those is safe to run on day one.

None of them touch a thing. They just show you the account through the eyes of someone who has run this playbook across a lot of spend.

The skills, and what each one runs

The repo is organized as four skills, one per platform plus the setup one.

LinkedIn Ads handles the full campaign lifecycle: strategy, targeting, creative, analytics, bidding, demographics, audience uploads, lead forms. It carries 15 strategy files and 14 scripts, including a full-funnel framework with budget splits, audience sizing rules, six campaign structure models, and a 35-item audit checklist.

Meta Ads runs Meta for B2B specifically, which is its own discipline: creative-as-targeting, audience strategy, campaign structure, optimization, and fatigue detection. It has 16 strategy files and 12 scripts, built around a Meta Ads operating system, a creative production pipeline, and the case for why Meta can hit a lower cost per lead than LinkedIn when you run it right.

Google Ads runs intent-first search: keyword management, bid strategy, search-terms auditing, performance analysis. Nine strategy files and 13 scripts, built on the idea of capturing demand before you try to create it.

The fourth skill is Onboarding, the setup walkthrough. And underneath all three platforms sits a foundations layer: ten cross-platform frameworks covering the demand engine, budget allocation, copywriting, channel selection, and a scaling quadrant that applies no matter where you're spending. Read those foundations files before you touch anything. They're the part that makes the rest make sense.

The 12 jobs you run day to day

Michel Lieben - inline image

The twelve jobs split into four that build the campaign and eight that defend the spend

Inside those skills are the 12 ad-ops jobs Ivan built. Four of them get a campaign off the ground (audience-builder counts twice, since it ships on both Meta and LinkedIn).

  • audience-builder turns your CRM lists into custom targetable audiences, on Meta and on LinkedIn.
  • creative-builder generates ad creatives from your brand specs.
  • bulk-editor mass-edits campaigns, ads, and naming in seconds.

The other eight defend the money once the campaign is live, which is most of the actual work.

  • search-terms finds the queries spending money with zero conversions.
  • negative-keywords turns those into exclusions so you stop paying for them.
  • keyword-analyzer audits quality scores and surfaces the gaps where you're overpaying or missing demand.
  • performance-auditor compares two timeframes and tells you what actually shifted.
  • creative-fatigue-analyzer watches your click-through rate and flags it dropping before you'd feel it.
  • fatigue-monitor flags when an audience is getting oversaturated so you rotate in time.
  • spend-tracker watches budget pacing across every campaign so nothing overspends unnoticed.
  • bid-optimizer tunes bids across campaigns in bulk instead of one slow edit at a time.

You don't memorize these names. You describe what you want and the agent reaches for the right one. "Find the wasted spend in my search campaigns" runs the search-terms and negative-keywords jobs. "Is anything fatiguing on Meta" runs the fatigue checks.

The names are just how the work is organized underneath.

Phase four: hand over the keys, one job at a time

Once the audits are matching your own read, you let the agent start making edits. Do it in the same careful order, smallest blast radius first.

Start with negative keywords, because the worst case is you stop paying for a junk query. Ask it to pull the zero-conversion search terms, show you the list, and add them as exclusions once you approve. Then let it handle creative-fatigue flags and bid nudges the same way: it proposes, you approve, it executes. Keep yourself in the approval loop until the edits are boring and predictable. Only then do you let it run the routine jobs on its own and report back what it edited.

The rule that keeps this safe is simple.

The agent proposes and executes. You decide what "good" looks like. It never gets to invent the target, only to hit the one you set.

The weekly operating ritual

Michel Lieben - inline image

The weekly loop: search terms, creative fatigue, budget pacing, compare week over week

Here's where the whole thing pays off.

The agent is most valuable run as a standing rhythm, not opened in a panic when a number looks off. Once a week, in one sitting, run this loop across every account:

"Pull this week's Google search terms and give me the zero-conversion queries to exclude."

"Check every Meta campaign for creative fatigue and flag anything with a dropping CTR."

"Review budget pacing across all three platforms and flag anything running over or under."

"Compare this week to last and tell me what moved and what you'd do about it."

That loop is exactly the maintenance a busy operator skips when a client call runs long, and it's where ad budgets quietly leak. An agent runs it the same way every week without getting bored, which is the entire point. It isn't smarter than a good media buyer. It just never forgets to do the boring part.

The part that stays human

None of this fires the operator. It moves them off the clicking and onto the judgment.

You still decide which segments to chase, whether a creative angle is any good, whether a result is real or a measurement artifact, what to scale, and what to kill. Scale what's hitting your cost target with room left in the budget. Kill what's had enough spend to prove itself and hasn't.

The agent surfaces the numbers and runs the edits, you make those calls.

Try to run ads fully unattended and you'll learn fast why that fails.

The agent will happily optimize toward a conversion event that's mismeasured, or prune a keyword that was feeding your best account. The judgment stays yours.

The repetitive execution goes to the machine.

Where to start

Don't try to wire up all three platforms and twelve skills this weekend. Build it in order.

Clone the repo and read the foundations files first, before you connect anything. That alone is worth the download. Then connect one platform, the one you spend the most on, and stay in read-only until the audits earn their place. Hand over one job, negative keywords, and keep approving until it's boring. Add the fatigue checks, then the bid management, then the next platform.

Run the weekly ritual the whole time. You earn each layer.

Ivan walks through a full live build on camera in Claude Code for Ads if you want to see it running first. When you're ready to set it up yourself, comment "ads" and we'll send you the repo, free, along with the rest of our GTM stack. It's the same playbook we use to run $300K a month.

The only thing between you and running your paid motion from a terminal is the patience to set it up one step at a time.

Remix in YouMind

Turn one viral article into a full content workflow

Collect the source, decode the pattern, create assets, draft the story, and distribute from one AI workspace.

Explore YouMind
For creators

Turn your Markdown into a clean 𝕏 article

When you publish your own long-form writing, images, tables, and code blocks make 𝕏 formatting painful. YouMind turns a full Markdown draft into a clean, ready-to-post 𝕏 article.

Try Markdown to 𝕏

More patterns to decode

Recent viral articles

Explore more viral articles