Documentation
Feedback
Guides
API Reference

Guides
Master Datav2 Guides
Use v2 triggers to interact with orders

This documentation assumes that you use Master Data V2 and are familiar with JSON Schemas.

All Master Data V2 interactions occur through API. We strongly recommend you use Postman and familiarize with our API documentation.

The Master Data v2 orders entity has been deprecated for all VTEX accounts created after January 2023 and previously existing accounts that did not use it. We do not recommend this feature for creating orders integrations, due to the inconsistencies that may occur. The orders Feed and Hook is the preferred way to integrate orders. If your store already uses this data entity, migrate your integration to the orders Feed and Hook as soon as possible.

A trigger is nothing more than configuring a predetermined condition and taking an action (HTTP request or sending an email).

You can use dynamic expressions usind dot notation in place of variables. So fetching the order's email address would look something like this: {!order.clientProfiledata.email}

In this example we will be setting up a trigger that will be activated when the order status changes to invoiced. You'll be POSTing a JSON Schema with all the necessary information.

Please consult the OMS API documentation to see the list of supported statuses. Ex: order-completed.


_10
..."v-trigger": [
_10
{
_10
"name": "TestTrigger",
_10
"condition": "status=devolucao-completed",
_10
"active": true,
_10
"action": {...

In case of more complicated conditions, or statuses that are not directly supported by the OMS API you can use dot notation to consult a nested value.

You can create conditions based on any value of any field, including nested fields up to the second level.


_10
..."v-trigger": [
_10
{
_10
"name": "TestTrigger",
_10
"condition": "Body.ChildOne.ChildTwo=Foo",
_10
"active": true,
_10
"action": {...

Contributors
3
Photo of the contributor
Photo of the contributor
Photo of the contributor
+ 3 contributors
Was this helpful?
Yes
No
Suggest edits (Github)
Contributors
3
Photo of the contributor
Photo of the contributor
Photo of the contributor
+ 3 contributors
On this page