为了进行电商平台 lazada 的API开发,首先我们需要做下面几件事情。
1)开发者注册一个账号
2)然后为每个 lazada 应用注册一个应用程序键(App Key) 。
3)下载 lazada API的SDK并掌握基本的API基础知识和调用
4)利用SDK接口和对象,传入AppKey或者必要的时候获取并传入SessionKey来进行程序开发。
5)利用lazada平台的文档中心和API测试工具,对接口进行测试。从而了解返回信息,方便程序获取。
以上是一般lazada API应用开发的关键流程,其中通过lazada文档中心和API测试工具,进行概念了解和接口信息查询很重要。因为这些数据就是我们需要在逐步显示出来的。lazada 的API很多,不过都分为了好几个领域,慢慢就会了解深入了。
{
“item”: {
“num_iid”: “625127127506”,
“title”: “【同心礼】花西子同心锁口红/浮雕雕花哑光唇膏女滋润浆果红棕色”,
“desc_short”: “”,
“price”: “219”,
“orginal_price”: “219.90”,
“nick”: “花西子旗舰店”,
“num”: “10687”,
“pic_url”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01k84u7v1zOwLX6pptp_!!3392536705.jpg”,
“brand”: “花西子”,
“brandId”: “1875524276”,
“rootCatId”: “50010788”,
“cid”: “50010808”,
“crumbs”: null,
“detail_url”: “https://item.taobao.com/item.htm?id=625127127506”,
“desc”: “”,
“item_imgs”: [
{
“url”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01k84u7v1zOwLX6pptp_!!3392536705.jpg”
},
{
“url”: “//img.alicdn.com/imgextra/i4/3392536705/O1CN010qWF9c1zOwJih3V6k_!!3392536705-0-lubanu-s.jpg”
},
{
“url”: “//img.alicdn.com/imgextra/i1/3392536705/O1CN01f0aC4Q1zOwJvcNH8i_!!3392536705-0-lubanu-s.jpg”
},
{
“url”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN013Cu3Zc1zOwKwXSzre_!!3392536705.jpg”
},
{
“url”: “//img.alicdn.com/imgextra/i4/3392536705/O1CN01LB2YIi1zOwLDU1cwh_!!3392536705-0-lubanu-s.jpg”
}
],
“item_weight”: 0,
“location”: “浙江杭州”,
“post_fee”: 0,
“express_fee”: 0,
“ems_fee”: 0,
“shipping_to”: “”,
“has_discount”: “true”,
“video”: [],
“is_virtual”: null,
“sample_id”: “”,
“is_promotion”: “true”,
“prop_imgs”: {
“prop_img”: [
{
“properties”: “1627207:14241253875”,
“url”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01KBWwZh1zOwKMGVRrI_!!3392536705.jpg”
},
{
“properties”: “1627207:14241344308”,
“url”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01q0UKy31zOwKDKaYBn_!!3392536705.jpg”
},
{
“properties”: “1627207:13238717831”,
“url”: “//img.alicdn.com/imgextra/i1/3392536705/O1CN011TbEUz1zOwJqM9qfc_!!3392536705.jpg”
},
{
“properties”: “1627207:14241344309”,
“url”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01wtURuD1zOwJvdcmkn_!!3392536705.jpg”
},
{
“properties”: “1627207:9310525219”,
“url”: “//img.alicdn.com/imgextra/i4/3392536705/O1CN019aDqJ51zOwJpENQpZ_!!3392536705.jpg”
},
{
“properties”: “1627207:9310521207”,
“url”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN0170fgIa1zOwJmaBZFc_!!3392536705.jpg”
},
{
“properties”: “1627207:14293760229”,
“url”: “//img.alicdn.com/imgextra/i1/3392536705/O1CN01M8Ierq1zOwJszdbgU_!!3392536705.jpg”
},
{
“properties”: “1627207:9310476507”,
“url”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01EJlyEg1zOwJftlt8W_!!3392536705.jpg”
},
{
“properties”: “1627207:13225497174”,
“url”: “//img.alicdn.com/imgextra/i1/3392536705/O1CN01guH3481zOwJnvyGox_!!3392536705.jpg”
},
{
“properties”: “1627207:13225384768”,
“url”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01kJ3L4n1zOwJoemUkj_!!3392536705.jpg”
},
{
“properties”: “1627207:16337414851”,
“url”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01Uk9o941zOwKtPbVGH_!!3392536705.jpg”
},
{
“properties”: “1627207:16337473205”,
“url”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01qsgxTT1zOwKmbz9wn_!!3392536705.jpg”
}
]
},
“property_alias”: “”,
“props”: [
{
“name”: “品牌”,
“value”: “花西子”
},
{
“name”: “品名”,
“value”: “花露养唇同心锁口红”
},
{
“name”: “产地”,
“value”: “中国”
},
{
“name”: “颜色分类”,
“value”: “M1314一生一世(红枫柿子) M1311一心一意(甜杏蜜桃) M520我爱你(糖浆番茄) M7319情深依旧(莓果酒红) M131绛仙锁(甜椒山楂) M210丹霞锁(落日橙橘) M1666一帆风顺(棕红浆果) M130醉梅锁(复古莓红) 【1对共2支口红礼盒】520定情版(同心锁口红2支:M520+M1314+眉粉笔05+化妆棉14片) 【3对共6支口红礼盒】1314长情版(同心锁口红6支:M520+M317+M7319+M1311+M1314+M3334+眉粉笔05+化妆棉49片) M9420就是爱你(烟熏莓果-傣族印象定制版) M9213钟爱一生(灰棕奶咖-傣族印象定制版)”
},
{
“name”: “批准文号”,
“value”: “浙G妆网备字2020015687”
},
{
“name”: “功效”,
“value”: “不易脱色 易上色 提升气色”
},
{
“name”: “规格类型”,
“value”: “正常规格”
},
{
“name”: “款式”,
“value”: “基本款”
},
{
“name”: “是否为特殊用途化妆品”,
“value”: “否”
},
{
“name”: “限期使用日期范围”,
“value”: “2023-07-01至2023-07-24”
}
],
“props_name”: “1627207:14241253875:颜色分类:M1314一生一世(红枫柿子);1627207:14241344308:颜色分类:M1311一心一意(甜杏蜜桃);1627207:13238717831:颜色分类:M520我爱你(糖浆番茄);1627207:14241344309:颜色分类:M7319情深依旧(莓果酒红);1627207:9310525219:颜色分类:M131绛仙锁(甜椒山楂);1627207:9310521207:颜色分类:M210丹霞锁(落日橙橘);1627207:14293760229:颜色分类:M1666一帆风顺(棕红浆果);1627207:9310476507:颜色分类:M130醉梅锁(复古莓红);1627207:13225497174:颜色分类:【1对共2支口红礼盒】520定情版(同心锁口红2支:M520+M1314+眉粉笔05+化妆棉14片);1627207:13225384768:颜色分类:【3对共6支口红礼盒】1314长情版(同心锁口红6支:M520+M317+M7319+M1311+M1314+M3334+眉粉笔05+化妆棉49片);1627207:16337414851:颜色分类:M9420就是爱你(烟熏莓果-傣族印象定制版);1627207:16337473205:颜色分类:M9213钟爱一生(灰棕奶咖-傣族印象定制版)”,
“total_sold”: “145801”,
“skus”: {
“sku”: [
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:14241253875”,
“properties_name”: “1627207:14241253875:颜色分类:M1314一生一世(红枫柿子)”,
“quantity”: “1046”,
“sku_id”: “4873191930248”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:14241344308”,
“properties_name”: “1627207:14241344308:颜色分类:M1311一心一意(甜杏蜜桃)”,
“quantity”: “1159”,
“sku_id”: “4873191930250”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:13238717831”,
“properties_name”: “1627207:13238717831:颜色分类:M520我爱你(糖浆番茄)”,
“quantity”: “1175”,
“sku_id”: “4873191930249”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:14241344309”,
“properties_name”: “1627207:14241344309:颜色分类:M7319情深依旧(莓果酒红)”,
“quantity”: “679”,
“sku_id”: “4873191930251”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:9310525219”,
“properties_name”: “1627207:9310525219:颜色分类:M131绛仙锁(甜椒山楂)”,
“quantity”: “1211”,
“sku_id”: “4592311970806”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:9310521207”,
“properties_name”: “1627207:9310521207:颜色分类:M210丹霞锁(落日橙橘)”,
“quantity”: “1056”,
“sku_id”: “4592311970807”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:14293760229”,
“properties_name”: “1627207:14293760229:颜色分类:M1666一帆风顺(棕红浆果)”,
“quantity”: “652”,
“sku_id”: “4592311970810”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:9310476507”,
“properties_name”: “1627207:9310476507:颜色分类:M130醉梅锁(复古莓红)”,
“quantity”: “569”,
“sku_id”: “4592311970805”
},
{
“price”: “520”,
“total_price”: 0,
“orginal_price”: “520”,
“properties”: “1627207:13225497174”,
“properties_name”: “1627207:13225497174:颜色分类:【1对共2支口红礼盒】520定情版(同心锁口红2支:M520+M1314+眉粉笔05+化妆棉14片)”,
“quantity”: “772”,
“sku_id”: “4873191930247”
},
{
“price”: “1314”,
“total_price”: 0,
“orginal_price”: “1314”,
“properties”: “1627207:13225384768”,
“properties_name”: “1627207:13225384768:颜色分类:【3对共6支口红礼盒】1314长情版(同心锁口红6支:M520+M317+M7319+M1311+M1314+M3334+眉粉笔05+化妆棉49片)”,
“quantity”: “799”,
“sku_id”: “4873191930246”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:16337414851”,
“properties_name”: “1627207:16337414851:颜色分类:M9420就是爱你(烟熏莓果-傣族印象定制版)”,
“quantity”: “784”,
“sku_id”: “4755229401441”
},
{
“price”: “219”,
“total_price”: 0,
“orginal_price”: “219”,
“properties”: “1627207:16337473205”,
“properties_name”: “1627207:16337473205:颜色分类:M9213钟爱一生(灰棕奶咖-傣族印象定制版)”,
“quantity”: “785”,
“sku_id”: “4755229401442”
}
]
},
“seller_id”: “3392536705”,
“shop_id”: “439637221”,
“props_list”: {
“1627207:14241253875”: “颜色分类:M1314一生一世(红枫柿子)”,
“1627207:14241344308”: “颜色分类:M1311一心一意(甜杏蜜桃)”,
“1627207:13238717831”: “颜色分类:M520我爱你(糖浆番茄)”,
“1627207:14241344309”: “颜色分类:M7319情深依旧(莓果酒红)”,
“1627207:9310525219”: “颜色分类:M131绛仙锁(甜椒山楂)”,
“1627207:9310521207”: “颜色分类:M210丹霞锁(落日橙橘)”,
“1627207:14293760229”: “颜色分类:M1666一帆风顺(棕红浆果)”,
“1627207:9310476507”: “颜色分类:M130醉梅锁(复古莓红)”,
“1627207:13225497174”: “颜色分类:【1对共2支口红礼盒】520定情版(同心锁口红2支:M520+M1314+眉粉笔05+化妆棉14片)”,
“1627207:13225384768”: “颜色分类:【3对共6支口红礼盒】1314长情版(同心锁口红6支:M520+M317+M7319+M1311+M1314+M3334+眉粉笔05+化妆棉49片)”,
“1627207:16337414851”: “颜色分类:M9420就是爱你(烟熏莓果-傣族印象定制版)”,
“1627207:16337473205”: “颜色分类:M9213钟爱一生(灰棕奶咖-傣族印象定制版)”
},
“seller_info”: {
“nick”: “花西子旗舰店”,
“item_score”: "4.8 ",
“score_p”: "4.8 ",
“delivery_score”: "4.8 ",
“shop_type”: “B”,
“user_num_id”: “3392536705”,
“sid”: “439637221”,
“title”: “花西子旗舰店”,
“zhuy”: “https://shop439637221.taobao.com/”,
“shop_name”: “花西子旗舰店”
},
“tmall”: true,
“update_time”: “2021-12-10 17:46:46”,
“data_update”: “2021-12-10 17:46:46”,
“data_f”: “jcs”,
“data_from”: “hid”,
“promo_type”: null,
“props_img”: {
“1627207:14241253875”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01KBWwZh1zOwKMGVRrI_!!3392536705.jpg”,
“1627207:14241344308”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01q0UKy31zOwKDKaYBn_!!3392536705.jpg”,
“1627207:13238717831”: “//img.alicdn.com/imgextra/i1/3392536705/O1CN011TbEUz1zOwJqM9qfc_!!3392536705.jpg”,
“1627207:14241344309”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01wtURuD1zOwJvdcmkn_!!3392536705.jpg”,
“1627207:9310525219”: “//img.alicdn.com/imgextra/i4/3392536705/O1CN019aDqJ51zOwJpENQpZ_!!3392536705.jpg”,
“1627207:9310521207”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN0170fgIa1zOwJmaBZFc_!!3392536705.jpg”,
“1627207:14293760229”: “//img.alicdn.com/imgextra/i1/3392536705/O1CN01M8Ierq1zOwJszdbgU_!!3392536705.jpg”,
“1627207:9310476507”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01EJlyEg1zOwJftlt8W_!!3392536705.jpg”,
“1627207:13225497174”: “//img.alicdn.com/imgextra/i1/3392536705/O1CN01guH3481zOwJnvyGox_!!3392536705.jpg”,
“1627207:13225384768”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01kJ3L4n1zOwJoemUkj_!!3392536705.jpg”,
“1627207:16337414851”: “//img.alicdn.com/imgextra/i3/3392536705/O1CN01Uk9o941zOwKtPbVGH_!!3392536705.jpg”,
“1627207:16337473205”: “//img.alicdn.com/imgextra/i2/3392536705/O1CN01qsgxTT1zOwKmbz9wn_!!3392536705.jpg”
},
“error”: null,
“format_check”: “ok”,
“sales”: 0,
“desc_img”: [],
“shop_item”: [],
“relate_items”: []
},
“error”: “”,
“secache”: “ff550921304f1e4d38423fa53efbc4a1”,
“secache_time”: 1652061835,
“secache_date”: “2022-05-09 10:03:55”,
“translate_status”: “”,
“translate_time”: 0,
“language”: {
“default_lang”: “cn”,
“current_lang”: “cn”
},
“reason”: “”,
“error_code”: “0000”,
“cache”: 0,
“api_info”: “today:23 max:10100 all[48=23+11+14]”,
“execution_time”: “0.318”,
“server_time”: “Beijing/2022-05-09 10:03:55”,
“client_ip”: “106.6.37.230”,
“call_args”: {
“num_iid”: “625127127506”,
“is_promotion”: “1”
},
“api_type”: “taobao”,
“translate_language”: “zh-CN”,
“translate_engine”: “google_new”,
“server_memory”: “5.95MB”,
“request_id”: “gw-1.6278768b3d7f5”,
“last_id”: “949903375”
}