API Docs
/
No Results Found
Sales Orders

Sales Orders

A sales order is a financial document that confirms an impending sale. It details the exact quantity, price and delivery details of the products or services being sold. Perform the simple operations mentioned below to create and manage your Sales Orders.

Attribute

salesorder_id
long
Unique ID generated by the server for the Sales Order. This is used as identifier.
salesorder_number
string
The Sales Order number. This is unique for each sales order.
date
string
The date for the Sales Order.
status
string
The current status of the Sales Order.
shipment_date
string
Shipment date of the Sales Order.
reference_number
string
Reference number of the Sales Order
customer_id
long
Unique ID generated for the customer. This is used as an identifier.
customer_name
string
Name of the customer.
contact_persons
array
List of contact persons details.
Show Sub-Attributes arrow
contact_person_id
long
Unique ID generated by the server for the contact person
currency_id
long
Unique ID generated by the server for the currency. This is used as an identifier.
currency_code
string
Currency code.
currency_symbol
string
The symbol for the selected currency.
exchange_rate
double
Exchange rate of the currency, with respect to the base currency.
discount_amount
double
Discount to be applied on the Sales Order.
discount
double
The percentage of Discount applied.
is_discount_before_tax
boolean
Used to check whether the discount is applied before tax or after tax.
discount_type
string
Type of discount. Allowed values are entity_level,item_level. For entity_level type, discount is applied at entity level and the node discount resides outside the line_items node.For item_level type, discount is applied at item level and the node discount resides inside each line_item under the line_items node
estimate_id
long
Unique ID generated by the server from the Estimate created in Zoho Books. This is used as an identifier.
delivery_method
string
Delivery method of the shipment.
delivery_method_id
long
Unique ID generated by the server for the delivery method. This is used as an identifier.
line_items
array
A sales order can contain multiple line items. Each line item contains item_id,name,description,rate,quantity,unit,tax_id,tax_name,tax_type,tax_percentage,item_total.
Show Sub-Attributes arrow
item_id
long
Unique ID generated by the server for the item. This is used as an identifier.
line_item_id
long
Unique ID generated by the server for each line item. This is used as an identifier.
name
string
Name of the line item.
description
string
Description of the line item.
item_order
integer
The order of the line items, starts from 0 by default.
bcy_rate
double
Item rate in the organization's base currency.
rate
double
Rate / Selling Price of the line item.
quantity
double
Quantity of the line item.
quantity_invoiced
double
Quantity invoiced of the line item.
quantity_packed
double
Quantity packed of the line item.
quantity_shipped
double
Quantity shipped of the line item.
unit
string
Unit of line item.
tax_id
long
Unique ID generated by the server for the tax. This is used as an identifier.
tds_tax_id
string
🇲🇽 Mexico
only
ID of the TDS tax or TDS tax group applied
tax_name
string
Name of the tax applied on the line item.
tax_type
string
Denotes the type of the tax. This can either be a single tax or a tax group.
tax_percentage
double
Percentage of the tax.
item_total
double
Total of line item.
is_invoiced
boolean
Checks whether the Sales Order has been invoiced or not.
image_id
double
Unique ID generated by the server for the item image. This is used an identifier.
image_name
string
Name of the image of the line item.
image_type
string
The type (file format) of the image.
warehouse_id
long
Unique ID generated by the server for the ware houses
hsn_or_sac
string
🇮🇳 India
only
Add HSN/SAC code for your goods/services
sat_item_key_code
string
🇲🇽 Mexico
only
Add SAT Item Key Code for your goods/services. Download the CFDI Catalogs.
unitkey_code
string
🇲🇽 Mexico
only
Add SAT Unit Key Code for your goods/services. Download the CFDI Catalogs.
shipping_charge
double
Shipping charges that can be applied to the Sales Order.
adjustment
double
Adjustment on the Sales Order's total.
adjustment_description
string
Description for the adjustment.
sub_total
double
Sub total of the Sales Order.
tax_total
double
Tax total of the Sales Order.
total
double
Total amount of the Sales Order.
taxes
array
Number of taxes applied on sales order. Each tax contains: tax_name and tax_amount.
Show Sub-Attributes arrow
tax_name
string
Name of the tax applied on the line item.
tax_amount
double
Amount of the tax.
price_precision
integer
The precision level for the price's decimal point in a Sales Order.
pricebook_id
string
Unique ID generated by the server for the Pricebook. This is used as an identifier.
shipping_address
object
Customer's shipping address. It contains - address, city, state, zip, country and fax.
Show Sub-Attributes arrow
address
string
Name of the street of the customer’s shipping address.
city
string
Name of the city of the customer’s shipping address.
state
string
Name of the state of the customer's shipping address.
zip
string
Zip code of the customer’s shipping address.
country
string
Name of the country of the customer’s shipping address.
fax
string
Fax number of the customer’s shipping address.
billing_address
object
Customer's billing address. It contains - address, city, state, zip, country and fax.
Show Sub-Attributes arrow
address
string
Name of the street of the customer’s shipping address.
city
string
Name of the city of the customer’s shipping address.
state
string
Name of the state of the customer's shipping address.
zip
string
Zip code of the customer’s shipping address.
country
string
Name of the country of the customer’s shipping address.
fax
string
Fax number of the customer’s shipping address.
notes
string
Notes for the Sales Order.
terms
string
Terms for the Sales Order.
template_id
long
Unique ID generated by the server for the Template. This is used as an identifier.
template_name
string
Name of the template used for the Sales Order.
template_type
string
Type of the template.
created_time
string
Time at which the Sales Order was created.
last_modified_time
string
Time at which the sales order details were last modified.
salesperson_id
string
Unique ID generated by the server for the sales person. This is used as an identifier.
salesperson_name
string
Name of the Sales Person.
documents
array
Sales order can have files attached to them. Each attachment has the following attributes can_send_in_mail, file_name, file_type, file_size_formatted, attachment_order, document_id, file_size.
Show Sub-Attributes arrow
can_send_in_mail
boolean
Checks whether the sales order can be sent as a mail or not.
file_name
string
This indicates the name of the file.
file_type
string
This indicates the type of the file.
file_size_formatted
string
This indicates the size of the formatted file.
attachment_order
integer
This indicates the chronological number of the attachment.
document_id
long
Unique ID generated by the server for the document. This is used as an identifier.
file_size
long
this indicates the size of the attached file.
is_pre_gst
boolean
🇮🇳 India
only
Applicable for transactions that fall before july 1, 2017
gst_no
string
🇮🇳 India
only
15 digit GST identification number of the customer.
gst_treatment
string
🇮🇳 India
only
Choose whether the contact is GST registered/unregistered/consumer/overseas. Allowed values are business_gst , business_none , overseas , consumer .
place_of_supply
string
🇮🇳 India
only
Place where the goods/services are supplied to. (If not given, place of contact given for the contact will be taken)

Example

{ "salesorder_id": 4815000000044895, "salesorder_number": "SO-00003", "date": "2015-05-28", "status": "fulfilled", "shipment_date": "2015-06-02", "reference_number": "REF-S-00003", "customer_id": 4815000000044080, "customer_name": "Molly", "contact_persons": [ { "contact_person_id": 4815000000044080 } ], "currency_id": 4815000000000097, "currency_code": "USD", "currency_symbol": "$", "exchange_rate": 1, "discount_amount": 0, "discount": "20.00%", "is_discount_before_tax": true, "discount_type": "entity_level", "estimate_id": 4815000000045091, "delivery_method": "FedEx", "delivery_method_id": 4815000000044822, "line_items": [ { "item_id": 4815000000044100, "line_item_id": 4815000000044897, "name": "Laptop-white/15inch/dell", "description": "Just a sample description.", "item_order": 0, "bcy_rate": 122, "rate": 122, "quantity": 2, "quantity_invoiced": 2, "quantity_packed": 2, "quantity_shipped": 2, "unit": "qty", "tax_id": 4815000000044043, "tds_tax_id": "460000000017098", "tax_name": "Sales Tax", "tax_type": "tax", "tax_percentage": 12, "item_total": 244, "is_invoiced": true, "image_id": 2077500000000002000, "image_name": "dell.jpg", "image_type": "jpg", "warehouse_id": 130426000000664020, "hsn_or_sac": 80540, "sat_item_key_code": 71121206, "unitkey_code": "E48" } ], "shipping_charge": 7, "adjustment": 0, "adjustment_description": "Just an example description.", "sub_total": 244, "tax_total": 29, "total": 350, "taxes": [ { "tax_name": "Sales Tax", "tax_amount": 29.28 } ], "price_precision": 2, "pricebook_id": 4815000000044054, "shipping_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "billing_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "notes": "Sample Note", "terms": "Terms and Conditions", "template_id": 4815000000017003, "template_name": "Standard", "template_type": "standard", "created_time": "2015-05-28T00:00:00.000Z", "last_modified_time": "2015-05-28T00:00:00.000Z", "salesperson_id": 4815000000044762, "salesperson_name": "Lara", "documents": [ { "can_send_in_mail": true, "file_name": "sample.pdf", "file_type": "pdf", "file_size_formatted": "116.8 KB", "attachment_order": 1, "document_id": 16115000000096068, "file_size": 11957 } ], "is_pre_gst": false, "gst_no": "22AAAAA0000A1Z5", "gst_treatment": "business_gst", "place_of_supply": "TN" }

Create a Sales Order

Creates a new Sales Order in Zoho Inventory. Description about extra parameter ignore_auto_number_generation - Ignore auto sales order number generation for this sales order. This mandates the Sales Order number to be entered. Allowed Values true and false.
OAuth Scope : ZohoInventory.salesorders.CREATE

Arguments

customer_id
long
(Required)
Unique ID generated for the customer. This is used as an identifier.
salesorder_number
string
(Required)
The Sales Order number. This is unique for each sales order.
date
string
The date for the Sales Order.
shipment_date
string
Shipment date of the Sales Order.
custom_fields
array
Show Sub-Attributes arrow
custom_field_id
long
index
integer
Index of the custom field
label
string
Label of the Custom Field
value
string
Value of the Custom Field
reference_number
string
Reference number of the Sales Order
line_items
array
(Required)
A sales order can contain multiple line items. Each line item contains item_id,name,description,rate,quantity,unit,tax_id,tax_name,tax_type,tax_percentage,item_total.
Show Sub-Attributes arrow
item_id
long
Unique ID generated by the server for the item. This is used as an identifier.
name
string
Name of the line item.
description
string
Description of the line item.
rate
double
Rate / Selling Price of the line item.
quantity
double
Quantity of the line item.
unit
string
Unit of line item.
tax_id
long
Unique ID generated by the server for the tax. This is used as an identifier.
tds_tax_id
string
🇲🇽 Mexico
only
ID of the TDS tax or TDS tax group applied
tax_name
string
Name of the tax applied on the line item.
tax_type
string
Denotes the type of the tax. This can either be a single tax or a tax group.
tax_percentage
double
Percentage of the tax.
item_total
double
Total of line item.
warehouse_id
long
Unique ID generated by the server for the ware houses
hsn_or_sac
string
🇮🇳 India
only
Add HSN/SAC code for your goods/services
sat_item_key_code
string
🇲🇽 Mexico
only
Add SAT Item Key Code for your goods/services. Download the CFDI Catalogs.
unitkey_code
string
🇲🇽 Mexico
only
Add SAT Unit Key Code for your goods/services. Download the CFDI Catalogs.
notes
string
Notes for the Sales Order.
terms
string
Terms for the Sales Order.
discount
double
The percentage of Discount applied.
is_discount_before_tax
boolean
Used to check whether the discount is applied before tax or after tax.
discount_type
string
Type of discount. Allowed values are entity_level,item_level. For entity_level type, discount is applied at entity level and the node discount resides outside the line_items node.For item_level type, discount is applied at item level and the node discount resides inside each line_item under the line_items node
shipping_charge
double
Shipping charges that can be applied to the Sales Order.
delivery_method
string
Delivery method of the shipment.
adjustment
double
Adjustment on the Sales Order's total.
pricebook_id
string
Unique ID generated by the server for the Pricebook. This is used as an identifier.
salesperson_id
string
Unique ID generated by the server for the sales person. This is used as an identifier.
adjustment_description
string
Description for the adjustment.
is_inclusive_tax
boolean
Used to specify whether the line item rates are inclusive or exclusive of tax.
exchange_rate
double
Exchange rate of the currency, with respect to the base currency.
template_id
long
Unique ID generated by the server for the Template. This is used as an identifier.
documents
array
Sales order can have files attached to them. Each attachment has the following attributes can_send_in_mail, file_name, file_type, file_size_formatted, attachment_order, document_id, file_size.
Show Sub-Attributes arrow
can_send_in_mail
boolean
Checks whether the sales order can be sent as a mail or not.
file_name
string
This indicates the name of the file.
file_type
string
This indicates the type of the file.
file_size_formatted
string
This indicates the size of the formatted file.
attachment_order
integer
This indicates the chronological number of the attachment.
document_id
long
Unique ID generated by the server for the document. This is used as an identifier.
file_size
long
this indicates the size of the attached file.
billing_address_id
long
Unique Id generated by the server for address in contacts page. To add a billing address to sales order, send the address_id using this node. Else, the default billing address for that contact is used
shipping_address_id
long
Unique Id generated by the server for address in contacts page. To add a shipping address to sales order, send the address_id using this node. Else, the default shipping address for that contact is used
place_of_supply
string
🇮🇳 India
only
Place where the goods/services are supplied to. (If not given, place of contact given for the contact will be taken)
gst_treatment
string
🇮🇳 India
only
Choose whether the contact is GST registered/unregistered/consumer/overseas. Allowed values are business_gst , business_none , overseas , consumer .
gst_no
string
🇮🇳 India
only
15 digit GST identification number of the customer.

Query Parameters

ignore_auto_number_generation
Ignore auto sales order number generation for this sales order. This mandates the sales order number. Allowed values are true , false .

Request Example

Click to copy
parameters_data='{"field1":"value1","field2":"value2"}'; headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695" type: POST headers: headers_data content-type: application/json parameters: parameters_data connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); MediaType mediaType = MediaType.parse("application/json"); RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}"); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695") .post(body) .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .addHeader("content-type", "application/json") .build(); Response response = client.newCall(request).execute();
const options = { method: 'POST', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f', 'content-type': 'application/json' }, body: '{"field1":"value1","field2":"value2"}' }; fetch('https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}" headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f", 'content-type': "application/json" } conn.request("POST", "/inventory/v1/salesorders?organization_id=10234695", payload, headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "POST", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f", "content-type": "application/json" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.write(JSON.stringify({field1: 'value1', field2: 'value2'})); req.end();
curl --request POST \ --url 'https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' \ --header 'content-type: application/json' \ --data '{"field1":"value1","field2":"value2"}'

Body Parameters

Click to copy
{ "customer_id": 4815000000044080, "salesorder_number": "SO-00003", "date": "2015-05-28", "shipment_date": "2015-06-02", "custom_fields": [ { "custom_field_id": 0, "index": 0, "label": "string", "value": "string" } ], "reference_number": "REF-S-00003", "line_items": [ { "item_id": 4815000000044100, "name": "Laptop-white/15inch/dell", "description": "Just a sample description.", "rate": 122, "quantity": 2, "unit": "qty", "tax_id": 4815000000044043, "tds_tax_id": "460000000017098", "tax_name": "Sales Tax", "tax_type": "tax", "tax_percentage": 12, "item_total": 244, "warehouse_id": 130426000000664020, "hsn_or_sac": 80540, "sat_item_key_code": 71121206, "unitkey_code": "E48" } ], "notes": "Sample Note", "terms": "Terms and Conditions", "discount": "20.00%", "is_discount_before_tax": true, "discount_type": "entity_level", "shipping_charge": 7, "delivery_method": "FedEx", "adjustment": 0, "pricebook_id": 4815000000044054, "salesperson_id": 4815000000044762, "adjustment_description": "Just an example description.", "is_inclusive_tax": false, "exchange_rate": 1, "template_id": 4815000000017003, "documents": [ { "can_send_in_mail": true, "file_name": "sample.pdf", "file_type": "pdf", "file_size_formatted": "116.8 KB", "attachment_order": 1, "document_id": 16115000000096068, "file_size": 11957 } ], "billing_address_id": 4815000000017005, "shipping_address_id": 4815000000017005, "place_of_supply": "TN", "gst_treatment": "business_gst", "gst_no": "22AAAAA0000A1Z5" }

Response Example

{ "code": 0, "message": "success", "sales_order": { "salesorder_id": 4815000000044895, "salesorder_number": "SO-00003", "date": "2015-05-28", "status": "fulfilled", "shipment_date": "2015-06-02", "reference_number": "REF-S-00003", "customer_id": 4815000000044080, "customer_name": "Molly", "contact_persons": [ { "contact_person_id": 4815000000044080 } ], "currency_id": 4815000000000097, "currency_code": "USD", "currency_symbol": "$", "exchange_rate": 1, "discount_amount": 0, "discount": "20.00%", "is_discount_before_tax": true, "discount_type": "entity_level", "estimate_id": 4815000000045091, "delivery_method": "FedEx", "delivery_method_id": 4815000000044822, "line_items": [ { "item_id": 4815000000044100, "line_item_id": 4815000000044897, "name": "Laptop-white/15inch/dell", "description": "Just a sample description.", "item_order": 0, "bcy_rate": 122, "rate": 122, "quantity": 2, "quantity_invoiced": 2, "quantity_packed": 2, "quantity_shipped": 2, "unit": "qty", "tax_id": 4815000000044043, "tds_tax_id": "460000000017098", "tax_name": "Sales Tax", "tax_type": "tax", "tax_percentage": 12, "item_total": 244, "is_invoiced": true, "image_id": 2077500000000002000, "image_name": "dell.jpg", "image_type": "jpg", "warehouse_id": 130426000000664020, "hsn_or_sac": 80540, "sat_item_key_code": 71121206, "unitkey_code": "E48" } ], "shipping_charge": 7, "adjustment": 0, "adjustment_description": "Just an example description.", "sub_total": 244, "tax_total": 29, "total": 350, "taxes": [ { "tax_name": "Sales Tax", "tax_amount": 29.28 } ], "price_precision": 2, "pricebook_id": 4815000000044054, "shipping_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "billing_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "notes": "Sample Note", "terms": "Terms and Conditions", "template_id": 4815000000017003, "template_name": "Standard", "template_type": "standard", "created_time": "2015-05-28T00:00:00.000Z", "last_modified_time": "2015-05-28T00:00:00.000Z", "salesperson_id": 4815000000044762, "salesperson_name": "Lara", "documents": [ { "can_send_in_mail": true, "file_name": "sample.pdf", "file_type": "pdf", "file_size_formatted": "116.8 KB", "attachment_order": 1, "document_id": 16115000000096068, "file_size": 11957 } ], "is_pre_gst": false, "gst_no": "22AAAAA0000A1Z5", "gst_treatment": "business_gst", "place_of_supply": "TN" } }

List all Sales Orders

Lists all the available Sales Orders in Zoho Inventory.
OAuth Scope : ZohoInventory.salesorders.READ

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695" type: GET headers: headers_data content-type: application/octet-stream connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695") .get() .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .build(); Response response = client.newCall(request).execute();
const options = { method: 'GET', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' } }; fetch('https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } conn.request("GET", "/inventory/v1/salesorders?organization_id=10234695", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "GET", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
curl --request GET \ --url 'https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'

Response Example

{ "code": 0, "message": "success", "salesorders": [ { "salesorder_id": 4815000000044895, "customer_name": "Molly", "customer_id": 4815000000044080, "status": "fulfilled", "salesorder_number": "SO-00003", "reference_number": "REF-S-00003", "date": "2015-05-28", "shipment_date": "2015-06-02", "shipment_days": 2, "quantity": 2, "quantity_invoiced": 2, "quantity_packed": 2, "quantity_shipped": 2, "currency_code": "USD", "total": 350, "bcy_total": 33, "created_time": "2015-05-28T00:00:00.000Z", "last_modified_time": "2015-05-28T00:00:00.000Z", "is_emailed": true, "is_drop_shipment": false, "is_backorder": false, "sales_channel": "direct_sales", "custom_fields": [ { "custom_field_id": 0, "index": 0, "label": "string", "value": "string" } ] }, {...}, {...} ] }

Bulk delete Sales Orders

Bulk delete the selected Sales Orders.
OAuth Scope : ZohoInventory.salesorders.DELETE

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695" type: DELETE headers: headers_data content-type: application/octet-stream connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695") .delete(null) .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .build(); Response response = client.newCall(request).execute();
const options = { method: 'DELETE', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' } }; fetch('https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } conn.request("DELETE", "/inventory/v1/salesorders?organization_id=10234695", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "DELETE", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
curl --request DELETE \ --url 'https://www.zohoapis.com/inventory/v1/salesorders?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'

Response Example

{ "code": 0, "message": "The selected sales orders have been deleted", "data": [ {...}, {...} ] }

Update a Sales Order

Updates a new Sales Order in Zoho Inventory. Description about extra parameter ignore_auto_number_generation - Ignore auto sales order number generation for this sales order. This mandates the Sales Order number to be entered. Allowed Values true and false.
OAuth Scope : ZohoInventory.salesorders.UPDATE

Arguments

salesorder_number
string
(Required)
The Sales Order number. This is unique for each sales order.
date
string
The date for the Sales Order.
shipment_date
string
Shipment date of the Sales Order.
custom_fields
array
Show Sub-Attributes arrow
custom_field_id
long
index
integer
Index of the custom field
label
string
Label of the Custom Field
value
string
Value of the Custom Field
reference_number
string
Reference number of the Sales Order
customer_id
long
(Required)
Unique ID generated for the customer. This is used as an identifier.
contact_persons
array
List of contact persons details.
Show Sub-Attributes arrow
contact_person_id
long
Unique ID generated by the server for the contact person
discount
double
The percentage of Discount applied.
is_discount_before_tax
boolean
Used to check whether the discount is applied before tax or after tax.
discount_type
string
Type of discount. Allowed values are entity_level,item_level. For entity_level type, discount is applied at entity level and the node discount resides outside the line_items node.For item_level type, discount is applied at item level and the node discount resides inside each line_item under the line_items node
delivery_method
string
Delivery method of the shipment.
shipping_charge
double
Shipping charges that can be applied to the Sales Order.
adjustment
double
Adjustment on the Sales Order's total.
adjustment_description
string
Description for the adjustment.
pricebook_id
string
Unique ID generated by the server for the Pricebook. This is used as an identifier.
notes
string
Notes for the Sales Order.
salesperson_name
string
Name of the Sales Person.
terms
string
Terms for the Sales Order.
exchange_rate
double
Exchange rate of the currency, with respect to the base currency.
line_items
array
(Required)
A sales order can contain multiple line items. Each line item contains item_id,name,description,rate,quantity,unit,tax_id,tax_name,tax_type,tax_percentage,item_total.
Show Sub-Attributes arrow
line_item_id
long
Unique ID generated by the server for each line item. This is used as an identifier.
item_id
long
Unique ID generated by the server for the item. This is used as an identifier.
name
string
Name of the line item.
description
string
Description of the line item.
rate
double
Rate / Selling Price of the line item.
quantity
double
Quantity of the line item.
unit
string
Unit of line item.
tax_id
long
Unique ID generated by the server for the tax. This is used as an identifier.
tds_tax_id
string
🇲🇽 Mexico
only
ID of the TDS tax or TDS tax group applied
tax_name
string
Name of the tax applied on the line item.
tax_type
string
Denotes the type of the tax. This can either be a single tax or a tax group.
tax_percentage
double
Percentage of the tax.
item_total
double
Total of line item.
warehouse_id
long
Unique ID generated by the server for the ware houses
hsn_or_sac
string
🇮🇳 India
only
Add HSN/SAC code for your goods/services
sat_item_key_code
string
🇲🇽 Mexico
only
Add SAT Item Key Code for your goods/services. Download the CFDI Catalogs.
unitkey_code
string
🇲🇽 Mexico
only
Add SAT Unit Key Code for your goods/services. Download the CFDI Catalogs.
billing_address_id
long
Unique Id generated by the server for address in contacts page. To add a billing address to sales order, send the address_id using this node. Else, the default billing address for that contact is used
shipping_address_id
long
Unique Id generated by the server for address in contacts page. To add a shipping address to sales order, send the address_id using this node. Else, the default shipping address for that contact is used
place_of_supply
string
🇮🇳 India
only
Place where the goods/services are supplied to. (If not given, place of contact given for the contact will be taken)
gst_treatment
string
🇮🇳 India
only
Choose whether the contact is GST registered/unregistered/consumer/overseas. Allowed values are business_gst , business_none , overseas , consumer .
gst_no
string
🇮🇳 India
only
15 digit GST identification number of the customer.

Query Parameters

ignore_auto_number_generation
Ignore auto sales order number generation for this sales order. This mandates the sales order number. Allowed values are true , false .

Request Example

Click to copy
parameters_data='{"field1":"value1","field2":"value2"}'; headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695" type: PUT headers: headers_data content-type: application/json parameters: parameters_data connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); MediaType mediaType = MediaType.parse("application/json"); RequestBody body = RequestBody.create(mediaType, "{\"field1\":\"value1\",\"field2\":\"value2\"}"); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695") .put(body) .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .addHeader("content-type", "application/json") .build(); Response response = client.newCall(request).execute();
const options = { method: 'PUT', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f', 'content-type': 'application/json' }, body: '{"field1":"value1","field2":"value2"}' }; fetch('https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") payload = "{\"field1\":\"value1\",\"field2\":\"value2\"}" headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f", 'content-type': "application/json" } conn.request("PUT", "/inventory/v1/salesorders/4815000000044895?organization_id=10234695", payload, headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "PUT", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders/4815000000044895?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f", "content-type": "application/json" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.write(JSON.stringify({field1: 'value1', field2: 'value2'})); req.end();
curl --request PUT \ --url 'https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' \ --header 'content-type: application/json' \ --data '{"field1":"value1","field2":"value2"}'

Body Parameters

Click to copy
{ "salesorder_number": "SO-00003", "date": "2015-05-28", "shipment_date": "2015-06-02", "custom_fields": [ { "custom_field_id": 0, "index": 0, "label": "string", "value": "string" } ], "reference_number": "REF-S-00003", "customer_id": 4815000000044080, "contact_persons": [ { "contact_person_id": 4815000000044080 } ], "discount": "20.00%", "is_discount_before_tax": true, "discount_type": "entity_level", "delivery_method": "FedEx", "shipping_charge": 7, "adjustment": 0, "adjustment_description": "Just an example description.", "pricebook_id": 4815000000044054, "notes": "Sample Note", "salesperson_name": "Lara", "terms": "Terms and Conditions", "exchange_rate": 1, "line_items": [ { "line_item_id": 4815000000044897, "item_id": 4815000000044100, "name": "Laptop-white/15inch/dell", "description": "Just a sample description.", "rate": 122, "quantity": 2, "unit": "qty", "tax_id": 4815000000044043, "tds_tax_id": "460000000017098", "tax_name": "Sales Tax", "tax_type": "tax", "tax_percentage": 12, "item_total": 244, "warehouse_id": 130426000000664020, "hsn_or_sac": 80540, "sat_item_key_code": 71121206, "unitkey_code": "E48" } ], "billing_address_id": 4815000000017005, "shipping_address_id": 4815000000017005, "place_of_supply": "TN", "gst_treatment": "business_gst", "gst_no": "22AAAAA0000A1Z5" }

Response Example

{ "code": 0, "message": "Sales Order has been updated.", "sales_order": { "salesorder_id": 4815000000044895, "salesorder_number": "SO-00003", "date": "2015-05-28", "status": "fulfilled", "shipment_date": "2015-06-02", "reference_number": "REF-S-00003", "customer_id": 4815000000044080, "customer_name": "Molly", "contact_persons": [ { "contact_person_id": 4815000000044080 } ], "currency_id": 4815000000000097, "currency_code": "USD", "currency_symbol": "$", "exchange_rate": 1, "discount_amount": 0, "discount": "20.00%", "is_discount_before_tax": true, "discount_type": "entity_level", "estimate_id": 4815000000045091, "delivery_method": "FedEx", "delivery_method_id": 4815000000044822, "line_items": [ { "item_id": 4815000000044100, "line_item_id": 4815000000044897, "name": "Laptop-white/15inch/dell", "description": "Just a sample description.", "item_order": 0, "bcy_rate": 122, "rate": 122, "quantity": 2, "quantity_invoiced": 2, "quantity_packed": 2, "quantity_shipped": 2, "unit": "qty", "tax_id": 4815000000044043, "tds_tax_id": "460000000017098", "tax_name": "Sales Tax", "tax_type": "tax", "tax_percentage": 12, "item_total": 244, "is_invoiced": true, "image_id": 2077500000000002000, "image_name": "dell.jpg", "image_type": "jpg", "warehouse_id": 130426000000664020, "hsn_or_sac": 80540, "sat_item_key_code": 71121206, "unitkey_code": "E48" } ], "shipping_charge": 7, "adjustment": 0, "adjustment_description": "Just an example description.", "sub_total": 244, "tax_total": 29, "total": 350, "taxes": [ { "tax_name": "Sales Tax", "tax_amount": 29.28 } ], "price_precision": 2, "pricebook_id": 4815000000044054, "packages": [ { "package_id": 4815000000044905, "package_number": "PK-00004", "status": "fulfilled", "detailed_status": "Delivered", "status_message": "Delivered", "shipment_id": 4815000000044917, "shipment_number": "SH-00004", "shipment_status": 3, "carrier": "FedEx", "service": "SMART_POST", "tracking_number": "TRK214124124", "shipment_date": "2015-06-02", "delivery_days": 12, "delivery_guarantee": true } ], "invoices": [ { "invoice_id": 4815000000045091, "invoice_number": "INV-001", "status": "fulfilled", "date": "2015-05-28", "due_date": "2015-06-13", "total": 350, "balance": 0 } ], "shipping_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "billing_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "notes": "Sample Note", "terms": "Terms and Conditions", "template_id": 4815000000017003, "template_name": "Standard", "template_type": "standard", "created_time": "2015-05-28T00:00:00.000Z", "last_modified_time": "2015-05-28T00:00:00.000Z", "attachment_name": "sample.pdf", "can_send_in_mail": true, "salesperson_id": 4815000000044762, "salesperson_name": "Lara", "is_pre_gst": false, "gst_no": "22AAAAA0000A1Z5", "gst_treatment": "business_gst", "place_of_supply": "TN" } }

Retrieve a Sales Order

Retrieves the details for an existing Sales Order.
OAuth Scope : ZohoInventory.salesorders.READ

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695" type: GET headers: headers_data content-type: application/octet-stream connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695") .get() .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .build(); Response response = client.newCall(request).execute();
const options = { method: 'GET', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' } }; fetch('https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } conn.request("GET", "/inventory/v1/salesorders/4815000000044895?organization_id=10234695", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "GET", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders/4815000000044895?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
curl --request GET \ --url 'https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'

Response Example

{ "code": 0, "message": "success", "salesorder": { "salesorder_id": 4815000000044895, "documents": [ { "can_send_in_mail": true, "file_name": "sample.pdf", "file_type": "pdf", "file_size_formatted": "116.8 KB", "attachment_order": 1, "document_id": 16115000000096068, "file_size": 11957 } ], "salesorder_number": "SO-00003", "date": "2015-05-28", "status": "fulfilled", "shipment_date": "2015-06-02", "reference_number": "REF-S-00003", "customer_id": 4815000000044080, "customer_name": "Molly", "contact_persons": [ { "contact_person_id": 4815000000044080 } ], "currency_id": 4815000000000097, "currency_code": "USD", "currency_symbol": "$", "exchange_rate": 1, "discount_amount": 0, "discount": "20.00%", "is_discount_before_tax": true, "discount_type": "entity_level", "estimate_id": 4815000000045091, "delivery_method": "FedEx", "delivery_method_id": 4815000000044822, "is_inclusive_tax": false, "sales_channel": "direct_sales", "is_dropshipped": false, "is_backordered": false, "is_backorder_allowed": false, "line_items": [ { "item_id": 4815000000044100, "line_item_id": 4815000000044897, "name": "Laptop-white/15inch/dell", "description": "Just a sample description.", "item_order": 0, "bcy_rate": 122, "rate": 122, "quantity": 2, "quantity_invoiced": 2, "quantity_packed": 2, "quantity_shipped": 2, "unit": "qty", "tax_id": 4815000000044043, "tds_tax_id": "460000000017098", "tax_name": "Sales Tax", "tax_type": "tax", "tax_percentage": 12, "item_total": 244, "is_invoiced": true, "image_id": 2077500000000002000, "image_name": "dell.jpg", "image_type": "jpg", "warehouse_id": 130426000000664020, "hsn_or_sac": 80540, "sat_item_key_code": 71121206, "unitkey_code": "E48" } ], "shipping_charge": 7, "adjustment": 0, "pricebook_id": 4815000000044054, "adjustment_description": "Just an example description.", "sub_total": 244, "tax_total": 29, "total": 350, "taxes": [ { "tax_name": "Sales Tax", "tax_amount": 29.28 } ], "price_precision": 2, "is_emailed": true, "has_unconfirmed_line_item": true, "packages": [ { "package_id": 4815000000044905, "package_number": "PK-00004", "status": "fulfilled", "detailed_status": "Delivered", "status_message": "Delivered", "shipment_id": 4815000000044917, "shipment_number": "SH-00004", "shipment_status": 3, "carrier": "FedEx", "service": "SMART_POST", "tracking_number": "TRK214124124", "shipment_date": "2015-06-02", "delivery_days": 12, "delivery_guarantee": true } ], "invoices": [ { "invoice_id": 4815000000045091, "invoice_number": "INV-001", "status": "fulfilled", "date": "2015-05-28", "due_date": "2015-06-13", "total": 350, "balance": 0 } ], "purchaseorders": [ "string" ], "billing_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "shipping_address": { "address": "No:432,Bayside,Queens", "city": "New York City", "state": "New York", "zip": 11364, "country": "U.S.A", "fax": "424-524242" }, "notes": "Sample Note", "terms": "Terms and Conditions", "custom_fields": [ { "custom_field_id": 0, "index": 0, "label": "string", "value": "string" } ], "template_id": 4815000000017003, "template_name": "Standard", "template_type": "standard", "created_time": "2015-05-28T00:00:00.000Z", "last_modified_time": "2015-05-28T00:00:00.000Z", "attachment_name": "sample.pdf", "can_send_in_mail": true, "salesperson_id": 4815000000044762, "salesperson_name": "Lara", "is_pre_gst": false, "gst_no": "22AAAAA0000A1Z5", "gst_treatment": "business_gst", "place_of_supply": "TN" } }

Delete a Sales Order

Deletes an existing Sales Order from Zoho Inventory.
OAuth Scope : ZohoInventory.salesorders.DELETE

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695" type: DELETE headers: headers_data content-type: application/octet-stream connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695") .delete(null) .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .build(); Response response = client.newCall(request).execute();
const options = { method: 'DELETE', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' } }; fetch('https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } conn.request("DELETE", "/inventory/v1/salesorders/4815000000044895?organization_id=10234695", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "DELETE", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders/4815000000044895?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
curl --request DELETE \ --url 'https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'

Response Example

{ "code": 0, "message": "The Sales Order has been deleted." }

Mark as Confirmed

Changes the status of a Sales Order to Confirmed.
OAuth Scope : ZohoInventory.salesorders.CREATE

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/confirmed?organization_id=10234695" type: POST headers: headers_data content-type: application/octet-stream connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/confirmed?organization_id=10234695") .post(null) .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .build(); Response response = client.newCall(request).execute();
const options = { method: 'POST', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' } }; fetch('https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/confirmed?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } conn.request("POST", "/inventory/v1/salesorders/4815000000044895/status/confirmed?organization_id=10234695", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "POST", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders/4815000000044895/status/confirmed?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
curl --request POST \ --url 'https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/confirmed?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'

Response Example

{ "code": 0, "message": "Sales order status has been changed to 'Confirmed'." }

Mark as Void

Changes the status of a Sales Order to Void.
OAuth Scope : ZohoInventory.salesorders.CREATE

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/void?organization_id=10234695" type: POST headers: headers_data content-type: application/octet-stream connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/void?organization_id=10234695") .post(null) .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .build(); Response response = client.newCall(request).execute();
const options = { method: 'POST', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' } }; fetch('https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/void?organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } conn.request("POST", "/inventory/v1/salesorders/4815000000044895/status/void?organization_id=10234695", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "POST", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders/4815000000044895/status/void?organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
curl --request POST \ --url 'https://www.zohoapis.com/inventory/v1/salesorders/4815000000044895/status/void?organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'

Response Example

{ "code": 0, "message": "The status of the Sales Order has been changed to void." }

Bulk confirm Sales Orders

Mark existing Sales Orders as confirmed in Zoho Inventory
OAuth Scope : ZohoInventory.salesorders.CREATE

Query Parameters

salesorder_ids
(Required)
List of sales order ids separated by comma
organization_id
(Required)
ID of the organization

Request Example

Click to copy
headers_data = Map(); headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f"); response = invokeUrl [ url: "https://www.zohoapis.com/inventory/v1/salesorders/status/confirmed?salesorder_ids=4815000000045208,4815000000045274,4815000000045340&organization_id=10234695" type: POST headers: headers_data content-type: application/octet-stream connection: <connection_name> ] info response;
OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.zohoapis.com/inventory/v1/salesorders/status/confirmed?salesorder_ids=4815000000045208%2C4815000000045274%2C4815000000045340&organization_id=10234695") .post(null) .addHeader("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f") .build(); Response response = client.newCall(request).execute();
const options = { method: 'POST', headers: { Authorization: 'Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' } }; fetch('https://www.zohoapis.com/inventory/v1/salesorders/status/confirmed?salesorder_ids=4815000000045208%2C4815000000045274%2C4815000000045340&organization_id=10234695', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
import http.client conn = http.client.HTTPSConnection("www.zohoapis.com") headers = { 'Authorization': "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } conn.request("POST", "/inventory/v1/salesorders/status/confirmed?salesorder_ids=4815000000045208%2C4815000000045274%2C4815000000045340&organization_id=10234695", headers=headers) res = conn.getresponse() data = res.read() print(data.decode("utf-8"))
const http = require("https"); const options = { "method": "POST", "hostname": "www.zohoapis.com", "port": null, "path": "/inventory/v1/salesorders/status/confirmed?salesorder_ids=4815000000045208%2C4815000000045274%2C4815000000045340&organization_id=10234695", "headers": { "Authorization": "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f" } }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end();
curl --request POST \ --url 'https://www.zohoapis.com/inventory/v1/salesorders/status/confirmed?salesorder_ids=4815000000045208%2C4815000000045274%2C4815000000045340&organization_id=10234695' \ --header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'

Response Example

{ "code": 0, "message": "Sales order status has been changed to Confirmed.", "data": { "email_success_info": [ { "code": 0, "message": "The status of the sales order has been changed to Open.", "ids": [ "4815000000045208,4815000000045274,4815000000045340" ] } ], "email_error_info": [ {...} ] } }