POST
/v1/mgmt/tenant/update/batch

Authorization

Descope Project ID and Management Key
AuthorizationBearer <token>

Project ID:Management Key as bearer token.

In: header

Request Body

application/json

tenants*array<UpdateTenantRequest>
Items1 <= items

Update multiple tenants in a single batch, using a valid management key. Each tenant is updated independently; per-tenant failures are returned in the response body.

curl -X POST "https://api.descope.com/v1/mgmt/tenant/update/batch" \  -H "Content-Type: application/json" \  -d '{    "tenants": [      {        "id": "string",        "name": "string"      }    ]  }'
{  "updatedTenantIds": [    "string"  ],  "failedTenants": [    {      "failure": "string",      "tenant": {        "id": "string",        "name": "string",        "selfProvisioningDomains": [          "string"        ],        "customAttributes": {          "attribute-key": "attribute-value"        },        "authType": "string",        "disabled": true,        "enforceSSO": true,        "enforceSSOExclusions": [          "string"        ],        "federatedAppIds": [          "string"        ],        "roleInheritance": "string",        "approvedDomains": null,        "enforceSSOExclusionPermissions": [          "string"        ]      }    }  ],  "additionalErrors": {    "property1": "string",    "property2": "string"  }}
export interface Response {updatedTenantIds?: string[]failedTenants?: UpdateTenantBatchFailureResponse[]additionalErrors?: {[k: string]: string}}export interface UpdateTenantBatchFailureResponse {failure?: string/** * Replaces the tenant's settings: a field left unset is cleared, except approvedDomains and an empty authType, which keep their current values. */tenant?: {id: stringname: stringselfProvisioningDomains?: string[]/** * Custom attributes as key-value pairs. Keys must be strings; values can be strings, numbers, booleans, or arrays. */customAttributes?: {[k: string]: string}/** * deprecated - authType should be set via ConfigureTenantSettings */authType?: stringdisabled?: booleanenforceSSO?: booleanenforceSSOExclusions?: string[]federatedAppIds?: string[]roleInheritance?: string/** * The tenant's vanity hostname (e.g. surveys.example.com), unique across the project's tenants. Requests that reach the project through its trusted proxy on this hostname are bound to this tenant. One item for now *  A list of hostnames, absent keeps the current value and an empty list clears it */approvedDomains?: {[k: string]: unknown}/** * Permission names or IDs whose holders in the tenant may sign in without SSO while enforceSSO is on (break-glass accounts) */enforceSSOExclusionPermissions?: string[]}}
Was this helpful?