---
title: "Update SSO Provider"
method: PATCH
path: "/api/v2/sso-providers/{sso_provider_id}"
tags: ["Auth", "Community", "Enterprise"]
---

# Update SSO Provider

`PATCH /api/v2/sso-providers/{sso_provider_id}`

Updates an existing SSO provider. Updating saml provider requires a "multipart/form-data" body. Updating oidc provider requires "application/json" body. Response is respective provider

## Request body

- object
  - `name` string — Name of the OIDC provider
  - `issuer` string, url — URL of the OIDC issuer
  - `client_id` string — Client ID for the OIDC provider
  - `config` object
    - `auto_provision` object
      - `enabled` boolean — boolean that, if enabled, allows SSO providers to auto provision bloodhound users on initial login
      - `default_role_id` integer — default role id for the user created from SSO provider auto provision
      - `role_provision` boolean — boolean that, if enabled, allows sso providers to manage roles for newly created users

## Response `200`

OK

- union
  - object
    - `data` ModelSamlProvider
      - `id` integer — This is the unique identifier for this object.
      - `created_at` string, date-time
      - `updated_at` string, date-time
      - `deleted_at` NullTime
        - `time` string, date-time — An RFC-3339 formatted string
        - `valid` boolean — Valid is true if `time` is not `null`.
      - `name` string
      - `display_name` string
      - `idp_issuer_uri` string
      - `idp_sso_uri` string
      - `principal_attribute_mappings` string[]
      - `sp_issuer_uri` string
      - `sp_sso_uri` string
      - `sp_metadata_uri` string
      - `sp_acs_uri` string
      - `sso_provider_id` NullInt32
        - `int32` integer
        - `valid` boolean — Valid is true if `int32` is not `null`.
  - object
    - `data` ModelOidcProvider
      - `id` integer — This is the unique identifier for this object.
      - `created_at` string, date-time
      - `updated_at` string, date-time
      - `deleted_at` NullTime
        - `time` string, date-time — An RFC-3339 formatted string
        - `valid` boolean — Valid is true if `time` is not `null`.
      - `client_id` string
      - `issuer` string
      - `sso_provider_id` integer

## Other responses

- `401` — **Unauthorized** This endpoint failed an authentication requirement. Either the client tried to access a protected endpoint without being authenticated, or an auth validation failed (ex- invalid credentials or expired token).
- `403` — **Forbidden** This is most commonly caused by an authenticated client trying to access a resource that it does not have permission for.
- `404` — **Not Found** This error typically comes from operations where a valid ID was passed to the request to look up an entity but the entity could not be found.
- `429` — **Too Many Requests** The client has sent too many requests within a certain time window and tripped the rate limiting middleware.
- `500` — **Internal Server Error** This is usually the result of either an unexpected database or application error. The client may try modifying or resending the request, but the error is likely not related to the client doing something wrong.

---

[API](https://skmtc.net/specterops/apis/bloodhound-api.md) · [All operations](https://skmtc.net/specterops/apis/bloodhound-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/specterops/bloodhound-api/versions/9e5dcb1a1b37/schema)
