You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
printf '# add --auto-update to opt into automatic updates for future releases\n'
165
165
printf '```\n\n'
166
-
printf '**Generic MCP client** — point it at `https://mcp.cpln.io/mcp` with `Authorization: Bearer ${CPLN_TOKEN}`. See README for the per-client config snippet.\n\n'
166
+
printf '**Generic MCP client** — point it at `https://mcp.cpln.io/mcp`. OAuth 2.1 sign-in handles authorization on first use. See README for the config snippet.\n\n'
Copy file name to clipboardExpand all lines: GEMINI.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,7 +24,7 @@ If `CPLN_ORG`, `CPLN_GVC`, or `CPLN_PROFILE` are unset and the command needs sco
24
24
25
25
-`cpln apply` always requires `--file <manifest>`. There is no implicit manifest path.
26
26
- Secret creation uses type-specific commands: `cpln secret create-opaque`, `create-aws`, `create-tls`, `create-dictionary`, etc. Generic `cpln secret create` does not exist.
27
-
-Bearer token (`CPLN_TOKEN`) is sent live to `https://mcp.cpln.io/mcp`for MCP operations. Treat MCP access as production access to the configured org.
27
+
-MCP calls to `https://mcp.cpln.io/mcp`are authorized by an OAuth 2.1 access token scoped to the orgs the user granted at sign-in. Treat MCP access as production access to those orgs.
28
28
29
29
## Scale-to-zero — never the default for production
Then start Codex and open `/plugins`. Use the left/right arrow keys to navigate between marketplaces until you reach Control Plane, then select and install the `cpln` plugin. The Codex plugin manifest points to `.codex-plugin/mcp.json`, which installs the hosted `cpln` MCP server with `CPLN_TOKEN` as its bearer-token environment variable.
40
+
Then start Codex and open `/plugins`. Use the left/right arrow keys to navigate between marketplaces until you reach Control Plane, then select and install the `cpln` plugin. The Codex plugin manifest points to `.codex-plugin/mcp.json`, which installs the hosted `cpln` MCP server. On first MCP call, you'll be prompted to sign in to Control Plane and choose which organizations the assistant may operate on.
41
41
42
42
If you prefer the standalone marketplace installer, install the plugin artifact directly from GitHub:
43
43
@@ -102,40 +102,35 @@ cd ai-plugin
102
102
103
103
### Generic MCP Client
104
104
105
-
If your client only needs MCP and does not consume one of this repo's plugin formats, add the `cpln` server manually using that client's MCP config format. For clients that support header interpolation:
105
+
If your client only needs MCP and does not consume one of this repo's plugin formats, add the `cpln` server manually:
106
106
107
107
```json
108
108
{
109
109
"mcpServers": {
110
110
"cpln": {
111
111
"type": "http",
112
-
"url": "https://mcp.cpln.io/mcp",
113
-
"headers": {
114
-
"Authorization": "Bearer ${CPLN_TOKEN}"
115
-
}
112
+
"url": "https://mcp.cpln.io/mcp"
116
113
}
117
114
}
118
115
}
119
116
```
120
117
121
-
## Configuration
118
+
On first use, the client prompts you to sign in to Control Plane and choose which organizations it may operate on. The issued access token is scoped to those organizations.
122
119
123
-
Create a Control Plane service account token and expose it to the client environment as `CPLN_TOKEN`. Use least-privilege policies for the service account whenever possible.
120
+
## Authentication
124
121
125
-
```bash
126
-
export CPLN_TOKEN="<your-service-account-token>"
127
-
```
128
-
129
-
Gemini CLI prompts for `CPLN_TOKEN` because `gemini-extension.json` marks it as a sensitive setting.
122
+
MCP authentication uses OAuth 2.1 + PKCE. On first use, you sign in to Control Plane and choose which organizations the AI client may operate on; every MCP tool call is then enforced against that scope server-side. To change which orgs an AI client may use, sign in again and re-run consent — the new grant replaces the old one.
130
123
131
124
## Environment Variables
132
125
133
-
| Variable | Required | Sensitive | Used by | Purpose |
|`CPLN_TOKEN`| Optional | Yes | Control Plane CLI workflows | Service account token for `cpln` CLI invocations from CI/CD, Terraform, or Pulumi. |
131
+
|`CPLN_ORG`| Optional | No | Control Plane CLI workflows | Default Control Plane organization for CLI commands. |
132
+
|`CPLN_GVC`| Optional | No | Control Plane CLI workflows | Default GVC for GVC-scoped CLI commands. |
133
+
|`CPLN_PROFILE`| Optional | No | Control Plane CLI workflows | Selects a local `cpln` CLI profile. |
139
134
140
135
See `.env.example` for a local template. Do not commit real tokens.
141
136
@@ -182,16 +177,17 @@ This repository includes:
182
177
183
178
Client-specific MCP configuration files:
184
179
185
-
- Codex: `plugins/cpln/.codex-plugin/mcp.json` uses `url` and `bearer_token_env_var`.
186
-
- Claude Code: `plugins/cpln/.claude-mcp.json` uses `type: "http"` and `headers.Authorization`.
187
-
- Gemini CLI: `gemini-extension.json` uses `httpUrl` and `headers.Authorization`.
180
+
- Codex: `plugins/cpln/.codex-plugin/mcp.json` points at the hosted MCP URL; Codex negotiates OAuth on first call.
181
+
- Claude Code: `plugins/cpln/.claude-mcp.json` uses `type: "http"`; Claude Code negotiates OAuth on first call.
182
+
- Cursor: `plugins/cpln/.cursor-plugin/mcp.json` points at the hosted MCP URL; Cursor negotiates OAuth on first call.
183
+
- Gemini CLI: `gemini-extension.json` uses `httpUrl`; Gemini negotiates OAuth on first call.
188
184
189
-
The hosted MCP server exposes live Control Plane tools for reading and mutating infrastructure. Treat MCP access as production access to the configured Control Plane organization.
185
+
The hosted MCP server exposes live Control Plane tools for reading and mutating infrastructure. Treat MCP access as production access to the organizations you granted at consent time.
190
186
191
187
## Security and Privacy
192
188
193
-
-`CPLN_TOKEN` is sent as a bearer token to `https://mcp.cpln.io/mcp`when MCP tools are used.
194
-
- MCP tools may read or modify Control Plane resources depending on the token's permissions.
189
+
-MCP requests to `https://mcp.cpln.io/mcp`are authorized by an OAuth 2.1 access token scoped to the organizations you granted at sign-in and to your own Control Plane permissions inside each.
190
+
- MCP tools may read or modify Control Plane resources within those orgs, subject to your user-level RBAC.
195
191
- The plugin itself does not store logs, secrets, prompts, or telemetry.
196
192
- Your AI client and model provider may process prompts, command output, logs, manifests, and MCP responses according to their own retention policies.
197
193
- Workload logs, audit events, secret metadata, and infrastructure state are only fetched when a user or agent invokes the relevant workflow/tool.
@@ -204,7 +200,8 @@ Report vulnerabilities by following the process in [SECURITY.md](SECURITY.md).
| MCP requests fail with authentication errors | Confirm `CPLN_TOKEN` is set in the AI client environment and belongs to an active service account. |
203
+
| MCP requests fail with authentication errors | Re-run sign-in (most clients prompt on the next tool call, or restart the client). Confirm you granted at least one organization at the consent screen. |
204
+
| MCP tool call returns "org not authorized" | The current grant does not include that org. Sign in again and tick the missing org at the consent screen, or ask the org owner to add you to it first. |
208
205
| MCP tools are unavailable in Codex | Confirm the plugin was installed from `/plugins`, not only that the marketplace was added. Then restart Codex and use `/mcp` inside the session to inspect plugin-provided MCP servers. |
209
206
| Codex `/plugins` → Control Plane shows "No plugin hooks." and guardrails are not injected | Codex gates plugin hooks behind a feature flag. Add `[features]\nplugins = true\nplugin_hooks = true` to `~/.codex/config.toml` and restart Codex. See the Codex install section above. |
210
207
| MCP tools are unavailable in another client | Confirm the client supports one of this repo's MCP configs (`plugins/cpln/.claude-mcp.json`, `plugins/cpln/.codex-plugin/mcp.json`, or the MCP block inside `gemini-extension.json`), or manually configured the `cpln` MCP server in that client's native MCP format. |
Copy file name to clipboardExpand all lines: SECURITY.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,9 +19,9 @@ Do not open a public issue for vulnerabilities that expose secrets, tokens, cust
19
19
20
20
## Secrets and Credentials
21
21
22
-
-Never commit real `CPLN_TOKEN` values or service account keys.
23
-
-Use least-privilege service accounts for MCP access.
24
-
-Rotate any token that may have been exposed to an AI client, shell history, logs, screenshots, or repository history.
22
+
-The hosted MCP server authenticates the user via OAuth 2.1 + PKCE. Tokens are issued per-client, scoped to the orgs the user explicitly granted at consent time, and stored by the AI client.
23
+
-If you suspect an AI client's stored OAuth token is compromised, sign in and re-run consent — the new grant supersedes the old one. (For a hard revoke, the org owner can remove the user.)
24
+
-The `cpln` CLI workflows in this plugin (CI/CD, Terraform, Pulumi) use a service account token in `CPLN_TOKEN`. Never commit real values or service account keys, and use least-privilege service accounts.
Copy file name to clipboardExpand all lines: gemini-extension.json
+1-12Lines changed: 1 addition & 12 deletions
Original file line number
Diff line number
Diff line change
@@ -2,20 +2,9 @@
2
2
"name": "cpln",
3
3
"version": "1.3.2",
4
4
"description": "Control Plane — hybrid multi-cloud platform. Skills, agents, and guardrails for deploying workloads, managing secrets, configuring networking, troubleshooting, and migrating from Kubernetes across AWS, GCP, Azure, and private clouds.",
5
-
"settings": [
6
-
{
7
-
"name": "Control Plane Token",
8
-
"description": "Service account token for the Control Plane MCP Server. Create one at https://docs.controlplane.com/guides/create-service-account",
0 commit comments