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

# Create Mcp Auth Config

> Create a new MCP authentication configuration.



## OpenAPI

````yaml /api-reference/openapi.json post /v1/mcp-auth-configs/
openapi: 3.1.0
info:
  description: >-
    Modular and extensible framework for building AI agents. This API requires
    JWT Bearer token authentication for most endpoints. Include your JWT token
    in the Authorization header. Public endpoints include /, /health, /docs,
    /redoc, and /openapi.json.
  title: AgentArea API
  version: 0.1.0
servers: []
security:
  - bearer: []
paths:
  /v1/mcp-auth-configs/:
    post:
      tags:
        - v1
        - protected
        - mcp-auth-configs
      summary: Create Mcp Auth Config
      description: Create a new MCP authentication configuration.
      operationId: create_mcp_auth_config_v1_mcp_auth_configs__post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MCPAuthConfigCreateRequest'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MCPAuthConfigResponse'
          description: Successful Response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
      security:
        - HTTPBearer: []
components:
  schemas:
    MCPAuthConfigCreateRequest:
      properties:
        auth_type:
          description: 'One of: api_key, bearer, oauth2'
          title: Auth Type
          type: string
        config:
          additionalProperties: true
          description: Non-sensitive config (header_name, token_url, client_id, scopes, …)
          title: Config
          type: object
        credentials:
          additionalProperties: true
          description: >-
            Sensitive credentials encrypted at rest (header_value, token,
            client_secret, …)
          title: Credentials
          type: object
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        name:
          description: Human-readable name for this auth config
          title: Name
          type: string
      required:
        - name
        - auth_type
      title: MCPAuthConfigCreateRequest
      type: object
    MCPAuthConfigResponse:
      properties:
        auth_type:
          title: Auth Type
          type: string
        config:
          additionalProperties: true
          title: Config
          type: object
        created_at:
          title: Created At
          type: string
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        id:
          format: uuid
          title: Id
          type: string
        name:
          title: Name
          type: string
        updated_at:
          title: Updated At
          type: string
      required:
        - id
        - name
        - description
        - auth_type
        - config
        - created_at
        - updated_at
      title: MCPAuthConfigResponse
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    ValidationError:
      properties:
        ctx:
          title: Context
          type: object
        input:
          title: Input
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
  securitySchemes:
    bearer:
      bearerFormat: JWT
      description: JWT Bearer token for authentication
      scheme: bearer
      type: http
    HTTPBearer:
      scheme: bearer
      type: http

````