agents mcp-config
Emit ready-to-paste MCP client config from a credential's secrets
Render the per-client MCP configuration (Claude Code, Cursor, VS Code) for the hosted agent-database MCP endpoint, given a credential's MCP URL and token. Because secrets are shown only once at creation, pass the URL + token directly (--url/--mcp-token), pipe the JSON output of agents create --json / agents rotate --json with --from-json, or read it from a saved file with --from-file. The output matches the dashboard credential-reveal dialog exactly.
Usage
pgbeam agents mcp-config [flags]Options
| Option | Description | Required | Default |
|---|---|---|---|
--url <value> | Hosted MCP URL (the mcp_url from create/rotate) | No | - |
--mcp-token <value> | Bearer token for the MCP endpoint (the mcp_token from create/rotate) | No | - |
--from-json | Read mcp_url + mcp_token from an agents create --json blob piped on stdin. | No | false |
--from-file <value> | Read mcp_url + mcp_token from an agents create --json blob saved to this file. | No | - |
--client <value> | MCP client: claude (default), cursor, vscode, or all | No | claude |
--write | Write each client's config to its conventional file path instead of stdout | No | false |
Global options
All global options (--token, --profile,
--project, --org, --json, --no-color, --debug) are also available on
this command.
Examples
# Emit Claude Code config from a URL + token
pgbeam agents mcp-config --url https://abc.proxy.pgbeam.app/mcp --mcp-token pba_xxx
# Emit config for all clients
pgbeam agents mcp-config --url https://abc.proxy.pgbeam.app/mcp --mcp-token pba_xxx --client all
# Pipe from create and write Cursor config to its file
pgbeam agents create --name ci --policy pol_xxx --json | pgbeam agents mcp-config --from-json --write --client cursorOutput
Prints the MCP config block(s). With --json, returns a structured array of { client, file, config }. With --write, writes each client's config to its conventional file path.