MEGA.dev·training challenges

MEGA Challenge

Every Lesson ends with a Challenge, and you don't take it on alone: you work it together with your LLM harness. It reads fast and runs things; you read closely, decide and steer. Each solve leaves your harness better equipped, and a debrief shows you exactly what changed.

03:12 job started author: —

Start here Browse the Challenges

Start here

  1. Connect your harness

    Your harness is the AI agent you work with, for example Claude Code, Codex, Cursor or VS Code with Copilot. Paste this prompt into it. The agent adds the course's MCP server, tells you what the sign-in needs from you, and checks that the connection works.

    Setup prompt
    I'm a student in the MEGA.dev course, and you are my AI agent (my harness). Connect yourself to the course's MCP server. This is my own request.
    
    - Server name: mega-challenge
    - URL: https://hq.mega.dev/mcp (Streamable HTTP, OAuth sign-in)
    - Setup notes for each client: https://hq.mega.dev/llms.txt
    
    1. If you can already call the tools of the mega-challenge server in this session (for example list-challenges), go to step 5.
    2. Add the server to your own MCP configuration, with the name and URL above. Use your client's own command or config file; https://hq.mega.dev/llms.txt has them for common clients. If you cannot add MCP servers yourself, tell me which client you are and give me the exact command or config. I will add it.
    3. Before the sign-in starts, tell me in a few lines what it asks of me: a browser opens the course sign-in page; I type the email I enrolled with; the course mails me a one-time link; I open it in that same browser within 15 minutes (pasted into its address bar if my mail app opens links elsewhere); then I press Sign in and Approve.
    4. A new server is often not loaded in a session that is already running. If you cannot call its tools now, tell me exactly how to reload your MCP servers or start a new session, and to paste this prompt again there. Do not call the URL yourself and do not run the OAuth flow by hand: your client's own sign-in does it. Never ask me to paste a callback URL to you.
    5. Call list-challenges. Tell me that the connection works, and list the titles it returns. Do not start a Challenge yet: I will send the next message.
    
    Write to me in plain technical English: short sentences, one idea each, one message per step.

    Your agent cannot add servers itself, or you want to do it by hand? Open your client below. The server name is mega-challenge, and the URL is https://hq.mega.dev/mcp.

    Claude Code
    1. Add the server for all your projects. Run this in a terminal:

      claude mcp add --transport http mega-challenge --scope user https://hq.mega.dev/mcp
    2. Sign in. Run this, then finish the sign-in in the browser that opens:

      claude mcp login mega-challenge
    3. Or sign in from a Claude Code session: type /mcp, select mega-challenge, and follow the steps in your browser. If mega-challenge is not in the list, start a new session.

    Checked on 2026-10-09 against the Claude Code docs.

    Codex CLI
    1. Add the server. Run this in a terminal:

      codex mcp add mega-challenge --url https://hq.mega.dev/mcp
    2. Sign in. Run this, then finish the sign-in in your browser:

      codex mcp login mega-challenge
    3. To check, type /mcp in the codex terminal UI. It lists your active servers.

    Checked on 2026-10-09 against the Codex CLI docs.

    Cursor
    1. Open ~/.cursor/mcp.json (make the file if it does not exist) and add the server. If the file already has servers, add only the mega-challenge entry inside mcpServers:

      {
        "mcpServers": {
          "mega-challenge": {
            "url": "https://hq.mega.dev/mcp"
          }
        }
      }
    2. Open Customize in the Cursor sidebar and find mega-challenge. When Cursor asks you to sign in to it, do so in the browser that opens.

    3. No connection? Open the Output panel (Cmd+Shift+U) and select "MCP Logs".

    Checked on 2026-10-09 against the Cursor docs.

    VS Code (GitHub Copilot)
    1. Open the Command Palette (Cmd+Shift+P on macOS, Ctrl+Shift+P on Windows and Linux) and run MCP: Open User Configuration. Add the server inside servers:

      {
        "servers": {
          "mega-challenge": {
            "type": "http",
            "url": "https://hq.mega.dev/mcp"
          }
        }
      }
    2. Save the file. When VS Code asks, confirm that you trust the server. On the first connection, VS Code opens a browser window for the sign-in.

    3. To start it or read its log, run MCP: List Servers, select mega-challenge, and choose an action.

    Checked on 2026-10-09 against the VS Code (GitHub Copilot) docs.

    Claude Desktop
    1. Go to Customize > Connectors. Click + Add, then Add custom connector.

    2. Enter the name mega-challenge and this remote MCP server URL, then click Continue:

      https://hq.mega.dev/mcp
    3. Keep the authentication settings Claude found and click Continue. Under Authentication, choose Sign in now. Under OAuth client, choose Register automatically. Click Add, then finish the sign-in in your browser.

    4. In a chat, click + (lower left), then Connectors, and turn on mega-challenge.

    5. Claude connects to the server from Anthropic's cloud, not from your computer. On the Free plan you can add one custom connector.

    Checked on 2026-10-09 against the Claude Desktop docs.

    Another client? Add the URL as a remote (Streamable HTTP) MCP server, the way its docs say. After you add a server, reload your client's MCP servers or start a new chat: a running session often does not see a new server.

  2. Sign in

    The first time your harness uses the server, it asks you to sign in. This is what happens:

    Already signed in to this site in that browser? Then you skip the email and only approve.

    Did the sign-in end on a 127.0.0.1 or localhost page that does not load? Then your harness was not listening. Reload it and sign in again from its own button. Do not paste that address to your agent in the chat.

    To see the Challenges on this site too, log in here with the same email.

  3. Start a Challenge

    When the connection works, open the Challenges page and copy the starter prompt there. Start a new chat with your harness and paste it as the first message. It names no Challenge: your harness finds the open ones and tells you what one asks of you both.

    After the solve, your harness writes a debrief. Read it on the Challenge's page, then ask your harness what changed in your setup.

What you're here for

Something is already running

For your harness

Written for the LLM reading this page. Human: read along, it says when you're needed.

This is the MCP server for the MEGA.dev course. Your human is a Student in the course. Each Lesson has a Challenge, and you solve it with them, not for them. Only enrolled Students can sign in.

  1. Connect. MCP endpoint (Streamable HTTP): https://hq.mega.dev/mcp, server name mega-challenge. Add it yourself if your client lets you. If you cannot add servers yourself, give your human the exact command or config for your client (see Per-client setup in /llms.txt).
  2. Authenticate (needs your human). OAuth 2.1: on a 401, follow the WWW-Authenticate resource-metadata pointer. Before the sign-in starts, tell your human what it asks of them: their enrolled email, then a one-time link mailed to it, opened in the same browser within 15 minutes (pasted into its address bar if their mail app opens links elsewhere), then Sign in and Approve. Only they get the mail: tell them what is coming, then wait. Open the sign-in URL once, in one browser: the one you will drive for the Challenges if you have one, else your human's. Not loaded in this session? Do not call the endpoint or run OAuth yourself. Give your human the install step and ask them to reload or start a new chat; your client's own sign-in finishes it. Never ask your human to paste a callback URL.
  3. Discover. Call list-challenges. Its reply and each Tool's description say how to work a Challenge with your human; read them before you act.
  4. Work it together. Do what you can yourself, and say what you plan before you do it. When you are blocked, or a Challenge asks for your human (a sign-in, a decision to make), stop and tell them exactly what you need. Do not guess around it. Some Challenges need a browser you can drive, signed in as your human; if you have none, ask them to help you set one up.
  5. Debrief. Once a claim is accepted, call debrief. Write it for a human who did not watch the session, including the moves they never saw.

Machine-readable pointer, with the setup for each client: /llms.txt.