For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
SupportDeveloper ForumLogin
  • Overview
    • Introduction
    • Getting Started
    • Integration Example (PSA)
    • Authentication
    • Error Handling
    • Pagination
    • Filtering
    • Ordering
    • Rate Limits
    • Permissions
    • Webhooks
    • MCP Server
    • Versioning
    • Changelog
    • Support
  • API v1 Reference
    • Projects Overview
    • Tasks Overview
    • Time Tracking Overview
    • Documents Overview
    • Search Overview
    • Companies Overview
    • Users Overview
    • Files & Images Overview
    • Custom Fields Overview
    • Workload & Planning Overview
    • Project Templates Overview
    • Workflows Overview
    • Login & Access Overview
      • GETReturns all roles of the workspace.
      • POSTCreates a new role with specified permissions.
      • POSTMoves a user from their current role to another role.
      • GETReturns all users in roles of the workspace.
      • GETReturns the role with the specified id.
      • PUTUpdates the role with the specified id.
      • POSTAdds the user to the role with the specified id.
      • GETReturns all deactivated menu items for the specified role.
      • POSTCreates or updates the deactivated menu items for the specified role.
      • POSTDeletes the role with the specified id.
      • GETReturns all permissions of the specified role.
      • POSTCreates, updates or deletes a permission of the specified role.
      • POSTArchives or unarchives the role with the specified id.
      • GETReturns all users of the specified role.
      • POSTActivates the user with the specified id.
      • POSTDeactivates the user with the specified id.
      • GETReturns the role with the specified name.
    • API Management Overview
LogoLogo
SupportDeveloper ForumLogin
API v1 ReferenceRoles

Deletes the role with the specified id.

POST
https://api.awork.com/api/v1/roles/:roleId/delete
POST
/api/v1/roles/:roleId/delete
$curl -X POST https://api.awork.com/api/v1/roles/roleId/delete \
> -H "Authorization: Bearer <token>" \
> -H "Content-Type: application/json" \
> -d '{
> "newRoleId": "9f8b7c6d-1234-4a56-b789-0c1d2e3f4a5b"
>}'
1{}
<Check title="Required Permissions" icon="key">The user must be an admin or have `workspace-manage-config:write` permissions.</Check>
Was this page helpful?
Previous

Returns all permissions of the specified role.

Next
Built with
Required Permissions
The user must be an admin or have workspace-manage-config:write permissions.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

roleIdstringRequiredformat: "uuid"
The id of the role.

Request

The delete role form payload.
newRoleIdstring or nullOptionalformat: "uuid"
The id of the role to which all users of the old role will be moved. Required if there are users assigned to the role being deleted.

Response

No Content

Errors

400
Bad Request Error
404
Not Found Error
500
Internal Server Error