Notifications
The notification centre (bell) and browser push: list and mark notifications read; register a browser for Web Push.
| Method | Path | Summary |
|---|---|---|
| GET | /v1/user/notifications | List your notifications |
| POST | /v1/user/notifications/read | Mark notifications read |
| GET | /v1/user/push/key | Get the Web Push public key |
| POST | /v1/user/push/subscribe | Register a browser for push notifications |
| POST | /v1/user/push/unsubscribe | Stop push notifications to a browser |
#List your notifications
GET
/v1/user/notifications- Address
https://<your-org>.brambleit.cloud/api/v1/user/notifications- Requires
- Signed-in session,
X-API-Key, or a Bramble app access token (Authorization: Bearer).
Query parameters
| Name | Type | Description |
|---|---|---|
limit | integer |
Response 200
| Field | Type | Description |
|---|---|---|
notifications | array of object | |
notifications[].id | integer | |
notifications[].app | string | |
notifications[].kind | string | |
notifications[].title | string | |
notifications[].body | string, or null | |
notifications[].url | string, or null | |
notifications[].created_at | string (date-time) | |
notifications[].read_at | string (date-time), or null | |
unread | number |
Example response
JSON
{
"notifications": [
{
"id": 42,
"app": "string",
"kind": "string",
"title": "Example title",
"body": "<p>…</p>",
"url": "https://example.com/…",
"created_at": "2026-11-12T09:30:00.000Z",
"read_at": "2026-11-12T09:30:00.000Z"
}
],
"unread": 12.5
}Example request
Bash
curl -X GET 'https://<your-org>.brambleit.cloud/api/v1/user/notifications' \
-H "X-API-Key: $BRAMBLE_KEY"JavaScript
const res = await fetch('https://<your-org>.brambleit.cloud/api/v1/user/notifications', {
method: 'GET',
headers: { 'X-API-Key': process.env.BRAMBLE_KEY },
});
const data = await res.json();Python
import os, requests
r = requests.get(
"https://<your-org>.brambleit.cloud/api/v1/user/notifications",
headers={"X-API-Key": os.environ["BRAMBLE_KEY"]},
)
r.raise_for_status()
data = r.json()PowerShell
$headers = @{ 'X-API-Key' = $env:BRAMBLE_KEY }
Invoke-RestMethod -Method GET -Uri 'https://<your-org>.brambleit.cloud/api/v1/user/notifications' -Headers $headers#Mark notifications read
POST
/v1/user/notifications/read- Address
https://<your-org>.brambleit.cloud/api/v1/user/notifications/read- Requires
- Signed-in session,
X-API-Key, or a Bramble app access token (Authorization: Bearer).
Request body JSON
| Name | Type | Description |
|---|---|---|
ids | array of any | Notification ids to mark read. |
all | any | true marks every notification read. |
Response 200
| Field | Type | Description |
|---|---|---|
ok | boolean |
Example response
JSON
{
"ok": true
}Example request
Bash
curl -X POST 'https://<your-org>.brambleit.cloud/api/v1/user/notifications/read' \
-H "X-API-Key: $BRAMBLE_KEY" \
-H "Content-Type: application/json" \
-d '{"ids":[],"all":"…"}'JavaScript
const res = await fetch('https://<your-org>.brambleit.cloud/api/v1/user/notifications/read', {
method: 'POST',
headers: { 'X-API-Key': process.env.BRAMBLE_KEY, 'Content-Type': 'application/json' },
body: JSON.stringify({"ids":[],"all":"…"}),
});
const data = await res.json();Python
import os, requests
r = requests.post(
"https://<your-org>.brambleit.cloud/api/v1/user/notifications/read",
headers={"X-API-Key": os.environ["BRAMBLE_KEY"]},
json={"ids":[],"all":"…"},
)
r.raise_for_status()
data = r.json()PowerShell
$headers = @{ 'X-API-Key' = $env:BRAMBLE_KEY }
$body = '{"ids":[],"all":"…"}'
Invoke-RestMethod -Method POST -Uri 'https://<your-org>.brambleit.cloud/api/v1/user/notifications/read' -Headers $headers -ContentType 'application/json' -Body $body#Get the Web Push public key
GET
/v1/user/push/key- Address
https://<your-org>.brambleit.cloud/api/v1/user/push/key- Requires
- Signed-in session,
X-API-Key, or a Bramble app access token (Authorization: Bearer).
Response 200
| Field | Type | Description |
|---|---|---|
publicKey | string |
Example response
JSON
{
"publicKey": "…"
}Example request
Bash
curl -X GET 'https://<your-org>.brambleit.cloud/api/v1/user/push/key' \
-H "X-API-Key: $BRAMBLE_KEY"JavaScript
const res = await fetch('https://<your-org>.brambleit.cloud/api/v1/user/push/key', {
method: 'GET',
headers: { 'X-API-Key': process.env.BRAMBLE_KEY },
});
const data = await res.json();Python
import os, requests
r = requests.get(
"https://<your-org>.brambleit.cloud/api/v1/user/push/key",
headers={"X-API-Key": os.environ["BRAMBLE_KEY"]},
)
r.raise_for_status()
data = r.json()PowerShell
$headers = @{ 'X-API-Key' = $env:BRAMBLE_KEY }
Invoke-RestMethod -Method GET -Uri 'https://<your-org>.brambleit.cloud/api/v1/user/push/key' -Headers $headers#Register a browser for push notifications
POST
/v1/user/push/subscribe- Address
https://<your-org>.brambleit.cloud/api/v1/user/push/subscribe- Requires
- Signed-in session,
X-API-Key, or a Bramble app access token (Authorization: Bearer).
Request body JSON
| Name | Type | Description |
|---|---|---|
subscription | any | The browser's PushSubscription (as JSON). |
scope | any |
Response 200
| Field | Type | Description |
|---|---|---|
ok | boolean |
Example response
JSON
{
"ok": true
}Example request
Bash
curl -X POST 'https://<your-org>.brambleit.cloud/api/v1/user/push/subscribe' \
-H "X-API-Key: $BRAMBLE_KEY" \
-H "Content-Type: application/json" \
-d '{"subscription":"…","scope":"…"}'JavaScript
const res = await fetch('https://<your-org>.brambleit.cloud/api/v1/user/push/subscribe', {
method: 'POST',
headers: { 'X-API-Key': process.env.BRAMBLE_KEY, 'Content-Type': 'application/json' },
body: JSON.stringify({"subscription":"…","scope":"…"}),
});
const data = await res.json();Python
import os, requests
r = requests.post(
"https://<your-org>.brambleit.cloud/api/v1/user/push/subscribe",
headers={"X-API-Key": os.environ["BRAMBLE_KEY"]},
json={"subscription":"…","scope":"…"},
)
r.raise_for_status()
data = r.json()PowerShell
$headers = @{ 'X-API-Key' = $env:BRAMBLE_KEY }
$body = '{"subscription":"…","scope":"…"}'
Invoke-RestMethod -Method POST -Uri 'https://<your-org>.brambleit.cloud/api/v1/user/push/subscribe' -Headers $headers -ContentType 'application/json' -Body $body#Stop push notifications to a browser
POST
/v1/user/push/unsubscribe- Address
https://<your-org>.brambleit.cloud/api/v1/user/push/unsubscribe- Requires
- Signed-in session,
X-API-Key, or a Bramble app access token (Authorization: Bearer).
Request body JSON
| Name | Type | Description |
|---|---|---|
endpoint | any | The subscription's endpoint URL. |
Response 200
| Field | Type | Description |
|---|---|---|
ok | boolean |
Example response
JSON
{
"ok": true
}Example request
Bash
curl -X POST 'https://<your-org>.brambleit.cloud/api/v1/user/push/unsubscribe' \
-H "X-API-Key: $BRAMBLE_KEY" \
-H "Content-Type: application/json" \
-d '{"endpoint":"…"}'JavaScript
const res = await fetch('https://<your-org>.brambleit.cloud/api/v1/user/push/unsubscribe', {
method: 'POST',
headers: { 'X-API-Key': process.env.BRAMBLE_KEY, 'Content-Type': 'application/json' },
body: JSON.stringify({"endpoint":"…"}),
});
const data = await res.json();Python
import os, requests
r = requests.post(
"https://<your-org>.brambleit.cloud/api/v1/user/push/unsubscribe",
headers={"X-API-Key": os.environ["BRAMBLE_KEY"]},
json={"endpoint":"…"},
)
r.raise_for_status()
data = r.json()PowerShell
$headers = @{ 'X-API-Key' = $env:BRAMBLE_KEY }
$body = '{"endpoint":"…"}'
Invoke-RestMethod -Method POST -Uri 'https://<your-org>.brambleit.cloud/api/v1/user/push/unsubscribe' -Headers $headers -ContentType 'application/json' -Body $bodyWas this page helpful?
Thanks for your feedback.