Skip to main content

How it works

Free credit, and your own key

The Tutor, Ask Northwind and the demos on the Northwind storefront call the real Claude API, and every call costs real money. To keep them free to try, and possible to keep running, each learner gets $2 of credit when they sign in with GitHub. When it runs out, you can keep going with your own Anthropic API key.

Why sign in at all

Reading the course needs no account, and it never will. Signing in is only for the parts that spend money on every click.

Before sign-in existed, those features ran on one shared key with a limit per internet connection. That limit could not tell one person from a script, or a workshop of thirty people behind one conference Wi-Fi from one person refreshing a page. Credit per person fixes both: you get your own allowance, and nobody else can use it up.

GitHub is the sign-in because almost everyone taking a course about an API already has an account, and because it can prove an account is not brand new, which is what keeps the free credit from being claimed over and over.

What signing in shares

  • No permissions. The site asks GitHub for no access at all: not your repositories, not your email, not your organizations.
  • Three facts are kept: your GitHub user id, your username, and when your account was created. Against those, the site stores how much credit you were given and how much you have used, in dollars. It does not store what you asked.
  • You stay signed in for up to 7 days. The record of your credit is deleted 180 days after you were last active.

The full detail is in the privacy policy and the cookie policy.

What $2 buys

Enough to work through a few Tutor sessions and try every demo, which is what it is for: deciding whether the course is worth your time. The labs themselves run on your own machine with your own key, about $4 in API calls over two days, so a learner going all the way will have a key anyway.

What you doUsually aboutMost it could cost
Live preview (as you type)under a cent
Classify a support ticket2–3 cents
Tutor: build a planabout 3 cents
Tutor: a hintabout 2 cents
Tutor: review your attemptabout 4 cents
Tutor: prepare a lesson5–10 cents
Ask Northwind: one question5–15 cents

The middle column is a rough guide, not a quote: real costs vary with how much you write and how warm the cache is. The right-hand column is exact, and it is what the meter sets aside. Typical costs are low because the course material is cached: after the first request, Claude reads most of each prompt at a tenth of the normal price. That is prompt caching, and Lab 5 is about exactly this.

How the meter counts

Nobody knows what a call costs until it has finished, and by then it has been spent. So before each call, the meter sets aside the most that call could possibly cost — the right-hand column above — and only runs it if that fits in what you have left. When the answer arrives, everything it did not use goes straight back.

This has two consequences worth knowing:

  • You are never cut off halfway through an answer. If a call starts, your credit already covered its worst case.
  • A call can be refused while you still have some credit. With $0.30 left, a Tutor lesson might not fit even though it would probably have cost a few cents. Cheaper features, like the live preview, keep working.

There is also a limit on free credit across everyone per day, so a busy day can pause it for everybody until midnight UTC. Your own key is never affected by that.

Bringing your own Anthropic key

When your credit runs out, or any time before, open the meter in the corner of any page and choose Use your own Anthropic key. From then on your requests run on your key, up to a spending limit you choose.

There are good reasons to do it even before the $2 is gone:

  • You need one for the labs anyway. The labs run on your own machine and call the API with your key.
  • You set the limit, not us. Nothing is refused for free credit; you pay what a call actually costs, directly to Anthropic, up to whatever limit you give the key.
  • You see the real bill. Your spend shows up in the Anthropic Console, which is a useful thing to watch while learning an API that charges per token.

Getting a key the safe way

  1. Sign in at console.anthropic.com and add a small amount of credit.
  2. Create a key under Settings → API keys just for this course, and give it a name you will recognise, such as “triage course”. A key used only here can be disabled without breaking anything else you run.
  3. Set a monthly spend limit for your organization in the Console. Anthropic does not offer limits per key, so the organization limit is the ceiling on what any key of yours can cost.
  4. Paste the key into the meter, and choose how much this site may spend with it: the field starts at $5, about a whole course with room to spare. It is checked with Anthropic, at no cost, before it is saved.

Your limit on this site

The limit counts everything spent with your key while it is stored here, and the meter shows how much of it you have used. You can raise it, lower it or remove it at any time from the meter.

  • It works like the free credit. Before each request, the most that request could cost is set aside, and it only runs if that fits under your limit; the unused part comes straight back. So a request is never cut off halfway, and several running at once cannot slip past the limit together.
  • Reaching it stops requests, not your work. You are told why, and the meter opens so you can raise the limit or stop there.
  • It starts again with the key. Remove the key, or let it expire, and a key added later starts from zero.

What it does not replace: this limit is enforced by this site’s own code. It stops this site spending more than you intended, from a long session or a bug. It cannot stop someone who had taken over the site, who would not go through that code, which is why the Console organization limit above still matters.

Is my key safe?

The short answer: with a spend limit set, the most it could ever cost you is that limit, and you can switch the key off yourself in seconds. Disabling a key in the Anthropic Console stops it everywhere at once, no matter what any website has stored. Everything below is how this site keeps you from needing to.

What protects it

If this happenedYour key is protected because
Someone got a copy of the databaseKeys are stored encrypted, and the encryption key is not in the database. A copy of the data alone does not reveal a key.
Another learner, or another of your own sign-ins, tried to use itEach key is locked to the sign-in it was entered in. Moved anywhere else, it does not decrypt.
A malicious script ran on the pageThe key is never sent back to the browser. After you save it, the page only ever receives its last four characters, so there is nothing on the page to steal.
An error was loggedAnything shaped like an API key is removed from error messages before they are logged, and keys are never put in URLs.
Anthropic rejected the keyIt is deleted, and you are told. The site does not switch to its own key and carry on, so it is always clear whose account a request was billed to.
This site spent more than you meant it toIt stops at the limit you set in the meter. Each request’s worst case is set aside before it runs, so even requests running at once cannot go past it together.
You forgot about itIt deletes itself after 24 hours without use, and immediately when you press Remove key or sign out.
This site itself was compromisedThis one cannot be ruled out. Whoever runs the site holds the encryption key, so an attacker with full control of the server could use keys stored or entered while they had it. That is exactly why the steps above say to use a key made just for this course, with a spend limit: the damage is capped, and the fix is one click in the Console.

For the technically curious: keys are encrypted with AES-256-GCM, with your session as authenticated data, which is what makes a copied key useless elsewhere. The API key itself only ever travels over HTTPS.

Don’t take our word for it

The course is open source, so every claim on this page can be checked against the code that does it:

Prefer your key never leaves your machine?

Then don’t paste it here. The whole course — the Tutor, Ask Northwind and the storefront demos — runs on your own computer with npm run dev:all, using a key in storefront/.env.local. Locally there is no sign-in and no credit, and your key goes only to Anthropic. The setup guide covers the first steps.

Common questions

My GitHub account is new and I got no credit.

Accounts younger than 30 days get no free credit, and there is a limit on new grants per day. Both are what stop the credit being farmed with throwaway accounts. Everything else works with your own key.

I am in a workshop.

Sign in before the session starts. If your facilitator gave you an API key, paste that into the meter. Facilitators can also raise the credit for a whole group.

Can I stop using my key?

Yes. Open the meter and press Remove key, or sign out, and the stored copy is deleted. To be certain it can never be used again by anyone, disable it in the Anthropic Console as well.

Does signing in give the site access to anything else?

No. It decides who pays for an AI request and nothing more.

Something here unclear, or a question it does not answer: merlynn@gmail.com. The design behind it is written up in the course repository.