Use DownBad in VS Code with GitHub Copilot
Goal: GitHub Copilot in VS Code reads your DownBad monitors and incidents, works out why an incident happened, fixes it in your code, and has DownBad confirm the fix.
Copilot reaches DownBad’s MCP server (MCP, the Model Context Protocol, is the standard way AI assistants reach other services). In the Chat view, choose Copilot in the Session Target dropdown first: the steps below set up servers for Copilot sessions.
| Way | Address | Good for |
|---|---|---|
| Sign in to DownBad | https://mcp.downbad.app/mcp | Your own machine, no key to keep |
| An API key | https://mcp.downbad.app/mcp | A shared project file, with the key kept outside it |
| No account | https://mcp.downbad.app/tools | Trying the health check and DownBad’s status only |
The tools themselves, and which need a paid plan, are listed in Connect an AI Assistant with MCP.
Connect by signing in
Section titled “Connect by signing in”-
Run Chat: Open Customizations from the Command Palette and select MCP Servers. Select Add Server (+) in the User group.
-
Choose HTTP (HTTP or Server-Sent Events) and enter
https://mcp.downbad.app/mcp. -
Enter
downbadas the server ID. -
Select Global, then Copilot Global. This saves DownBad in your own Copilot settings, so it works in every project, and in Copilot CLI on the same computer.
-
Complete the sign-in prompt when VS Code shows it. If it doesn’t, open the ellipsis (…) menu next to downbad in MCP Servers and choose Authenticate when it’s offered. Your browser opens DownBad.
-
Sign in to DownBad if you aren’t already. On DownBad’s Connect an app page, check the app’s name and the address it sends you back to, choose Read only or Read and write, and choose Approve. That page, and what each choice allows, is shown in Connect and Disconnect Apps.
Or edit the file yourself
Section titled “Or edit the file yourself”Copilot Global is a file, ~/.copilot/mcp-config.json (or
mcp-config.json in the folder COPILOT_HOME names, if you set it). To
share DownBad with everyone working in one project instead, put the same
entry in a file named .mcp.json at the project’s root folder and commit it.
{ "mcpServers": { "downbad": { "type": "http", "url": "https://mcp.downbad.app/mcp", "tools": ["*"] } }}"tools": ["*"] lets Copilot use every DownBad tool. It doesn’t turn off
Copilot’s approval of each tool call. Then sign in as in step 5.
Older guides put servers in .vscode/mcp.json under a servers key. That
format belongs to VS Code’s older built-in agent, which is deprecated, so
use mcpServers in the files above.
Or install with one link
Section titled “Or install with one link”Install DownBad in VS Code opens DownBad’s server page in VS Code, so you can review it before you install it. Then sign in to DownBad when VS Code asks. VS Code keeps a server added this way in its own settings, not in the files above.
Connect with an API key
Section titled “Connect with an API key”Make a key first, named VS Code:
Create and Revoke API Keys. Then put
this in ~/.copilot/mcp-config.json, or in .mcp.json at a project’s root
folder:
{ "mcpServers": { "downbad": { "type": "http", "url": "https://mcp.downbad.app/mcp", "headers": { "Authorization": "Bearer ${DOWNBAD_API_KEY}" }, "tools": ["*"] } }}${DOWNBAD_API_KEY} reads the key from an environment variable of that
name (a value your computer hands to programs it starts), so the key isn’t
saved in a file you might commit. Set the variable before starting VS Code.
Write it with the braces: VS Code reads a bare $DOWNBAD_API_KEY as plain
text.
Copilot’s files can’t ask you for a key when the server starts, so an environment variable is the way to keep it out of the file.
Connect without an account
Section titled “Connect without an account”Put this in ~/.copilot/mcp-config.json, or in .mcp.json at a project’s
root folder:
{ "mcpServers": { "downbadTools": { "type": "http", "url": "https://mcp.downbad.app/tools", "tools": ["*"] } }}It gives run_health_check and get_downbad_status only.
Expected result: ask Copilot “List my DownBad monitors”. It calls
list_monitors and answers with your monitors. Expand the tool call in the
chat to check it came from DownBad: an answer with no tool call doesn’t
prove the connection works.
Have DownBad start your agent
Section titled “Have DownBad start your agent”The steps above have you ask your assistant. An agent webhook works the other way round: when DownBad confirms an incident, it sends the details to your agent and starts it, and again when the incident recovers. It’s a webhook channel on a paid plan, with one of three destinations:
- Claude Code Routine: starts a Claude Code routine, which can then use this connection to read the incident and recheck.
- GitHub repository_dispatch: starts whichever workflow or agent runs in your repository.
- Agent Webhook: the signed incident payload for any other agent.
Troubleshooting
Section titled “Troubleshooting”VS Code keeps a log for each server. In Chat: Open Customizations › MCP Servers, open the ellipsis (…) menu next to downbad and choose Show Output. MCP: List Servers in the Command Palette offers the same.
downbad doesn’t appear, or won’t start
Section titled “downbad doesn’t appear, or won’t start”-
Check Copilot is chosen in the Session Target dropdown.
-
If you edited a file yourself, check it’s one Copilot reads,
~/.copilot/mcp-config.jsonor.mcp.jsonat the project’s root, that it usesmcpServers, notservers, and that it’s valid JSON. -
Check the address is exactly
https://mcp.downbad.app/mcp. -
A project’s
.mcp.jsononly starts in a trusted folder. If VS Code opened the project in Restricted Mode, trust the folder first. -
Check DownBad itself at downbad.app. If it’s down for everyone, wait.
DownBad says you need to sign in
Section titled “DownBad says you need to sign in”The sign-in or key stopped working: it was revoked, it expired, or the
person who made it left the account. Choose Authenticate for
downbad when it’s offered, or make a new key. With a key, check DOWNBAD_API_KEY
was set before VS Code started. The reasons DownBad gives are in
MCP Connection Problems.
Your organization blocks the server
Section titled “Your organization blocks the server”If your company manages Copilot, an administrator may allow only listed MCP
servers. Ask them to allow https://mcp.downbad.app/mcp. Your own settings
can’t override that.
DownBad’s page refuses to connect VS Code
Section titled “DownBad’s page refuses to connect VS Code”The Connect an app page says why: a Viewer can approve Read only, the request expired, or your sign-in has no DownBad account. Each case and its fix is in Connected App Refused.
A tool is refused
Section titled “A tool is refused”Copilot passes on DownBad’s reason: the rule, what to do, and when to try again. A tool that changes your account needs Read and write access on a paid plan; a recheck needs the Pro plan or above. Find the rule in MCP Connection Problems.
Still stuck
Section titled “Still stuck”Collect the lines from Show Output, the tool that failed and its error word for word, and when it happened. Never include a whole key. Then send it to us through Contact Us.