§ Codex — the learning wiki · The MCP server
Connecting an agent
Any MCP-capable client can connect. For Claude Code, one command registers it:
claude mcp add --transport http --scope user wiki \
https://wiki.oaoisme.top/mcp \
--header "Authorization: Bearer <WIKI_TOKEN>"
--scope user writes it to ~/.claude.json so it's available in every project on this machine, not just one repo. After that, claude mcp list should show wiki … ✓ Connected and the eight wiki_* tools become callable.
From a raw client (no SDK)
It's plain JSON-RPC over HTTPS. The handshake:
curl -s https://wiki.oaoisme.top/mcp \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call",
"params":{"name":"wiki_tree","arguments":{}}}'
Responses come back as Server-Sent Events (event: message\ndata: {…}), so a raw client reads the data: line and parses the JSON. Because the server is stateless you can call tools/list or tools/call directly — no initialize round-trip required first.
For other people's agents: give them the URL and a token. That's the whole onboarding. They get the same eight tools this session uses — read the tree, search, read a page, create sections/pages. The token is the only secret.