Agent integrations
Connect Codex
Add Kindling to a private Codex CLI profile. Configure the exact endpoint and minimum OAuth scopes before asking anyone to consent.
Who it’s for Platform owners and admins who work in the Codex CLI.
On this page
Before you start
- Ask your administrator for the exact HTTPS MCP URL, the approved Codex OAuth client ID, the exact registered redirect URI for your CLI and the scopes you can request.
- Use your named platform owner or admin account with an active grant for the specific clinic and operations. A dashboard session or Claude Code’s OAuth client cannot replace that grant.
- Use the Codex CLI, not a ChatGPT app connection. The configuration was checked locally on Codex CLI 0.170.0. Native OAuth sign-in has not been verified on a live Kindling installation; proceed only if your operator confirms the enrolled setup supports it.
Configure a private CLI profile
Add the entry below to a private Codex profile, for example ~/.codex/kindling-synthetic.config.toml if you use the default Codex home. Do not store it in the project or version control. The example uses the planned Kindling-hosted endpoint. Confirm that your administrator has enabled your workspace at that exact URL, replace the example OAuth client ID and scopes with the approved values, and use a distinct connection name per agency.
[mcp_servers.kindling-agency-a]
url = "https://voice.adaventi.com/mcp/deployment/v1"
oauth_resource = "https://voice.adaventi.com/mcp/deployment/v1"
scopes = ["kindling-deploy/deployment:templates:read"]
[mcp_servers.kindling-agency-a.oauth]
client_id = "fixture_codex_app"url and oauth_resource must contain the same exact approved MCP URL. The example requests template listing only. List only approved fully prefixed scopes in scopes. Do not put a secret or bearer token in this file.
Optional: pin the loopback port for this server
If your operator approved a fixed loopback callback, add the approved port to the existing [mcp_servers.kindling-agency-a.oauth] section. This example pins the local listener to port 8765; it does not select a callback path.
callback_port = 8765Check that the callback URI Codex actually sends matches the registered one in full, including the host, port and any server-specific path suffix. A per-server callback_url is an approved URI, not a listener setting. Codex can ignore that URI and derive a suffixed callback if the provider does not support issuer-bound responses and the saved URI lacks the required suffix. See the Codex callback selection rules. Stop if the installed client and app registration cannot be made to match.
Do not use codex mcp add for this setup: it can open an initial OAuth screen before minimal scopes are set. The Codex CLI implementation documents that behavior and the resource option.
Sign in and verify access
Once your operator has confirmed native sign-in for your enrolled installation, request the same scopes explicitly at login using your private profile. For multiple approved scopes, pass them as a comma-separated list.
codex -p kindling-synthetic mcp login kindling-agency-a \
--scopes kindling-deploy/deployment:templates:readSign in with the approved account. Cancel if the sign-in asks for more access than approved or omits the required consent. Do not retry with automatic app registration, fewer restrictions or another client’s credential to make an incompatible login succeed.
Start Codex using codex -p kindling-synthetic and view the connection and tools with /mcp. With the example scope, expect only list_deployment_templates. Verify actual access with the approved synthetic clinic ID and that tool. If you have access to another action instead, follow the matching safe step in the synthetic walkthrough. Missing tools and denied calls are covered in troubleshooting.
Disconnect and remove
Log out while the profile entry still exists, then remove both the server table and its .oauth table from the private profile. If you configured a global entry instead, use codex mcp remove kindling-agency-a after logging out of that entry. Ask the Kindling administrator to revoke the exact clinic grant if access should end; local logout is not a server-side revocation.
codex -p kindling-synthetic mcp logout kindling-agency-aNext: try the four deployment tools or check access and troubleshooting.