Build
Custom MCP client
Apogee’s server is JSON-RPC over HTTPS. Use fetch, httpx, or any MCP Streamable HTTP client. This repo does not vendor an official SDK.
Compatible hosts include Cursor, VS Code, Claude (connectors), ChatGPT (developer connectors), Grok, Claude Code, Windsurf, and Codex CLI as configured on /connect. A custom app should POST to the canonical URL.
TypeScript (tested pattern)
fetch JSON-RPC
const MCP = process.env.APOGEE_MCP_URL ?? "https://apogeemcp.digital/api/mcp";
async function mcp<T>(method: string, params: unknown = {}, id = 1): Promise<T> {
const res = await fetch(MCP, {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({ jsonrpc: "2.0", id, method, params }),
});
if (res.status === 429) throw new Error("RATE_LIMITED");
const json = await res.json();
if (json.error) throw new Error(json.error.message);
return json.result as T;
}
const init = await mcp("initialize");
const { tools } = await mcp<{ tools: Array<{ name: string }> }>("tools/list");
const scan = await mcp("tools/call", {
name: "scan_token",
arguments: { query: "NVDA" },
});
console.log(init, tools.length, scan);Python (same protocol)
urllib JSON-RPC
import json, os, urllib.request
MCP = os.environ.get("APOGEE_MCP_URL", "https://apogeemcp.digital/api/mcp")
def mcp(method, params=None, id=1):
body = json.dumps({"jsonrpc": "2.0", "id": id, "method": method, "params": params or {}}).encode()
req = urllib.request.Request(MCP, data=body, headers={"content-type": "application/json"})
with urllib.request.urlopen(req, timeout=30) as res:
payload = json.loads(res.read().decode())
if payload.get("error"):
raise RuntimeError(payload["error"])
return payload.get("result")
mcp("initialize")
tools = mcp("tools/list")["tools"]
scan = mcp("tools/call", {"name": "scan_token", "arguments": {"query": "NVDA"}})
print(len(tools), scan["structuredContent"] if isinstance(scan, dict) else scan)Never commit secrets. There is no Apogee API key today. If you add your own proxy auth, use environment variables.
POSTs initialize and tools/list to this origin’s /api/mcp. No API key.