2  API Key

3 API Key

AI-powered feedback in this book uses the Fireworks AI API. To run the exercises interactively you need a Fireworks API key — the book never asks for any other key.

3.1 Get a key

Create a Fireworks account and generate an API key from the Fireworks console. Keys look like fw_....

3.2 Enter your key

Loading API key settings…

Enter your key above once. It is stored only in this browser’s localStorage and shared across every chapter of the book, so you do not re-enter it per exercise. When an exercise runs, the key is sent only in an Authorization: Bearer header to api.fireworks.ai. It is never logged, never echoed back into the page, and never sent to any other server.

3.3 Serve the book over HTTP

The key page and the exercises use localStorage and JavaScript ES modules, both of which are blocked when a page is opened from the local filesystem (file://). Serve the rendered book over HTTP instead — from the demo-book/_output/ directory:

python3 -m http.server 8000

…then open http://localhost:8000/api-key.html.