Reviews Events Reference
This documentation page includes the list of all events emitted by the Reviews Module’s workflows.Review Events
Summary
| Event | Description |
|---|---|
| algolia.reviews.changed | Emitted when a review is created or updated, triggering search index synchronization. |
algolia.reviews.changed
Emitted when a review is created or updated, triggering search index synchronization in Algolia. This event is used to keep the search index up-to-date with review data changes.Payload
Workflows Emitting this Event
The following workflows emit this event when they’re executed. These workflows are executed by the application’s API routes.- createReviewWorkflow - Emitted after a review is successfully created
- updateReviewWorkflow - Emitted after a review is successfully updated
Notes
Event Usage
Thealgolia.reviews.changed event is primarily used for search index synchronization. When emitted, subscribers can:
- Update Search Indexes: Keep Algolia search indexes synchronized with the latest review data
- Recalculate Ratings: Trigger recalculation of aggregate ratings for products or sellers
- Send Notifications: Notify relevant parties (sellers, admins) about new or updated reviews
- Analytics: Track review activity for analytics and reporting purposes
Review Deletion
Note that thedeleteReviewWorkflow does not emit any events. Review deletions are handled through workflow hooks rather than events. If you need to react to review deletions, use the workflow’s reviewDeleted hook or subscribe to the requests.review.removed event from the Requests Module, which triggers the deletion workflow.
Review References
Reviews can be associated with two types of entities:- Products (
reference: "product") - Customer reviews of products they purchased - Sellers (
reference: "seller") - Customer reviews of their experience with sellers