Preview. This site is still being built. Features, prices and terms may change, and nothing here is a binding offer. Read the preview notice

Preview. Still being built; nothing here is a binding offer. Details

Notifications

9 routes. Paths are relative to https://api.intersink.com/v1.

All groups

The signed-in account's notifications, newest first

GET/notifications

Needs a signed-in user (Bearer token or access_token cookie).

Each row carries the stable type and target ({ kind, id, ...ids }, ids as strings), the same as the SSE notification.created event and the push data. security.device_added rows carry target.device_id: the e2ee device id of the device that was added.

Parameters

NameTypeDescription
limitrequiredstring, query
offsetrequiredstring, query
active_profile_idrequiredstring, query

Response

200. data is object[].

FieldTypeDescription
idrequiredinteger or string
typerequiredstringThe kind. New kinds are only added; a kind is never renamed. Example: "security.device_added"
titlerequiredstringExample: "New device added"
messagerequiredstringExample: "A new device was added: Firefox on macOS."
readrequiredboolean
post_idrequiredinteger or string
campaign_idrequiredinteger or string
event_idrequiredinteger or string
thumbnail_urlrequiredstring
comment_idrequiredinteger or string
routerequiredobject
route.screenrequiredstringExample: "security"
route.idrequiredstringExample: ""
targetrequiredobject
target.kindrequiredstringWhat the notification is about: post, comment, story, profile, group, event, listing, report, account (new-place sign-in alert), or an older kind's screen such as security (other security alerts, including security.device_added). Some kinds add more string ids next to the ones listed here (interest_id, outcome, source, decision, content_kind, action). Example: "post"
target.idrequiredstringExample: "42"
target.post_idstringComment targets: the post the comment is on.
target.device_idstringsecurity.device_added only: the e2ee device id (1 to 127, as a decimal string) of the device that was just added, so that device can tell its own alert from one about another device. Example: "2"
target.listing_kindstringListing targets. One of: "post", "product".
recipient_profile_idrequiredstring
created_atrequiredstring (date-time)
actorrequiredobject
actor.idrequiredstring
actor.namerequiredstring
actor.avatarrequiredstring
actor.image_urlrequiredstring

Mark as read

PATCH/notifications/{id}/read

Needs a signed-in user (Bearer token or access_token cookie).

Parameters

NameTypeDescription
idrequirednumber, path

Response

200. The payload in data is not described in the spec yet.

Broadcast

POST/notifications/broadcast

Public: no sign-in needed.

Parameters

NameTypeDescription
x-admin-keystring, header

Response

201. The payload in data is not described in the spec yet.

Your notification preferences: flat per-type push switches and `delivery: { <type>: { in_app, push, email } }` for like, comment, repost, donation, follow, campaign, connection, share, mention, group, event, listing and safety

GET/notifications/preferences

Needs a signed-in user (Bearer token or access_token cookie).

Response

200. The payload in data is not described in the spec yet.

Change preferences: flat `{ <type>: boolean }` (push) and/or `{ delivery: { <type>: { in_app?, push?, email? } } }`. Unknown types, channels or non-boolean values answer 400.

PATCH/notifications/preferences

Needs a signed-in user (Bearer token or access_token cookie).

Response

200. The payload in data is not described in the spec yet.

Register push token

POST/notifications/push-token

Needs a signed-in user (Bearer token or access_token cookie).

Response

201. The payload in data is not described in the spec yet.

Remove push token

DELETE/notifications/push-token

Needs a signed-in user (Bearer token or access_token cookie).

Response

200. The payload in data is not described in the spec yet.

Mark all as read

PATCH/notifications/read-all

Needs a signed-in user (Bearer token or access_token cookie).

Parameters

NameTypeDescription
active_profile_idrequiredstring, query

Response

200. The payload in data is not described in the spec yet.

Get unread count

GET/notifications/unread-count

Needs a signed-in user (Bearer token or access_token cookie).

Parameters

NameTypeDescription
active_profile_idrequiredstring, query

Response

200. The payload in data is not described in the spec yet.