Orange Collar Media
Orange Collar Media
DOCS
OCMLABS/MODULE-WEBHOOK · SUPPORTED EVENTS

The ten curated events, and subscribing to any Magento event by name

MAGENTO 2.4.7 - 2.4.8 PHP 8.2 - 8.4 LUMA + HYVÄ COMPOSER

Webhooks are managed under System > OCM Labs > Webhooks. Each subscription pairs one event with one destination URL and payload template.

OCMLabs Webhooks admin grid

Curated events

Ten events cover the common integration points. Each exposes entity-specific template variables alongside the universal meta.* set, and each prefills the form with a working default template when selected.

Event (admin label)System eventPrimary variables exposed
Order Placedsales_order_place_afterorder (+ order.items, order.billing_address, order.shipping_address, order.payment)
Order Updatedsales_order_save_afterorder, plus computed order.status_changed (bool) and order.previous_status
Shipment Createdsales_order_shipment_save_aftershipment (+ shipment.tracks, shipment.items), order
Invoice Createdsales_order_invoice_save_afterinvoice, order
Credit Memo Createdsales_order_creditmemo_save_aftercreditmemo, order
Customer Registeredcustomer_register_successcustomer
Customer Updatedcustomer_save_after_data_objectcustomer, orig_customer (may be empty on create)
Product Savedcatalog_product_save_afterproduct
Product Deletedcatalog_product_delete_afterproduct (snapshotted at observe time, so delete events still carry full data)
Stock Level Changedcataloginventory_stock_item_save_afterstock_item, plus product.sku / product.id

Payloads use snapshot semantics: they reflect entity state at the moment the event fired, not at delivery time. That is deliberate - the consumer may run seconds later, and by then the entity could have changed or (for delete events) no longer exist.

Store view scoping

Each webhook can be limited to specific store views or left on all stores. An event firing in an out-of-scope store view simply does not trigger that webhook.

Custom events

The event select also offers a “Custom event…” option that reveals a free-text field, letting you subscribe a webhook to any Magento event by name - for example checkout_cart_product_add_after.

Custom events are gated behind Stores > Configuration > OCM Labs > Webhooks > Advanced > Enable Custom Events and handled by a dispatch plugin that is inert until that flag is on; even when enabled, its hot path is a single cached lookup per event dispatch, so the overhead of leaving it enabled is negligible.

Custom event payloads are built generically: every scalar and data object in the event’s data array is exposed under its original key, alongside the usual meta.* variables. The exact shape depends on the event, so use Send Test and the delivery log to see what a given event actually carries.