mcp-oauth

Operations of the MCP Gateway API. Paths are relative to your deployment's API host.

POST /api/mcp-gateway-api/mcp-servers/{serverId}/oauth/initiate

Initiate OAuth 2.1 PKCE flow for an MCP server

Authentication: bearer token (Authorization: Bearer <token>)

ParameterInTypeRequiredDescription
serverIdpathstringyes

Request body: application/json OAuthInitiateRequestDto

StatusDescriptionBody
201application/json OAuthInitiateResponseDtoDataEnvelope
400application/problem+json ProblemDetailsDto
401application/problem+json ProblemDetailsDto
403application/problem+json ProblemDetailsDto
404application/problem+json ProblemDetailsDto
409application/problem+json ProblemDetailsDto
422application/problem+json ProblemDetailsDto
500application/problem+json ProblemDetailsDto

GET /api/mcp-gateway-api/oauth/callback

OAuth 2.1 auth-code callback (called by the authorization server)

Authentication: bearer token (Authorization: Bearer <token>)

ParameterInTypeRequiredDescription
codequerystringyesAuthorization code from the OAuth provider.
statequerystringyesState parameter echoed back by the provider.
StatusDescriptionBody
200application/json ObjectDataEnvelope
400application/problem+json ProblemDetailsDto
401application/problem+json ProblemDetailsDto
403application/problem+json ProblemDetailsDto
404application/problem+json ProblemDetailsDto
409application/problem+json ProblemDetailsDto
422application/problem+json ProblemDetailsDto
500application/problem+json ProblemDetailsDto