Skip to main content
Use browser-based OAuth when an end user connects Jinko to a compatible MCP client. Use an API key for the CLI and new SDK integrations. CLI OAuth login is deprecated.

MCP OAuth (DCR)

MCP OAuth is the simplest option for end-user-facing MCP clients. The client discovers Jinko’s authorization server, registers itself, and runs OAuth 2.1 with PKCE in the user’s browser.

Supported clients

  1. Claude Desktop or Claude Web: Open Settings, then Connectors, then Add custom connector. Enter https://mcp.builders.gojinko.com/mcp and leave the OAuth fields blank.
  2. Claude Code: Run claude mcp add --transport http jinko https://mcp.builders.gojinko.com/mcp.
  3. ChatGPT: Add the connector in the MCP settings on desktop or web.
  4. Cursor: Open Settings, then MCP Servers, and add the endpoint URL.

What happens under the hood

1

Discovery

The client reads https://mcp.builders.gojinko.com/.well-known/oauth-authorization-server to find the authorization server at auth.gojinko.com.
2

Dynamic Client Registration

The client registers itself and receives a client ID and secret. No user action is required.
3

Authorization with PKCE

The client opens auth.gojinko.com in a browser. The user signs in or creates an account, then Jinko redirects the client with an authorization code.
4

Token exchange

The client exchanges the code for access and refresh tokens, then stores them using its normal credential storage.
5

Account auto-provision

On first use, Jinko reads the JWT sub claim and creates the user without a waitlist or manual approval.
The client refreshes tokens automatically.

CLI and SDK authentication

The CLI accepts API keys, including interactive key entry with jinko auth login:
The SDK can read and refresh existing OAuth credentials from its shared configuration. The CLI no longer creates OAuth credentials. Do not pass an OAuth token to the SDK’s apiKey option.

OAuth on the REST API

The REST gateway accepts Jinko OAuth bearer tokens and jnk_ API keys. Ownership and route permissions still apply.
The REST gateway sends a non-key bearer token to the backend for verification. API keys can use X-API-Key: jnk_t_... or Authorization: Bearer jnk_t_.... New tenant keys start with jnk_t_ in production and jnk_sandbox_t_ in sandbox. Older person-bound keys with the jnk_ prefix remain valid as legacy keys. MCP OAuth has its own client-managed sign-in flow. An existing CLI token is not automatically valid on MCP.

Which auth should I use?

Use an API key when no user-facing sign-in is needed.

Common failures

See Errors & troubleshooting for HTTP-level debugging.