curl --request POST \
--url https://api.retailreadyai.com/api/v1/orders/create \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"po_number": "some-po-number",
"picksheet_code": "some-picksheet-code",
"brand_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"retailer_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"facility_id": "14e517b3-5091-4748-8a25-c497aec2ce9z",
"items": [
{
"sku": "pillow-sku",
"upc": "pillow-upc",
"quantity": 5,
"case_pack_quantity": 5,
"case_barcode": "pillow-case-upc",
"vendor_pn": "vendor-part-number",
"description": "soft pillows"
}
],
"address_data": {
"ship_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"address_line2": "<string>",
"facility_code": "<string>",
"dc_number": "<string>"
},
"bill_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>",
"email": "jsmith@example.com"
},
"mark_for_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>"
}
},
"external_order_id": "some-external-order-id",
"dept_number": "123456",
"purchase_order_type": "Test Department",
"transportation_method": "FREIGHT",
"carrier": "Fedex Freight",
"dates": {
"requested_delivery_date": "2024-08-15",
"earliest_delivery_date": "2024-08-10",
"latest_delivery_date": "2024-08-20",
"earliest_ship_date": "2024-08-05",
"latest_ship_date": "2024-08-12",
"cancel_by_date": "2024-08-25",
"requested_ship_date": "2024-08-08",
"stage_by": "2024-08-01"
}
}
'import requests
url = "https://api.retailreadyai.com/api/v1/orders/create"
payload = {
"po_number": "some-po-number",
"picksheet_code": "some-picksheet-code",
"brand_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"retailer_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"facility_id": "14e517b3-5091-4748-8a25-c497aec2ce9z",
"items": [
{
"sku": "pillow-sku",
"upc": "pillow-upc",
"quantity": 5,
"case_pack_quantity": 5,
"case_barcode": "pillow-case-upc",
"vendor_pn": "vendor-part-number",
"description": "soft pillows"
}
],
"address_data": {
"ship_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"address_line2": "<string>",
"facility_code": "<string>",
"dc_number": "<string>"
},
"bill_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>",
"email": "jsmith@example.com"
},
"mark_for_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>"
}
},
"external_order_id": "some-external-order-id",
"dept_number": "123456",
"purchase_order_type": "Test Department",
"transportation_method": "FREIGHT",
"carrier": "Fedex Freight",
"dates": {
"requested_delivery_date": "2024-08-15",
"earliest_delivery_date": "2024-08-10",
"latest_delivery_date": "2024-08-20",
"earliest_ship_date": "2024-08-05",
"latest_ship_date": "2024-08-12",
"cancel_by_date": "2024-08-25",
"requested_ship_date": "2024-08-08",
"stage_by": "2024-08-01"
}
}
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({
po_number: 'some-po-number',
picksheet_code: 'some-picksheet-code',
brand_id: '14e517b3-5091-4748-8a25-c497aec2ce98',
retailer_id: '14e517b3-5091-4748-8a25-c497aec2ce98',
facility_id: '14e517b3-5091-4748-8a25-c497aec2ce9z',
items: [
{
sku: 'pillow-sku',
upc: 'pillow-upc',
quantity: 5,
case_pack_quantity: 5,
case_barcode: 'pillow-case-upc',
vendor_pn: 'vendor-part-number',
description: 'soft pillows'
}
],
address_data: {
ship_to_contact: {
name: '<string>',
address_line1: '<string>',
city: '<string>',
province: '<string>',
country: '<string>',
zip: '<string>',
address_line2: '<string>',
facility_code: '<string>',
dc_number: '<string>'
},
bill_to_contact: {
name: '<string>',
address_line1: '<string>',
address_line2: '<string>',
city: '<string>',
province: '<string>',
country: '<string>',
zip: '<string>',
facility_code: '<string>',
address_number: '<string>',
email: 'jsmith@example.com'
},
mark_for_contact: {
name: '<string>',
address_line1: '<string>',
address_line2: '<string>',
city: '<string>',
state: '<string>',
country: '<string>',
zip: '<string>',
facility_code: '<string>',
address_number: '<string>'
}
},
external_order_id: 'some-external-order-id',
dept_number: '123456',
purchase_order_type: 'Test Department',
transportation_method: 'FREIGHT',
carrier: 'Fedex Freight',
dates: {
requested_delivery_date: '2024-08-15',
earliest_delivery_date: '2024-08-10',
latest_delivery_date: '2024-08-20',
earliest_ship_date: '2024-08-05',
latest_ship_date: '2024-08-12',
cancel_by_date: '2024-08-25',
requested_ship_date: '2024-08-08',
stage_by: '2024-08-01'
}
})
};
fetch('https://api.retailreadyai.com/api/v1/orders/create', 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.retailreadyai.com/api/v1/orders/create",
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([
'po_number' => 'some-po-number',
'picksheet_code' => 'some-picksheet-code',
'brand_id' => '14e517b3-5091-4748-8a25-c497aec2ce98',
'retailer_id' => '14e517b3-5091-4748-8a25-c497aec2ce98',
'facility_id' => '14e517b3-5091-4748-8a25-c497aec2ce9z',
'items' => [
[
'sku' => 'pillow-sku',
'upc' => 'pillow-upc',
'quantity' => 5,
'case_pack_quantity' => 5,
'case_barcode' => 'pillow-case-upc',
'vendor_pn' => 'vendor-part-number',
'description' => 'soft pillows'
]
],
'address_data' => [
'ship_to_contact' => [
'name' => '<string>',
'address_line1' => '<string>',
'city' => '<string>',
'province' => '<string>',
'country' => '<string>',
'zip' => '<string>',
'address_line2' => '<string>',
'facility_code' => '<string>',
'dc_number' => '<string>'
],
'bill_to_contact' => [
'name' => '<string>',
'address_line1' => '<string>',
'address_line2' => '<string>',
'city' => '<string>',
'province' => '<string>',
'country' => '<string>',
'zip' => '<string>',
'facility_code' => '<string>',
'address_number' => '<string>',
'email' => 'jsmith@example.com'
],
'mark_for_contact' => [
'name' => '<string>',
'address_line1' => '<string>',
'address_line2' => '<string>',
'city' => '<string>',
'state' => '<string>',
'country' => '<string>',
'zip' => '<string>',
'facility_code' => '<string>',
'address_number' => '<string>'
]
],
'external_order_id' => 'some-external-order-id',
'dept_number' => '123456',
'purchase_order_type' => 'Test Department',
'transportation_method' => 'FREIGHT',
'carrier' => 'Fedex Freight',
'dates' => [
'requested_delivery_date' => '2024-08-15',
'earliest_delivery_date' => '2024-08-10',
'latest_delivery_date' => '2024-08-20',
'earliest_ship_date' => '2024-08-05',
'latest_ship_date' => '2024-08-12',
'cancel_by_date' => '2024-08-25',
'requested_ship_date' => '2024-08-08',
'stage_by' => '2024-08-01'
]
]),
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.retailreadyai.com/api/v1/orders/create"
payload := strings.NewReader("{\n \"po_number\": \"some-po-number\",\n \"picksheet_code\": \"some-picksheet-code\",\n \"brand_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"retailer_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"facility_id\": \"14e517b3-5091-4748-8a25-c497aec2ce9z\",\n \"items\": [\n {\n \"sku\": \"pillow-sku\",\n \"upc\": \"pillow-upc\",\n \"quantity\": 5,\n \"case_pack_quantity\": 5,\n \"case_barcode\": \"pillow-case-upc\",\n \"vendor_pn\": \"vendor-part-number\",\n \"description\": \"soft pillows\"\n }\n ],\n \"address_data\": {\n \"ship_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"dc_number\": \"<string>\"\n },\n \"bill_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\",\n \"email\": \"jsmith@example.com\"\n },\n \"mark_for_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"state\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\"\n }\n },\n \"external_order_id\": \"some-external-order-id\",\n \"dept_number\": \"123456\",\n \"purchase_order_type\": \"Test Department\",\n \"transportation_method\": \"FREIGHT\",\n \"carrier\": \"Fedex Freight\",\n \"dates\": {\n \"requested_delivery_date\": \"2024-08-15\",\n \"earliest_delivery_date\": \"2024-08-10\",\n \"latest_delivery_date\": \"2024-08-20\",\n \"earliest_ship_date\": \"2024-08-05\",\n \"latest_ship_date\": \"2024-08-12\",\n \"cancel_by_date\": \"2024-08-25\",\n \"requested_ship_date\": \"2024-08-08\",\n \"stage_by\": \"2024-08-01\"\n }\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.retailreadyai.com/api/v1/orders/create")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"po_number\": \"some-po-number\",\n \"picksheet_code\": \"some-picksheet-code\",\n \"brand_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"retailer_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"facility_id\": \"14e517b3-5091-4748-8a25-c497aec2ce9z\",\n \"items\": [\n {\n \"sku\": \"pillow-sku\",\n \"upc\": \"pillow-upc\",\n \"quantity\": 5,\n \"case_pack_quantity\": 5,\n \"case_barcode\": \"pillow-case-upc\",\n \"vendor_pn\": \"vendor-part-number\",\n \"description\": \"soft pillows\"\n }\n ],\n \"address_data\": {\n \"ship_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"dc_number\": \"<string>\"\n },\n \"bill_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\",\n \"email\": \"jsmith@example.com\"\n },\n \"mark_for_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"state\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\"\n }\n },\n \"external_order_id\": \"some-external-order-id\",\n \"dept_number\": \"123456\",\n \"purchase_order_type\": \"Test Department\",\n \"transportation_method\": \"FREIGHT\",\n \"carrier\": \"Fedex Freight\",\n \"dates\": {\n \"requested_delivery_date\": \"2024-08-15\",\n \"earliest_delivery_date\": \"2024-08-10\",\n \"latest_delivery_date\": \"2024-08-20\",\n \"earliest_ship_date\": \"2024-08-05\",\n \"latest_ship_date\": \"2024-08-12\",\n \"cancel_by_date\": \"2024-08-25\",\n \"requested_ship_date\": \"2024-08-08\",\n \"stage_by\": \"2024-08-01\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.retailreadyai.com/api/v1/orders/create")
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 \"po_number\": \"some-po-number\",\n \"picksheet_code\": \"some-picksheet-code\",\n \"brand_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"retailer_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"facility_id\": \"14e517b3-5091-4748-8a25-c497aec2ce9z\",\n \"items\": [\n {\n \"sku\": \"pillow-sku\",\n \"upc\": \"pillow-upc\",\n \"quantity\": 5,\n \"case_pack_quantity\": 5,\n \"case_barcode\": \"pillow-case-upc\",\n \"vendor_pn\": \"vendor-part-number\",\n \"description\": \"soft pillows\"\n }\n ],\n \"address_data\": {\n \"ship_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"dc_number\": \"<string>\"\n },\n \"bill_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\",\n \"email\": \"jsmith@example.com\"\n },\n \"mark_for_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"state\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\"\n }\n },\n \"external_order_id\": \"some-external-order-id\",\n \"dept_number\": \"123456\",\n \"purchase_order_type\": \"Test Department\",\n \"transportation_method\": \"FREIGHT\",\n \"carrier\": \"Fedex Freight\",\n \"dates\": {\n \"requested_delivery_date\": \"2024-08-15\",\n \"earliest_delivery_date\": \"2024-08-10\",\n \"latest_delivery_date\": \"2024-08-20\",\n \"earliest_ship_date\": \"2024-08-05\",\n \"latest_ship_date\": \"2024-08-12\",\n \"cancel_by_date\": \"2024-08-25\",\n \"requested_ship_date\": \"2024-08-08\",\n \"stage_by\": \"2024-08-01\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Order created successfully",
"data": {
"order_id": "14e517b3-5091-4748-8a25-c497aec2ce98"
}
}{
"message": "Failed to create order: picksheet_code is required",
"error": {
"code": "INVALID_REQUEST"
}
}Create Order
Create a new order
curl --request POST \
--url https://api.retailreadyai.com/api/v1/orders/create \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"po_number": "some-po-number",
"picksheet_code": "some-picksheet-code",
"brand_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"retailer_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"facility_id": "14e517b3-5091-4748-8a25-c497aec2ce9z",
"items": [
{
"sku": "pillow-sku",
"upc": "pillow-upc",
"quantity": 5,
"case_pack_quantity": 5,
"case_barcode": "pillow-case-upc",
"vendor_pn": "vendor-part-number",
"description": "soft pillows"
}
],
"address_data": {
"ship_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"address_line2": "<string>",
"facility_code": "<string>",
"dc_number": "<string>"
},
"bill_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>",
"email": "jsmith@example.com"
},
"mark_for_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>"
}
},
"external_order_id": "some-external-order-id",
"dept_number": "123456",
"purchase_order_type": "Test Department",
"transportation_method": "FREIGHT",
"carrier": "Fedex Freight",
"dates": {
"requested_delivery_date": "2024-08-15",
"earliest_delivery_date": "2024-08-10",
"latest_delivery_date": "2024-08-20",
"earliest_ship_date": "2024-08-05",
"latest_ship_date": "2024-08-12",
"cancel_by_date": "2024-08-25",
"requested_ship_date": "2024-08-08",
"stage_by": "2024-08-01"
}
}
'import requests
url = "https://api.retailreadyai.com/api/v1/orders/create"
payload = {
"po_number": "some-po-number",
"picksheet_code": "some-picksheet-code",
"brand_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"retailer_id": "14e517b3-5091-4748-8a25-c497aec2ce98",
"facility_id": "14e517b3-5091-4748-8a25-c497aec2ce9z",
"items": [
{
"sku": "pillow-sku",
"upc": "pillow-upc",
"quantity": 5,
"case_pack_quantity": 5,
"case_barcode": "pillow-case-upc",
"vendor_pn": "vendor-part-number",
"description": "soft pillows"
}
],
"address_data": {
"ship_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"address_line2": "<string>",
"facility_code": "<string>",
"dc_number": "<string>"
},
"bill_to_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"province": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>",
"email": "jsmith@example.com"
},
"mark_for_contact": {
"name": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>",
"zip": "<string>",
"facility_code": "<string>",
"address_number": "<string>"
}
},
"external_order_id": "some-external-order-id",
"dept_number": "123456",
"purchase_order_type": "Test Department",
"transportation_method": "FREIGHT",
"carrier": "Fedex Freight",
"dates": {
"requested_delivery_date": "2024-08-15",
"earliest_delivery_date": "2024-08-10",
"latest_delivery_date": "2024-08-20",
"earliest_ship_date": "2024-08-05",
"latest_ship_date": "2024-08-12",
"cancel_by_date": "2024-08-25",
"requested_ship_date": "2024-08-08",
"stage_by": "2024-08-01"
}
}
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({
po_number: 'some-po-number',
picksheet_code: 'some-picksheet-code',
brand_id: '14e517b3-5091-4748-8a25-c497aec2ce98',
retailer_id: '14e517b3-5091-4748-8a25-c497aec2ce98',
facility_id: '14e517b3-5091-4748-8a25-c497aec2ce9z',
items: [
{
sku: 'pillow-sku',
upc: 'pillow-upc',
quantity: 5,
case_pack_quantity: 5,
case_barcode: 'pillow-case-upc',
vendor_pn: 'vendor-part-number',
description: 'soft pillows'
}
],
address_data: {
ship_to_contact: {
name: '<string>',
address_line1: '<string>',
city: '<string>',
province: '<string>',
country: '<string>',
zip: '<string>',
address_line2: '<string>',
facility_code: '<string>',
dc_number: '<string>'
},
bill_to_contact: {
name: '<string>',
address_line1: '<string>',
address_line2: '<string>',
city: '<string>',
province: '<string>',
country: '<string>',
zip: '<string>',
facility_code: '<string>',
address_number: '<string>',
email: 'jsmith@example.com'
},
mark_for_contact: {
name: '<string>',
address_line1: '<string>',
address_line2: '<string>',
city: '<string>',
state: '<string>',
country: '<string>',
zip: '<string>',
facility_code: '<string>',
address_number: '<string>'
}
},
external_order_id: 'some-external-order-id',
dept_number: '123456',
purchase_order_type: 'Test Department',
transportation_method: 'FREIGHT',
carrier: 'Fedex Freight',
dates: {
requested_delivery_date: '2024-08-15',
earliest_delivery_date: '2024-08-10',
latest_delivery_date: '2024-08-20',
earliest_ship_date: '2024-08-05',
latest_ship_date: '2024-08-12',
cancel_by_date: '2024-08-25',
requested_ship_date: '2024-08-08',
stage_by: '2024-08-01'
}
})
};
fetch('https://api.retailreadyai.com/api/v1/orders/create', 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.retailreadyai.com/api/v1/orders/create",
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([
'po_number' => 'some-po-number',
'picksheet_code' => 'some-picksheet-code',
'brand_id' => '14e517b3-5091-4748-8a25-c497aec2ce98',
'retailer_id' => '14e517b3-5091-4748-8a25-c497aec2ce98',
'facility_id' => '14e517b3-5091-4748-8a25-c497aec2ce9z',
'items' => [
[
'sku' => 'pillow-sku',
'upc' => 'pillow-upc',
'quantity' => 5,
'case_pack_quantity' => 5,
'case_barcode' => 'pillow-case-upc',
'vendor_pn' => 'vendor-part-number',
'description' => 'soft pillows'
]
],
'address_data' => [
'ship_to_contact' => [
'name' => '<string>',
'address_line1' => '<string>',
'city' => '<string>',
'province' => '<string>',
'country' => '<string>',
'zip' => '<string>',
'address_line2' => '<string>',
'facility_code' => '<string>',
'dc_number' => '<string>'
],
'bill_to_contact' => [
'name' => '<string>',
'address_line1' => '<string>',
'address_line2' => '<string>',
'city' => '<string>',
'province' => '<string>',
'country' => '<string>',
'zip' => '<string>',
'facility_code' => '<string>',
'address_number' => '<string>',
'email' => 'jsmith@example.com'
],
'mark_for_contact' => [
'name' => '<string>',
'address_line1' => '<string>',
'address_line2' => '<string>',
'city' => '<string>',
'state' => '<string>',
'country' => '<string>',
'zip' => '<string>',
'facility_code' => '<string>',
'address_number' => '<string>'
]
],
'external_order_id' => 'some-external-order-id',
'dept_number' => '123456',
'purchase_order_type' => 'Test Department',
'transportation_method' => 'FREIGHT',
'carrier' => 'Fedex Freight',
'dates' => [
'requested_delivery_date' => '2024-08-15',
'earliest_delivery_date' => '2024-08-10',
'latest_delivery_date' => '2024-08-20',
'earliest_ship_date' => '2024-08-05',
'latest_ship_date' => '2024-08-12',
'cancel_by_date' => '2024-08-25',
'requested_ship_date' => '2024-08-08',
'stage_by' => '2024-08-01'
]
]),
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.retailreadyai.com/api/v1/orders/create"
payload := strings.NewReader("{\n \"po_number\": \"some-po-number\",\n \"picksheet_code\": \"some-picksheet-code\",\n \"brand_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"retailer_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"facility_id\": \"14e517b3-5091-4748-8a25-c497aec2ce9z\",\n \"items\": [\n {\n \"sku\": \"pillow-sku\",\n \"upc\": \"pillow-upc\",\n \"quantity\": 5,\n \"case_pack_quantity\": 5,\n \"case_barcode\": \"pillow-case-upc\",\n \"vendor_pn\": \"vendor-part-number\",\n \"description\": \"soft pillows\"\n }\n ],\n \"address_data\": {\n \"ship_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"dc_number\": \"<string>\"\n },\n \"bill_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\",\n \"email\": \"jsmith@example.com\"\n },\n \"mark_for_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"state\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\"\n }\n },\n \"external_order_id\": \"some-external-order-id\",\n \"dept_number\": \"123456\",\n \"purchase_order_type\": \"Test Department\",\n \"transportation_method\": \"FREIGHT\",\n \"carrier\": \"Fedex Freight\",\n \"dates\": {\n \"requested_delivery_date\": \"2024-08-15\",\n \"earliest_delivery_date\": \"2024-08-10\",\n \"latest_delivery_date\": \"2024-08-20\",\n \"earliest_ship_date\": \"2024-08-05\",\n \"latest_ship_date\": \"2024-08-12\",\n \"cancel_by_date\": \"2024-08-25\",\n \"requested_ship_date\": \"2024-08-08\",\n \"stage_by\": \"2024-08-01\"\n }\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.retailreadyai.com/api/v1/orders/create")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"po_number\": \"some-po-number\",\n \"picksheet_code\": \"some-picksheet-code\",\n \"brand_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"retailer_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"facility_id\": \"14e517b3-5091-4748-8a25-c497aec2ce9z\",\n \"items\": [\n {\n \"sku\": \"pillow-sku\",\n \"upc\": \"pillow-upc\",\n \"quantity\": 5,\n \"case_pack_quantity\": 5,\n \"case_barcode\": \"pillow-case-upc\",\n \"vendor_pn\": \"vendor-part-number\",\n \"description\": \"soft pillows\"\n }\n ],\n \"address_data\": {\n \"ship_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"dc_number\": \"<string>\"\n },\n \"bill_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\",\n \"email\": \"jsmith@example.com\"\n },\n \"mark_for_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"state\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\"\n }\n },\n \"external_order_id\": \"some-external-order-id\",\n \"dept_number\": \"123456\",\n \"purchase_order_type\": \"Test Department\",\n \"transportation_method\": \"FREIGHT\",\n \"carrier\": \"Fedex Freight\",\n \"dates\": {\n \"requested_delivery_date\": \"2024-08-15\",\n \"earliest_delivery_date\": \"2024-08-10\",\n \"latest_delivery_date\": \"2024-08-20\",\n \"earliest_ship_date\": \"2024-08-05\",\n \"latest_ship_date\": \"2024-08-12\",\n \"cancel_by_date\": \"2024-08-25\",\n \"requested_ship_date\": \"2024-08-08\",\n \"stage_by\": \"2024-08-01\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.retailreadyai.com/api/v1/orders/create")
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 \"po_number\": \"some-po-number\",\n \"picksheet_code\": \"some-picksheet-code\",\n \"brand_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"retailer_id\": \"14e517b3-5091-4748-8a25-c497aec2ce98\",\n \"facility_id\": \"14e517b3-5091-4748-8a25-c497aec2ce9z\",\n \"items\": [\n {\n \"sku\": \"pillow-sku\",\n \"upc\": \"pillow-upc\",\n \"quantity\": 5,\n \"case_pack_quantity\": 5,\n \"case_barcode\": \"pillow-case-upc\",\n \"vendor_pn\": \"vendor-part-number\",\n \"description\": \"soft pillows\"\n }\n ],\n \"address_data\": {\n \"ship_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"dc_number\": \"<string>\"\n },\n \"bill_to_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"province\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\",\n \"email\": \"jsmith@example.com\"\n },\n \"mark_for_contact\": {\n \"name\": \"<string>\",\n \"address_line1\": \"<string>\",\n \"address_line2\": \"<string>\",\n \"city\": \"<string>\",\n \"state\": \"<string>\",\n \"country\": \"<string>\",\n \"zip\": \"<string>\",\n \"facility_code\": \"<string>\",\n \"address_number\": \"<string>\"\n }\n },\n \"external_order_id\": \"some-external-order-id\",\n \"dept_number\": \"123456\",\n \"purchase_order_type\": \"Test Department\",\n \"transportation_method\": \"FREIGHT\",\n \"carrier\": \"Fedex Freight\",\n \"dates\": {\n \"requested_delivery_date\": \"2024-08-15\",\n \"earliest_delivery_date\": \"2024-08-10\",\n \"latest_delivery_date\": \"2024-08-20\",\n \"earliest_ship_date\": \"2024-08-05\",\n \"latest_ship_date\": \"2024-08-12\",\n \"cancel_by_date\": \"2024-08-25\",\n \"requested_ship_date\": \"2024-08-08\",\n \"stage_by\": \"2024-08-01\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Order created successfully",
"data": {
"order_id": "14e517b3-5091-4748-8a25-c497aec2ce98"
}
}{
"message": "Failed to create order: picksheet_code is required",
"error": {
"code": "INVALID_REQUEST"
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Purchase order number
"some-po-number"
Picksheet Code/Warehouse Order Number
"some-picksheet-code"
UUID of the brand
"14e517b3-5091-4748-8a25-c497aec2ce98"
UUID of the retailer
"14e517b3-5091-4748-8a25-c497aec2ce98"
UUID of the facility
"14e517b3-5091-4748-8a25-c497aec2ce9z"
Show child attributes
Show child attributes
Show child attributes
Show child attributes
External Order ID
"some-external-order-id"
Department number. Required for Nordstrom, Walmart, TJX, Von Maur, DICK's Sporting Goods, Macy's, Dillard's, and Bloomingdales.
"123456"
Type of purchase order. Required for Walmart, TJX, SaksOffFifth.com, Saks Off Fifth Store, DICK's Sporting Goods, Macy's Store, Macy's.com, and Bloomingdales
"Test Department"
Method of transportation
"FREIGHT"
Carrier
"Fedex Freight"
Service Method
ups_ground, fedex_ground Show child attributes
Show child attributes

