Sample - OpenAI API
DELETE/projects/{project_id}/roles/{role_id}

Delete a project role

Deletes a custom role from a project. Supply project_id and role_id to identify the project role you want to remove, and use the confirmation response to verify the deletion.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

2 parameters
project_idstringrequired
The ID of the project to update.
role_idstringrequired
The ID of the role to delete.

2 status codes
200Returns a deletion confirmation containing the deleted role's identifier and a `deleted` flag.
objectstringrequired
Always `role.deleted`.
Allowed:role.deleted
idstringrequired
Identifier of the deleted role.
deletedbooleanrequired
Whether the role was deleted.
429Returned when the request was rejected because a rate limit was exceeded.
errorobjectrequired

Error handling

A 429 is returned when the request exceeds the applicable rate limit. project_id and role_id must identify the project role you intend to delete.