Professional Documents
Culture Documents
ZoodMall Merchant API 2.0.16-En
ZoodMall Merchant API 2.0.16-En
16
CONTENTS
ZoodMall Merchant API.................................................................................................................... 1
1 Calls Specification ..................................................................................................................... 4
1.1 Request URL .................................................................................................................... 4
1.2 HTTP Request Method ................................................................................................ 4
1.3 Request Description ..................................................................................................... 4
2 Add Products,Update Products ....................................................................................... 6
2.1 NAME: ProductRpc.create ......................................................................................... 6
2.2 Request Parameter ....................................................................................................... 6
2.3 Return Parameters ........................................................................................................ 7
2.4 Descr ................................................................................................................................... 7
2.4.1 categoryId..................................................................................................................... 7
2.4.2 marketCodes ............................................................................................................... 8
3 Retrieve Product ........................................................................................................................ 9
3.1 NAME: ProductRpc.finds ............................................................................................ 9
3.2 Request Parameter ....................................................................................................... 9
3.3 Return Parameters ........................................................................................................ 9
4 Retrieve Orders ....................................................................................................................... 12
4.1 NAME: OrderRpc.finds ............................................................................................. 12
4.2 Request Parameter .................................................................................................... 12
4.3 Return Parameters ..................................................................................................... 12
5 Update Tracking Number of Order ................................................................................. 14
5.1 NAME: OrderRpc.updateTrackNumber ............................................................ 14
5.2 Request Parameter .................................................................................................... 14
5.3 Return Parameters ..................................................................................................... 14
6 Update Product information ............................................................................................. 15
6.1 NAME: ProductRpc. change.................................................................................... 15
6.2 Return Parameters ..................................................................................................... 16
7 Add new variations ............................................................................................................... 17
7.1 NAME: ProductRpc. addSku ................................................................................... 17
7.2 Request Parameter .................................................................................................... 17
7.3 Return Parameters ..................................................................................................... 17
8 Update variations Property Value ................................................................................... 17
8.1 NAME: ProductRpc. changeSku ............................................................................ 17
8.2 Request Parameter .................................................................................................... 17
8.3 Return Parameters ..................................................................................................... 17
9 Stop sales of SKU/variations ............................................................................................. 18
9.1 NAME: ProductRpc.changeSaleStatus ............................................................... 18
9.2 Request Parameter .................................................................................................... 18
9.3 Return Parameters ..................................................................................................... 18
10 Put Products to markets...................................................................................................... 18
10.1 NAME: ProductRpc. onShelves ......................................................................... 18
10.2 Request Parameter ................................................................................................ 18
10.3 Return Parameters ................................................................................................ 18
11 disable Products in one markets ..................................................................................... 19
2
API version:v2.0.16
11.1 NAME: ProductRpc. offShelves ......................................................................... 19
11.2 Request Parameter ................................................................................................ 19
11.3 Return Parameters ................................................................................................ 19
12 Check Products verification information ..................................................................... 19
12.1 NAME: ProductRpc. checkAuditStatus .......................................................... 19
12.2 Request Parameter ................................................................................................ 19
12.3 Return Parameters ................................................................................................ 19
13 Cancel items in order............................................................................................................ 20
13.1 NAME: cancelOrder ............................................................................................... 20
13.2 Request Parameter ................................................................................................ 20
13.3 Return Parameters ................................................................................................ 20
14 Error Codes ............................................................................................................................... 20
3
API version:v2.0.16
1 Calls Specification
1.1 Request URL
Production environment:https://open.zoodmall.com/rpc.php
Test environment:https://staging-in-open.zoodmall.com/rpc.php
C. Response Parameter
{
"jsonrpc":" JSON-RPC protocol version,must be 2.0",
"id":" identification of client (string which is defined by merchant)",
4
API version:v2.0.16
"result":"",
"error":""
}
D. Parameters Description
Find instructions for PHP and Python below:
https://github.com/subutux/json-rpc2php/
Response:
HTTP/1.1 200 OK
Date: Wed, 17 Jan 2018 10:20:09 GMT
Server: Apache
X-Powered-By: PHP/5.4.35
Set-Cookie: PHPSESSID=87lu9nt6ui9rpftmh2qccj8mt3; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
x-RPC-Auth-Session: 87lu9nt6ui9rpftmh2qccj8mt3
Content-Length: 1974
Content-Type: application/json
{"jsonrpc":"2.0","id":"7SItvCfdXnWWiQzF","result":{"products":[],"pagination":{"
page":1,"rowsPerPage":10,"totalCount":"0"}}
5
API version:v2.0.16
6
API version:v2.0.16
"marketCodes":"codes of market (separated by”,”, refer to 2.4.2
marketCodes )[string(10)]" ,
"shippingFee_KZ":" shipping cost to Kazakhstan [double(10,2)]",
...
"shippingFee_LB":" shipping cost to Lebanon[double(10,2)]",
"description":" description of product[string(4000)]"
"declaredValue":"product value declared to Customs[double(10,2)]",
"hsCode":"HS code[string(50)]",
"productHeight":"package heighth (mm)[int(10)]",
"productLenght":"package length (mm) [int(10)]",
"productWidth":"package width (mm) [int(10)]",
"productWeight":"package weight(g)[double(12,4)]",
"tags":"product tags (separated by ||) [string(200)]",
"crossedPrice":"MSRP(Manufacturer Suggested Retail Price)[double(10,2)]",
"hasBattery":"1=battery inside;2=no battery)[int(3)]",
"hasPowder":"1=powder; 2=not powder [int(3)]",
"hasLiquid":"1=liquid included; 2=no liquid[int(3)]"
},
...
]]
Request maximum (Add, update)10 products each time.
2.4 Descr
If the SKU already exists in ZoodMall database, the product will be updated.
If the SKU does not exist, the product will be added.
2.4.1 categoryId
CategoryId Category
1 Women’s Clothing
2 Men’s Clothing
3 Phones & Accessories
4 Computer & Office
5 Consumer Electronics
6 Jewelry & Watches
7
API version:v2.0.16
CategoryId Category
7 Home & Garden
8 Bags & Shoes
9 Toys, Kids & Baby
10 Sports & Outdoors
11 Health & Beauty
12 Automobiles & Motorcycles
13 Home Improvement
14 Food
15 Handicraft
2.4.2 marketCodes
marketCodes Country
KZ Kazakhstan
LB Lebanon
IR Iran
AF Afghanistan
AZ Azerbaijan
UZ Uzbekistan
TR Turkey
IQ Iraq
If shipping cost is not uploaded, the default shipping cost will take effect for these
products.
8
API version:v2.0.16
3 Retrieve Product
3.1 NAME: ProductRpc.finds
9
API version:v2.0.16
...
"image url x[string(400)]"
],
"categoryId":" category ID of product (refer to 2.4.1 categoryId)
[int(10)]",
"propertyName":" name of variation property (separated by ||)
[string(200)]"
"property":[
{
"sku":" SKU of product property[string(200)]",
"propertyValue":" value of variation property (separated by ||)
[string(200)]",
"propertyImage":" image url of variation product [string(1000)]",
"price":" the price of variation product [dobule(10,2)]"
},
...
{
"sku":" SKU of product property [string(200)]",
"propertyValue":" value of variation property (separated by ||)
[string(200)]",
"propertyImage":"property of image [string(1000)]",
"price":" the price of variation product [double(10,2)]"
}
],
"sproperty":[
{
"name":" name of specification [string(50)]",
"value":" value of specification [string(50)]"
},
...
{
"name":" name of specification [string(50)]",
"value":" value of specification [string(50)]"
}
],
"spropertyLang":{
"ru":[
{
"name":" specification name in Russian[string(50)]",
"value":" specification value in Russian [string(50)]"
},
...
{
"name":" specification name in Russian [string(50)]",
"value":" specification value in Russian [string(50)]"
}
],
...
10
API version:v2.0.16
"fa":[
{
"name":" specification name in Farsi [string(50)]",
"value":" specification value in Farsi[string(50)]"
},
...
{
"name":" specification name in Farsi [string(50)]",
"value":" specification value in Farsi [string(50)]"
}
]
}
...
],
"pagination":{
"page":" current page[int(10)]",
"rowsPerPage":"results per page[int(10)]",
"totalCount":"total quantity of results[int(10)]"
}
}
11
API version:v2.0.16
4 Retrieve Orders
4.1 NAME: OrderRpc.finds
"status":"order status[int(3)]",
"hasPicking":"status of picking orders[int(3)]" [1. In preparation; 2 new orders
which are paid but waiting to be processed]
"processOrder":1 // 1: change order status into “In preparatin”
{
"sku":"product SKU[string(200)]",
"productName":"product name[string(200)]",
"quantity":" item quantity[int(10)]",
"price":" total amount of this variation[double(10,2)]",
"productUrl":"product URL[string(400)]",
"productId":"product Id[string(10)]",
"trackNumber":"tracking number [string(50)]"
"timeShipped":"time of shipping [datetime]"
},
...
{
"sku":"product SKU[string(200)]",
"productName":"product name[string(200)]",
"quantity":" item quantity[int(10)]",
"price":" total amount of this variation [double(10,2)]",
"productUrl":"product URL[string(400)]",
"productId":"product Id[string(10)]",
"trackNumber":"tracking number [string(50)]"
"timeShipped":"time of shipping [datetime]"
}
],
"address":{
"countryCode":"the code of recipient’s country[string(100)]"
"receiver":" recipient [string(200)]",
"province":" province of recipient[string(100)]",
13
API version:v2.0.16
14
API version:v2.0.16
[[
{
"productId":" product ID [int(10)]",
"name":" product name [string(200)]",
"nameLang":{
"ru":"product name in Russian [string(200)]",
...
"fa":" product name in Farsi[string(200)]",
},
"categoryId":"product category ID[int(10)]",
"description":"product description[string(4000)]",
"descriptionLang":{
"ru":" product description in Russian [string(4000)]",
...
"fa":" product description in Farsi [string(4000)]",
},
"sproperty":[
{
"name":" specification name[string(50)]",
"value":" specification value[string(50)]"
},
...
{
"name":" specification name [string(50)]",
"value":" specification value [string(50)]"
}
],
"spropertyLang":{
"ru":[
{
"name":" specification name in Russian[string(50)]",
"value":" specification value in Russian [string(50)]"
},
...
{
"name":" specification name in Russian [string(50)]",
"value":" specification value in Russian [string(50)]"
}
],
...
15
API version:v2.0.16
"fa":[
{
"name":" specification name in Farsi [string(50)]",
"value":" specification value in Farsi[string(50)]"
},
...
{
"name":" specification name in Farsi [string(50)]",
"value":" specification value in Farsi [string(50)]"
}
]
},
"picture":[
"image url 1[string(400)]",
...
"image url x[string(400)]"
],
"defaultPrice":" product Price [double(10,2)]",
"declaredValue":"product value declared to Customs[double(10,2)]",
"hsCode":"HS code[string(50)]",
"productHeight":"package heighth (mm)[int(10)]",
"productLenght":"package length (mm) [int(10)]",
"productWidth":"package width (mm) [int(10)]",
"productWeight":"package weight(g)[double(12,4)]",
"tags":"product tags (separated by ||) [string(200)]",
"crossedPrice":"MSRP(Manufacturer Suggested Retail Price)[double(10,2)]",
"hasBattery":"1=battery inside;2=no battery)[int(3)]",
"hasPowder":"1=powder; 2=not powder [int(3)]",
"hasLiquid":"1=liquid included; 2=no liquid[int(3)]"
"onSale":"1= on sale; 2= stop sale [int(3)]",
},
...
]]
16
API version:v2.0.16
17
API version:v2.0.16
18
API version:v2.0.16
19
API version:v2.0.16
"auditRemark":
[
{
"time":"Audit time[date]",
"timeStamp":"Audit Timestamp [time]",
"remark": "Audit Remarks[string(200)]"
}
...
]
}
...
]
13 Cancel items in order
13.1 NAME: cancelOrder
14 Error Codes
code reason
100001 post search conditions error
110001 post parameters error
20
API version:v2.0.16
110022 Default logistic information has not been set in back office
21
API version:v2.0.16
22