Your API key

Margaret uses Claude — Anthropic's AI — to run your helpers. To do that, it needs an API key: a unique code that connects Margaret to your Anthropic account so Claude can process your requests.

This is called BYOK — Bring Your Own Key. It means Margaret never handles billing on your behalf. You pay Anthropic directly, at their standard rates, for exactly what you use. Nothing more.

Getting an API key

  1. Go to console.anthropic.com and create an account (or sign in if you have one)
  2. Once you're in, go to API Keys in the left menu
  3. Click Create Key, give it a name (e.g. "Margaret"), and copy it immediately — you won't be able to see it again
  4. Paste it into Margaret's setup screen or Settings

That's it. Margaret stores the key securely in your Mac's system keychain — the same place your saved passwords live. It's never written to a file or sent anywhere other than Anthropic.

What does it cost?

You pay Anthropic per use, based on how much text goes in and comes out of each run. The amounts are small — most individual runs cost between $0.001 and $0.05 depending on the model and how long the output is.

Margaret shows you an estimated cost after every run so you always know what you've spent.

Rough guide by model

ModelBest forApproximate cost per typical run
Haiku 4.5Short, simple tasks$0.001 – $0.005
Sonnet 4.6Most tasks$0.005 – $0.02
Opus 4.7Complex analysis, long documents$0.02 – $0.10

These are rough estimates. The actual cost depends on the length of your input and how much Margaret writes back. You can see your exact spend in your Anthropic console at any time.

Adding credit to your Anthropic account

New Anthropic accounts start with a small free credit. Once that's used up, you add credit in the Anthropic console under Billing. There's no subscription — you add what you want and it gets used as you go.

A £20–£30 top-up will last most people several months of regular use.

Keeping your key safe

  • Don't share your API key with anyone
  • If you think it's been compromised, go to the Anthropic console and delete it immediately, then create a new one
  • You can clear your key from Margaret at any time in Settings — this doesn't delete it from Anthropic, just removes it from your Mac

What if I don't have a key yet?

You can still use Margaret to create and organise helpers — you just won't be able to run them until you add a key. The setup screen has a "skip for now" option if you want to explore first.