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

# Get authorization server metadata

> Returns the OAuth 2.0 Authorization Server Metadata (RFC 8414). Clients use it to discover the authorization, token, registration, and revocation endpoints.



## OpenAPI

````yaml /api-reference/sourcebot-public.openapi.json get /.well-known/oauth-authorization-server
openapi: 3.0.3
info:
  title: Sourcebot Public API
  version: v6.1.2
  description: >-
    OpenAPI description for the public Sourcebot REST endpoints used for search,
    repository listing, and file browsing. API keys are the standard integration
    mechanism, and OAuth bearer tokens are EE-only.
servers: []
security:
  - bearerToken: []
  - apiKeyHeader: []
  - {}
tags:
  - name: Search & Navigation
    description: Code search and symbol navigation endpoints.
  - name: Connections
    description: Code host connection metadata.
  - name: Repositories
    description: Repository listing and metadata endpoints.
  - name: Git
    description: Git history, diff, and file content endpoints.
  - name: Scoped Access Tokens
    description: >-
      Mint and revoke short-lived credentials restricted to specific
      repositories.
  - name: System
    description: System health and version endpoints.
  - name: OAuth
    description: >-
      OAuth 2.0 authorization server for apps that call Sourcebot on behalf of a
      user.
  - name: Enterprise (EE)
    description: Enterprise endpoints for user management and audit logging.
paths:
  /.well-known/oauth-authorization-server:
    get:
      tags:
        - OAuth
      summary: Get authorization server metadata
      description: >-
        Returns the OAuth 2.0 Authorization Server Metadata (RFC 8414). Clients
        use it to discover the authorization, token, registration, and
        revocation endpoints.
      operationId: getOAuthAuthorizationServerMetadata
      responses:
        '200':
          description: Authorization server metadata.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicOAuthAuthorizationServerMetadata'
        '404':
          description: OAuth is not available on this instance.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicOAuthError'
      security: []
components:
  schemas:
    PublicOAuthAuthorizationServerMetadata:
      type: object
      properties:
        issuer:
          type: string
          format: uri
        authorization_endpoint:
          type: string
          format: uri
        token_endpoint:
          type: string
          format: uri
        registration_endpoint:
          type: string
          format: uri
        revocation_endpoint:
          type: string
          format: uri
        response_types_supported:
          type: array
          items:
            type: string
            enum:
              - code
        grant_types_supported:
          type: array
          items:
            type: string
            enum:
              - authorization_code
              - refresh_token
        scopes_supported:
          type: array
          items:
            type: string
        code_challenge_methods_supported:
          type: array
          items:
            type: string
            enum:
              - S256
        token_endpoint_auth_methods_supported:
          type: array
          items:
            type: string
            enum:
              - none
        dpop_signing_alg_values_supported:
          type: array
          items:
            type: string
        service_documentation:
          type: string
          format: uri
      required:
        - issuer
        - authorization_endpoint
        - token_endpoint
        - registration_endpoint
        - revocation_endpoint
        - response_types_supported
        - grant_types_supported
        - scopes_supported
        - code_challenge_methods_supported
        - token_endpoint_auth_methods_supported
        - dpop_signing_alg_values_supported
        - service_documentation
      description: OAuth 2.0 Authorization Server Metadata, as defined in RFC 8414.
    PublicOAuthError:
      type: object
      properties:
        error:
          type: string
          description: >-
            OAuth error code, such as `invalid_request`, `invalid_grant`, or
            `access_denied`.
        error_description:
          type: string
          description: Human-readable explanation of the error.
      required:
        - error
        - error_description
      description: >-
        Error response returned by the OAuth endpoints, as defined in RFC 6749
        Section 5.2.
  securitySchemes:
    bearerToken:
      type: http
      scheme: bearer
      description: >-
        Bearer authentication header of the form `Bearer <token>`. The token may
        be a Sourcebot API key, OAuth access token, or scoped access token,
        subject to endpoint requirements.
    apiKeyHeader:
      type: apiKey
      in: header
      name: X-Sourcebot-Api-Key
      description: >-
        Header of the form `X-Sourcebot-Api-Key: <token>`, where `<token>` is
        your API key.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.