curl --request POST \
--url https://api.wizcommerce.com/v2/orders \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"customer_id": "12345678-90ab-cdef-1234-567890abcdef",
"payment_status": "PAID",
"fulfillment_status": "PARTIALLY_DELIVERED",
"created_at": "2025-01-01T00:00:00Z",
"updated_at": "2025-01-01T00:00:00Z",
"line_items": [
{
"sku": "RUG14754",
"quantity": 10,
"shipped_quantity": 0,
"invoiced_quantity": 0,
"cancelled_quantity": 0,
"picked_quantity": 0,
"unit_price": 100,
"discount": 0,
"discount_type": "percentage",
"is_adhoc": false,
"note": "Extra packing material"
}
],
"reference_id": "1234567890",
"display_id": "1234567890",
"payment_term": "Payment Term",
"shipping_method": "Shipping Method",
"freight_term": "Freight Term",
"amount": 100,
"amount_paid": 100,
"discount_value": 10,
"tax_value": 10,
"shipping_charge": 10,
"shipment_date": "2025-01-01T00:00:00Z",
"due_date": "2025-01-01T00:00:00Z",
"payment_method": "On Account",
"payment_method_id": "1234567890",
"customer_note": "Customer Notes",
"internal_note": "Internal Notes",
"status": "draft",
"source": "high-point",
"po_number": "<string>",
"billing_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"shipping_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"primary_contact": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@example.com",
"phone": "+14155552671",
"designation": "Sales Manager",
"reference_id": "12345678-90ab-cdef-1234-567890abcdef",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"attributes": [
{
"name": "1234567890",
"value": "red"
}
],
"additional_charges": [
{
"name": "<string>",
"amount": 123
}
],
"entity_source": "openapi"
}
'import requests
url = "https://api.wizcommerce.com/v2/orders"
payload = {
"customer_id": "12345678-90ab-cdef-1234-567890abcdef",
"payment_status": "PAID",
"fulfillment_status": "PARTIALLY_DELIVERED",
"created_at": "2025-01-01T00:00:00Z",
"updated_at": "2025-01-01T00:00:00Z",
"line_items": [
{
"sku": "RUG14754",
"quantity": 10,
"shipped_quantity": 0,
"invoiced_quantity": 0,
"cancelled_quantity": 0,
"picked_quantity": 0,
"unit_price": 100,
"discount": 0,
"discount_type": "percentage",
"is_adhoc": False,
"note": "Extra packing material"
}
],
"reference_id": "1234567890",
"display_id": "1234567890",
"payment_term": "Payment Term",
"shipping_method": "Shipping Method",
"freight_term": "Freight Term",
"amount": 100,
"amount_paid": 100,
"discount_value": 10,
"tax_value": 10,
"shipping_charge": 10,
"shipment_date": "2025-01-01T00:00:00Z",
"due_date": "2025-01-01T00:00:00Z",
"payment_method": "On Account",
"payment_method_id": "1234567890",
"customer_note": "Customer Notes",
"internal_note": "Internal Notes",
"status": "draft",
"source": "high-point",
"po_number": "<string>",
"billing_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"shipping_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"primary_contact": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@example.com",
"phone": "+14155552671",
"designation": "Sales Manager",
"reference_id": "12345678-90ab-cdef-1234-567890abcdef",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"attributes": [
{
"name": "1234567890",
"value": "red"
}
],
"additional_charges": [
{
"name": "<string>",
"amount": 123
}
],
"entity_source": "openapi"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
customer_id: '12345678-90ab-cdef-1234-567890abcdef',
payment_status: 'PAID',
fulfillment_status: 'PARTIALLY_DELIVERED',
created_at: '2025-01-01T00:00:00Z',
updated_at: '2025-01-01T00:00:00Z',
line_items: [
{
sku: 'RUG14754',
quantity: 10,
shipped_quantity: 0,
invoiced_quantity: 0,
cancelled_quantity: 0,
picked_quantity: 0,
unit_price: 100,
discount: 0,
discount_type: 'percentage',
is_adhoc: false,
note: 'Extra packing material'
}
],
reference_id: '1234567890',
display_id: '1234567890',
payment_term: 'Payment Term',
shipping_method: 'Shipping Method',
freight_term: 'Freight Term',
amount: 100,
amount_paid: 100,
discount_value: 10,
tax_value: 10,
shipping_charge: 10,
shipment_date: '2025-01-01T00:00:00Z',
due_date: '2025-01-01T00:00:00Z',
payment_method: 'On Account',
payment_method_id: '1234567890',
customer_note: 'Customer Notes',
internal_note: 'Internal Notes',
status: 'draft',
source: 'high-point',
po_number: '<string>',
billing_address: {
id: '12345678-90ab-cdef-1234-567890abcdef',
first_name: 'John',
last_name: 'Doe',
phone: '+14155552671',
email: 'john.doe@example.com',
address_line_1: '123 Main St',
address_line_2: 'Apt 101',
city: 'Anytown',
state: 'CA',
country: 'US',
zip_code: '12345',
reference_id: 'REF_1234567890',
attributes: [{name: '1234567890', value: 'red'}]
},
shipping_address: {
id: '12345678-90ab-cdef-1234-567890abcdef',
first_name: 'John',
last_name: 'Doe',
phone: '+14155552671',
email: 'john.doe@example.com',
address_line_1: '123 Main St',
address_line_2: 'Apt 101',
city: 'Anytown',
state: 'CA',
country: 'US',
zip_code: '12345',
reference_id: 'REF_1234567890',
attributes: [{name: '1234567890', value: 'red'}]
},
primary_contact: {
id: '12345678-90ab-cdef-1234-567890abcdef',
first_name: 'John',
last_name: 'Doe',
email: 'john.doe@example.com',
phone: '+14155552671',
designation: 'Sales Manager',
reference_id: '12345678-90ab-cdef-1234-567890abcdef',
attributes: [{name: '1234567890', value: 'red'}]
},
attributes: [{name: '1234567890', value: 'red'}],
additional_charges: [{name: '<string>', amount: 123}],
entity_source: 'openapi'
})
};
fetch('https://api.wizcommerce.com/v2/orders', 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.wizcommerce.com/v2/orders",
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([
'customer_id' => '12345678-90ab-cdef-1234-567890abcdef',
'payment_status' => 'PAID',
'fulfillment_status' => 'PARTIALLY_DELIVERED',
'created_at' => '2025-01-01T00:00:00Z',
'updated_at' => '2025-01-01T00:00:00Z',
'line_items' => [
[
'sku' => 'RUG14754',
'quantity' => 10,
'shipped_quantity' => 0,
'invoiced_quantity' => 0,
'cancelled_quantity' => 0,
'picked_quantity' => 0,
'unit_price' => 100,
'discount' => 0,
'discount_type' => 'percentage',
'is_adhoc' => false,
'note' => 'Extra packing material'
]
],
'reference_id' => '1234567890',
'display_id' => '1234567890',
'payment_term' => 'Payment Term',
'shipping_method' => 'Shipping Method',
'freight_term' => 'Freight Term',
'amount' => 100,
'amount_paid' => 100,
'discount_value' => 10,
'tax_value' => 10,
'shipping_charge' => 10,
'shipment_date' => '2025-01-01T00:00:00Z',
'due_date' => '2025-01-01T00:00:00Z',
'payment_method' => 'On Account',
'payment_method_id' => '1234567890',
'customer_note' => 'Customer Notes',
'internal_note' => 'Internal Notes',
'status' => 'draft',
'source' => 'high-point',
'po_number' => '<string>',
'billing_address' => [
'id' => '12345678-90ab-cdef-1234-567890abcdef',
'first_name' => 'John',
'last_name' => 'Doe',
'phone' => '+14155552671',
'email' => 'john.doe@example.com',
'address_line_1' => '123 Main St',
'address_line_2' => 'Apt 101',
'city' => 'Anytown',
'state' => 'CA',
'country' => 'US',
'zip_code' => '12345',
'reference_id' => 'REF_1234567890',
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
]
],
'shipping_address' => [
'id' => '12345678-90ab-cdef-1234-567890abcdef',
'first_name' => 'John',
'last_name' => 'Doe',
'phone' => '+14155552671',
'email' => 'john.doe@example.com',
'address_line_1' => '123 Main St',
'address_line_2' => 'Apt 101',
'city' => 'Anytown',
'state' => 'CA',
'country' => 'US',
'zip_code' => '12345',
'reference_id' => 'REF_1234567890',
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
]
],
'primary_contact' => [
'id' => '12345678-90ab-cdef-1234-567890abcdef',
'first_name' => 'John',
'last_name' => 'Doe',
'email' => 'john.doe@example.com',
'phone' => '+14155552671',
'designation' => 'Sales Manager',
'reference_id' => '12345678-90ab-cdef-1234-567890abcdef',
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
]
],
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
],
'additional_charges' => [
[
'name' => '<string>',
'amount' => 123
]
],
'entity_source' => 'openapi'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$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.wizcommerce.com/v2/orders"
payload := strings.NewReader("{\n \"customer_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"payment_status\": \"PAID\",\n \"fulfillment_status\": \"PARTIALLY_DELIVERED\",\n \"created_at\": \"2025-01-01T00:00:00Z\",\n \"updated_at\": \"2025-01-01T00:00:00Z\",\n \"line_items\": [\n {\n \"sku\": \"RUG14754\",\n \"quantity\": 10,\n \"shipped_quantity\": 0,\n \"invoiced_quantity\": 0,\n \"cancelled_quantity\": 0,\n \"picked_quantity\": 0,\n \"unit_price\": 100,\n \"discount\": 0,\n \"discount_type\": \"percentage\",\n \"is_adhoc\": false,\n \"note\": \"Extra packing material\"\n }\n ],\n \"reference_id\": \"1234567890\",\n \"display_id\": \"1234567890\",\n \"payment_term\": \"Payment Term\",\n \"shipping_method\": \"Shipping Method\",\n \"freight_term\": \"Freight Term\",\n \"amount\": 100,\n \"amount_paid\": 100,\n \"discount_value\": 10,\n \"tax_value\": 10,\n \"shipping_charge\": 10,\n \"shipment_date\": \"2025-01-01T00:00:00Z\",\n \"due_date\": \"2025-01-01T00:00:00Z\",\n \"payment_method\": \"On Account\",\n \"payment_method_id\": \"1234567890\",\n \"customer_note\": \"Customer Notes\",\n \"internal_note\": \"Internal Notes\",\n \"status\": \"draft\",\n \"source\": \"high-point\",\n \"po_number\": \"<string>\",\n \"billing_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"shipping_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"primary_contact\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"email\": \"john.doe@example.com\",\n \"phone\": \"+14155552671\",\n \"designation\": \"Sales Manager\",\n \"reference_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ],\n \"additional_charges\": [\n {\n \"name\": \"<string>\",\n \"amount\": 123\n }\n ],\n \"entity_source\": \"openapi\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.wizcommerce.com/v2/orders")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"customer_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"payment_status\": \"PAID\",\n \"fulfillment_status\": \"PARTIALLY_DELIVERED\",\n \"created_at\": \"2025-01-01T00:00:00Z\",\n \"updated_at\": \"2025-01-01T00:00:00Z\",\n \"line_items\": [\n {\n \"sku\": \"RUG14754\",\n \"quantity\": 10,\n \"shipped_quantity\": 0,\n \"invoiced_quantity\": 0,\n \"cancelled_quantity\": 0,\n \"picked_quantity\": 0,\n \"unit_price\": 100,\n \"discount\": 0,\n \"discount_type\": \"percentage\",\n \"is_adhoc\": false,\n \"note\": \"Extra packing material\"\n }\n ],\n \"reference_id\": \"1234567890\",\n \"display_id\": \"1234567890\",\n \"payment_term\": \"Payment Term\",\n \"shipping_method\": \"Shipping Method\",\n \"freight_term\": \"Freight Term\",\n \"amount\": 100,\n \"amount_paid\": 100,\n \"discount_value\": 10,\n \"tax_value\": 10,\n \"shipping_charge\": 10,\n \"shipment_date\": \"2025-01-01T00:00:00Z\",\n \"due_date\": \"2025-01-01T00:00:00Z\",\n \"payment_method\": \"On Account\",\n \"payment_method_id\": \"1234567890\",\n \"customer_note\": \"Customer Notes\",\n \"internal_note\": \"Internal Notes\",\n \"status\": \"draft\",\n \"source\": \"high-point\",\n \"po_number\": \"<string>\",\n \"billing_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"shipping_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"primary_contact\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"email\": \"john.doe@example.com\",\n \"phone\": \"+14155552671\",\n \"designation\": \"Sales Manager\",\n \"reference_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ],\n \"additional_charges\": [\n {\n \"name\": \"<string>\",\n \"amount\": 123\n }\n ],\n \"entity_source\": \"openapi\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wizcommerce.com/v2/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"customer_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"payment_status\": \"PAID\",\n \"fulfillment_status\": \"PARTIALLY_DELIVERED\",\n \"created_at\": \"2025-01-01T00:00:00Z\",\n \"updated_at\": \"2025-01-01T00:00:00Z\",\n \"line_items\": [\n {\n \"sku\": \"RUG14754\",\n \"quantity\": 10,\n \"shipped_quantity\": 0,\n \"invoiced_quantity\": 0,\n \"cancelled_quantity\": 0,\n \"picked_quantity\": 0,\n \"unit_price\": 100,\n \"discount\": 0,\n \"discount_type\": \"percentage\",\n \"is_adhoc\": false,\n \"note\": \"Extra packing material\"\n }\n ],\n \"reference_id\": \"1234567890\",\n \"display_id\": \"1234567890\",\n \"payment_term\": \"Payment Term\",\n \"shipping_method\": \"Shipping Method\",\n \"freight_term\": \"Freight Term\",\n \"amount\": 100,\n \"amount_paid\": 100,\n \"discount_value\": 10,\n \"tax_value\": 10,\n \"shipping_charge\": 10,\n \"shipment_date\": \"2025-01-01T00:00:00Z\",\n \"due_date\": \"2025-01-01T00:00:00Z\",\n \"payment_method\": \"On Account\",\n \"payment_method_id\": \"1234567890\",\n \"customer_note\": \"Customer Notes\",\n \"internal_note\": \"Internal Notes\",\n \"status\": \"draft\",\n \"source\": \"high-point\",\n \"po_number\": \"<string>\",\n \"billing_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"shipping_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"primary_contact\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"email\": \"john.doe@example.com\",\n \"phone\": \"+14155552671\",\n \"designation\": \"Sales Manager\",\n \"reference_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ],\n \"additional_charges\": [\n {\n \"name\": \"<string>\",\n \"amount\": 123\n }\n ],\n \"entity_source\": \"openapi\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "01f5d171-d3e3-4b2b-bd57-0727194b5bed",
"reference_id": "1234567890",
"display_id": "WC_1234567890",
"customer_id": "1234567890",
"type": "order",
"status": "active",
"amount": 100,
"amount_paid": 100,
"payment_status": "PAID",
"fulfillment_status": "PARTIALLY_DELIVERED UNFULFILLED PARTIALLY_FULFILLED FULFILLED IN_PROGRESS DELIVERED",
"payment_method_id": "1234567890",
"payment_method": "payment_method",
"payment_term": "payment_term",
"shipping_method": "shipping_method",
"freight_term": "freight_term",
"internal_note": "internal_note",
"customer_note": "customer_note",
"shipment_date": "2021-01-01T00:00:00Z",
"due_date": "2021-01-01T00:00:00Z",
"source": "cart",
"price_list_id": "1234567890",
"primary_contact": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@example.com",
"phone": "+14155552671",
"designation": "Sales Manager",
"reference_id": "12345678-90ab-cdef-1234-567890abcdef"
},
"shipping_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"state_info": {
"code": "US-CA",
"short_code": "CA",
"name": "California"
},
"country": "US",
"zip_code": "12345",
"reference_id": "1234567890"
},
"billing_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"state_info": {
"code": "US-CA",
"short_code": "CA",
"name": "California"
},
"country": "US",
"zip_code": "12345",
"reference_id": "1234567890"
},
"po_number": "<string>",
"created_at": "2021-01-01T00:00:00Z",
"updated_at": "2021-01-01T00:00:00Z"
}
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}Create order
Create order
curl --request POST \
--url https://api.wizcommerce.com/v2/orders \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"customer_id": "12345678-90ab-cdef-1234-567890abcdef",
"payment_status": "PAID",
"fulfillment_status": "PARTIALLY_DELIVERED",
"created_at": "2025-01-01T00:00:00Z",
"updated_at": "2025-01-01T00:00:00Z",
"line_items": [
{
"sku": "RUG14754",
"quantity": 10,
"shipped_quantity": 0,
"invoiced_quantity": 0,
"cancelled_quantity": 0,
"picked_quantity": 0,
"unit_price": 100,
"discount": 0,
"discount_type": "percentage",
"is_adhoc": false,
"note": "Extra packing material"
}
],
"reference_id": "1234567890",
"display_id": "1234567890",
"payment_term": "Payment Term",
"shipping_method": "Shipping Method",
"freight_term": "Freight Term",
"amount": 100,
"amount_paid": 100,
"discount_value": 10,
"tax_value": 10,
"shipping_charge": 10,
"shipment_date": "2025-01-01T00:00:00Z",
"due_date": "2025-01-01T00:00:00Z",
"payment_method": "On Account",
"payment_method_id": "1234567890",
"customer_note": "Customer Notes",
"internal_note": "Internal Notes",
"status": "draft",
"source": "high-point",
"po_number": "<string>",
"billing_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"shipping_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"primary_contact": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@example.com",
"phone": "+14155552671",
"designation": "Sales Manager",
"reference_id": "12345678-90ab-cdef-1234-567890abcdef",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"attributes": [
{
"name": "1234567890",
"value": "red"
}
],
"additional_charges": [
{
"name": "<string>",
"amount": 123
}
],
"entity_source": "openapi"
}
'import requests
url = "https://api.wizcommerce.com/v2/orders"
payload = {
"customer_id": "12345678-90ab-cdef-1234-567890abcdef",
"payment_status": "PAID",
"fulfillment_status": "PARTIALLY_DELIVERED",
"created_at": "2025-01-01T00:00:00Z",
"updated_at": "2025-01-01T00:00:00Z",
"line_items": [
{
"sku": "RUG14754",
"quantity": 10,
"shipped_quantity": 0,
"invoiced_quantity": 0,
"cancelled_quantity": 0,
"picked_quantity": 0,
"unit_price": 100,
"discount": 0,
"discount_type": "percentage",
"is_adhoc": False,
"note": "Extra packing material"
}
],
"reference_id": "1234567890",
"display_id": "1234567890",
"payment_term": "Payment Term",
"shipping_method": "Shipping Method",
"freight_term": "Freight Term",
"amount": 100,
"amount_paid": 100,
"discount_value": 10,
"tax_value": 10,
"shipping_charge": 10,
"shipment_date": "2025-01-01T00:00:00Z",
"due_date": "2025-01-01T00:00:00Z",
"payment_method": "On Account",
"payment_method_id": "1234567890",
"customer_note": "Customer Notes",
"internal_note": "Internal Notes",
"status": "draft",
"source": "high-point",
"po_number": "<string>",
"billing_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"shipping_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"country": "US",
"zip_code": "12345",
"reference_id": "REF_1234567890",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"primary_contact": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@example.com",
"phone": "+14155552671",
"designation": "Sales Manager",
"reference_id": "12345678-90ab-cdef-1234-567890abcdef",
"attributes": [
{
"name": "1234567890",
"value": "red"
}
]
},
"attributes": [
{
"name": "1234567890",
"value": "red"
}
],
"additional_charges": [
{
"name": "<string>",
"amount": 123
}
],
"entity_source": "openapi"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
customer_id: '12345678-90ab-cdef-1234-567890abcdef',
payment_status: 'PAID',
fulfillment_status: 'PARTIALLY_DELIVERED',
created_at: '2025-01-01T00:00:00Z',
updated_at: '2025-01-01T00:00:00Z',
line_items: [
{
sku: 'RUG14754',
quantity: 10,
shipped_quantity: 0,
invoiced_quantity: 0,
cancelled_quantity: 0,
picked_quantity: 0,
unit_price: 100,
discount: 0,
discount_type: 'percentage',
is_adhoc: false,
note: 'Extra packing material'
}
],
reference_id: '1234567890',
display_id: '1234567890',
payment_term: 'Payment Term',
shipping_method: 'Shipping Method',
freight_term: 'Freight Term',
amount: 100,
amount_paid: 100,
discount_value: 10,
tax_value: 10,
shipping_charge: 10,
shipment_date: '2025-01-01T00:00:00Z',
due_date: '2025-01-01T00:00:00Z',
payment_method: 'On Account',
payment_method_id: '1234567890',
customer_note: 'Customer Notes',
internal_note: 'Internal Notes',
status: 'draft',
source: 'high-point',
po_number: '<string>',
billing_address: {
id: '12345678-90ab-cdef-1234-567890abcdef',
first_name: 'John',
last_name: 'Doe',
phone: '+14155552671',
email: 'john.doe@example.com',
address_line_1: '123 Main St',
address_line_2: 'Apt 101',
city: 'Anytown',
state: 'CA',
country: 'US',
zip_code: '12345',
reference_id: 'REF_1234567890',
attributes: [{name: '1234567890', value: 'red'}]
},
shipping_address: {
id: '12345678-90ab-cdef-1234-567890abcdef',
first_name: 'John',
last_name: 'Doe',
phone: '+14155552671',
email: 'john.doe@example.com',
address_line_1: '123 Main St',
address_line_2: 'Apt 101',
city: 'Anytown',
state: 'CA',
country: 'US',
zip_code: '12345',
reference_id: 'REF_1234567890',
attributes: [{name: '1234567890', value: 'red'}]
},
primary_contact: {
id: '12345678-90ab-cdef-1234-567890abcdef',
first_name: 'John',
last_name: 'Doe',
email: 'john.doe@example.com',
phone: '+14155552671',
designation: 'Sales Manager',
reference_id: '12345678-90ab-cdef-1234-567890abcdef',
attributes: [{name: '1234567890', value: 'red'}]
},
attributes: [{name: '1234567890', value: 'red'}],
additional_charges: [{name: '<string>', amount: 123}],
entity_source: 'openapi'
})
};
fetch('https://api.wizcommerce.com/v2/orders', 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.wizcommerce.com/v2/orders",
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([
'customer_id' => '12345678-90ab-cdef-1234-567890abcdef',
'payment_status' => 'PAID',
'fulfillment_status' => 'PARTIALLY_DELIVERED',
'created_at' => '2025-01-01T00:00:00Z',
'updated_at' => '2025-01-01T00:00:00Z',
'line_items' => [
[
'sku' => 'RUG14754',
'quantity' => 10,
'shipped_quantity' => 0,
'invoiced_quantity' => 0,
'cancelled_quantity' => 0,
'picked_quantity' => 0,
'unit_price' => 100,
'discount' => 0,
'discount_type' => 'percentage',
'is_adhoc' => false,
'note' => 'Extra packing material'
]
],
'reference_id' => '1234567890',
'display_id' => '1234567890',
'payment_term' => 'Payment Term',
'shipping_method' => 'Shipping Method',
'freight_term' => 'Freight Term',
'amount' => 100,
'amount_paid' => 100,
'discount_value' => 10,
'tax_value' => 10,
'shipping_charge' => 10,
'shipment_date' => '2025-01-01T00:00:00Z',
'due_date' => '2025-01-01T00:00:00Z',
'payment_method' => 'On Account',
'payment_method_id' => '1234567890',
'customer_note' => 'Customer Notes',
'internal_note' => 'Internal Notes',
'status' => 'draft',
'source' => 'high-point',
'po_number' => '<string>',
'billing_address' => [
'id' => '12345678-90ab-cdef-1234-567890abcdef',
'first_name' => 'John',
'last_name' => 'Doe',
'phone' => '+14155552671',
'email' => 'john.doe@example.com',
'address_line_1' => '123 Main St',
'address_line_2' => 'Apt 101',
'city' => 'Anytown',
'state' => 'CA',
'country' => 'US',
'zip_code' => '12345',
'reference_id' => 'REF_1234567890',
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
]
],
'shipping_address' => [
'id' => '12345678-90ab-cdef-1234-567890abcdef',
'first_name' => 'John',
'last_name' => 'Doe',
'phone' => '+14155552671',
'email' => 'john.doe@example.com',
'address_line_1' => '123 Main St',
'address_line_2' => 'Apt 101',
'city' => 'Anytown',
'state' => 'CA',
'country' => 'US',
'zip_code' => '12345',
'reference_id' => 'REF_1234567890',
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
]
],
'primary_contact' => [
'id' => '12345678-90ab-cdef-1234-567890abcdef',
'first_name' => 'John',
'last_name' => 'Doe',
'email' => 'john.doe@example.com',
'phone' => '+14155552671',
'designation' => 'Sales Manager',
'reference_id' => '12345678-90ab-cdef-1234-567890abcdef',
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
]
],
'attributes' => [
[
'name' => '1234567890',
'value' => 'red'
]
],
'additional_charges' => [
[
'name' => '<string>',
'amount' => 123
]
],
'entity_source' => 'openapi'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$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.wizcommerce.com/v2/orders"
payload := strings.NewReader("{\n \"customer_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"payment_status\": \"PAID\",\n \"fulfillment_status\": \"PARTIALLY_DELIVERED\",\n \"created_at\": \"2025-01-01T00:00:00Z\",\n \"updated_at\": \"2025-01-01T00:00:00Z\",\n \"line_items\": [\n {\n \"sku\": \"RUG14754\",\n \"quantity\": 10,\n \"shipped_quantity\": 0,\n \"invoiced_quantity\": 0,\n \"cancelled_quantity\": 0,\n \"picked_quantity\": 0,\n \"unit_price\": 100,\n \"discount\": 0,\n \"discount_type\": \"percentage\",\n \"is_adhoc\": false,\n \"note\": \"Extra packing material\"\n }\n ],\n \"reference_id\": \"1234567890\",\n \"display_id\": \"1234567890\",\n \"payment_term\": \"Payment Term\",\n \"shipping_method\": \"Shipping Method\",\n \"freight_term\": \"Freight Term\",\n \"amount\": 100,\n \"amount_paid\": 100,\n \"discount_value\": 10,\n \"tax_value\": 10,\n \"shipping_charge\": 10,\n \"shipment_date\": \"2025-01-01T00:00:00Z\",\n \"due_date\": \"2025-01-01T00:00:00Z\",\n \"payment_method\": \"On Account\",\n \"payment_method_id\": \"1234567890\",\n \"customer_note\": \"Customer Notes\",\n \"internal_note\": \"Internal Notes\",\n \"status\": \"draft\",\n \"source\": \"high-point\",\n \"po_number\": \"<string>\",\n \"billing_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"shipping_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"primary_contact\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"email\": \"john.doe@example.com\",\n \"phone\": \"+14155552671\",\n \"designation\": \"Sales Manager\",\n \"reference_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ],\n \"additional_charges\": [\n {\n \"name\": \"<string>\",\n \"amount\": 123\n }\n ],\n \"entity_source\": \"openapi\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.wizcommerce.com/v2/orders")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"customer_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"payment_status\": \"PAID\",\n \"fulfillment_status\": \"PARTIALLY_DELIVERED\",\n \"created_at\": \"2025-01-01T00:00:00Z\",\n \"updated_at\": \"2025-01-01T00:00:00Z\",\n \"line_items\": [\n {\n \"sku\": \"RUG14754\",\n \"quantity\": 10,\n \"shipped_quantity\": 0,\n \"invoiced_quantity\": 0,\n \"cancelled_quantity\": 0,\n \"picked_quantity\": 0,\n \"unit_price\": 100,\n \"discount\": 0,\n \"discount_type\": \"percentage\",\n \"is_adhoc\": false,\n \"note\": \"Extra packing material\"\n }\n ],\n \"reference_id\": \"1234567890\",\n \"display_id\": \"1234567890\",\n \"payment_term\": \"Payment Term\",\n \"shipping_method\": \"Shipping Method\",\n \"freight_term\": \"Freight Term\",\n \"amount\": 100,\n \"amount_paid\": 100,\n \"discount_value\": 10,\n \"tax_value\": 10,\n \"shipping_charge\": 10,\n \"shipment_date\": \"2025-01-01T00:00:00Z\",\n \"due_date\": \"2025-01-01T00:00:00Z\",\n \"payment_method\": \"On Account\",\n \"payment_method_id\": \"1234567890\",\n \"customer_note\": \"Customer Notes\",\n \"internal_note\": \"Internal Notes\",\n \"status\": \"draft\",\n \"source\": \"high-point\",\n \"po_number\": \"<string>\",\n \"billing_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"shipping_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"primary_contact\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"email\": \"john.doe@example.com\",\n \"phone\": \"+14155552671\",\n \"designation\": \"Sales Manager\",\n \"reference_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ],\n \"additional_charges\": [\n {\n \"name\": \"<string>\",\n \"amount\": 123\n }\n ],\n \"entity_source\": \"openapi\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wizcommerce.com/v2/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"customer_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"payment_status\": \"PAID\",\n \"fulfillment_status\": \"PARTIALLY_DELIVERED\",\n \"created_at\": \"2025-01-01T00:00:00Z\",\n \"updated_at\": \"2025-01-01T00:00:00Z\",\n \"line_items\": [\n {\n \"sku\": \"RUG14754\",\n \"quantity\": 10,\n \"shipped_quantity\": 0,\n \"invoiced_quantity\": 0,\n \"cancelled_quantity\": 0,\n \"picked_quantity\": 0,\n \"unit_price\": 100,\n \"discount\": 0,\n \"discount_type\": \"percentage\",\n \"is_adhoc\": false,\n \"note\": \"Extra packing material\"\n }\n ],\n \"reference_id\": \"1234567890\",\n \"display_id\": \"1234567890\",\n \"payment_term\": \"Payment Term\",\n \"shipping_method\": \"Shipping Method\",\n \"freight_term\": \"Freight Term\",\n \"amount\": 100,\n \"amount_paid\": 100,\n \"discount_value\": 10,\n \"tax_value\": 10,\n \"shipping_charge\": 10,\n \"shipment_date\": \"2025-01-01T00:00:00Z\",\n \"due_date\": \"2025-01-01T00:00:00Z\",\n \"payment_method\": \"On Account\",\n \"payment_method_id\": \"1234567890\",\n \"customer_note\": \"Customer Notes\",\n \"internal_note\": \"Internal Notes\",\n \"status\": \"draft\",\n \"source\": \"high-point\",\n \"po_number\": \"<string>\",\n \"billing_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"shipping_address\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"phone\": \"+14155552671\",\n \"email\": \"john.doe@example.com\",\n \"address_line_1\": \"123 Main St\",\n \"address_line_2\": \"Apt 101\",\n \"city\": \"Anytown\",\n \"state\": \"CA\",\n \"country\": \"US\",\n \"zip_code\": \"12345\",\n \"reference_id\": \"REF_1234567890\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"primary_contact\": {\n \"id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"first_name\": \"John\",\n \"last_name\": \"Doe\",\n \"email\": \"john.doe@example.com\",\n \"phone\": \"+14155552671\",\n \"designation\": \"Sales Manager\",\n \"reference_id\": \"12345678-90ab-cdef-1234-567890abcdef\",\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ]\n },\n \"attributes\": [\n {\n \"name\": \"1234567890\",\n \"value\": \"red\"\n }\n ],\n \"additional_charges\": [\n {\n \"name\": \"<string>\",\n \"amount\": 123\n }\n ],\n \"entity_source\": \"openapi\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "01f5d171-d3e3-4b2b-bd57-0727194b5bed",
"reference_id": "1234567890",
"display_id": "WC_1234567890",
"customer_id": "1234567890",
"type": "order",
"status": "active",
"amount": 100,
"amount_paid": 100,
"payment_status": "PAID",
"fulfillment_status": "PARTIALLY_DELIVERED UNFULFILLED PARTIALLY_FULFILLED FULFILLED IN_PROGRESS DELIVERED",
"payment_method_id": "1234567890",
"payment_method": "payment_method",
"payment_term": "payment_term",
"shipping_method": "shipping_method",
"freight_term": "freight_term",
"internal_note": "internal_note",
"customer_note": "customer_note",
"shipment_date": "2021-01-01T00:00:00Z",
"due_date": "2021-01-01T00:00:00Z",
"source": "cart",
"price_list_id": "1234567890",
"primary_contact": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@example.com",
"phone": "+14155552671",
"designation": "Sales Manager",
"reference_id": "12345678-90ab-cdef-1234-567890abcdef"
},
"shipping_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"state_info": {
"code": "US-CA",
"short_code": "CA",
"name": "California"
},
"country": "US",
"zip_code": "12345",
"reference_id": "1234567890"
},
"billing_address": {
"id": "12345678-90ab-cdef-1234-567890abcdef",
"first_name": "John",
"last_name": "Doe",
"phone": "+14155552671",
"email": "john.doe@example.com",
"address_line_1": "123 Main St",
"address_line_2": "Apt 101",
"city": "Anytown",
"state": "CA",
"state_info": {
"code": "US-CA",
"short_code": "CA",
"name": "California"
},
"country": "US",
"zip_code": "12345",
"reference_id": "1234567890"
},
"po_number": "<string>",
"created_at": "2021-01-01T00:00:00Z",
"updated_at": "2021-01-01T00:00:00Z"
}
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}{
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"reason": "<string>"
}
]
}Authorizations
API Key for authentication
Body
request
"12345678-90ab-cdef-1234-567890abcdef"
PAID, PENDING, PARTIALLY_PAID, REFUNDED, OVERPAID, VOIDED "PAID"
PARTIALLY_DELIVERED, UNFULFILLED, PARTIALLY_FULFILLED, FULFILLED, IN_PROGRESS, DELIVERED "PARTIALLY_DELIVERED"
"2025-01-01T00:00:00Z"
Updated at must be later than the order creation date
"2025-01-01T00:00:00Z"
Show child attributes
Show child attributes
255"1234567890"
This is the display ID of the order, it is generated by the system if not provided.
255"1234567890"
255"Payment Term"
255"Shipping Method"
255"Freight Term"
This is total amount of the order before all discounts, taxes, shipping charges, etc. are applied.
100
100
Discount offered on the order, always amount of actual discount offered. e.g. if discount is 10% off, then discount value is 10.00 for 100.00 amount
10
Tax value on the order, always amount of actual tax offered. e.g. if tax is 10% of amount, then tax value is 10.00 for 100.00 amount
10
Shipping charge on the order, always amount of actual shipping charge offered. e.g. if shipping charge is $10.00, then shipping charge is $10.00
10
Shipment date must be later than the order creation date
"2025-01-01T00:00:00Z"
Due date must be later than the order creation date, send null if due date is not applicable
"2025-01-01T00:00:00Z"
255"On Account"
255"1234567890"
"Customer Notes"
255"Internal Notes"
Status of the order, can be draft, confirmed, if not provided then it will be confirmed
draft, confirmed "draft"
Source of the order, if not provided then it will be openapi
"high-point"
Show child attributes
Show child attributes
255Show child attributes
Show child attributes
Billing address is stored and persisted in the order. It can be sent as custom address without ID which can be stored as temporary address to be used for billing only for this order
Show child attributes
Show child attributes
Shipping address is stored and persisted in the order. It can be sent as custom address without ID which can be stored as temporary address to be used for shipping only for this order
Show child attributes
Show child attributes
Primary contact is stored and persisted in the order. It can be sent as custom contact without ID which can be stored as temporary contact to be used for primary contact only for this order
Show child attributes
Show child attributes
Show child attributes
Show child attributes
These are additional charges on the order apart from shipping, tax, discount, etc. It will be add-on to the total amount of the order.
Show child attributes
Show child attributes
Source of the entity, if not provided then it will be openapi
"openapi"
Response
Created
Show child attributes
Show child attributes
Was this page helpful?
