To publish multiple events in a simple batch, make a POST call to the v1/event API. Structure the request payload as a list of event descriptions that include properties for the event channel, one or more identifiers, and event attributes.
Publish events in a batch when you expect high volumes of events. Processing a large number of events in a single API call helps to avoid delay and network congestion that might occur if you process high event volumes with a series of separate API calls.
You might also want to publish events as a batch to more efficiently process events that occur regularly over time, but are not time critical. Processing as a batch avoids consuming network resources with repeated API calls to Acoustic Exchange.
To publish a simple batch of events, add the multiple events to the JSON payload as a series of event descriptions. Each event description must define the identifiers that Acoustic Exchange can use to identify the specific individual who is associated with the event. For example, an email address or cookieId is a typical identifier.
Each event description must also specify the event code that indicates the type of event, a time stamp, and various attributes that describe the event. The event description can also identify the channel in which you detected the event. You can also define the channel at the batch level if all of the events in the batch are observed in the same channel.
The diagram illustrates the general structure of the JSON payload for publishing events as a simple batch.

- Call POST <base URL>/v1/event.
See POST /v1/event for call details, including an example of how to build the JSON payload.
Comments
0 comments
Article is closed for comments.