Composite Items
A form or version of an composite item that differs in some respect from other forms of the same or from a standard. You can create your composite items by associating multiple items and their respective quantities.
Attribute
true for composite items
Always inventory
Only images with gif,png,jpeg,jpg,bmp extensions are allowed
true for composite items
intra
or inter
{
"composite_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"unit": "units",
"tax_id": 504366000000053100,
"description": "Just a sample description",
"tax_name": "VAT",
"tax_percentage": 13,
"tax_type": "tax",
"purchase_account_id": 504366000000034000,
"purchase_account_name": "Cost of Goods Sold",
"account_id": 504366000000000400,
"account_name": "sales",
"inventory_account_id": 504366000000034000,
"inventory_account_name": "Inventory Asset",
"status": "active",
"source": "user",
"is_combo_product": true,
"item_type": "inventory",
"rate": 85000,
"pricebook_rate": 85000,
"purchase_rate": 30000,
"reorder_level": 1,
"initial_stock": 2,
"initial_stock_rate": 30000,
"vendor_id": 504366000000053250,
"vendor_name": "Mr. vendor combo",
"stock_on_hand": 2,
"asset_value": 0,
"available_stock": 2,
"actual_available_stock": 2,
"sku": "SKUIS",
"upc": 746325287436,
"ean": 5789414385764,
"isbn": 368302334,
"part_number": "JHFKE7GK7",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"custom_fields": [
{
"custom_field_id": 504366000000053400,
"value": "GBGD078",
"index": 1,
"label": "VAT ID"
}
],
"mapped_items": [
{
"line_item_id": 504366000000053250,
"item_id": 4815000000044208,
"name": "Combo of Apple IPhone and Smartwatch",
"rate": 85000,
"purchase_rate": 30000,
"sku": "SKUIS",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"image_type": "jpg",
"unit": "units",
"is_combo_product": true,
"description": "Just a sample description",
"quantity": 1,
"stock_on_hand": 2,
"available_stock": 2,
"actual_available_stock": 2
}
],
"item_tax_preferences": [
{
"tax_id": 504366000000053100,
"tax_specification": "intra"
}
],
"hsn_or_sac": 85423100
}
Creating a Composite Item
A new composite item can be created after creating items that we want to associcate with composite item. User can attach image for composite item by calling Different API 'https://www.zohoapis.com/inventory/v1/compositeitems/{composite_item_id}/image', passing form-data parameter image i.e. -F image=bag_s.jpg
OAuth Scope : ZohoInventory.compositeitems.CREATE
Arguments
true for composite items
Always inventory
intra
or inter
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/compositeitems?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/compositeitems?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/compositeitems?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/compositeitems?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/compositeitems?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/compositeitems?organization_id=10234695' \
--header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"name": "Combo of Apple IPhone and Smartwatch",
"mapped_items": [
{
"quantity": 1,
"item_id": 4815000000044208,
"line_item_id": 504366000000053250
}
],
"description": "Just a sample description",
"is_combo_product": true,
"vendor_id": 504366000000053250,
"purchase_rate": 30000,
"purchase_description": "Composite item purchase description",
"initial_stock": 2,
"initial_stock_rate": 30000,
"tax_id": 504366000000053100,
"sku": "SKUIS",
"isbn": 368302334,
"ean": 5789414385764,
"part_number": "JHFKE7GK7",
"reorder_level": 1,
"unit": "units",
"upc": 746325287436,
"item_type": "inventory",
"rate": 85000,
"custom_fields": [
{
"custom_field_id": 504366000000053400,
"value": "GBGD078"
}
],
"account_id": 504366000000000400,
"purchase_account_id": 504366000000034000,
"inventory_account_id": 504366000000034000,
"item_tax_preferences": [
{
"tax_id": 504366000000053100,
"tax_specification": "intra"
}
],
"hsn_or_sac": 85423100,
"product_type": "goods"
}
{
"code": 0,
"message": "The item has been added.",
"composite_item": {
"composite_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"unit": "units",
"tax_id": 504366000000053100,
"description": "Just a sample description",
"tax_name": "VAT",
"tax_percentage": 13,
"tax_type": "tax",
"purchase_account_id": 504366000000034000,
"purchase_account_name": "Cost of Goods Sold",
"account_id": 504366000000000400,
"account_name": "sales",
"inventory_account_id": 504366000000034000,
"inventory_account_name": "Inventory Asset",
"status": "active",
"source": "user",
"is_combo_product": true,
"item_type": "inventory",
"rate": 85000,
"pricebook_rate": 85000,
"purchase_rate": 30000,
"reorder_level": 1,
"initial_stock": 2,
"initial_stock_rate": 30000,
"vendor_id": 504366000000053250,
"vendor_name": "Mr. vendor combo",
"stock_on_hand": 2,
"asset_value": 0,
"available_stock": 2,
"actual_available_stock": 2,
"sku": "SKUIS",
"upc": 746325287436,
"ean": 5789414385764,
"isbn": 368302334,
"part_number": "JHFKE7GK7",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"custom_fields": [
{
"custom_field_id": 504366000000053400,
"value": "GBGD078",
"index": 1,
"label": "VAT ID"
}
],
"mapped_items": [
{
"line_item_id": 504366000000053250,
"item_id": 4815000000044208,
"name": "Combo of Apple IPhone and Smartwatch",
"rate": 85000,
"purchase_rate": 30000,
"sku": "SKUIS",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"image_type": "jpg",
"unit": "units",
"is_combo_product": true,
"description": "Just a sample description",
"quantity": 1,
"stock_on_hand": 2,
"available_stock": 2,
"actual_available_stock": 2
}
],
"item_tax_preferences": [
{
"tax_id": 504366000000053100,
"tax_specification": "intra"
}
],
"hsn_or_sac": 85423100
}
}
List All Composite Items
List of all composite items.
OAuth Scope : ZohoInventory.compositeitems.READ
Query Parameters
name
,sku
,rate
,tax_name
,purchase_rate
,created_time
,last_modified_time
,reorder_level
Status.All
,Status.Active
,Inactive
,Lowstock
headers_data = Map();
headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f");
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/compositeitems?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/compositeitems?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/compositeitems?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/compositeitems?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/compositeitems?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/compositeitems?organization_id=10234695' \
--header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'
{
"code": 0,
"message": "success",
"composite_items": [
{
"composite_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"status": "active",
"source": "user",
"description": "Just a sample description",
"rate": 85000,
"tax_id": 504366000000053100,
"tax_name": "VAT",
"tax_percentage": 13,
"purchase_description": "Composite item purchase description",
"purchase_rate": 30000,
"is_combo_product": true,
"item_type": "inventory",
"product_type": "goods",
"is_taxable": true,
"stock_on_hand": 2,
"available_stock": 2,
"actual_available_stock": 2,
"sku": "SKUIS",
"upc": 746325287436,
"ean": 5789414385764,
"isbn": 368302334,
"part_number": "JHFKE7GK7",
"reorder_level": 1,
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"created_time": "2013-08-05",
"last_modified_time": "string"
},
{...},
{...}
]
}
Updating a composite item
Updating details of an existing composite item.
OAuth Scope : ZohoInventory.compositeitems.UPDATE
Arguments
true for composite items
Always inventory
Only images with gif,png,jpeg,jpg,bmp extensions are allowed
true for composite items
intra
or inter
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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?organization_id=10234695' \
--header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"composite_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"unit": "units",
"tax_id": 504366000000053100,
"description": "Just a sample description",
"tax_name": "VAT",
"tax_percentage": 13,
"tax_type": "tax",
"purchase_account_id": 504366000000034000,
"purchase_account_name": "Cost of Goods Sold",
"account_id": 504366000000000400,
"account_name": "sales",
"inventory_account_id": 504366000000034000,
"inventory_account_name": "Inventory Asset",
"status": "active",
"source": "user",
"is_combo_product": true,
"item_type": "inventory",
"rate": 85000,
"pricebook_rate": 85000,
"purchase_rate": 30000,
"reorder_level": 1,
"initial_stock": 2,
"initial_stock_rate": 30000,
"vendor_id": 504366000000053250,
"vendor_name": "Mr. vendor combo",
"stock_on_hand": 2,
"asset_value": 0,
"available_stock": 2,
"actual_available_stock": 2,
"sku": "SKUIS",
"upc": 746325287436,
"ean": 5789414385764,
"isbn": 368302334,
"part_number": "JHFKE7GK7",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"custom_fields": [
{
"custom_field_id": 504366000000053400,
"value": "GBGD078",
"index": 1,
"label": "VAT ID"
}
],
"mapped_items": [
{
"line_item_id": 504366000000053250,
"item_id": 4815000000044208,
"name": "Combo of Apple IPhone and Smartwatch",
"rate": 85000,
"purchase_rate": 30000,
"sku": "SKUIS",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"image_type": "jpg",
"unit": "units",
"is_combo_product": true,
"description": "Just a sample description",
"quantity": 1,
"stock_on_hand": 2,
"available_stock": 2,
"actual_available_stock": 2
}
],
"item_tax_preferences": [
{
"tax_id": 504366000000053100,
"tax_specification": "intra"
}
],
"hsn_or_sac": 85423100,
"product_type": "goods"
}
{
"code": 0,
"message": "Item details have been saved.",
"composite_item": {
"composite_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"unit": "units",
"tax_id": 504366000000053100,
"description": "Just a sample description",
"tax_name": "VAT",
"tax_percentage": 13,
"tax_type": "tax",
"purchase_account_id": 504366000000034000,
"purchase_account_name": "Cost of Goods Sold",
"account_id": 504366000000000400,
"account_name": "sales",
"inventory_account_id": 504366000000034000,
"inventory_account_name": "Inventory Asset",
"status": "active",
"source": "user",
"is_combo_product": true,
"item_type": "inventory",
"rate": 85000,
"pricebook_rate": 85000,
"purchase_rate": 30000,
"reorder_level": 1,
"initial_stock": 2,
"initial_stock_rate": 30000,
"vendor_id": 504366000000053250,
"vendor_name": "Mr. vendor combo",
"stock_on_hand": 2,
"asset_value": 0,
"available_stock": 2,
"actual_available_stock": 2,
"sku": "SKUIS",
"upc": 746325287436,
"ean": 5789414385764,
"isbn": 368302334,
"part_number": "JHFKE7GK7",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"custom_fields": [
{
"custom_field_id": 504366000000053400,
"value": "GBGD078",
"index": 1,
"label": "VAT ID"
}
],
"mapped_items": [
{
"line_item_id": 504366000000053250,
"item_id": 4815000000044208,
"name": "Combo of Apple IPhone and Smartwatch",
"rate": 85000,
"purchase_rate": 30000,
"sku": "SKUIS",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"image_type": "jpg",
"unit": "units",
"is_combo_product": true,
"description": "Just a sample description",
"quantity": 1,
"stock_on_hand": 2,
"available_stock": 2,
"actual_available_stock": 2
}
],
"item_tax_preferences": [
{
"tax_id": 504366000000053100,
"tax_specification": "intra"
}
],
"hsn_or_sac": 85423100
}
}
Retrieving a Composite Item
Retrieving details of an existing compostie item.
OAuth Scope : ZohoInventory.compositeitems.READ
headers_data = Map();
headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f");
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?organization_id=10234695' \
--header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'
{
"code": 0,
"message": "success",
"composite_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"status": "active",
"source": "user",
"unit": "units",
"tax_id": 504366000000053100,
"description": "Just a sample description",
"tax_name": "VAT",
"tax_percentage": 13,
"tax_type": "tax",
"purchase_account_id": 504366000000034000,
"purchase_account_name": "Cost of Goods Sold",
"account_id": 504366000000000400,
"account_name": "sales",
"inventory_account_id": 504366000000034000,
"inventory_account_name": "Inventory Asset",
"is_combo_product": true,
"item_type": "inventory",
"rate": 85000,
"pricebook_rate": 85000,
"purchase_rate": 30000,
"reorder_level": 1,
"initial_stock": 2,
"initial_stock_rate": 30000,
"vendor_id": 504366000000053250,
"vendor_name": "Mr. vendor combo",
"stock_on_hand": 2,
"asset_value": 0,
"available_stock": 2,
"actual_available_stock": 2,
"sku": "SKUIS",
"upc": 746325287436,
"ean": 5789414385764,
"isbn": 368302334,
"part_number": "JHFKE7GK7",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"custom_fields": [
{
"custom_field_id": 504366000000053400,
"value": "GBGD078",
"index": 1,
"label": "VAT ID"
}
],
"mapped_items": [
{
"line_item_id": 504366000000053250,
"item_id": 4815000000044208,
"name": "Combo of Apple IPhone and Smartwatch",
"rate": 85000,
"purchase_rate": 30000,
"sku": "SKUIS",
"image_id": 8408722000000019000,
"image_name": "img1.jpg",
"purchase_description": "Composite item purchase description",
"image_type": "jpg",
"unit": "units",
"is_combo_product": true,
"description": "Just a sample description",
"quantity": 1,
"stock_on_hand": 2,
"available_stock": 2,
"actual_available_stock": 2
}
],
"item_tax_preferences": [
{
"tax_id": 504366000000053100,
"tax_specification": "intra"
}
],
"hsn_or_sac": 85423100
}
Deleting a Composite Item
Deleting an existing Composite Item.
OAuth Scope : ZohoInventory.compositeitems.DELETE
headers_data = Map();
headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f");
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?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/compositeitems/504366000000053250?organization_id=10234695' \
--header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'
{
"code": 0,
"message": "The item has been deleted."
}
Mark as Active
Changing status of an existing composite item to active.
OAuth Scope : ZohoInventory.compositeitems.CREATE
headers_data = Map();
headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f");
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/compositeitems/504366000000053250/active?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/compositeitems/504366000000053250/active?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/compositeitems/504366000000053250/active?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/compositeitems/504366000000053250/active?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/compositeitems/504366000000053250/active?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/compositeitems/504366000000053250/active?organization_id=10234695' \
--header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'
{
"code": 0,
"message": "Re-activation complete! The item is back in business!"
}
Mark as Inactive
Changing status of an existing composite item to inactive.
OAuth Scope : ZohoInventory.compositeitems.CREATE
headers_data = Map();
headers_data.put("Authorization", "Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f");
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/compositeitems/504366000000053250/inactive?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/compositeitems/504366000000053250/inactive?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/compositeitems/504366000000053250/inactive?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/compositeitems/504366000000053250/inactive?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/compositeitems/504366000000053250/inactive?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/compositeitems/504366000000053250/inactive?organization_id=10234695' \
--header 'Authorization: Zoho-oauthtoken 1000.41d9xxxxxxxxxxxxxxxxxxxxxxxxc2d1.8fccxxxxxxxxxxxxxxxxxxxxxxxx125f'
{
"code": 0,
"message": "The item has been marked as inactive."
}
Create Bundle
Bundling is the technique of putting together different components in desired quantities to produce a single commodity. These components could be goods, services and other non-inventory items of your choice.
Arguments
item_id
,name
,description
,quantity_consumed
,unit
,account_id
,warehouse_id
.parameters_data='{"field1":"value1","field2":"value2"}';
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/bundles?organization_id=10234695"
type: POST
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/bundles?organization_id=10234695")
.post(body)
.addHeader("content-type", "application/json")
.build();
Response response = client.newCall(request).execute();
const options = {
method: 'POST',
headers: {'content-type': 'application/json'},
body: '{"field1":"value1","field2":"value2"}'
};
fetch('https://www.zohoapis.com/inventory/v1/bundles?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 = { 'content-type': "application/json" }
conn.request("POST", "/inventory/v1/bundles?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/bundles?organization_id=10234695",
"headers": {
"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/bundles?organization_id=10234695' \
--header 'content-type: application/json' \
--data '{"field1":"value1","field2":"value2"}'
{
"reference_number": "REF-B-00005",
"date": "2017-01-05",
"description": "Just a sample description",
"composite_item_id": 504366000000053250,
"composite_item_name": "Combo of Apple IPhone and Smartwatch",
"composite_item_sku": "SKUIS",
"quantity_to_bundle": 1,
"line_items": [
{
"item_id": 4815000000044208,
"name": "Combo of Apple IPhone and Smartwatch",
"description": "Just a sample description",
"quantity_consumed": 1,
"unit": "units",
"account_id": 504366000000000400,
"account_name": "sales",
"warehouse_id": 4815000000000390,
"warehouse_name": "MyWarehouse",
"rate": 85000
}
],
"is_completed": true
}
{
"code": 0,
"message": "Bundle has been created.",
"bundle_id": 504366000000053250,
"reference_number": "REF-B-00005",
"date": "2017-01-05",
"description": "Just a sample description",
"composite_item_id": 504366000000053250,
"composite_item_name": "Combo of Apple IPhone and Smartwatch",
"composite_item_sku": "SKUIS",
"quantity_to_bundle": 1,
"line_items": [
{
"item_id": 4815000000044208,
"line_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"description": "Just a sample description",
"quantity_consumed": 1,
"unit": "units",
"account_id": 504366000000000400,
"account_name": "sales",
"warehouse_id": 4815000000000390,
"warehouse_name": "MyWarehouse",
"rate": 85000
}
]
}
Bundling History
List of all bundles of a given composite item.
Query Parameters
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/bundles?organization_id=10234695&composite_item_id=504366000000053250"
type: GET
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/bundles?organization_id=10234695&composite_item_id=504366000000053250")
.get()
.build();
Response response = client.newCall(request).execute();
const options = {method: 'GET'};
fetch('https://www.zohoapis.com/inventory/v1/bundles?organization_id=10234695&composite_item_id=504366000000053250', 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")
conn.request("GET", "/inventory/v1/bundles?organization_id=10234695&composite_item_id=504366000000053250")
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/bundles?organization_id=10234695&composite_item_id=504366000000053250",
"headers": {}
};
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/bundles?organization_id=10234695&composite_item_id=504366000000053250'
{
"code": 0,
"message": "success",
"bundles": [
{
"bundle_id": 504366000000053250,
"reference_number": "REF-B-00005",
"date": "2017-01-05",
"description": "Just a sample description",
"composite_item_id": 504366000000053250,
"composite_item_name": "Combo of Apple IPhone and Smartwatch",
"composite_item_sku": "SKUIS",
"quantity_to_bundle": 1,
"line_items": [
{
"item_id": 4815000000044208,
"line_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"description": "Just a sample description",
"quantity_consumed": 1,
"unit": "units",
"account_id": 504366000000000400,
"account_name": "sales",
"warehouse_id": 4815000000000390,
"warehouse_name": "MyWarehouse",
"rate": 85000
}
]
},
{...},
{...}
]
}
Retrieve Bundle
Fetches the details for an existing bundle.
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/bundles/504366000000053250?organization_id=10234695"
type: GET
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/bundles/504366000000053250?organization_id=10234695")
.get()
.build();
Response response = client.newCall(request).execute();
const options = {method: 'GET'};
fetch('https://www.zohoapis.com/inventory/v1/bundles/504366000000053250?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")
conn.request("GET", "/inventory/v1/bundles/504366000000053250?organization_id=10234695")
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/bundles/504366000000053250?organization_id=10234695",
"headers": {}
};
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/bundles/504366000000053250?organization_id=10234695'
{
"code": 0,
"message": "success",
"bundle": {
"bundle_id": 504366000000053250,
"reference_number": "REF-B-00005",
"date": "2017-01-05",
"description": "Just a sample description",
"composite_item_id": 504366000000053250,
"composite_item_name": "Combo of Apple IPhone and Smartwatch",
"composite_item_sku": "SKUIS",
"quantity_to_bundle": 1,
"line_items": [
{
"item_id": 4815000000044208,
"line_item_id": 504366000000053250,
"name": "Combo of Apple IPhone and Smartwatch",
"description": "Just a sample description",
"quantity_consumed": 1,
"unit": "units",
"account_id": 504366000000000400,
"account_name": "sales",
"warehouse_id": 4815000000000390,
"warehouse_name": "MyWarehouse",
"rate": 85000
}
],
"is_completed": true
}
}
Delete Bundle
Deletes an existing bundle from Zoho Inventory.
response = invokeUrl
[
url: "https://www.zohoapis.com/inventory/v1/bundles/504366000000053250?organization_id=10234695"
type: DELETE
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/bundles/504366000000053250?organization_id=10234695")
.delete(null)
.build();
Response response = client.newCall(request).execute();
const options = {method: 'DELETE'};
fetch('https://www.zohoapis.com/inventory/v1/bundles/504366000000053250?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")
conn.request("DELETE", "/inventory/v1/bundles/504366000000053250?organization_id=10234695")
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/bundles/504366000000053250?organization_id=10234695",
"headers": {}
};
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/bundles/504366000000053250?organization_id=10234695'
{
"code": 0,
"message": "The bundle has been deleted."
}