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

# Update a Provider

> Updates an existing Provider configuration.



## OpenAPI

````yaml /es/openapi/v3-current/AM-identity.yaml patch /v1/providers/{id}
openapi: 3.0.1
info:
  contact: {}
  description: This is a swagger documentation for the Identity API
  termsOfService: http://swagger.io/terms/
  title: Identity API
  version: 1.0.0
servers:
  - url: //localhost:4001/
security: []
paths:
  /v1/providers/{id}:
    patch:
      tags:
        - Providers
      summary: Update a Provider
      description: Updates an existing Provider configuration.
      parameters:
        - description: Provider ID
          in: path
          name: id
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ProviderUpdateInput'
        description: Provider Update Input
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProviderResponse'
          description: OK
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/pkg.HTTPError'
          description: Bad Request
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/pkg.HTTPError'
          description: Not Found
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/pkg.HTTPError'
          description: Internal Server Error
      security:
        - BearerAuth: []
components:
  schemas:
    ProviderUpdateInput:
      description: ProviderUpdateInput payload
      example:
        disableSsl: true
        templateCode: templateCode
        clientSecret2: clientSecret2
        title: title
        content: content
        intranetEndpoint: intranetEndpoint
        endpoint: endpoint
        appId: appId
        host: host
        clientSecret: clientSecret
        customUserInfoUrl: customUserInfoUrl
        clientId: clientId
        signName: signName
        method: method
        receiver: receiver
        issuerUrl: issuerUrl
        customTokenUrl: customTokenUrl
        clientId2: clientId2
        customAuthUrl: customAuthUrl
        port: 0
        regionId: regionId
        domain: domain
        name: name
        subType: subType
        scopes: scopes
      properties:
        appId:
          type: string
        clientId:
          type: string
        clientId2:
          type: string
        clientSecret:
          description: '#nosec G117 -- auth service, field must be in JSON response'
          type: string
        clientSecret2:
          description: '#nosec G117 -- auth service, field must be in JSON response'
          type: string
        content:
          type: string
        customAuthUrl:
          type: string
        customTokenUrl:
          type: string
        customUserInfoUrl:
          type: string
        disableSsl:
          type: boolean
        domain:
          type: string
        endpoint:
          type: string
        host:
          type: string
        intranetEndpoint:
          type: string
        issuerUrl:
          type: string
        method:
          type: string
        name:
          type: string
        port:
          type: integer
        receiver:
          type: string
        regionId:
          type: string
        scopes:
          type: string
        signName:
          type: string
        subType:
          type: string
        templateCode:
          type: string
        title:
          type: string
      type: object
    ProviderResponse:
      description: ProviderResponse payload
      example:
        disableSsl: true
        templateCode: templateCode
        title: title
        type: SendGrid
        content: content
        createdAt: '2021-09-01T00:00:00.000Z'
        intranetEndpoint: intranetEndpoint
        endpoint: endpoint
        appId: appId
        host: host
        customUserInfoUrl: customUserInfoUrl
        id: 00000000-0000-0000-0000-000000000000
        clientId: clientId
        signName: signName
        method: method
        receiver: receiver
        issuerUrl: issuerUrl
        customTokenUrl: customTokenUrl
        clientId2: clientId2
        customAuthUrl: customAuthUrl
        providerUrl: providerUrl
        port: 0
        regionId: regionId
        domain: domain
        name: SMTP Corp
        subType: subType
        scopes: scopes
        category: Email
      properties:
        appId:
          type: string
        category:
          example: Email
          type: string
        clientId:
          type: string
        clientId2:
          type: string
        content:
          type: string
        createdAt:
          example: '2021-09-01T00:00:00.000Z'
          type: string
        customAuthUrl:
          type: string
        customTokenUrl:
          type: string
        customUserInfoUrl:
          type: string
        disableSsl:
          type: boolean
        domain:
          type: string
        endpoint:
          type: string
        host:
          type: string
        id:
          example: 00000000-0000-0000-0000-000000000000
          type: string
        intranetEndpoint:
          type: string
        issuerUrl:
          type: string
        method:
          type: string
        name:
          example: SMTP Corp
          type: string
        port:
          type: integer
        providerUrl:
          type: string
        receiver:
          type: string
        regionId:
          type: string
        scopes:
          type: string
        signName:
          type: string
        subType:
          type: string
        templateCode:
          type: string
        title:
          type: string
        type:
          description: >-
            Type is the provider type exactly as stored in Casdoor. SMS
            providers

            created before the canonical "Twilio SMS" was adopted are still
            stored as

            "Twilio", so both values can appear here.
          example: SendGrid
          type: string
      type: object
    pkg.HTTPError:
      properties:
        code:
          type: string
        entityType:
          type: string
        err:
          type: object
        message:
          type: string
        title:
          type: string
      type: object
  securitySchemes:
    BearerAuth:
      description: 'Bearer authentication. Send Authorization: Bearer <token>.'
      in: header
      name: Authorization
      type: apiKey

````