role.deleted
Role deleted; collaborators revert to default.
project_id is always null for role events. This is the final event you
will receive for the given role_id.
When this fires
A custom role is deleted. Any collaborators currently holding the role revert to the team's default role.
Required ability
role:view-any — token must carry this at mint time to subscribe an endpoint to this event.
Payload
{
"id": "evt_01HX...",
"type": "role.deleted",
"created_at": "2026-05-22T10:05:00Z",
"api_version": "2026-05-01",
"project_id": null,
"data": {
"team_id": "tem_01HX...",
"role": {
"id": "rol_01HX...",
"code": "plan-editor"
}
}
}Field reference
| Field | Type | Notes |
|---|---|---|
id | string ULID | Unique event id, prefixed evt_. Use for idempotent processing. |
type | string | Always role.deleted for this event. |
created_at | ISO 8601 timestamp | Server-side emission time. |
api_version | string | Webhook API contract version. |
project_id | null | Always null — account-level event. |
data.team_id | string ULID | Team the role belonged to. |
data.role.id | string ULID | Role that was deleted. |
data.role.code | string | Last-known stable role code. |
Caveats
- Collaborators previously on this role do not produce per-user
team.member.role_changedevents for the fallback transition. - System roles cannot be deleted, so this event only ever applies to custom roles.
Related events
role.created— first event in the lifecycle.team.member.role_changed— emits for explicit role re-assignments.- Role events overview — back to family overview.
How is this guide?