curl --request PATCH \
--url https://prod01.copilot.fabric.inc/data-subscription/v1/orders/{orderId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"order": {
"shipTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"billTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"paymentDetails": {
"paymentIdentifier": {
"cardIdentifier": "1234",
"expiryDate": "12/20"
},
"paymentMethod": "credit_card",
"paymentKind": "Visa"
},
"scheduledDate": "2019-01-01T00:00:00.000Z",
"status": "SCHEDULED",
"lineItems": [
{
"shipping": {
"shipmentCarrier": "USPS",
"shipmentMethod": "Ground",
"shipmentInstructions": "Please leave the package in the box",
"taxCode": "SHP020000",
"shippingAmount": 10,
"taxAmount": 1,
"currencyCode": "USD"
},
"offer": {
"id": "SUB-E10717",
"source": "PDP"
},
"Item": {
"quantity": 1,
"weight": 10,
"weightUnit": "lb",
"tax": {
"taxCode": "FR020000",
"taxAmount": 10,
"currencyCode": "USD"
}
},
"customAttributes": {
"storeId": "60cb07fc20387b000821c5c3",
"associateId": 1,
"trackingUrl": "609436d21baded0008945b05"
}
}
]
}
}
'{
"responseStatus": "OK",
"message": "Request processed successfully",
"data": {
"order": {
"status": "SCHEDULED",
"totalAmount": 100,
"currencyCode": "USD",
"scheduledDate": "2019-01-01T00:00:00.000Z",
"customer": {
"customerReferenceId": "12345",
"locale": "en_US",
"email": "[email protected]",
"firstName": "Pat",
"lastName": "Kake",
"contactnumber": "5555551234",
"middleName": "E",
"segments": [
"employee"
],
"employeeId": "345",
"status": "ACTIVE",
"isDeleted": false,
"DeletedAt": "2021-01-01T00:00:00.000Z",
"createdAt": "2019-10-12T21:35:05.756Z",
"updatedAt": "2021-10-14T05:40:55.997Z",
"communicationPreference": {
"email": true,
"sms": true
}
},
"shipTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"billTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"paymentDetails": {
"paymentIdentifier": {
"cardIdentifier": "1234",
"expiryDate": "12/20"
},
"paymentMethod": "credit_card",
"paymentKind": "Visa"
},
"isDeleted": false,
"deletedAt": "2019-01-01T00:00:00.000Z",
"id": "6384462ab645220008a4358a",
"totalTax": 10,
"totalDiscount": 10,
"lineItems": [
{
"lineItemId": 1,
"subscription": {
"plan": {
"frequency": 30,
"frequencyType": "Daily",
"id": "1001"
},
"id": "6256610bc312410009b7390b"
},
"item": {
"id": 1000000006,
"sku": "MOBO-X570",
"quantity": 1,
"itemPrice": {
"price": 100,
"currencyCode": "USD"
},
"weight": 10,
"weightUnit": "lb",
"title": "Vitamin",
"description": "Vitamin C",
"tax": {
"taxCode": "FR020000",
"taxAmount": 10,
"currencyCode": "USD"
}
},
"shipping": {
"shipmentCarrier": "USPS",
"shipmentMethod": "Ground",
"shipmentInstructions": "Please leave the package in the box",
"taxCode": "SHP020000",
"shippingAmount": 10,
"taxAmount": 1,
"currencyCode": "USD"
},
"offer": {
"id": "SUB-E10717",
"source": "PDP"
},
"customAttributes": {
"storeId": "60cb07fc20387b000821c5c3",
"associateId": 1,
"trackingUrl": "609436d21baded0008945b05"
}
}
],
"createdAt": "2021-10-12T21:35:05.756Z",
"updatedAt": "2021-10-14T05:40:55.997Z",
"statusUpdatedAt": "2021-10-14T10:24:36.468Z",
"Retry": {
"maxRetries": 3,
"retryType": "PAYMENT RETRY",
"retryAfterDays": 1,
"retryCount": 2
},
"error": {
"errorCode": "ORDER_NOT_FOUND",
"errorMessage": "The order is not found"
}
}
}
}Update single order, specified by order ID
curl --request PATCH \
--url https://prod01.copilot.fabric.inc/data-subscription/v1/orders/{orderId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"order": {
"shipTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"billTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"paymentDetails": {
"paymentIdentifier": {
"cardIdentifier": "1234",
"expiryDate": "12/20"
},
"paymentMethod": "credit_card",
"paymentKind": "Visa"
},
"scheduledDate": "2019-01-01T00:00:00.000Z",
"status": "SCHEDULED",
"lineItems": [
{
"shipping": {
"shipmentCarrier": "USPS",
"shipmentMethod": "Ground",
"shipmentInstructions": "Please leave the package in the box",
"taxCode": "SHP020000",
"shippingAmount": 10,
"taxAmount": 1,
"currencyCode": "USD"
},
"offer": {
"id": "SUB-E10717",
"source": "PDP"
},
"Item": {
"quantity": 1,
"weight": 10,
"weightUnit": "lb",
"tax": {
"taxCode": "FR020000",
"taxAmount": 10,
"currencyCode": "USD"
}
},
"customAttributes": {
"storeId": "60cb07fc20387b000821c5c3",
"associateId": 1,
"trackingUrl": "609436d21baded0008945b05"
}
}
]
}
}
'{
"responseStatus": "OK",
"message": "Request processed successfully",
"data": {
"order": {
"status": "SCHEDULED",
"totalAmount": 100,
"currencyCode": "USD",
"scheduledDate": "2019-01-01T00:00:00.000Z",
"customer": {
"customerReferenceId": "12345",
"locale": "en_US",
"email": "[email protected]",
"firstName": "Pat",
"lastName": "Kake",
"contactnumber": "5555551234",
"middleName": "E",
"segments": [
"employee"
],
"employeeId": "345",
"status": "ACTIVE",
"isDeleted": false,
"DeletedAt": "2021-01-01T00:00:00.000Z",
"createdAt": "2019-10-12T21:35:05.756Z",
"updatedAt": "2021-10-14T05:40:55.997Z",
"communicationPreference": {
"email": true,
"sms": true
}
},
"shipTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"billTo": {
"name": {
"firstName": "Pat",
"lastName": "Kake",
"middleName": "E"
},
"streetAddress": {
"street1": "123 Main St",
"street2": "Suite 100"
},
"city": "Boston",
"state": "MA",
"postalCode": "02127",
"country": "US",
"phone": {
"number": "5555551234",
"kind": "home"
}
},
"paymentDetails": {
"paymentIdentifier": {
"cardIdentifier": "1234",
"expiryDate": "12/20"
},
"paymentMethod": "credit_card",
"paymentKind": "Visa"
},
"isDeleted": false,
"deletedAt": "2019-01-01T00:00:00.000Z",
"id": "6384462ab645220008a4358a",
"totalTax": 10,
"totalDiscount": 10,
"lineItems": [
{
"lineItemId": 1,
"subscription": {
"plan": {
"frequency": 30,
"frequencyType": "Daily",
"id": "1001"
},
"id": "6256610bc312410009b7390b"
},
"item": {
"id": 1000000006,
"sku": "MOBO-X570",
"quantity": 1,
"itemPrice": {
"price": 100,
"currencyCode": "USD"
},
"weight": 10,
"weightUnit": "lb",
"title": "Vitamin",
"description": "Vitamin C",
"tax": {
"taxCode": "FR020000",
"taxAmount": 10,
"currencyCode": "USD"
}
},
"shipping": {
"shipmentCarrier": "USPS",
"shipmentMethod": "Ground",
"shipmentInstructions": "Please leave the package in the box",
"taxCode": "SHP020000",
"shippingAmount": 10,
"taxAmount": 1,
"currencyCode": "USD"
},
"offer": {
"id": "SUB-E10717",
"source": "PDP"
},
"customAttributes": {
"storeId": "60cb07fc20387b000821c5c3",
"associateId": 1,
"trackingUrl": "609436d21baded0008945b05"
}
}
],
"createdAt": "2021-10-12T21:35:05.756Z",
"updatedAt": "2021-10-14T05:40:55.997Z",
"statusUpdatedAt": "2021-10-14T10:24:36.468Z",
"Retry": {
"maxRetries": 3,
"retryType": "PAYMENT RETRY",
"retryAfterDays": 1,
"retryCount": 2
},
"error": {
"errorCode": "ORDER_NOT_FOUND",
"errorMessage": "The order is not found"
}
}
}
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Order ID General object ID
"606f01f441b8fc0008529916"
Details to update order
Order details to be updated
Show child attributes
Ship-to address and phone details
Show child attributes
City name
"Boston"
State name
"MA"
Postal code
"02127"
Country name
"US"
Bill-to address and phone details
Show child attributes
City name
"Boston"
State name
"MA"
Postal code
"02127"
Country name
"US"
Payment details
Show child attributes
Payment method
"credit_card"
Payment type
"Visa"
Date on which order is scheduled to be created
"2019-01-01T00:00:00.000Z"
Order status
SCHEDULED, CANCELED, SUCCESS, SKIPPED, RETRY, SUBMITTED, FAILED "SCHEDULED"
Show child attributes
Shipping details
Show child attributes
Shipment carrier
"USPS"
Shipment method
"Ground"
Shipment instructions
"Please leave the package in the box"
Shipment tax code
"SHP020000"
Shipping cost
10
Shipment tax amount (value, not percentage)
1
Shipment currency code
"USD"
Order item update details
Show child attributes
Number of items
1
Item weight amount
10
Item weight unit
"lb"
Request processed successfully
Order details after updating order
Brief response status
"OK"
Full response message
"Request processed successfully"
Order details
Show child attributes
Order details
Show child attributes
Order status
SCHEDULED, CANCELED, SUCCESS, SKIPPED, RETRY, SUBMITTED, FAILED "SCHEDULED"
Total order price
100
Order currency code
"USD"
Date on which order is scheduled to be created
"2019-01-01T00:00:00.000Z"
Customer information
Show child attributes
Customer reference ID
"12345"
Customer locale (language_country)
"en_US"
Customer's email address
Customer's first name
"Pat"
Customer's last name
"Kake"
Customer's contact number
"5555551234"
Customer's middle name or initial
"E"
Customer's segments
Customer's segment (employee, management, pro user, etc.)
Customer employee ID
"345"
Customer status
ACTIVE, INACTIVE "ACTIVE"
true: Customer is deleted
false: Customer is not deleted
false
If isDeleted=true, time at which the customer was deleted
If isDeleted=false, NULL
"2021-01-01T00:00:00.000Z"
Time customer was created
"2019-10-12T21:35:05.756Z"
Most recent time customer was updated
"2021-10-14T05:40:55.997Z"
Customer's communications preferences
Show child attributes
true: Customer agrees to be contacted via email
false: Customer does not want to be contacted via email
true
true: Customer agrees to be contacted via text message
false: Customer does not want to be contacted via text message
true
Ship-to address and phone details
Show child attributes
City name
"Boston"
State name
"MA"
Postal code
"02127"
Country name
"US"
Bill-to address and phone details
Show child attributes
City name
"Boston"
State name
"MA"
Postal code
"02127"
Country name
"US"
Payment details
Show child attributes
Payment method
"credit_card"
Payment type
"Visa"
true: Order is deleted
false: Order is not deleted
false
If isDeleted=true, time at which the order was deleted
If isDeleted=false, NULL
"2019-01-01T00:00:00.000Z"
Order ID
"6384462ab645220008a4358a"
Total tax on order
10
Total discount for order (amount, not percentage)
10
Show child attributes
Line item ID
1
Subscription details
Show child attributes
Subscription plan details
Show child attributes
Subscription plan frequency value
30
Subscription plan frequency period
"Daily"
Subscription plan ID
"1001"
Subscription ID
"6256610bc312410009b7390b"
Item details
Show child attributes
Item ID
1000000006
Item SKU
"MOBO-X570"
Number of items
1
Item weight amount
10
Item weight unit
"lb"
Item name
"Vitamin"
Item description
"Vitamin C"
Shipping details
Show child attributes
Shipment carrier
"USPS"
Shipment method
"Ground"
Shipment instructions
"Please leave the package in the box"
Shipment tax code
"SHP020000"
Shipping cost
10
Shipment tax amount (value, not percentage)
1
Shipment currency code
"USD"
Custom attributes
Time order was created
"2021-10-12T21:35:05.756Z"
Most recent time order was updated
"2021-10-14T05:40:55.997Z"
Most recent time order status was updated
"2021-10-14T10:24:36.468Z"
Order retry details
Show child attributes
Maximum number of retries
3
Retry type
PAYMENT RETRY, INTENTORY RETRY, GENERIC RETRY "PAYMENT RETRY"
Number of days after which to retry
1
Number of times to retry order
2
Was this page helpful?