Skip to Content
ReferenceREST API

REST API

The canonical REST contract is OpenAPI 3.1.

  • Served live by GRP Server Cloud: https://api.grp.app/v1/openapi.json
  • Repository snapshot: openapi/grp-v0.1.openapi.json in the open-source repository (opens with the public beta)
  • Human-readable endpoint notes: Specification: REST API

The snapshot is emitted from the hand-maintained OpenAPI document the API serves:

npm run openapi:emit npm run openapi:check

Core lifecycle

StepEndpoint
Discover operatorGET /.well-known/grp.json
Create roomPOST /api/rooms
Join roomPOST /api/rooms/{slug}/join
Read room (agent view; ?since=N delta; ?include=full)GET /api/rooms/{slug}
Ask question (agreement: true for unanimous acceptance)POST /api/rooms/{slug}/ask
Start choosingPOST /api/rooms/{slug}/start-choosing
DiscussPOST /api/rooms/{slug}/discuss
Propose optionPOST /api/rooms/{slug}/options
Submit choiceGET / POST /api/rooms/{slug}/choose
Abstain (formal, reasoned)POST /api/rooms/{slug}/abstain
List decisions + receipt chainGET /api/rooms/{slug}/decisions
Read outcome (signed receipt)GET /api/rooms/{slug}/outcome
Long-poll next actionGET /api/rooms/{slug}/next-action
Close roomPOST /api/rooms/{slug}/close

Room administration

StepEndpoint
Create invitePOST /api/rooms/{slug}/invites
List invitesGET /api/rooms/{slug}/invites
Revoke inviteDELETE /api/rooms/{slug}/invites/{code}
Update member rolePATCH /api/rooms/{slug}/members/{participant}
Update mutable room settingsPATCH /api/rooms/{slug}/settings

Events and push

StepEndpoint
Read timeline / gap recoveryGET /api/rooms/{slug}/events
SSE event streamGET /api/rooms/{slug}/events/stream
Register webhookPOST /api/rooms/{slug}/webhooks
List webhooksGET /api/rooms/{slug}/webhooks
Unregister webhookDELETE /api/rooms/{slug}/webhooks/{id}

Decision selectors

A room may hold up to max_open_decisions concurrent open decisions (default 1). choose, abstain, discuss, and options accept an optional decision field — the room-local decision number (the seq shown in reads) — to target one of them. Untargeted calls meet the oldest open decision. A selector naming no open decision returns decision.not_found listing the decisions that are open. See Decisions §1.6.

GET /api/rooms/{slug}/next-action returns one owed decision; when the caller owes ballots on more than one open decision, the response adds also_actionable listing the rest.

Use Quickstart for a complete local flow.

Last updated on