> ## Documentation Index
> Fetch the complete documentation index at: https://docs.prelude.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Register OAuth client

> Pre-register an OAuth client for a known integration, as an
alternative to Dynamic Client Registration or Client ID Metadata
Documents. A manually-registered client must carry its own
`provider_url` — it does not inherit the app's `default_provider_url`.




## OpenAPI

````yaml post /v2/session/apps/{appID}/oauth/clients
openapi: 3.1.1
info:
  title: Prelude Session Management API
  version: 0.0.1
  summary: The Prelude API for Session Management
  description: The Prelude API for Session Management.
  contact:
    email: support@prelude.so
    url: https://prelude.so
servers:
  - url: https://api.prelude.dev
    description: Production server
security:
  - Authorization: []
tags:
  - name: Mode
    description: Manage the mode (dev/prod) of your application.
  - name: Tokens
    description: Mint development tokens for your application.
  - name: Users
    description: Manage the users of your application.
  - name: Webhooks
    description: Manage the webhooks of your application.
  - name: Domains
    description: Manage the domains of your application.
  - name: Config - Scopes
    description: Manage the scope configuration of your application.
  - name: Config - Groups
    description: >-
      Manage the group configuration of your application. A group owns a set of
      scopes; users assigned to a group are granted the group's scopes.
  - name: Config - Claims
    description: Manage the claims mapping configuration of your application.
  - name: Config - Step-up
    description: Manage the step-up authentication configuration of your application.
  - name: Config - Migration
    description: Manage the user migration configuration of your application.
  - name: Config - Login OTP
    description: Manage the OTP login configuration of your application.
  - name: Config - Login OAuth
    description: Manage the OAuth login configuration of your application.
  - name: Config - Login SAML
    description: Manage the SAML 2.0 SSO connections of your application.
  - name: Config - Login Password
    description: Manage the password login configuration of your application.
  - name: Config - Passkey
    description: Manage the WebAuthn passkey configuration of your application.
  - name: Config - OAuth Server
    description: >-
      Configure your application as an OAuth 2.0 authorization server so MCP
      clients and other third-party apps can sign your users in.
paths:
  /v2/session/apps/{appID}/oauth/clients:
    parameters:
      - $ref: '#/components/parameters/appIDParam'
    post:
      tags:
        - Config - OAuth Server
      summary: Register OAuth client
      description: |
        Pre-register an OAuth client for a known integration, as an
        alternative to Dynamic Client Registration or Client ID Metadata
        Documents. A manually-registered client must carry its own
        `provider_url` — it does not inherit the app's `default_provider_url`.
      operationId: registerOAuthClient
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostOAuthClientRequest'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostOAuthClientResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvalidOAuthClientError'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AppNotFoundError'
components:
  parameters:
    appIDParam:
      in: path
      name: appID
      required: true
      description: The id of the app the request refers to.
      schema:
        $ref: '#/components/schemas/AppID'
  schemas:
    PostOAuthClientRequest:
      type: object
      properties:
        client_name:
          type: string
          description: Human-readable name shown on the consent screen.
          examples:
            - Internal MCP client
        redirect_uris:
          type: array
          description: Allowed redirect URIs for this client.
          items:
            type: string
          examples:
            - - https://mcp.example.com/oauth/callback
        scopes:
          type: array
          description: Scopes granted to this client.
          items:
            type: string
          examples:
            - - mcp:read
              - mcp:write
        provider_url:
          type: string
          description: >-
            Login UI origin for this client. Manually-registered clients do not
            inherit `default_provider_url` and must set their own.
          examples:
            - https://auth.example.com
      required:
        - client_name
        - redirect_uris
        - provider_url
    PostOAuthClientResponse:
      type: object
      properties:
        client:
          $ref: '#/components/schemas/OAuthClientResponse'
      required:
        - client
    InvalidOAuthClientError:
      type: object
      properties:
        code:
          type: string
          enum:
            - invalid_oauth_client
          examples:
            - invalid_oauth_client
        status:
          type: string
          enum:
            - bad_request
          examples:
            - bad_request
        message:
          type: string
          examples:
            - at least one redirect_uri is required
      required:
        - code
        - status
        - message
    AppNotFoundError:
      type: object
      properties:
        code:
          type: string
          enum:
            - app_not_found
          examples:
            - app_not_found
        status:
          type: string
          enum:
            - not_found
          examples:
            - not_found
        message:
          type: string
          examples:
            - The application was not found.
      required:
        - code
        - status
        - message
    AppID:
      type: string
      description: An application's unique identifier.
      examples:
        - 54e9ujn
        - fvua38g
    OAuthClientResponse:
      type: object
      properties:
        client_id:
          type: string
          description: The generated client identifier (prefixed with `oac_`).
          examples:
            - oac_01jqebhswje1ka1z7ahr9rfsgt
        app_id:
          type: string
          examples:
            - 54e9ujn
        client_name:
          type: string
          examples:
            - Internal MCP client
        redirect_uris:
          type: array
          items:
            type: string
          examples:
            - - https://mcp.example.com/oauth/callback
        scopes:
          type: array
          items:
            type: string
          examples:
            - - mcp:read
              - mcp:write
        provider_url:
          type: string
          examples:
            - https://auth.example.com
        created_at:
          type: integer
          format: int64
          description: Unix timestamp (seconds) of client creation.
          examples:
            - 1718000000
      required:
        - client_id
        - app_id
        - client_name
        - redirect_uris
        - created_at
  securitySchemes:
    Authorization:
      type: http
      scheme: bearer

````