MCP server
portscan.com speaks the
Model Context
Protocol over Streamable HTTP, so an AI agent can scan
ports as a native tool. Endpoint:
https://api.portscan.com/mcp. Two tools,
fast_scan and deep_scan. No key,
no signup.
How it works
- Scans your own IP. There is no target argument. By policy portscan only scans the public IP the request comes from, so a tool call scans the egress IP of the machine running your MCP client.
-
Non-blocking, poll by re-calling. A scan
takes ~20s (fast) to 1-5 min (deep). The call returns
immediately: it starts a scan if none is running, else
returns the current state. Call the tool again until
statusiscomplete. The(ip, scan_type)pair is the durable handle, so no session is needed. -
Results. When complete the tool returns
ports_open(port, service, banner),ports_filtered, the PTR record, and the duration. Anincompletestatus carries partial results flaggedpartial:true. -
Rescan. Pass
rescan:trueto force a fresh scan when a recent result already exists for your IP.
Tools
| Tool | Scans | Input |
|---|---|---|
| fast_scan | 32 common TCP ports (~20s) | rescan? (bool) |
| deep_scan | all 65535 TCP ports (~1-5 min) | rescan? (bool) |
Connect your client
Claude Code
claude mcp add --transport http portscan https://api.portscan.com/mcp
Cursor, Windsurf, Claude Desktop (MCP config)
{
"mcpServers": {
"portscan": { "url": "https://api.portscan.com/mcp" }
}
}VS Code (GitHub Copilot)
code --add-mcp '{"name":"portscan","type":"http","url":"https://api.portscan.com/mcp"}'Gemini CLI (~/.gemini/settings.json)
{
"mcpServers": {
"portscan": { "httpUrl": "https://api.portscan.com/mcp" }
}
}Codex (~/.codex/config.toml)
[mcp_servers.portscan] url = "https://api.portscan.com/mcp"
Antigravity (~/.gemini/antigravity/mcp_config.json)
{
"mcpServers": {
"portscan": { "serverUrl": "https://api.portscan.com/mcp" }
}
}ChatGPT
Turn on Developer mode (Settings, Apps and
Connectors, Advanced), create a connector, and paste
https://api.portscan.com/mcp as a Streamable HTTP endpoint with no
authentication. Requires a paid plan.
Raw protocol
Stateless JSON-RPC 2.0 over a single POST. List the tools:
curl -s https://api.portscan.com/mcp \
-H 'Content-Type: application/json' \
-H 'Accept: application/json, text/event-stream' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'Spec and registry
The transport is Streamable HTTP, stateless (no
Mcp-Session-Id). This aligns with the
2026-07-28 revision, which deprecates the
old HTTP+SSE transport, removes sessions, and moves
long-running work to the Tasks extension. Because the handle
is the caller IP, the same poll-by-recall flow works on both
today's spec and the Tasks model (where the task id is just
ip:scan_type).
Registry listing:
com.portscan/port-scanner. Manifest:
server.json.
See also the
HTTP API docs.