Configure the k9 MCP Server
The k9 MCP server brings Reachable Risk to your AI coding agent. It scores your CVE and dependency backlog by what is actually reachable in your code and actively exploited in the wild (KEV + EPSS), and returns a Fix Today / Schedule / Defer verdict with the evidence behind each call. Your agent supplies the reachability read; k9 supplies KEV + EPSS and the verdict.
It runs as a remote MCP server. Your agent connects over HTTP and you sign in with your k9 account on first connect. There is no API key or token to copy.
Before you start
- A k9 account. Sign up at https://www.k9security.io/lp/reachable-risk/ (7-day free trial, no card). The trial clock starts on your first scored finding.
- Endpoint:
https://mcp.k9security.io/mcp(Streamable HTTP). - Authentication: OAuth. On first connect your agent opens a browser to sign into your k9 account. No API key.
- Tools:
lookup_kev,lookup_epss,score_risk. - Prompts:
risk_scoring_rubric, plus the Reachable Risk workflow:fetch_dependency_alerts,score_dependency_alerts,fix_dependency_alerts. Agents that surface MCP prompts expose these as slash commands; others can read the matchingk9://workflow/…resource.
Many agents accept the generic mcpServers config-block form:
{
"mcpServers": {
"k9": {
"type": "http",
"url": "https://mcp.k9security.io/mcp"
}
}
}
Claude (claude.ai and Claude Desktop)
- Open Settings → Connectors → Add custom connector.
- Paste the k9 MCP server URL and click Add:
https://mcp.k9security.io/mcp
Claude opens a browser to sign into your k9 account on first connect.
Claude Code
There are several ways to register an MCP server with Claude Code. The simplest:
claude mcp add --transport http k9 https://mcp.k9security.io/
Claude Code opens the browser sign-in on first use. Config-file equivalent: add the generic mcpServers block above to ~/.claude.json.
Opencode
-
Add k9 to
opencode.json(project root, or global~/.config/opencode/opencode.json). Opencode uses its ownmcpkey withtype: remote(not themcpServersform):json { "$schema": "https://opencode.ai/config.json", "mcp": { "k9": { "type": "remote", "url": "https://mcp.k9security.io/mcp", "enabled": true } } } -
Authorize from the command line:
opencode mcp auth k9This opens your browser to sign into your k9 account. This step is required. Opencode does not start the OAuth flow from inside its TUI, so if you skip it, k9 shows as "not connected."
-
Confirm the connection: run
opencode mcp listandk9should show connected.
Notes
- If you rename the server in
opencode.json, re-runopencode mcp auth <new-name>, since stored tokens are keyed to the server name. - Manage auth with
opencode mcp auth k9,opencode mcp list, andopencode mcp logout k9. Tokens are stored at~/.local/share/opencode/mcp-auth.json.
VS Code (GitHub Copilot)
VS Code uses its own servers config key (not the mcpServers form). For a user-level (global) server, open the Command Palette and run MCP: Open User Configuration. This opens mcp.json in your VS Code profile folder. Then add a k9 server object under the servers key:
{
"servers": {
"k9": {
"type": "http",
"url": "https://mcp.k9security.io/mcp"
}
}
}
Workspace-level equivalent: put the same content in .vscode/mcp.json at your project root. For the full configuration reference, see the VS Code docs on adding an MCP server.
Then:
- VS Code shows a Start action above the server entry. Click it and approve the Trust prompt.
- VS Code opens a browser to sign into your k9 account. No API key.
- Use k9 from the Copilot Chat view in Agent mode. k9's tools appear in the tools picker, and the workflow prompts are available as slash commands (see below).
Using the k9 prompts in VS Code
In the Copilot Chat view, type / and pick the prompt using VS Code's MCP prefix, /mcp.k9.<prompt>:
/mcp.k9.fetch_dependency_alerts/mcp.k9.score_dependency_alerts/mcp.k9.fix_dependency_alerts/mcp.k9.risk_scoring_rubric
k9's resources appear under the server entry's More… menu and via Add Context… → MCP Resources.
Use the Copilot Chat view, not the Agents window. VS Code's separate Agents window (Preview) runs Copilot CLI and Cloud agent sessions, which can only reach local MCP servers that do not require authentication. k9 is a remote, OAuth-authenticated server, so it is unreachable there:
/mcp.k9.*prompts fail to resolve and the agent improvises its own steps instead. This is a VS Code client limitation. See the VS Code docs on Copilot CLI session limitations.
Other agents
Other MCP-capable agents (Cursor, OpenAI Codex CLI, Gemini CLI, and more) connect the same way. The endpoint and OAuth model are identical; only the config format and the auth trigger differ. Most read the generic mcpServers block above. For example, Cursor reads it from ~/.cursor/mcp.json (global) or .cursor/mcp.json (project).
If you get an agent connected and want us to document it here, reach out to support@k9security.io.
Score your first findings
In a repository with Dependabot alerts (or any CVE findings), ask your agent something like:
Please retrieve all of this project's open Dependabot alerts and score them for reachable risk.
Your agent gathers the findings and the reachability context; score_risk returns the FIX_TODAY / SCHEDULE / DEFER verdict with KEV + EPSS evidence. Your first scored finding starts the 7-day trial clock.
If your agent surfaces MCP prompts, you can run the same workflow as slash-command prompts instead of prose (see the per-agent sections above for the exact prefix).