Delete OIDC Provider
DELETE /environments/{env_id}/oidc_providers/{oidc_provider_id}
DELETE /environments/{env_id}/oidc_providers/{oidc_provider_id}Interactive request editor loads with JavaScript.
Authorization
BearerAdminToken Organization-scoped admin token. Read operations require a valid token, and write operations require a token with write permission.
In: header
Path Parameters
Environment ID that scopes the request.
uuidOIDC provider ID within the environment.
uuidResponse Body
application/json
application/json
application/json
application/json
application/json
curl -X DELETE "$AISIX_CP/environments/$ENV_ID/oidc_providers/$OIDC_PROVIDER_ID" \ -H "Authorization: Bearer $AISIX_TOKEN"OK
{
"warnings": [
{
"code": "string",
"message": "string"
}
],
"deleted": true,
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
}Request body or parameters failed validation.
{
"error": {
"code": "string",
"message": "string"
}
}Missing or invalid bearer.
{
"error": {
"code": "UNAUTHENTICATED",
"message": "no org context"
}
}Authenticated request is not permitted.
{
"error": {
"code": "CUSTOM_KEY_DISABLED",
"message": "custom API key values are disabled for this organization"
}
}Resource not found.
{
"error": {
"code": "NOT_FOUND",
"message": "provider key not found"
}
}Complete operation details and schema variants
DELETE /environments/{env_id}/oidc_providers/{oidc_provider_id}
Delete OIDC Provider
Deletes the OIDC provider. Tokens issued by it stop
authenticating as soon as the gateway picks up the change;
API keys and their jwt_subject bindings are unaffected.
Parameters
env_id(path, string, required): Environment ID that scopes the request.oidc_provider_id(path, string, required): OIDC provider ID within the environment.
Responses
-
200: OK -
warnings(array, optional): Present when api_keys or claim mappings still name the deleted provider. Both carriers reference a provider by NAME, so nothing can sweep them and nothing needs to: a key falls back to plain bearer authentication and a mapping stops being selected, both fail closed, and both are correct again the moment a provider of that name exists. Renaming a provider is implemented as delete plus re-create, so this is the routine case rather than an error. -
warnings[].code(string, required): Stable identifier for the kind of leftover reference. -
warnings[].message(string, required): Human-readable detail, including how many rows still refer to the deleted resource. -
deleted(boolean, required): Whether the OIDC provider was deleted. -
id(string, required): Deleted OIDC provider ID. -
400: Request body or parameters failed validation. -
error(object, required): Error details. -
error.code(string, required): Machine-readable identifier. Examples:UNAUTHENTICATED,INVALID_REQUEST,MASTER_KEY_UNSET,INTERNAL. -
error.message(string, required): Human-readable explanation; safe to surface to operators. -
401: Missing or invalid bearer. Response fields (application/json): identical toDELETE /environments/{env_id}/oidc_providers/{oidc_provider_id}, response 400 above. -
403: Authenticated request is not permitted. Response fields (application/json): identical toDELETE /environments/{env_id}/oidc_providers/{oidc_provider_id}, response 400 above. -
404: Resource not found. Response fields (application/json): identical toDELETE /environments/{env_id}/oidc_providers/{oidc_provider_id}, response 400 above.
cURL
curl -X DELETE '$AISIX_CP/environments/{env_id}/oidc_providers/{oidc_provider_id}' -H 'Authorization: Bearer $AISIX_TOKEN'