Learning resourcesReviewed · Model Context Protocol

OAuth Client Credentials for MCP

OAuth Client Credentials for MCP is a guide for developers connecting automated services to MCP servers, but client support varies and the extension is opt-in. It explains application authentication using client secrets or signed JWT assertions, with TypeScript and Python examples.

Researched 15 Nov 2026

In short.

OAuth Client Credentials for MCP is an implementation guide for developers building unattended MCP connections, but compatibility depends on explicit extension support. It covers application credentials, access tokens, issuer pinning, server validation and SDK providers. The page leaves SDK versions unspecified and does not reconcile its JWT bearer grant diagram with its client credentials setup instructions; the examples were not executed.

Researched and written by an AI model and checked by a second AI model. How it works

Coverage includes the complete selected page at [https://modelcontextprotocol.io/extensions/auth/oauth-client-credentials.md], including its authentication diagrams, credential warning, capability declarations, SDK examples and opt-in support notice. The documentation index, normative specification, repository, RFCs and client matrix are linked references only; their contents are excluded. SDK compatibility, actual token requests, runtime behavior, security properties in deployment, costs and licensing remain unverified where the page does not establish them. Nothing was executed.

The overview

identity

The resource is the MCP documentation guide at [https://modelcontextprotocol.io/extensions/auth/oauth-client-credentials.md]. It describes the extension identified as io.modelcontextprotocol/oauth-client-credentials, which lets automated clients obtain access without interactive user approval.

This page is an explanatory implementation guide. It links to a separate normative specification and reference repository, whose contents are outside the assessed scope.

assessment

The guide provides a concrete starting point for replacing a browser-based login step in service-owned MCP automation. Its useful details include per-request extension declarations, authorization-server issuer pinning, credential choices and server-side scope enforcement.

It does not establish compatibility with a particular deployed client or SDK version. Its JWT flow also needs clarification before implementation, so the page alone does not establish that the examples will work in a specific environment.

users

The intended users are developers maintaining background services, CI/CD pipelines, backend integrations and long-running workers that call MCP tools without a person present.

The approach authenticates an application rather than a person granting access. Where a human should explicitly authorize an integration, the page directs developers to standard MCP authorization.

capabilities

The page describes authentication with a client ID and secret, or with a signed JWT assertion verified against the client's registered public key. The resulting access token accompanies MCP HTTP requests in the Authorization header.

It presents TypeScript and Python providers for both credential choices and states that the SDKs handle token acquisition and renewal automatically. Clients declare extension support through request metadata; servers can optionally advertise support through server/discover.

Using it

requirements

An integration needs a client that explicitly supports the extension, an authorization server configured for the application, and an MCP server that validates tokens and enforces the scopes required by each operation. JWT assertions require a private signing key and registration of the corresponding public key; the secret-based route requires provisioned client credentials.

The SDK examples also require the expected authorization-server issuer. The guide does not specify minimum SDK or runtime versions, and its Python examples import httpx2 without providing a separate installation instruction for it.

mechanism

The client proves its application identity to the authorization server, receives an access token, and sends that token with MCP requests as Authorization: Bearer <access_token>. No browser redirect or interactive consent step is involved.

For signed assertions, the page describes iss and sub as the client ID, aud as the authorization server's token endpoint, and exp and iat as expiration and issuance times. Its server guidance calls for checking token signatures and claims against authorization-server public keys, then checking operation-specific scopes.

setup

The manual integration sequence is to declare the extension under io.modelcontextprotocol/clientCapabilities in request metadata, obtain an access token, attach it to MCP HTTP requests, and obtain replacement tokens before expiry.

For SDK use, the page gives npm install @modelcontextprotocol/client for TypeScript and pip install mcp for Python. The examples configure a credential provider and connect through Streamable HTTP. They pin the authorization-server issuer so credentials are not sent to a different issuer advertised by the MCP server.

On the server, configure token validation and required scopes. Advertising extension support through server/discover is recommended by the page but described as optional.

example

A scheduled worker that needs to discover available MCP tools illustrates the intended use. The TypeScript secret example constructs ClientCredentialsProvider with a client ID, secret and expected issuer, connects through StreamableHTTPClientTransport, calls listTools(), and closes the transport.

The Python examples use ClientCredentialsOAuthProvider or PrivateKeyJWTOAuthProvider with an in-memory token store and call list_tools(). The JWT sample configures an RS256 assertion with lifetime_seconds=300. These are documented examples, not observed execution results; the assertion lifetime does not establish the access token's lifetime.

Assessment & evidence

limitations

Extensions are opt-in and inactive by default, and support varies by client. The linked client matrix was not assessed, so support for any named client remains unknown.

The JWT diagram uses grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer, while the implementation instructions say to obtain a token using the client credentials grant. The private-key SDK examples do not show their outgoing token requests. The page does not reconcile these grant choices.

Client secrets are long-lived credentials that can permit silent application impersonation if leaked. The page recommends secure storage, rotation, minimum permissions and JWT assertions where possible. It does not supply a complete production credential lifecycle, access-token lifetime or deployment validation.

reasoning

The practical fit follows from whose identity the job needs: application credentials suit work owned by a service, while interactive authorization suits work requiring a person's approval. Removing interactive login enables scheduled and event-driven jobs, but credential protection, token renewal and permission enforcement still need explicit implementation.

The issuer pinning in the examples is particularly relevant because credentials are provisioned by a particular authorization server. The guide presents that pinning as protection against sending them to another advertised issuer.

alternatives

The explicit alternative is standard MCP authorization when a person should approve access. The guide does not compare other machine authentication systems or named authorization providers.

Within this extension, the page recommends signed JWT assertions and presents client secrets as a simpler deployment option. Assertions avoid transmitting the private signing key, while secrets require storage and rotation of a reusable credential. Operational effort and provider compatibility are not compared quantitatively.

evidence

The evidence consists of the complete selected documentation page at [https://modelcontextprotocol.io/extensions/auth/oauth-client-credentials.md], captured on 2026-11-15 at 00:14:24.698 UTC.

The page supports descriptions of intended behavior and supplied examples. No commands or examples were executed, and no authentication, interoperability, performance or security test results are available. Linked specifications, RFCs, repositories and support matrices were not assessed.

Access & freshness

costs

Costs are unknown. The page provides no prices, quotas or billing terms for authorization services, MCP access, hosting or credential management. Installation commands do not establish that an operational deployment is free.

rights

The supplied page contains no explicit license or redistribution grant for its text, examples or referenced implementations. Rights to redistribute those materials are therefore unknown from this evidence.

The repository and specification links identify related sources, but their licenses and terms were not assessed.

freshness

The capture establishes the page's contents as supplied on 2026-11-15. The page provides no explicit publication or last-update date and names no SDK package versions.

Its specification link contains a 2026-07-28 version path. That identifies the linked specification reference, but does not establish the documentation's revision date or compatibility with currently installed SDKs.

actions

Confirm extension support and the required SDK version for the intended client. Resolve the JWT grant choice against the linked normative specification and the chosen SDK's documentation before implementing the private-key route.

Provision application credentials with minimum necessary scopes, pin the expected authorization-server issuer, and configure server-side token and scope checks. For secrets, establish protected storage and rotation; for assertions, protect the signing key.

Before deployment, verify token acquisition and renewal, rejection of an unexpected issuer, denial of insufficient scopes, and the intended MCP operation in the actual environment. These checks remain unperformed.

Evidence for this report

selected-page.txtselected · checked 2026-11-15