Skip to main content
POST
/
ecommerce.order.status.updated
Estado de pedido actualizado
curl --request POST \
  --url https://api.example.com/ecommerce.order.status.updated \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "type": "ecommerce.order.status.updated",
  "data": {
    "order": {
      "_id": "ord-123",
      "isScheduled": true,
      "isConfirmed": true,
      "websiteId": "<string>",
      "storeId": "<string>",
      "code": "123",
      "fullCode": "C#123",
      "userId": "<string>",
      "createdAt": "2020-01-01T00:00:00.000Z",
      "address": {
        "_id": "<string>",
        "placeId": "<string>",
        "address": "Av. Apoquindo 3000",
        "addressLine2": "Depto 1201",
        "addressSecondary": "<string>",
        "location": {
          "lat": -33.4489,
          "lng": -70.6693
        }
      },
      "menuId": "<string>",
      "deliverAt": "2020-01-01T00:00:00.000Z",
      "timeText": "<string>",
      "paymentType": "<string>",
      "paymentTypeLabel": "<string>",
      "paymentTypeIsIntegration": true,
      "tipAmount": 123,
      "amountToPay": 123,
      "deliveryFee": 123,
      "deliveryFeeWithoutDiscount": 123,
      "serviceFee": 123,
      "itemsPrice": 123,
      "totalPrice": 123,
      "baseItemsPrice": 123,
      "baseTotalPrice": 123,
      "itemsPriceBeforeDiscountsAfterProductDiscount": 123,
      "totalPriceBeforeDiscountsAfterProductDiscount": 123,
      "discountedAmountAfterProductDiscount": 123,
      "justoCoinsDiscount": 123,
      "websiteCoinsDiscount": 123,
      "totalDiscount": 123,
      "amountFinancedByWebsite": 123,
      "amountFinancedByJusto": 123,
      "expectedPreparationDuration": 123,
      "deliveryDuration": 123,
      "cashAmount": 123,
      "source": "<string>",
      "buyerName": "<string>",
      "phone": "<string>",
      "email": "<string>",
      "couponId": "<string>",
      "couponName": "<string>",
      "couponCode": "<string>",
      "couponExternalId": "<string>",
      "couponDiscount": 123,
      "couponPercentageOff": 123,
      "couponType": "<string>",
      "promotionDiscount": 123,
      "promotionIds": [
        "<string>"
      ],
      "flagColor": "<string>",
      "items": [
        {
          "_id": "<string>",
          "product": {
            "_id": "<string>",
            "name": "Hamburguesa",
            "externalId": "<string>",
            "metadata": {},
            "priceMetadata": {}
          },
          "unitPrice": 5990,
          "baseUnitPrice": 5990,
          "productPrice": 5990,
          "baseProductPrice": 5990,
          "amount": 2,
          "comment": "<string>",
          "description": "Bebida: Coca Zero - Comentario: \"Sin cebolla\"",
          "promotionId": "<string>",
          "promotionDiscount": 123,
          "promotionType": "<string>",
          "promotionLabel": "<string>",
          "modifiers": [
            {
              "modifierId": "<string>",
              "externalId": "<string>",
              "name": "Agregados",
              "shortName": "<string>",
              "metadata": {},
              "description": "<string>",
              "countById": {},
              "countByExternalId": {},
              "options": [
                {
                  "optionId": "<string>",
                  "name": "Queso",
                  "price": 1000,
                  "externalId": "<string>",
                  "metadata": {},
                  "priceMetadata": {}
                }
              ]
            }
          ]
        }
      ],
      "transaction": {
        "_id": "<string>",
        "totalPrice": 123,
        "paymentType": "<string>",
        "cardType": "<string>",
        "cardLast4": "<string>",
        "status": "<string>"
      },
      "deliveries": [
        {
          "_id": "<string>",
          "price": 2500,
          "placeName": "<string>",
          "isCash": true,
          "instructions": "<string>",
          "driverPassword": "5366",
          "fromLocation": {
            "lat": -33.4489,
            "lng": -70.6693
          },
          "toLocation": {
            "lat": -33.4489,
            "lng": -70.6693
          },
          "trackingURL": "<string>",
          "orderId": "<string>",
          "activatesAt": "2020-01-01T00:00:00.000Z",
          "createdAt": "2020-01-01T00:00:00.000Z",
          "forDate": "2020-01-01T00:00:00.000Z",
          "nearStoreAt": "2020-01-01T00:00:00.000Z",
          "pickupAt": "2020-01-01T00:00:00.000Z",
          "nearClientAt": "2020-01-01T00:00:00.000Z",
          "completedAt": "2020-01-01T00:00:00.000Z",
          "canceledAt": "2020-01-01T00:00:00.000Z",
          "deliveryExpectedAt": "2020-01-01T00:00:00.000Z",
          "estimatedArrivalAtStoreAt": "2020-01-01T00:00:00.000Z",
          "driverReceivedAt": "2020-01-01T00:00:00.000Z",
          "driverInformation": {},
          "deliveryInformation": {},
          "externalId": "<string>",
          "specialCode": "<string>"
        }
      ],
      "orderParams": {},
      "hasManagedDelivery": true,
      "gift": {},
      "billing": {},
      "cancellationInfo": {},
      "deliveryZoneName": "<string>"
    },
    "delivery": {
      "_id": "<string>",
      "price": 2500,
      "placeName": "<string>",
      "isCash": true,
      "instructions": "<string>",
      "driverPassword": "5366",
      "fromLocation": {
        "lat": -33.4489,
        "lng": -70.6693
      },
      "toLocation": {
        "lat": -33.4489,
        "lng": -70.6693
      },
      "trackingURL": "<string>",
      "orderId": "<string>",
      "activatesAt": "2020-01-01T00:00:00.000Z",
      "createdAt": "2020-01-01T00:00:00.000Z",
      "forDate": "2020-01-01T00:00:00.000Z",
      "nearStoreAt": "2020-01-01T00:00:00.000Z",
      "pickupAt": "2020-01-01T00:00:00.000Z",
      "nearClientAt": "2020-01-01T00:00:00.000Z",
      "completedAt": "2020-01-01T00:00:00.000Z",
      "canceledAt": "2020-01-01T00:00:00.000Z",
      "deliveryExpectedAt": "2020-01-01T00:00:00.000Z",
      "estimatedArrivalAtStoreAt": "2020-01-01T00:00:00.000Z",
      "driverReceivedAt": "2020-01-01T00:00:00.000Z",
      "driverInformation": {},
      "deliveryInformation": {},
      "externalId": "<string>",
      "specialCode": "<string>"
    }
  },
  "websiteId": "<string>",
  "storeId": "<string>",
  "date": "2020-01-01T00:00:00.000Z",
  "eventId": "<string>"
}
'
import requests

url = "https://api.example.com/ecommerce.order.status.updated"

payload = {
"type": "ecommerce.order.status.updated",
"data": {
"order": {
"_id": "ord-123",
"isScheduled": True,
"isConfirmed": True,
"websiteId": "<string>",
"storeId": "<string>",
"code": "123",
"fullCode": "C#123",
"userId": "<string>",
"createdAt": "2020-01-01T00:00:00.000Z",
"address": {
"_id": "<string>",
"placeId": "<string>",
"address": "Av. Apoquindo 3000",
"addressLine2": "Depto 1201",
"addressSecondary": "<string>",
"location": {
"lat": -33.4489,
"lng": -70.6693
}
},
"menuId": "<string>",
"deliverAt": "2020-01-01T00:00:00.000Z",
"timeText": "<string>",
"paymentType": "<string>",
"paymentTypeLabel": "<string>",
"paymentTypeIsIntegration": True,
"tipAmount": 123,
"amountToPay": 123,
"deliveryFee": 123,
"deliveryFeeWithoutDiscount": 123,
"serviceFee": 123,
"itemsPrice": 123,
"totalPrice": 123,
"baseItemsPrice": 123,
"baseTotalPrice": 123,
"itemsPriceBeforeDiscountsAfterProductDiscount": 123,
"totalPriceBeforeDiscountsAfterProductDiscount": 123,
"discountedAmountAfterProductDiscount": 123,
"justoCoinsDiscount": 123,
"websiteCoinsDiscount": 123,
"totalDiscount": 123,
"amountFinancedByWebsite": 123,
"amountFinancedByJusto": 123,
"expectedPreparationDuration": 123,
"deliveryDuration": 123,
"cashAmount": 123,
"source": "<string>",
"buyerName": "<string>",
"phone": "<string>",
"email": "<string>",
"couponId": "<string>",
"couponName": "<string>",
"couponCode": "<string>",
"couponExternalId": "<string>",
"couponDiscount": 123,
"couponPercentageOff": 123,
"couponType": "<string>",
"promotionDiscount": 123,
"promotionIds": ["<string>"],
"flagColor": "<string>",
"items": [
{
"_id": "<string>",
"product": {
"_id": "<string>",
"name": "Hamburguesa",
"externalId": "<string>",
"metadata": {},
"priceMetadata": {}
},
"unitPrice": 5990,
"baseUnitPrice": 5990,
"productPrice": 5990,
"baseProductPrice": 5990,
"amount": 2,
"comment": "<string>",
"description": "Bebida: Coca Zero - Comentario: \"Sin cebolla\"",
"promotionId": "<string>",
"promotionDiscount": 123,
"promotionType": "<string>",
"promotionLabel": "<string>",
"modifiers": [
{
"modifierId": "<string>",
"externalId": "<string>",
"name": "Agregados",
"shortName": "<string>",
"metadata": {},
"description": "<string>",
"countById": {},
"countByExternalId": {},
"options": [
{
"optionId": "<string>",
"name": "Queso",
"price": 1000,
"externalId": "<string>",
"metadata": {},
"priceMetadata": {}
}
]
}
]
}
],
"transaction": {
"_id": "<string>",
"totalPrice": 123,
"paymentType": "<string>",
"cardType": "<string>",
"cardLast4": "<string>",
"status": "<string>"
},
"deliveries": [
{
"_id": "<string>",
"price": 2500,
"placeName": "<string>",
"isCash": True,
"instructions": "<string>",
"driverPassword": "5366",
"fromLocation": {
"lat": -33.4489,
"lng": -70.6693
},
"toLocation": {
"lat": -33.4489,
"lng": -70.6693
},
"trackingURL": "<string>",
"orderId": "<string>",
"activatesAt": "2020-01-01T00:00:00.000Z",
"createdAt": "2020-01-01T00:00:00.000Z",
"forDate": "2020-01-01T00:00:00.000Z",
"nearStoreAt": "2020-01-01T00:00:00.000Z",
"pickupAt": "2020-01-01T00:00:00.000Z",
"nearClientAt": "2020-01-01T00:00:00.000Z",
"completedAt": "2020-01-01T00:00:00.000Z",
"canceledAt": "2020-01-01T00:00:00.000Z",
"deliveryExpectedAt": "2020-01-01T00:00:00.000Z",
"estimatedArrivalAtStoreAt": "2020-01-01T00:00:00.000Z",
"driverReceivedAt": "2020-01-01T00:00:00.000Z",
"driverInformation": {},
"deliveryInformation": {},
"externalId": "<string>",
"specialCode": "<string>"
}
],
"orderParams": {},
"hasManagedDelivery": True,
"gift": {},
"billing": {},
"cancellationInfo": {},
"deliveryZoneName": "<string>"
},
"delivery": {
"_id": "<string>",
"price": 2500,
"placeName": "<string>",
"isCash": True,
"instructions": "<string>",
"driverPassword": "5366",
"fromLocation": {
"lat": -33.4489,
"lng": -70.6693
},
"toLocation": {
"lat": -33.4489,
"lng": -70.6693
},
"trackingURL": "<string>",
"orderId": "<string>",
"activatesAt": "2020-01-01T00:00:00.000Z",
"createdAt": "2020-01-01T00:00:00.000Z",
"forDate": "2020-01-01T00:00:00.000Z",
"nearStoreAt": "2020-01-01T00:00:00.000Z",
"pickupAt": "2020-01-01T00:00:00.000Z",
"nearClientAt": "2020-01-01T00:00:00.000Z",
"completedAt": "2020-01-01T00:00:00.000Z",
"canceledAt": "2020-01-01T00:00:00.000Z",
"deliveryExpectedAt": "2020-01-01T00:00:00.000Z",
"estimatedArrivalAtStoreAt": "2020-01-01T00:00:00.000Z",
"driverReceivedAt": "2020-01-01T00:00:00.000Z",
"driverInformation": {},
"deliveryInformation": {},
"externalId": "<string>",
"specialCode": "<string>"
}
},
"websiteId": "<string>",
"storeId": "<string>",
"date": "2020-01-01T00:00:00.000Z",
"eventId": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
type: 'ecommerce.order.status.updated',
data: {
order: {
_id: 'ord-123',
isScheduled: true,
isConfirmed: true,
websiteId: '<string>',
storeId: '<string>',
code: '123',
fullCode: 'C#123',
userId: '<string>',
createdAt: '2020-01-01T00:00:00.000Z',
address: {
_id: '<string>',
placeId: '<string>',
address: 'Av. Apoquindo 3000',
addressLine2: 'Depto 1201',
addressSecondary: '<string>',
location: {lat: -33.4489, lng: -70.6693}
},
menuId: '<string>',
deliverAt: '2020-01-01T00:00:00.000Z',
timeText: '<string>',
paymentType: '<string>',
paymentTypeLabel: '<string>',
paymentTypeIsIntegration: true,
tipAmount: 123,
amountToPay: 123,
deliveryFee: 123,
deliveryFeeWithoutDiscount: 123,
serviceFee: 123,
itemsPrice: 123,
totalPrice: 123,
baseItemsPrice: 123,
baseTotalPrice: 123,
itemsPriceBeforeDiscountsAfterProductDiscount: 123,
totalPriceBeforeDiscountsAfterProductDiscount: 123,
discountedAmountAfterProductDiscount: 123,
justoCoinsDiscount: 123,
websiteCoinsDiscount: 123,
totalDiscount: 123,
amountFinancedByWebsite: 123,
amountFinancedByJusto: 123,
expectedPreparationDuration: 123,
deliveryDuration: 123,
cashAmount: 123,
source: '<string>',
buyerName: '<string>',
phone: '<string>',
email: '<string>',
couponId: '<string>',
couponName: '<string>',
couponCode: '<string>',
couponExternalId: '<string>',
couponDiscount: 123,
couponPercentageOff: 123,
couponType: '<string>',
promotionDiscount: 123,
promotionIds: ['<string>'],
flagColor: '<string>',
items: [
{
_id: '<string>',
product: {
_id: '<string>',
name: 'Hamburguesa',
externalId: '<string>',
metadata: {},
priceMetadata: {}
},
unitPrice: 5990,
baseUnitPrice: 5990,
productPrice: 5990,
baseProductPrice: 5990,
amount: 2,
comment: '<string>',
description: 'Bebida: Coca Zero - Comentario: "Sin cebolla"',
promotionId: '<string>',
promotionDiscount: 123,
promotionType: '<string>',
promotionLabel: '<string>',
modifiers: [
{
modifierId: '<string>',
externalId: '<string>',
name: 'Agregados',
shortName: '<string>',
metadata: {},
description: '<string>',
countById: {},
countByExternalId: {},
options: [
{
optionId: '<string>',
name: 'Queso',
price: 1000,
externalId: '<string>',
metadata: {},
priceMetadata: {}
}
]
}
]
}
],
transaction: {
_id: '<string>',
totalPrice: 123,
paymentType: '<string>',
cardType: '<string>',
cardLast4: '<string>',
status: '<string>'
},
deliveries: [
{
_id: '<string>',
price: 2500,
placeName: '<string>',
isCash: true,
instructions: '<string>',
driverPassword: '5366',
fromLocation: {lat: -33.4489, lng: -70.6693},
toLocation: {lat: -33.4489, lng: -70.6693},
trackingURL: '<string>',
orderId: '<string>',
activatesAt: '2020-01-01T00:00:00.000Z',
createdAt: '2020-01-01T00:00:00.000Z',
forDate: '2020-01-01T00:00:00.000Z',
nearStoreAt: '2020-01-01T00:00:00.000Z',
pickupAt: '2020-01-01T00:00:00.000Z',
nearClientAt: '2020-01-01T00:00:00.000Z',
completedAt: '2020-01-01T00:00:00.000Z',
canceledAt: '2020-01-01T00:00:00.000Z',
deliveryExpectedAt: '2020-01-01T00:00:00.000Z',
estimatedArrivalAtStoreAt: '2020-01-01T00:00:00.000Z',
driverReceivedAt: '2020-01-01T00:00:00.000Z',
driverInformation: {},
deliveryInformation: {},
externalId: '<string>',
specialCode: '<string>'
}
],
orderParams: {},
hasManagedDelivery: true,
gift: {},
billing: {},
cancellationInfo: {},
deliveryZoneName: '<string>'
},
delivery: {
_id: '<string>',
price: 2500,
placeName: '<string>',
isCash: true,
instructions: '<string>',
driverPassword: '5366',
fromLocation: {lat: -33.4489, lng: -70.6693},
toLocation: {lat: -33.4489, lng: -70.6693},
trackingURL: '<string>',
orderId: '<string>',
activatesAt: '2020-01-01T00:00:00.000Z',
createdAt: '2020-01-01T00:00:00.000Z',
forDate: '2020-01-01T00:00:00.000Z',
nearStoreAt: '2020-01-01T00:00:00.000Z',
pickupAt: '2020-01-01T00:00:00.000Z',
nearClientAt: '2020-01-01T00:00:00.000Z',
completedAt: '2020-01-01T00:00:00.000Z',
canceledAt: '2020-01-01T00:00:00.000Z',
deliveryExpectedAt: '2020-01-01T00:00:00.000Z',
estimatedArrivalAtStoreAt: '2020-01-01T00:00:00.000Z',
driverReceivedAt: '2020-01-01T00:00:00.000Z',
driverInformation: {},
deliveryInformation: {},
externalId: '<string>',
specialCode: '<string>'
}
},
websiteId: '<string>',
storeId: '<string>',
date: '2020-01-01T00:00:00.000Z',
eventId: '<string>'
})
};

fetch('https://api.example.com/ecommerce.order.status.updated', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/ecommerce.order.status.updated",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'type' => 'ecommerce.order.status.updated',
'data' => [
'order' => [
'_id' => 'ord-123',
'isScheduled' => true,
'isConfirmed' => true,
'websiteId' => '<string>',
'storeId' => '<string>',
'code' => '123',
'fullCode' => 'C#123',
'userId' => '<string>',
'createdAt' => '2020-01-01T00:00:00.000Z',
'address' => [
'_id' => '<string>',
'placeId' => '<string>',
'address' => 'Av. Apoquindo 3000',
'addressLine2' => 'Depto 1201',
'addressSecondary' => '<string>',
'location' => [
'lat' => -33.4489,
'lng' => -70.6693
]
],
'menuId' => '<string>',
'deliverAt' => '2020-01-01T00:00:00.000Z',
'timeText' => '<string>',
'paymentType' => '<string>',
'paymentTypeLabel' => '<string>',
'paymentTypeIsIntegration' => true,
'tipAmount' => 123,
'amountToPay' => 123,
'deliveryFee' => 123,
'deliveryFeeWithoutDiscount' => 123,
'serviceFee' => 123,
'itemsPrice' => 123,
'totalPrice' => 123,
'baseItemsPrice' => 123,
'baseTotalPrice' => 123,
'itemsPriceBeforeDiscountsAfterProductDiscount' => 123,
'totalPriceBeforeDiscountsAfterProductDiscount' => 123,
'discountedAmountAfterProductDiscount' => 123,
'justoCoinsDiscount' => 123,
'websiteCoinsDiscount' => 123,
'totalDiscount' => 123,
'amountFinancedByWebsite' => 123,
'amountFinancedByJusto' => 123,
'expectedPreparationDuration' => 123,
'deliveryDuration' => 123,
'cashAmount' => 123,
'source' => '<string>',
'buyerName' => '<string>',
'phone' => '<string>',
'email' => '<string>',
'couponId' => '<string>',
'couponName' => '<string>',
'couponCode' => '<string>',
'couponExternalId' => '<string>',
'couponDiscount' => 123,
'couponPercentageOff' => 123,
'couponType' => '<string>',
'promotionDiscount' => 123,
'promotionIds' => [
'<string>'
],
'flagColor' => '<string>',
'items' => [
[
'_id' => '<string>',
'product' => [
'_id' => '<string>',
'name' => 'Hamburguesa',
'externalId' => '<string>',
'metadata' => [

],
'priceMetadata' => [

]
],
'unitPrice' => 5990,
'baseUnitPrice' => 5990,
'productPrice' => 5990,
'baseProductPrice' => 5990,
'amount' => 2,
'comment' => '<string>',
'description' => 'Bebida: Coca Zero - Comentario: "Sin cebolla"',
'promotionId' => '<string>',
'promotionDiscount' => 123,
'promotionType' => '<string>',
'promotionLabel' => '<string>',
'modifiers' => [
[
'modifierId' => '<string>',
'externalId' => '<string>',
'name' => 'Agregados',
'shortName' => '<string>',
'metadata' => [

],
'description' => '<string>',
'countById' => [

],
'countByExternalId' => [

],
'options' => [
[
'optionId' => '<string>',
'name' => 'Queso',
'price' => 1000,
'externalId' => '<string>',
'metadata' => [

],
'priceMetadata' => [

]
]
]
]
]
]
],
'transaction' => [
'_id' => '<string>',
'totalPrice' => 123,
'paymentType' => '<string>',
'cardType' => '<string>',
'cardLast4' => '<string>',
'status' => '<string>'
],
'deliveries' => [
[
'_id' => '<string>',
'price' => 2500,
'placeName' => '<string>',
'isCash' => true,
'instructions' => '<string>',
'driverPassword' => '5366',
'fromLocation' => [
'lat' => -33.4489,
'lng' => -70.6693
],
'toLocation' => [
'lat' => -33.4489,
'lng' => -70.6693
],
'trackingURL' => '<string>',
'orderId' => '<string>',
'activatesAt' => '2020-01-01T00:00:00.000Z',
'createdAt' => '2020-01-01T00:00:00.000Z',
'forDate' => '2020-01-01T00:00:00.000Z',
'nearStoreAt' => '2020-01-01T00:00:00.000Z',
'pickupAt' => '2020-01-01T00:00:00.000Z',
'nearClientAt' => '2020-01-01T00:00:00.000Z',
'completedAt' => '2020-01-01T00:00:00.000Z',
'canceledAt' => '2020-01-01T00:00:00.000Z',
'deliveryExpectedAt' => '2020-01-01T00:00:00.000Z',
'estimatedArrivalAtStoreAt' => '2020-01-01T00:00:00.000Z',
'driverReceivedAt' => '2020-01-01T00:00:00.000Z',
'driverInformation' => [

],
'deliveryInformation' => [

],
'externalId' => '<string>',
'specialCode' => '<string>'
]
],
'orderParams' => [

],
'hasManagedDelivery' => true,
'gift' => [

],
'billing' => [

],
'cancellationInfo' => [

],
'deliveryZoneName' => '<string>'
],
'delivery' => [
'_id' => '<string>',
'price' => 2500,
'placeName' => '<string>',
'isCash' => true,
'instructions' => '<string>',
'driverPassword' => '5366',
'fromLocation' => [
'lat' => -33.4489,
'lng' => -70.6693
],
'toLocation' => [
'lat' => -33.4489,
'lng' => -70.6693
],
'trackingURL' => '<string>',
'orderId' => '<string>',
'activatesAt' => '2020-01-01T00:00:00.000Z',
'createdAt' => '2020-01-01T00:00:00.000Z',
'forDate' => '2020-01-01T00:00:00.000Z',
'nearStoreAt' => '2020-01-01T00:00:00.000Z',
'pickupAt' => '2020-01-01T00:00:00.000Z',
'nearClientAt' => '2020-01-01T00:00:00.000Z',
'completedAt' => '2020-01-01T00:00:00.000Z',
'canceledAt' => '2020-01-01T00:00:00.000Z',
'deliveryExpectedAt' => '2020-01-01T00:00:00.000Z',
'estimatedArrivalAtStoreAt' => '2020-01-01T00:00:00.000Z',
'driverReceivedAt' => '2020-01-01T00:00:00.000Z',
'driverInformation' => [

],
'deliveryInformation' => [

],
'externalId' => '<string>',
'specialCode' => '<string>'
]
],
'websiteId' => '<string>',
'storeId' => '<string>',
'date' => '2020-01-01T00:00:00.000Z',
'eventId' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.example.com/ecommerce.order.status.updated"

payload := strings.NewReader("{\n \"type\": \"ecommerce.order.status.updated\",\n \"data\": {\n \"order\": {\n \"_id\": \"ord-123\",\n \"isScheduled\": true,\n \"isConfirmed\": true,\n \"websiteId\": \"<string>\",\n \"storeId\": \"<string>\",\n \"code\": \"123\",\n \"fullCode\": \"C#123\",\n \"userId\": \"<string>\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"address\": {\n \"_id\": \"<string>\",\n \"placeId\": \"<string>\",\n \"address\": \"Av. Apoquindo 3000\",\n \"addressLine2\": \"Depto 1201\",\n \"addressSecondary\": \"<string>\",\n \"location\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n }\n },\n \"menuId\": \"<string>\",\n \"deliverAt\": \"2020-01-01T00:00:00.000Z\",\n \"timeText\": \"<string>\",\n \"paymentType\": \"<string>\",\n \"paymentTypeLabel\": \"<string>\",\n \"paymentTypeIsIntegration\": true,\n \"tipAmount\": 123,\n \"amountToPay\": 123,\n \"deliveryFee\": 123,\n \"deliveryFeeWithoutDiscount\": 123,\n \"serviceFee\": 123,\n \"itemsPrice\": 123,\n \"totalPrice\": 123,\n \"baseItemsPrice\": 123,\n \"baseTotalPrice\": 123,\n \"itemsPriceBeforeDiscountsAfterProductDiscount\": 123,\n \"totalPriceBeforeDiscountsAfterProductDiscount\": 123,\n \"discountedAmountAfterProductDiscount\": 123,\n \"justoCoinsDiscount\": 123,\n \"websiteCoinsDiscount\": 123,\n \"totalDiscount\": 123,\n \"amountFinancedByWebsite\": 123,\n \"amountFinancedByJusto\": 123,\n \"expectedPreparationDuration\": 123,\n \"deliveryDuration\": 123,\n \"cashAmount\": 123,\n \"source\": \"<string>\",\n \"buyerName\": \"<string>\",\n \"phone\": \"<string>\",\n \"email\": \"<string>\",\n \"couponId\": \"<string>\",\n \"couponName\": \"<string>\",\n \"couponCode\": \"<string>\",\n \"couponExternalId\": \"<string>\",\n \"couponDiscount\": 123,\n \"couponPercentageOff\": 123,\n \"couponType\": \"<string>\",\n \"promotionDiscount\": 123,\n \"promotionIds\": [\n \"<string>\"\n ],\n \"flagColor\": \"<string>\",\n \"items\": [\n {\n \"_id\": \"<string>\",\n \"product\": {\n \"_id\": \"<string>\",\n \"name\": \"Hamburguesa\",\n \"externalId\": \"<string>\",\n \"metadata\": {},\n \"priceMetadata\": {}\n },\n \"unitPrice\": 5990,\n \"baseUnitPrice\": 5990,\n \"productPrice\": 5990,\n \"baseProductPrice\": 5990,\n \"amount\": 2,\n \"comment\": \"<string>\",\n \"description\": \"Bebida: Coca Zero - Comentario: \\\"Sin cebolla\\\"\",\n \"promotionId\": \"<string>\",\n \"promotionDiscount\": 123,\n \"promotionType\": \"<string>\",\n \"promotionLabel\": \"<string>\",\n \"modifiers\": [\n {\n \"modifierId\": \"<string>\",\n \"externalId\": \"<string>\",\n \"name\": \"Agregados\",\n \"shortName\": \"<string>\",\n \"metadata\": {},\n \"description\": \"<string>\",\n \"countById\": {},\n \"countByExternalId\": {},\n \"options\": [\n {\n \"optionId\": \"<string>\",\n \"name\": \"Queso\",\n \"price\": 1000,\n \"externalId\": \"<string>\",\n \"metadata\": {},\n \"priceMetadata\": {}\n }\n ]\n }\n ]\n }\n ],\n \"transaction\": {\n \"_id\": \"<string>\",\n \"totalPrice\": 123,\n \"paymentType\": \"<string>\",\n \"cardType\": \"<string>\",\n \"cardLast4\": \"<string>\",\n \"status\": \"<string>\"\n },\n \"deliveries\": [\n {\n \"_id\": \"<string>\",\n \"price\": 2500,\n \"placeName\": \"<string>\",\n \"isCash\": true,\n \"instructions\": \"<string>\",\n \"driverPassword\": \"5366\",\n \"fromLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"toLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"trackingURL\": \"<string>\",\n \"orderId\": \"<string>\",\n \"activatesAt\": \"2020-01-01T00:00:00.000Z\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"forDate\": \"2020-01-01T00:00:00.000Z\",\n \"nearStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"pickupAt\": \"2020-01-01T00:00:00.000Z\",\n \"nearClientAt\": \"2020-01-01T00:00:00.000Z\",\n \"completedAt\": \"2020-01-01T00:00:00.000Z\",\n \"canceledAt\": \"2020-01-01T00:00:00.000Z\",\n \"deliveryExpectedAt\": \"2020-01-01T00:00:00.000Z\",\n \"estimatedArrivalAtStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverReceivedAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverInformation\": {},\n \"deliveryInformation\": {},\n \"externalId\": \"<string>\",\n \"specialCode\": \"<string>\"\n }\n ],\n \"orderParams\": {},\n \"hasManagedDelivery\": true,\n \"gift\": {},\n \"billing\": {},\n \"cancellationInfo\": {},\n \"deliveryZoneName\": \"<string>\"\n },\n \"delivery\": {\n \"_id\": \"<string>\",\n \"price\": 2500,\n \"placeName\": \"<string>\",\n \"isCash\": true,\n \"instructions\": \"<string>\",\n \"driverPassword\": \"5366\",\n \"fromLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"toLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"trackingURL\": \"<string>\",\n \"orderId\": \"<string>\",\n \"activatesAt\": \"2020-01-01T00:00:00.000Z\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"forDate\": \"2020-01-01T00:00:00.000Z\",\n \"nearStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"pickupAt\": \"2020-01-01T00:00:00.000Z\",\n \"nearClientAt\": \"2020-01-01T00:00:00.000Z\",\n \"completedAt\": \"2020-01-01T00:00:00.000Z\",\n \"canceledAt\": \"2020-01-01T00:00:00.000Z\",\n \"deliveryExpectedAt\": \"2020-01-01T00:00:00.000Z\",\n \"estimatedArrivalAtStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverReceivedAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverInformation\": {},\n \"deliveryInformation\": {},\n \"externalId\": \"<string>\",\n \"specialCode\": \"<string>\"\n }\n },\n \"websiteId\": \"<string>\",\n \"storeId\": \"<string>\",\n \"date\": \"2020-01-01T00:00:00.000Z\",\n \"eventId\": \"<string>\"\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.example.com/ecommerce.order.status.updated")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"ecommerce.order.status.updated\",\n \"data\": {\n \"order\": {\n \"_id\": \"ord-123\",\n \"isScheduled\": true,\n \"isConfirmed\": true,\n \"websiteId\": \"<string>\",\n \"storeId\": \"<string>\",\n \"code\": \"123\",\n \"fullCode\": \"C#123\",\n \"userId\": \"<string>\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"address\": {\n \"_id\": \"<string>\",\n \"placeId\": \"<string>\",\n \"address\": \"Av. Apoquindo 3000\",\n \"addressLine2\": \"Depto 1201\",\n \"addressSecondary\": \"<string>\",\n \"location\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n }\n },\n \"menuId\": \"<string>\",\n \"deliverAt\": \"2020-01-01T00:00:00.000Z\",\n \"timeText\": \"<string>\",\n \"paymentType\": \"<string>\",\n \"paymentTypeLabel\": \"<string>\",\n \"paymentTypeIsIntegration\": true,\n \"tipAmount\": 123,\n \"amountToPay\": 123,\n \"deliveryFee\": 123,\n \"deliveryFeeWithoutDiscount\": 123,\n \"serviceFee\": 123,\n \"itemsPrice\": 123,\n \"totalPrice\": 123,\n \"baseItemsPrice\": 123,\n \"baseTotalPrice\": 123,\n \"itemsPriceBeforeDiscountsAfterProductDiscount\": 123,\n \"totalPriceBeforeDiscountsAfterProductDiscount\": 123,\n \"discountedAmountAfterProductDiscount\": 123,\n \"justoCoinsDiscount\": 123,\n \"websiteCoinsDiscount\": 123,\n \"totalDiscount\": 123,\n \"amountFinancedByWebsite\": 123,\n \"amountFinancedByJusto\": 123,\n \"expectedPreparationDuration\": 123,\n \"deliveryDuration\": 123,\n \"cashAmount\": 123,\n \"source\": \"<string>\",\n \"buyerName\": \"<string>\",\n \"phone\": \"<string>\",\n \"email\": \"<string>\",\n \"couponId\": \"<string>\",\n \"couponName\": \"<string>\",\n \"couponCode\": \"<string>\",\n \"couponExternalId\": \"<string>\",\n \"couponDiscount\": 123,\n \"couponPercentageOff\": 123,\n \"couponType\": \"<string>\",\n \"promotionDiscount\": 123,\n \"promotionIds\": [\n \"<string>\"\n ],\n \"flagColor\": \"<string>\",\n \"items\": [\n {\n \"_id\": \"<string>\",\n \"product\": {\n \"_id\": \"<string>\",\n \"name\": \"Hamburguesa\",\n \"externalId\": \"<string>\",\n \"metadata\": {},\n \"priceMetadata\": {}\n },\n \"unitPrice\": 5990,\n \"baseUnitPrice\": 5990,\n \"productPrice\": 5990,\n \"baseProductPrice\": 5990,\n \"amount\": 2,\n \"comment\": \"<string>\",\n \"description\": \"Bebida: Coca Zero - Comentario: \\\"Sin cebolla\\\"\",\n \"promotionId\": \"<string>\",\n \"promotionDiscount\": 123,\n \"promotionType\": \"<string>\",\n \"promotionLabel\": \"<string>\",\n \"modifiers\": [\n {\n \"modifierId\": \"<string>\",\n \"externalId\": \"<string>\",\n \"name\": \"Agregados\",\n \"shortName\": \"<string>\",\n \"metadata\": {},\n \"description\": \"<string>\",\n \"countById\": {},\n \"countByExternalId\": {},\n \"options\": [\n {\n \"optionId\": \"<string>\",\n \"name\": \"Queso\",\n \"price\": 1000,\n \"externalId\": \"<string>\",\n \"metadata\": {},\n \"priceMetadata\": {}\n }\n ]\n }\n ]\n }\n ],\n \"transaction\": {\n \"_id\": \"<string>\",\n \"totalPrice\": 123,\n \"paymentType\": \"<string>\",\n \"cardType\": \"<string>\",\n \"cardLast4\": \"<string>\",\n \"status\": \"<string>\"\n },\n \"deliveries\": [\n {\n \"_id\": \"<string>\",\n \"price\": 2500,\n \"placeName\": \"<string>\",\n \"isCash\": true,\n \"instructions\": \"<string>\",\n \"driverPassword\": \"5366\",\n \"fromLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"toLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"trackingURL\": \"<string>\",\n \"orderId\": \"<string>\",\n \"activatesAt\": \"2020-01-01T00:00:00.000Z\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"forDate\": \"2020-01-01T00:00:00.000Z\",\n \"nearStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"pickupAt\": \"2020-01-01T00:00:00.000Z\",\n \"nearClientAt\": \"2020-01-01T00:00:00.000Z\",\n \"completedAt\": \"2020-01-01T00:00:00.000Z\",\n \"canceledAt\": \"2020-01-01T00:00:00.000Z\",\n \"deliveryExpectedAt\": \"2020-01-01T00:00:00.000Z\",\n \"estimatedArrivalAtStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverReceivedAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverInformation\": {},\n \"deliveryInformation\": {},\n \"externalId\": \"<string>\",\n \"specialCode\": \"<string>\"\n }\n ],\n \"orderParams\": {},\n \"hasManagedDelivery\": true,\n \"gift\": {},\n \"billing\": {},\n \"cancellationInfo\": {},\n \"deliveryZoneName\": \"<string>\"\n },\n \"delivery\": {\n \"_id\": \"<string>\",\n \"price\": 2500,\n \"placeName\": \"<string>\",\n \"isCash\": true,\n \"instructions\": \"<string>\",\n \"driverPassword\": \"5366\",\n \"fromLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"toLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"trackingURL\": \"<string>\",\n \"orderId\": \"<string>\",\n \"activatesAt\": \"2020-01-01T00:00:00.000Z\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"forDate\": \"2020-01-01T00:00:00.000Z\",\n \"nearStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"pickupAt\": \"2020-01-01T00:00:00.000Z\",\n \"nearClientAt\": \"2020-01-01T00:00:00.000Z\",\n \"completedAt\": \"2020-01-01T00:00:00.000Z\",\n \"canceledAt\": \"2020-01-01T00:00:00.000Z\",\n \"deliveryExpectedAt\": \"2020-01-01T00:00:00.000Z\",\n \"estimatedArrivalAtStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverReceivedAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverInformation\": {},\n \"deliveryInformation\": {},\n \"externalId\": \"<string>\",\n \"specialCode\": \"<string>\"\n }\n },\n \"websiteId\": \"<string>\",\n \"storeId\": \"<string>\",\n \"date\": \"2020-01-01T00:00:00.000Z\",\n \"eventId\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.example.com/ecommerce.order.status.updated")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"type\": \"ecommerce.order.status.updated\",\n \"data\": {\n \"order\": {\n \"_id\": \"ord-123\",\n \"isScheduled\": true,\n \"isConfirmed\": true,\n \"websiteId\": \"<string>\",\n \"storeId\": \"<string>\",\n \"code\": \"123\",\n \"fullCode\": \"C#123\",\n \"userId\": \"<string>\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"address\": {\n \"_id\": \"<string>\",\n \"placeId\": \"<string>\",\n \"address\": \"Av. Apoquindo 3000\",\n \"addressLine2\": \"Depto 1201\",\n \"addressSecondary\": \"<string>\",\n \"location\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n }\n },\n \"menuId\": \"<string>\",\n \"deliverAt\": \"2020-01-01T00:00:00.000Z\",\n \"timeText\": \"<string>\",\n \"paymentType\": \"<string>\",\n \"paymentTypeLabel\": \"<string>\",\n \"paymentTypeIsIntegration\": true,\n \"tipAmount\": 123,\n \"amountToPay\": 123,\n \"deliveryFee\": 123,\n \"deliveryFeeWithoutDiscount\": 123,\n \"serviceFee\": 123,\n \"itemsPrice\": 123,\n \"totalPrice\": 123,\n \"baseItemsPrice\": 123,\n \"baseTotalPrice\": 123,\n \"itemsPriceBeforeDiscountsAfterProductDiscount\": 123,\n \"totalPriceBeforeDiscountsAfterProductDiscount\": 123,\n \"discountedAmountAfterProductDiscount\": 123,\n \"justoCoinsDiscount\": 123,\n \"websiteCoinsDiscount\": 123,\n \"totalDiscount\": 123,\n \"amountFinancedByWebsite\": 123,\n \"amountFinancedByJusto\": 123,\n \"expectedPreparationDuration\": 123,\n \"deliveryDuration\": 123,\n \"cashAmount\": 123,\n \"source\": \"<string>\",\n \"buyerName\": \"<string>\",\n \"phone\": \"<string>\",\n \"email\": \"<string>\",\n \"couponId\": \"<string>\",\n \"couponName\": \"<string>\",\n \"couponCode\": \"<string>\",\n \"couponExternalId\": \"<string>\",\n \"couponDiscount\": 123,\n \"couponPercentageOff\": 123,\n \"couponType\": \"<string>\",\n \"promotionDiscount\": 123,\n \"promotionIds\": [\n \"<string>\"\n ],\n \"flagColor\": \"<string>\",\n \"items\": [\n {\n \"_id\": \"<string>\",\n \"product\": {\n \"_id\": \"<string>\",\n \"name\": \"Hamburguesa\",\n \"externalId\": \"<string>\",\n \"metadata\": {},\n \"priceMetadata\": {}\n },\n \"unitPrice\": 5990,\n \"baseUnitPrice\": 5990,\n \"productPrice\": 5990,\n \"baseProductPrice\": 5990,\n \"amount\": 2,\n \"comment\": \"<string>\",\n \"description\": \"Bebida: Coca Zero - Comentario: \\\"Sin cebolla\\\"\",\n \"promotionId\": \"<string>\",\n \"promotionDiscount\": 123,\n \"promotionType\": \"<string>\",\n \"promotionLabel\": \"<string>\",\n \"modifiers\": [\n {\n \"modifierId\": \"<string>\",\n \"externalId\": \"<string>\",\n \"name\": \"Agregados\",\n \"shortName\": \"<string>\",\n \"metadata\": {},\n \"description\": \"<string>\",\n \"countById\": {},\n \"countByExternalId\": {},\n \"options\": [\n {\n \"optionId\": \"<string>\",\n \"name\": \"Queso\",\n \"price\": 1000,\n \"externalId\": \"<string>\",\n \"metadata\": {},\n \"priceMetadata\": {}\n }\n ]\n }\n ]\n }\n ],\n \"transaction\": {\n \"_id\": \"<string>\",\n \"totalPrice\": 123,\n \"paymentType\": \"<string>\",\n \"cardType\": \"<string>\",\n \"cardLast4\": \"<string>\",\n \"status\": \"<string>\"\n },\n \"deliveries\": [\n {\n \"_id\": \"<string>\",\n \"price\": 2500,\n \"placeName\": \"<string>\",\n \"isCash\": true,\n \"instructions\": \"<string>\",\n \"driverPassword\": \"5366\",\n \"fromLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"toLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"trackingURL\": \"<string>\",\n \"orderId\": \"<string>\",\n \"activatesAt\": \"2020-01-01T00:00:00.000Z\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"forDate\": \"2020-01-01T00:00:00.000Z\",\n \"nearStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"pickupAt\": \"2020-01-01T00:00:00.000Z\",\n \"nearClientAt\": \"2020-01-01T00:00:00.000Z\",\n \"completedAt\": \"2020-01-01T00:00:00.000Z\",\n \"canceledAt\": \"2020-01-01T00:00:00.000Z\",\n \"deliveryExpectedAt\": \"2020-01-01T00:00:00.000Z\",\n \"estimatedArrivalAtStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverReceivedAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverInformation\": {},\n \"deliveryInformation\": {},\n \"externalId\": \"<string>\",\n \"specialCode\": \"<string>\"\n }\n ],\n \"orderParams\": {},\n \"hasManagedDelivery\": true,\n \"gift\": {},\n \"billing\": {},\n \"cancellationInfo\": {},\n \"deliveryZoneName\": \"<string>\"\n },\n \"delivery\": {\n \"_id\": \"<string>\",\n \"price\": 2500,\n \"placeName\": \"<string>\",\n \"isCash\": true,\n \"instructions\": \"<string>\",\n \"driverPassword\": \"5366\",\n \"fromLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"toLocation\": {\n \"lat\": -33.4489,\n \"lng\": -70.6693\n },\n \"trackingURL\": \"<string>\",\n \"orderId\": \"<string>\",\n \"activatesAt\": \"2020-01-01T00:00:00.000Z\",\n \"createdAt\": \"2020-01-01T00:00:00.000Z\",\n \"forDate\": \"2020-01-01T00:00:00.000Z\",\n \"nearStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"pickupAt\": \"2020-01-01T00:00:00.000Z\",\n \"nearClientAt\": \"2020-01-01T00:00:00.000Z\",\n \"completedAt\": \"2020-01-01T00:00:00.000Z\",\n \"canceledAt\": \"2020-01-01T00:00:00.000Z\",\n \"deliveryExpectedAt\": \"2020-01-01T00:00:00.000Z\",\n \"estimatedArrivalAtStoreAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverReceivedAt\": \"2020-01-01T00:00:00.000Z\",\n \"driverInformation\": {},\n \"deliveryInformation\": {},\n \"externalId\": \"<string>\",\n \"specialCode\": \"<string>\"\n }\n },\n \"websiteId\": \"<string>\",\n \"storeId\": \"<string>\",\n \"date\": \"2020-01-01T00:00:00.000Z\",\n \"eventId\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
Este webhook se envía cuando cambia el estado de un pedido o cuando ocurre un evento importante del despacho asociado.

Cambios de estado del pedido

Cuando cambia el estado operacional de la orden, previousOrderStatus y newOrderStatus vienen con valores distintos.
{
  "type": "ecommerce.order.status.updated",
  "data": {
    "previousOrderStatus": "waiting",
    "newOrderStatus": "preparing",
    "order": {
      "_id": "order-id",
      "orderStatus": "preparing"
    }
  }
}

Eventos importantes del despacho

Cuando el evento se origina por un cambio importante del despacho, previousOrderStatus y newOrderStatus vienen con el mismo valor y el payload incluye delivery. Justo envía estos eventos de despacho cuando:
  • cambia el estado del despacho;
  • el repartidor llega cerca del local;
  • el repartidor llega cerca del cliente.
No se envía un webhook por cada cambio de ubicación del repartidor.
{
  "type": "ecommerce.order.status.updated",
  "data": {
    "previousOrderStatus": "preparing",
    "newOrderStatus": "preparing",
    "order": {
      "_id": "order-id",
      "orderStatus": "preparing"
    },
    "delivery": {
      "_id": "delivery-id",
      "status": "active",
      "nearStoreAt": "2026-05-28T15:30:00.000Z",
      "estimatedArrivalAtStoreAt": "2026-05-28T15:35:00.000Z",
      "driverInformation": {
        "type": "moto",
        "phone": "+56999999999",
        "name": "Peter",
        "image": "https://example.com/driver.png"
      }
    }
  }
}

Información del repartidor

Cuando hay un repartidor asignado y el proveedor de despacho entrega sus datos, Justo envía la información en data.delivery.driverInformation.
CampoSignificado
typeTipo de vehículo o repartidor, por ejemplo moto.
phoneTeléfono del repartidor, si está disponible.
nameNombre del repartidor, si está disponible.
imageURL de la foto del repartidor, si está disponible.
El objeto puede venir ausente si todavía no hay repartidor asignado o si el proveedor de despacho no entrega esa información. Algunos proveedores pueden enviar campos adicionales, como code o categoryId. Para sincronizar una orden, usa siempre data.order._id. Si necesitas el estado del despacho o datos del repartidor, revisa data.delivery cuando venga presente.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Webhook Payload

type
enum<string>

El tipo de webhook.

Available options:
ecommerce.order.status.updated
Allowed value: "ecommerce.order.status.updated"
data
object

Datos del webhook de actualización de pedido. Si previousOrderStatus y newOrderStatus son iguales, el evento corresponde a un cambio importante del despacho asociado.

websiteId
string

ID de la marca.

storeId
string

ID del local.

date
string<date-time>

Fecha en que se generó el evento.

Example:

"2020-01-01T00:00:00.000Z"

eventId
string

ID único del evento.

Response

200

OK