---
title: Update an invitation role
description: Changes the role on a pending invitation.
doc_version: 0.1.0-preview
last_updated: 2026-09-14
---

# Update an invitation role

`PATCH /v1/workspaces/{workspaceId}/invitations/{invitationId}`

Changes the role on a pending invitation. Requires the admin role.

## Authentication

Send `Authorization: Bearer <GRAPHON_API_KEY>`. Read the key from the
GRAPHON_API_KEY environment variable. Never print it.

## Path parameters

- `workspaceId` (string) — The workspace id.
- `invitationId` (string) — The invitation id.

## Request body

- `role` (string) — New role for the pending invitation. One of: viewer, editor, admin.

## Example request

```bash
curl --request PATCH \
  --url "https://api.graphon.ai/v1/workspaces/wspq7ws2np5l8z4/invitations/invC3d4E5f6G7" \
  --header "Authorization: Bearer $GRAPHON_API_KEY" \
  --header "Content-Type: application/json" \
  --data '{"role":"viewer"}'
```

## CLI

```bash
graphon invitations update inv_3kR9 --role viewer
```

## Example response

```json
{
  "id": "invC3d4E5f6G7",
  "workspaceId": "wspq7ws2np5l8z4",
  "email": "grace@example.com",
  "role": "editor",
  "state": "pending",
  "delivery": "queued",
  "expiresAt": "2026-09-21T18:00:00.000Z",
  "revision": 1
}
```

## Sitemap

See the full [sitemap](/sitemap.md) for all pages.
