← Agent setup

Codex

Register the server with the Codex CLI; the bearer header is read from the env var.

Updated

Add to Claude

1. Get a token

A workspace owner issues a credential at /mcp. Start with read-only scopes: article:read, brand:read, campaign:read. Export it in your shell profile:

export UPRANK_MCP_TOKEN="<your token>"

2. Register the server

~/.codex/config.toml

Endpoint https://uprank.devino.ca/api/mcp, streamable HTTP with a bearer header read from UPRANK_MCP_TOKEN.

codex mcp add uprank --url https://uprank.devino.ca/api/mcp --bearer-token-env-var UPRANK_MCP_TOKEN

Check that Codex loaded the server

Run codex mcp list and check that uprank is among the configured servers. Inside the Codex TUI, /mcp shows the active MCP servers.

codex mcp list

3. Verify

Ask the agent to call article_list with { "pageSize": 1 }. A JSON result with items and nextCursor means the connection and scopes are good. A 401 means the token is missing, revoked, expired, or a dev: credential used against production.

4. Next steps

Ask Codex in plain language; it picks the tool. These work with the read-only token.

  • List my five most recent uprank articles with their status.

    article_list

  • Summarize my site's uprank brand profile: voice, audience and proof points.

    brand_get

  • Which of my uprank articles have an expired claim or no current quality score?

    refresh_list

Ready for drafts? Issue a second token that adds research:run, article:write, quality:run and ask for the create_quality_article prompt with a site id and either a campaign id and a topic to research or an existing topic opportunity id. It researches, drafts and scores an article against the quality gates and stops before publishing.

Troubleshooting Codex

Do I need to add uprank again for the Codex IDE extension or the ChatGPT desktop app?
No. The Codex CLI, the IDE extension and the ChatGPT desktop app share the MCP configuration in ~/.codex/config.toml, so one codex mcp add covers all three.
Why does every uprank call from Codex return 401?
Codex reads the bearer token from UPRANK_MCP_TOKEN in its own environment when it connects. If no credential resolves, Codex connects without one, and uprank answers 401. Set UPRANK_MCP_TOKEN in the environment Codex starts from, then start Codex again.
Can I limit uprank to one repository in Codex?
Yes. Instead of the CLI command, add an [mcp_servers.uprank] table with url = "https://uprank.devino.ca/api/mcp" and bearer_token_env_var = "UPRANK_MCP_TOKEN" to the project's .codex/config.toml. Codex reads project config only in trusted projects.

No workspace yet?

Tokens belong to a workspace. Create one, then come back to step 1.