Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we
store it to create your key and to recognise you if you sign in with another
provider. By signing up you are subscribing to the APIs.io and API Evangelist
newsletters — you can unsubscribe from any issue. See our
Privacy Policy and Terms.
openapi: 3.2.0
info:
title: DialogBrain v2 API Gateway MCP OAUTH API
description: Clean refactored API gateway with minimal vertical slice
version: 0.1.0
tags:
- name: mcp-oauth
paths:
/.well-known/openai-apps-challenge:
get:
tags:
- mcp-oauth
summary: Openai Apps Challenge
description: Domain ownership verification for ChatGPT Apps listing.
operationId: openai_apps_challenge__well_known_openai_apps_challenge_get
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/.well-known/oauth-protected-resource:
get:
tags:
- mcp-oauth
summary: Oauth Protected Resource
operationId: oauth_protected_resource__well_known_oauth_protected_resource_get
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/.well-known/oauth-protected-resource/{resource_path}:
get:
tags:
- mcp-oauth
summary: Oauth Protected Resource For Path
description: 'RFC 9728 §3.1 path-inserted document: the resource is the URL the
client is actually calling.
A client checks the `resource` it gets back against the URL it connected
to, byte for byte. Ours answered `/mcp/` to everyone, so a client that
connected to `/mcp` — the form the landing page''s install button hands
out — failed the check AFTER the person had already signed in and a key
had been issued: "Protected resource .../mcp/ does not match expected
.../mcp". Every attempt left another revoked key behind (12 of them on
one account before this was traced, 2026-09-21).
The path is read off the raw request rather than from a route parameter,
because a parameter arrives already stripped of its trailing slash and
the slash is the whole point: the two spellings are different resource
identifiers to the client, and each has to be told its own.'
operationId: oauth_protected_resource_for_path__well_known_oauth_protected_resource__resource_path__get
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/.well-known/oauth-authorization-server:
get:
tags:
- mcp-oauth
summary: Oauth Authorization Server
operationId: oauth_authorization_server__well_known_oauth_authorization_server_get
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/oauth/client-metadata.json:
get:
tags:
- mcp-oauth
summary: Oauth Client Metadata Document
description: 'DialogBrain as an OAuth CLIENT: the client ID metadata document
(draft-ietf-oauth-client-id-metadata-document) that a third-party
authorization server fetches when a workspace connects its MCP server
through Add Integration and our client_id is this document''s URL.
Public and unauthenticated by design; the document carries no secret
(public client, token_endpoint_auth_method "none"). Everything else in
this module is DialogBrain as an authorization SERVER for MCP clients;
the two are unrelated and share only the path prefix.'
operationId: oauth_client_metadata_document_oauth_client_metadata_json_get
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/oauth/register:
post:
tags:
- mcp-oauth
summary: Oauth Register
operationId: oauth_register_oauth_register_post
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/oauth/client/{client_id}:
get:
tags:
- mcp-oauth
summary: Oauth Client Info
description: 'The name a registered client gave itself, for the consent screen.
Without it the consent page guessed from the redirect host and called every
app on localhost "Claude Code": Codex and Cursor connected under that name,
and their keys were filed as "Claude Code MCP" in Settings → Developer.
Only the declared name is returned — nothing that identifies the user.
An unknown client (registered before this lived in Redis) is a 404 and the
page falls back to a neutral label.'
operationId: oauth_client_info_oauth_client__client_id__get
parameters:
- name: client_id
in: path
required: true
schema:
type: string
title: Client Id
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/oauth/authorize:
get:
tags:
- mcp-oauth
summary: Oauth Authorize Get
operationId: oauth_authorize_get_oauth_authorize_get
parameters:
- name: client_id
in: query
required: false
schema:
type: string
default: ''
title: Client Id
- name: redirect_uri
in: query
required: false
schema:
type: string
default: ''
title: Redirect Uri
- name: state
in: query
required: false
schema:
type: string
default: ''
title: State
- name: code_challenge
in: query
required: false
schema:
type: string
default: ''
title: Code Challenge
- name: code_challenge_method
in: query
required: false
schema:
type: string
default: S256
title: Code Challenge Method
- name: response_type
in: query
required: false
schema:
type: string
default: code
title: Response Type
- name: scope
in: query
required: false
schema:
type: string
default: ''
title: Scope
responses:
'200':
description: Successful Response
content:
text/html:
schema:
type: string
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
post:
tags:
- mcp-oauth
summary: Oauth Authorize Post
operationId: oauth_authorize_post_oauth_authorize_post
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
$ref: '#/components/schemas/Body_oauth_authorize_post_oauth_authorize_post'
responses:
'200':
description: Successful Response
content:
text/html:
schema:
type: string
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/oauth/authorize_direct:
post:
tags:
- mcp-oauth
summary: Oauth Authorize Direct
description: 'Called by the frontend authorize page to complete OAuth without manual API key entry.
The frontend creates an API key on behalf of the logged-in user, then calls this endpoint
to generate an auth code and return the redirect URL.'
operationId: oauth_authorize_direct_oauth_authorize_direct_post
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/oauth/token:
post:
tags:
- mcp-oauth
summary: Oauth Token
operationId: oauth_token_oauth_token_post
requestBody:
content:
application/x-www-form-urlencoded:
schema:
$ref: '#/components/schemas/Body_oauth_token_oauth_token_post'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
input:
title: Input
ctx:
type: object
title: Context
type: object
required:
- loc
- msg
- type
title: ValidationError
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
Body_oauth_authorize_post_oauth_authorize_post:
properties:
api_key:
type: string
title: Api Key
client_id:
type: string
title: Client Id
default: ''
redirect_uri:
type: string
title: Redirect Uri
default: ''
state:
type: string
title: State
default: ''
code_challenge:
type: string
title: Code Challenge
default: ''
code_challenge_method:
type: string
title: Code Challenge Method
default: S256
type: object
required:
- api_key
title: Body_oauth_authorize_post_oauth_authorize_post
Body_oauth_token_oauth_token_post:
properties:
grant_type:
type: string
title: Grant Type
code:
type: string
title: Code
default: ''
redirect_uri:
type: string
title: Redirect Uri
default: ''
client_id:
type: string
title: Client Id
default: ''
code_verifier:
type: string
title: Code Verifier
default: ''
client_secret:
type: string
title: Client Secret
default: ''
refresh_token:
type: string
title: Refresh Token
default: ''
type: object
required:
- grant_type
title: Body_oauth_token_oauth_token_post