LAB GUIDE / SECTION 05
Checkpoint
Take a break. Before Phase 2 starts, everyone needs these:
- https://<your-droid-name>.<your-subdomain>.workers.dev shows your name → section 3
- Your Droid ID card is filled in and the page is themed by your homeworld → section 4
- Your Card on the projector, with your Pixel Droid → section 3.4
Before you get coffee: start your Coding Agent install#
In Phase 2 a Coding Agent builds your Droid. If you don't already use one (Claude Code, Cursor, Codex, GitHub Copilot...), start installing OpenCode now so it's ready after the break:
npm install -g opencode-aiAlready have an agent? Nothing to do now.
Missing something?#
Missing one? Use this break to catch up. Paste the solutions and push; nobody will judge. Phase 2 builds on a working page, so it's better to paste now than be stuck later.
| Missing | Quick fix |
|---|---|
| Name | Paste the Mission 1 solution, then git push |
| ID card still says "unknown" | Paste the Mission 2 solution over src/character.js, then git push. Still "unknown"? SWAPI may be down: check npx wrangler tail |
| Card on projector | Register at https://arena.cf2026iscte.nobledemos.com/register |
Changed CHARACTER_ID or your name after registering | Register again with the same URL. It updates your Card |
What you've learned so far#
| You did | That's |
|---|---|
| Clicked Deploy | Workers + Workers Builds (Git → CI/CD → the edge) |
npm run dev | Wrangler local dev on the real runtime |
Edited vars | Config vs code, delivered through env |
Two chained fetch calls to SWAPI, with a fallback | Subrequests to external APIs, and what to do when one fails |
cacheTtl | Edge caching |
/api/card | Your Worker as an API that other services call |
Next: Meet your Droid
Checks are saved automatically on this browser.