Edit a pending invite
OWNER-only. Discriminated body — `{ action: 'change-role', role }` updates the role, `{ action: 'extend' }` resets the TTL and re-attributes the inviter to the acting user.
/api/organizations/{orgId}/invites/{inviteId}OWNER-only. Discriminated body — { action: 'change-role', role } updates the role, { action: 'extend' } resets the TTL and re-attributes the inviter to the acting user.
Path Parameters
Organisation id (cuid)
Invite id (cuid)
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
curl -X PATCH "https://loading/api/organizations/string/invites/string" \ -H "Content-Type: application/json" \ -d '{ "action": "change-role", "role": "VIEWER" }'Send (or refresh) an invite POST
OWNER-only. Idempotent refresh-or-create: an existing PENDING invite to the same email is updated in place (TTL reset, role swapped, email re-fired). Email send is fire-and-forget — the invite row exists regardless of SMTP outcome. Per-sender rate-limit (`INVITE_DAILY_LIMIT = 100/day`) returns `429` when capped.
Revoke a pending invite DELETE
OWNER-only. Hard-delete (not a status flip) so the refresh-or-create path on `POST` keeps its idempotency without filtering revoked rows.