> ## Documentation Index
> Fetch the complete documentation index at: https://adadvisor.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# AdAdvisor Foundation Skill: Account Discovery and Unit Economics

> The AdAdvisor foundation skill auto-loads on every session. Handles Meta (Facebook) account discovery, business-context grounding, unit economics, and KPI decoding that every other AdAdvisor skill depends on.

The **foundation skill** is the floor every other AdAdvisor skill stands on. It loads automatically whenever you mention AdAdvisor, Meta (Facebook) ads, or your ad account, and it sets the conventions every chained skill builds on. You do not invoke it directly. Install it once and let it work in the background.

## What does the foundation skill do?

Before any analysis or mutation, the foundation skill walks Claude through four mandatory checks:

<Steps>
  <Step title="Account discovery">
    Calls `adadvisor:list_ad_accounts` to find every account you have access to. If you have multiple, it asks which one to work on rather than guessing.
  </Step>

  <Step title="Data freshness check">
    Verifies `data_synced` is true on the chosen account. If the initial import is still running, Claude tells you to wait instead of working on incomplete numbers.
  </Step>

  <Step title="Business context grounding">
    Reads the `adadvisor://account/{id}/context` resource to pull your break-even ROAS, AOV, target CPL, daily budget cap, and brand details. Every recommendation downstream is scored against these.
  </Step>

  <Step title="Pixel sanity check">
    Confirms your Meta pixel is firing recently and matches your storefront URL. If it is broken, every performance read is unreliable. Claude flags this before going further.
  </Step>
</Steps>

After these four checks, Claude routes to the specific workflow skill (audit, diagnose, launch, etc.) based on what you asked for.

## What mental models does the foundation skill load?

Beyond the four opening checks, the foundation skill loads four mental models that all other skills assume:

<Columns cols={2}>
  <Card title="Unit economics" icon="calculator">
    Break-even ROAS = 1 divided by contribution margin. Target ROAS = break-even multiplied by (1 + profit margin). Kill thresholds expressed in multiples of target CPA, never absolute dollars.
  </Card>

  <Card title="KPI decoding" icon="filter">
    Use `result_count`, `cost_per_result`, and `conversion_result_name` over legacy `purchases` and `revenue`. Subscribe and Lead campaigns return 0 on the legacy fields. Using them gives wrong answers.
  </Card>

  <Card title="Naming and currency" icon="hashtag">
    Currency values in major units always (50.0 means \$50, not 5000 cents). Names auto-generate to a structured `ADADVISOR || CBO/ABO || strategy || business || date` pattern unless you have an existing convention.
  </Card>

  <Card title="Activation invariants" icon="play">
    Every created entity starts PAUSED. Activation does not cascade. Resuming the campaign does not resume its ad sets or ads. You activate each level explicitly.
  </Card>
</Columns>

## When does the foundation skill trigger?

The foundation skill loads on virtually any AdAdvisor session. Triggers include:

* "adadvisor"
* "meta ads", "facebook ads", "instagram ads"
* "my ad account", "look at my ads"
* "let's work on my account", "connect my meta"
* Any time another AdAdvisor MCP tool is about to be called

Other skills (audit, diagnose, launch, scale, creative, targeting, playbooks) all chain on top of the foundation. They assume the four opening checks have happened.

## What anti-patterns does the foundation skill prevent?

<AccordionGroup>
  <Accordion title="Quoting ROAS without business context">
    Bad: "ROAS is 4.2x." Good: "ROAS is 4.2x against your 3.3x break-even. Profitable, but margin is thinner than the 5x target you would usually scale on."
  </Accordion>

  <Accordion title="Budget unit errors">
    Bad: passing `daily_budget: 5000` and accidentally creating a \$5,000 a day campaign. Good: always major units in account currency. The skill reminds Claude on every budget call.
  </Accordion>

  <Accordion title="One-day decision making">
    Bad: "CPA is up today, let's kill the campaign." Good: "We're at 1.4x target for one day, within normal variance. Kill threshold is 3x target with zero conversions over 3 days."
  </Accordion>

  <Accordion title="Forgetting `conversion_domain` on `create_ad`">
    Bad: Meta rejects with subcode 2490408. Good: the skill reminds Claude to pass the registrable second-level domain (e.g. `example.com`, not `shop.example.com`) on every pixel-optimized ad creation.
  </Accordion>

  <Accordion title="Reporting 'campaign is active' after resuming only the campaign">
    Bad: ads stay paused if their parent ad sets were not also resumed. Good: the skill instructs Claude to activate leaf-up (ad, then ad set, then campaign) and confirm `state_after` at each level.
  </Accordion>
</AccordionGroup>

## How do I install the foundation skill?

<Columns cols={2}>
  <Card title="Claude Code" icon="terminal" href="/skills/install-claude-code">
    The foundation ships with the full plugin. One install command, all eight skills.
  </Card>

  <Card title="Claude.ai & Desktop" icon="cloud" href="/skills/install-claude">
    Upload the foundation ZIP alongside any other skills you want.
  </Card>
</Columns>

<Note>
  Source code for this skill (including its `references/`) lives in [github.com/AdAdvisor/skills](https://github.com/AdAdvisor/skills/tree/main/skills/adadvisor). The whole repo is Apache 2.0. Fork it and modify the thresholds to match your business.
</Note>

## Frequently asked questions

<AccordionGroup>
  <Accordion title="What does the AdAdvisor foundation skill do?">
    The foundation skill performs four mandatory checks at the start of every session: account discovery (which Meta ad account to work on), data-freshness verification, business-context grounding (break-even ROAS, AOV, target CPL), and pixel sanity check. It also loads four mental models (unit economics, KPI decoding, naming/currency conventions, activation invariants) that every other AdAdvisor skill assumes.
  </Accordion>

  <Accordion title="Do I have to install the foundation skill?">
    Yes. Every other AdAdvisor skill (audit, diagnose, launch, scale, creative, targeting, playbooks) chains on top of the foundation. Without it, the other skills lack the break-even ROAS, target CPA, and pixel choice they need to score performance correctly.
  </Accordion>

  <Accordion title="Why does Claude default budget units to major units (dollars) not cents?">
    Because Meta's API uses minor units (cents) and the MCP server converts for you. Passing `daily_budget: 5000` thinking in cents would create a $5,000 a day campaign rather than $50. The foundation skill reminds Claude on every budget call to use major units in account currency.
  </Accordion>

  <Accordion title="Why does the foundation skill insist on reading the context resource?">
    Generic "good ROAS" is not actionable. The same 4x ROAS is profitable on a high-margin SaaS and unprofitable on a low-margin apparel brand. The context resource carries your break-even ROAS, AOV, target CPL, and daily budget cap so every recommendation is scored against your business, not industry averages.
  </Accordion>

  <Accordion title="When does the foundation skill auto-trigger?">
    On virtually any AdAdvisor session. Phrases like "adadvisor", "meta ads", "facebook ads", "my ad account", "look at my ads", "connect my meta", and any direct mention of an AdAdvisor MCP tool all load the foundation.
  </Accordion>
</AccordionGroup>

## Related skills

<Columns cols={3}>
  <Card title="Audit" icon="magnifying-glass" href="/skills/adadvisor-audit">
    The next step after foundation completes. Pixel, then structure, then performance, then red flags.
  </Card>

  <Card title="Diagnose" icon="stethoscope" href="/skills/adadvisor-diagnose">
    Performance investigation grounded in the foundation's unit economics.
  </Card>

  <Card title="Launch" icon="rocket" href="/skills/adadvisor-launch">
    Campaign creation that uses the foundation's pixel choice and naming conventions.
  </Card>
</Columns>
