- Qubitara Synapse
- Developer guide
- The REST API
The REST API
Base path#
Every endpoint lives under /api/v1 on your Synapse host:
https://<your-synapse-host>/api/v1Requests and responses are JSON. Send Content-Type: application/json with a body.
Authentication#
Two credentials work:
Credential | For | How |
|---|---|---|
A session | A person, or a script acting as one |
|
An API key | A machine | Created under API keys, scoped to what it may do. Sent as |
An organization that requires a second factor answers POST /auth/login with a challengeToken; complete it with POST /auth/login/mfa and the six-digit code.
A first request#
curl -X POST https://<host>/api/v1/auth/login \
-H "Content-Type: application/json" \
-d '{"organizationSlug":"acme","email":"[email protected]","password":"…"}'The second call lists the spaces the credential can see — the API calls them projects.
Conventions#
Identifiers are UUIDs. A page also has a human reference (
OPS-12) which is for display, not for the API.Spaces are
projectsin paths; space groups areworkspaces.Lists answer with an array, or with
{ "items": [...] }where the list is pageable;limitcaps a page.Timestamps are ISO 8601 in UTC.
Deletion is usually a verb that says what it does —
POST /pages/:id/archivesends a page to the trash,DELETE /pages/:id/purgeremoves it for good — because the two are very different acts.Not found and not yours look the same: 404. The API does not confirm that something exists to a caller who may not see it.
Who you are#
GET /auth/me answers with the signed-in person, their organization, and their capabilities. GET /profile/access lists every role they hold and where each came from; POST /profile/access/simulate asks "could I do action on resource?" without doing it.
Switching organizations#
A person who belongs to several organizations switches with POST /auth/switch — it ends the current session and starts one in the target organization. GET /auth/organizations lists the ones available.
The endpoints#
Grouped by what they touch. Each group has its own page here or in Administration.
Area | Paths |
|---|---|
Sign-in and sessions |
|
Spaces and space groups |
|
Pages, versions, trash |
|
Comments, reviews, labels, favorites, watching |
|
Attachments |
|
Search and AI |
|
Documentation (members) and public documentation |
|
Imports |
|
Notifications and activity |
|
Administration |
|
Billing |
|
SCIM (for identity providers) |
|