Event Notifications
Stay connected to your organization’s knowledge in real time. The Starmind platform can deliver events to your services, workflows, and apps via webhooks and other notification channels. Filter, subscribe, and route events efficiently to integrate expert insights directly into your architecture, ensuring the right information reaches the right place at the right time.
Webhooks let you create integrations that subscribe to specific events in Starmind. For example, whenever a notification is triggered, your webhook endpoint will receive an event payload in real time.
Webhooks
- Webhooks can be configured in the admin area within Starmind (https://yourdomain.starmind.com/admin/settings/web-hook/):
| Setting | Required | Description |
|---|---|---|
| Webhook URL | ✓ | The URL handles the payload. |
| Shared secret | X | A secret key to sign the payload. |
| Events | ✓ | A comma-separated list of supported webhook events. Currently, only "notifications" are supported. |
Payload
Each event type has a specific payload format with the relevant event information.
In addition to the fields documented for each event, webhook payloads include the user who performed the event ( sender) as well as the user who is targeted by the event (receiver). Both fields are optional and depend on the event type and specific event.
Bear in mind that the payload for notification events like new_solution_to_your_question or new_comment_to_your_question allows question posers to be identified. In order to preserve question poser anonymity, this information must not be leaked to any end-users (except for the question poser himself).
Delivery headers
HTTP requests made to your webhook’s configured URL endpoint will contain several special headers:
| Header | Description |
|---|---|
| X-Starmind-Event | Name of the event that triggered this delivery. |
| X-Starmind-Signature | HMAC-SHA256 hex digest of the payload, using the hook’s secret as the key (if configured). |
| X-Starmind-Realm-Id | The Starmind network id that triggered this delivery. |
Also, the User-Agent for the requests will have the prefix Starmind-Brainshot/ Version.
Delivery Body
| Field | Type | Description |
|---|---|---|
| id | integer | Notification ID |
| type | string | Notification type |
| question_id | integer | Question id the notification relates to (or null) |
| source_text | string | Question title if available for notification |
| target_id | integer | Id of the entity the notification relates to |
| target_type | string | Type of the entity the notification relates to |
| target_text | string | Content of the notification entity |
| url | URL | Absolute URL to the Starmind application |
| icon | URL | Absolute URL to an image for that notification |
| created | datetime | The DateTime the notification was created |
Updated 4 days ago
