---
title: "Notify multiple users"
method: POST
path: "/{WSID}/{version}/event/bulk"
tags: ["Fire an Event"]
---

# Notify multiple users

`POST /{WSID}/{version}/event/bulk`

This API enables you to notify multiple users with one event trigger.<br/><br/>Before firing your first notification event, you must perform the following actions in your Fyno account:<br/>- Create a Template<br/>- Create an Event<br/>- Create an API Key<br/>- And obtain your workspace ID from the API Keys page.

## Path parameters

- `WSID` string, required
- `version` 'live' | 'test', required

## Request body

- EventBulkBody
  - `event` string, required — Enter the name of the event you wish to fire.
  - `batch` union[], required — Your batch payload must specify at least *`distinct_id`* or *`to`* while firing a notification event.<br/><br/>If the payload contains&#58;<br/><br/>- <b>Option 1&#58;</b> ONLY *`to`* (and no *`distinct_id`*) - the event uses all destination values from the *`to`* object (as it is).<br/><br/>- <b>Option 2&#58;</b> ONLY *`distinct_id`* (and no *`to`*) - the event uses all destination values (such as SMS, WhatsApp, Email, Push, Voice and so on) from the user's profile and sends the notification.<br/><br/>- <b>Option 3&#58;</b> BOTH *`distinct_id`* and *`to`* - the `to` and `distinct_id` channel data merges (`to` object take precedences) and sends the notification. The sent notification is tagged to the ID specified, which can be then used to search the logs by using `distinct_id`.
    - union
      - object
        - `to` To, required
          - `sms` string — Enter the mobile number of the user. The number must start with the country code (without +). For example&#58; 919879XXXXXX.
          - `whatsapp` string — Enter the WhatsApp mobile number of the user. The number must start with the country code (without +). For example&#58; 919879XXXXXX
          - `email` string — Enter the email address of the user.
          - `slack` string — Enter the channel ID, user ID, or email address of the user.
          - `discord` string — Enter the discord ID of the user.
          - `teams` string — Enter the channel name. For teams, we currently support sending to one channel only. If you wish to send to multiple channels, do get in touch and we can share a workaround.
          - `push` string — If you use multiple Push providers, add the following prefix for the respective provider tokens:<br/><br/>- <b>For Expo&#58;</b> `expo_token:`<your_pushtoken><br/>- <b>For FCM&#58;</b> `fcm_token:`<your_pushtoken><br/>- <b>For OneSignal playerId&#58;</b> `onesignal_player_id:`<enter_playerid><br/>- <b>For OneSignal externalId&#58;</b> `onesignal_external_id:`<enter_externalid><br/>- <b>For Mi Push&#58;</b> `mi_token:`<your_pushtoken><br/><br/>If you use just one provider, then the prefix is not required. However, if you wish to use OneSignal with playerId token, then the prefix is required.
          - `inapp` string — Enter the distinct ID or the generated token of the user.
          - `voice` string — Enter the mobile number of the user. The number must start with the country code (without +). For example&#58; 919879XXXXXX.
        - `data` Data — (Optional) Enter the keys and values of your replaceabale placeholders. These values are replaced in the respective keys of the template when the notification is sent.
        - `callback` Callback — (Optional) You can enable callback for an event by specifying the `callback` attribute in the payload of the event. By enabling callback, you will be able to receive delivery status of the events onto your webhook URL specified in the "Allowlist URL" section of the application. See <a href="/docs/allowlist" target="_blank">Allowlist URL</a> for more details.<br/><br/>The following parameters are prefined within callback and can be passed dynamically when you invoke an event&#58;<br/><br/>**Note&#58;** Additional parameters can be added from the DLR configuration in the Allowlist URL page.
          - `custom_id` string, required — Use this parameter to send an ID that you would want to receive as a response (for reconciliation) in your delivery callback.
          - `custom1` string — (Optional) Use this parameter to send another ID that you want to receive as a response (for reconciliation) in your delivery callback.
          - `custom2` string — (Optional) Use this parameter to send yet another ID that you want to receive as a response (for reconciliation) in your delivery callback.
          - `enable` true | false — (Optional) Set `true` to enable delivery callback or `false` to disable delivery callback. The default value is `true`.
      - object
        - `distinct_id` string, required — Enter the distinct ID that you use to identify the recipient.
        - `data` Data — (Optional) Enter the keys and values of your replaceabale placeholders. These values are replaced in the respective keys of the template when the notification is sent.
        - `callback` Callback — (Optional) You can enable callback for an event by specifying the `callback` attribute in the payload of the event. By enabling callback, you will be able to receive delivery status of the events onto your webhook URL specified in the "Allowlist URL" section of the application. See <a href="/docs/allowlist" target="_blank">Allowlist URL</a> for more details.<br/><br/>The following parameters are prefined within callback and can be passed dynamically when you invoke an event&#58;<br/><br/>**Note&#58;** Additional parameters can be added from the DLR configuration in the Allowlist URL page.
          - `custom_id` string, required — Use this parameter to send an ID that you would want to receive as a response (for reconciliation) in your delivery callback.
          - `custom1` string — (Optional) Use this parameter to send another ID that you want to receive as a response (for reconciliation) in your delivery callback.
          - `custom2` string — (Optional) Use this parameter to send yet another ID that you want to receive as a response (for reconciliation) in your delivery callback.
          - `enable` true | false — (Optional) Set `true` to enable delivery callback or `false` to disable delivery callback. The default value is `true`.
      - object
        - `distinct_id` string, required — Enter the distinct ID that you use to identify the recipient.
        - `to` To, required
          - `sms` string — Enter the mobile number of the user. The number must start with the country code (without +). For example&#58; 919879XXXXXX.
          - `whatsapp` string — Enter the WhatsApp mobile number of the user. The number must start with the country code (without +). For example&#58; 919879XXXXXX
          - `email` string — Enter the email address of the user.
          - `slack` string — Enter the channel ID, user ID, or email address of the user.
          - `discord` string — Enter the discord ID of the user.
          - `teams` string — Enter the channel name. For teams, we currently support sending to one channel only. If you wish to send to multiple channels, do get in touch and we can share a workaround.
          - `push` string — If you use multiple Push providers, add the following prefix for the respective provider tokens:<br/><br/>- <b>For Expo&#58;</b> `expo_token:`<your_pushtoken><br/>- <b>For FCM&#58;</b> `fcm_token:`<your_pushtoken><br/>- <b>For OneSignal playerId&#58;</b> `onesignal_player_id:`<enter_playerid><br/>- <b>For OneSignal externalId&#58;</b> `onesignal_external_id:`<enter_externalid><br/>- <b>For Mi Push&#58;</b> `mi_token:`<your_pushtoken><br/><br/>If you use just one provider, then the prefix is not required. However, if you wish to use OneSignal with playerId token, then the prefix is required.
          - `inapp` string — Enter the distinct ID or the generated token of the user.
          - `voice` string — Enter the mobile number of the user. The number must start with the country code (without +). For example&#58; 919879XXXXXX.
        - `data` Data — (Optional) Enter the keys and values of your replaceabale placeholders. These values are replaced in the respective keys of the template when the notification is sent.
        - `callback` Callback — (Optional) You can enable callback for an event by specifying the `callback` attribute in the payload of the event. By enabling callback, you will be able to receive delivery status of the events onto your webhook URL specified in the "Allowlist URL" section of the application. See <a href="/docs/allowlist" target="_blank">Allowlist URL</a> for more details.<br/><br/>The following parameters are prefined within callback and can be passed dynamically when you invoke an event&#58;<br/><br/>**Note&#58;** Additional parameters can be added from the DLR configuration in the Allowlist URL page.
          - `custom_id` string, required — Use this parameter to send an ID that you would want to receive as a response (for reconciliation) in your delivery callback.
          - `custom1` string — (Optional) Use this parameter to send another ID that you want to receive as a response (for reconciliation) in your delivery callback.
          - `custom2` string — (Optional) Use this parameter to send yet another ID that you want to receive as a response (for reconciliation) in your delivery callback.
          - `enable` true | false — (Optional) Set `true` to enable delivery callback or `false` to disable delivery callback. The default value is `true`.

## Response `202`

Request accepted successfully

- InlineResponse2021
  - `request_id` string
  - `received_time` number
  - `event` string
  - `response` InlineResponse2021Response[]
    - `seq` integer
    - `sms` InlineResponse202ResponseSms
      - `status` string
      - `destination` string
      - `msg_id` string
    - `whatsapp` InlineResponse202ResponseSms
      - `status` string
      - `destination` string
      - `msg_id` string
    - `email` InlineResponse202ResponseEmail
      - `status` string
      - `destination` string
      - `msg_id` string
    - `slack` InlineResponse202ResponseSlack
      - `status` string
      - `destination` string
      - `msg_id` string
    - `discord` InlineResponse202ResponseDiscord
      - `status` string
      - `destination` string
      - `msg_id` string
    - `teams` InlineResponse202ResponseTeams
      - `status` string
      - `destination` string
      - `msg_id` string
    - `push` InlineResponse202ResponsePush
      - `status` string
      - `destination` string
      - `msg_id` string
    - `inapp` InlineResponse202ResponseInapp
      - `status` string
      - `destination` string
      - `msg_id` string
    - `voice` InlineResponse202ResponseSms
      - `status` string
      - `destination` string
      - `msg_id` string

## Other responses

- `400` — Event name does not exist
- `401` — API Key is invalid

## Changes

- **2025-02-07** `2dd806ab440c` — 1 breaking, 1 info
  - removed `subschema #1, subschema #2, subschema #3` from the `batch/items/` request property `oneOf` list
  - added `subschema #1, subschema #2, subschema #3` to the `batch/items/` request property `oneOf` list
- **2025-02-07** `7b479358bfc0` — 1 breaking, 1 info
  - removed `subschema #1, subschema #2, subschema #3` from the `batch/items/` request property `oneOf` list
  - added `subschema #1, subschema #2, subschema #3` to the `batch/items/` request property `oneOf` list

[Change history](https://skmtc.dev/fynoio/apis/fyno-rest-api/changes/:WSID/:version/event/bulk/post.md)

---

[API](https://skmtc.dev/fynoio/apis/fyno-rest-api.md) · [All operations](https://skmtc.dev/fynoio/apis/fyno-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/fynoio/fyno-rest-api/revisions/e14ea0f93a85/schema)
