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

# Update OAuth configuration

> Update OAuth provider configuration (admin only)



## OpenAPI

````yaml https://raw.githubusercontent.com/InsForge/InsForge/main/openapi/auth.yaml put /api/auth/oauth/{provider}/config
openapi: 3.0.3
info:
  title: Insforge Authentication API
  version: 2.0.0
  description: Authentication endpoints with separated auth and profile tables
servers: []
security: []
paths:
  /api/auth/oauth/{provider}/config:
    put:
      tags:
        - Admin
      summary: Update OAuth configuration
      description: Update OAuth provider configuration (admin only)
      parameters:
        - name: provider
          in: path
          required: true
          schema:
            type: string
            enum:
              - google
              - github
              - discord
              - linkedin
              - facebook
              - instagram
              - tiktok
              - apple
              - x
              - spotify
              - microsoft
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                clientId:
                  type: string
                clientSecret:
                  type: string
                redirectUri:
                  type: string
                scopes:
                  type: array
                  items:
                    type: string
                useSharedKey:
                  type: boolean
      responses:
        '200':
          description: Configuration updated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OAuthConfig'
        '400':
          description: Invalid request
        '401':
          description: Unauthorized
        '403':
          description: Forbidden - Admin only
        '404':
          description: Configuration not found
      security:
        - bearerAuth: []
components:
  schemas:
    OAuthConfig:
      type: object
      properties:
        id:
          type: string
          format: uuid
        provider:
          type: string
          enum:
            - google
            - github
            - discord
            - linkedin
            - facebook
            - instagram
            - tiktok
            - apple
            - x
            - spotify
            - microsoft
        clientId:
          type: string
          nullable: true
        redirectUri:
          type: string
          nullable: true
        scopes:
          type: array
          items:
            type: string
          nullable: true
        useSharedKey:
          type: boolean
        createdAt:
          type: string
          format: date-time
        updatedAt:
          type: string
          format: date-time
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````