Skip to main content

Messages overview

Once you have integrated Rokt with your site, you can communicate with the placements by subscribing and sending messages.

Listen to messages from the Placement

Message to update your cart

When the user interacts with the Rokt placement by adding, updating or removing items from the cart, you can subscribe to a stream and receive messages describing each of those changes.

Check our guide on how to integrate your cart with Rokt for more information.

Method placement.on(event)

Send messages to the Placement

Message to update Placement cart

When a change happens on your cart, you can update the Rokt placement cart by sending it a message.

Note Please be advised that changes need to comply with the existing configuration of your placement. If the message instructs the Rokt placement to increase or decrease the quantity out of the valid range (a minimum and/or maximum quantity could be set on cart items), the change will only takes effect within those bounderies.

Check our guide on how to update the Rokt cart for more information.

Method placement.send(event, data)