Provision MCP client-credentials
Mint an OAuth 2.0 client-credentials credential so a machine client (e.g. Salesforce AgentForce) can obtain org-scoped MCP access tokens.
Requires an org-scoped API key (gcai_...); user-scoped keys receive 403. The organization's single M2M application is created on first call and reused thereafter, so this endpoint is safe to call repeatedly. Each call mints a new secret and returns it once (it cannot be retrieved again). A WorkOS application allows up to 5 live credentials; once that limit is reached the identity provider rejects further mints (returned here as 502) until an existing credential is revoked.
Hand the returned client_id, client_secret, token_endpoint, and resource to the machine client's OAuth configuration.
Request
- Base URLhttps://app.gc.ai/api/external/v1
- AuthAPI key in header Authorization
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Response
A newly minted credential (secret shown once)
Example response
{
"client_id": "client_01HXWKHA5SX0JZYAD037JBE3PT",
"token_endpoint": "https://your-org.authkit.app/oauth2/token",
"resource": "https://app.example.com/api/mcp"
}Changes
No recorded changes to this operation across all 1 revision of this API.