Events

The event object and the allowed CRUD operations on the related resource endpoint

Events are automatically created for a resource when a specific action happens (i.e. orders.place). When a webhook is listening to that action's topic and the subscribed event occurs, Commerce Layer sends a POST request to the webhook's callback URL, and the associated event callback is created.

Events are automatically triggered at creation time, notifying all listening webhooks. If, for some reason, you want to force the firing of an existing event manually, you can patch it with the _trigger attribute set to true (you need to use integration API credentials) — the event will be immediately triggered, regardless of its uniqueness.

Events can be included when fetching the resources that support them to inspect each recorded action.

How-to

Check the related guide for more info about real-time webhooks and the related events.

This is an immutable API, meaning that create, and delete operations are not allowed on this endpoint. You can only fetch a list of events or a specific single one, which can also be updated in order to trigger it manually.

Last updated