Delete user API key
DELETE /api/service/users/{user_id}/orgs/{org_id}/api-keys/{key_name}
Delete a system API key created by the service. This endpoint allows the automations service to clean up API keys it previously created for users. Args: user_id: The user ID org_id: The organization ID key_name: The name of the key to delete (without SYSTEM: prefix) x_service_api_key: Service API key header for authentication Returns: dict: Success message Raises: HTTPException: 401 if service key is invalid HTTPException: 404 if key not found
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
user_id | path | string | yes | — |
org_id | path | string | yes | — |
key_name | path | string | yes | — |
X-Service-API-Key | header | `string | null` | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
Operation ID: delete_user_api_key_api_service_users__user_id__orgs__org_id__api_keys__key_name__delete