Skip to main content

Prerequisites

To follow this guide with the API, you’ll need to:
  • Go to Bodhveda Console.
  • Create a new project.
  • Click on API Keys in the sidebar.
  • Click on Create API Key and generate an API key with Full access scope.

Send direct notification with API

Use the send notification API to send a direct notification to a recipient. If the recipient doesn’t exist, Bodhveda creates it automatically when sending a direct notification.
Then you can use the list recipient’s notifications API and you will see the notification you just sent earlier.
This send carries no target, and adding one needs no setup either — targets work out of the box. Targets are how you get per-notification preferences and analytics, so they are the next thing to reach for.Cataloging a target — creating a project preference for it — is what puts it on your recipients’ settings screen so they can mute it. Until you do, the notification still sends, but nobody can switch it off. Once your catalog is stable you can turn on strict targets in your project settings, and an uncataloged target becomes a 400 instead of a silent gap.A topic: any entry covers every concrete topic beneath it, so one row like post/any/comment is enough for post/123/comment, post/456/comment, and the rest — no catalog write per post.

Send broadcast notification with API

Broadcast to multiple recipients. This requires some setup:
Create a recipient
Use create recipient API to create a recipient in your project.
Create a project preference
Before broadcasting, you must add at least one project preference to define a target (channel, topic, event):
  1. Go to Bodhveda Console.
  2. Click on Preferences in the sidebar.
  3. Click on Create Preference.
  4. Define a target by mentioning the channel, topic, and event, give it a name (and an optional description), and set default to enabled.
  5. Save the preference.
This way all recipients are by default subscribed to this target in your project.
Send broadcast notification
Use the send notification API to send a broadcast notification to a target that was used to create the project preference.
No recipient_id makes this notification turn into a broadcast. All recipients subscribed to this target will receive this notification.

Send notification from Console

You can also send notifications from the Bodhveda Console:
  1. Go to Notifications tab.
  2. Click on Send Notification to send a direct notification to a recipient or a broadcast to subscribed recipients.
Next Steps

API Reference

Explore the API in depth.

Concepts

Explore concepts that make up Bodhveda.