当前位置:网站首页>Integrated API interface code of domestic express companies for intra city distribution and ordering - Express 100
Integrated API interface code of domestic express companies for intra city distribution and ordering - Express 100
2022-06-24 13:20:00 【Express 100api】
One 、 Intra city distribution order
Select an express company to place an order .
1.1 Interface format
Provide a uniform format for HTTP POST or GET Call interface , And return to the unified format JSON data .
1.2 Request address
https://order.kuaidi100.com/sameCity/order
Request parameters :
Parameter name | If required | type | explain |
|---|---|---|---|
method | yes | string | Business types ( Default :order) |
key | yes | string | Authorization code , Express, please 100 Page application enterprise version interface access https://api.kuaidi100.com/register |
sign | yes | string | 32 Bit capital , Signature , For authentication , Press MD5 (param +t+key+ secret) In the order of MD5 encryption , No need to add “+” Number secret There's in the authorization email |
t | yes | string | Timestamps such as :1576123932000 |
param | yes | param | Spliced by other fields |
param data structure :
Parameter name | If required | type | explain |
|---|---|---|---|
com | yes | string | The code of the express company , All in small letters , see 《 Express company code 》 |
recManName | yes | string | Recipient's name |
recManMobile | yes | string | Recipient's mobile number , Either mobile number or phone number is required |
recManPrintAddr | yes | string | The full address of the recipient , For example, Keji South 12th Road, Nanshan District, Shenzhen, Guangdong 2 Kingdee Software Park |
sendManName | yes | string | name of sender |
sendManMobile | yes | string | Sender's mobile number , Either mobile number or phone number is required |
sendManPrintAddr | yes | string | The full address of the sender , For example, Keji South 12th Road, Nanshan District, Shenzhen, Guangdong 2 Kingdee Software Park B10 |
callbackUrl | yes | string | callBackUrl Order information callback |
orderType | no | string | Order type 0: Order immediately ( Default ) 1: Appointment form |
pickupTime | no | string | Make an appointment for pick-up time (2020-02-02 22:00:00), Reserved parts are required |
weight | yes | double | The total weight of the article KG, No need to bring units , example :1.5 |
serviceType | yes | string | Service type of express service , example : File ads ; Refer to the parameter dictionary |
remark | no | string | remarks |
salt | no | string | Random string for signature |
orderSourceNo | no | String | Item source No ( Such as Meituan 、 Hungry? Orders are convenient for riders to pick up ) |
orderSourceType | no | String | Source of the item ( Such as Meituan 、 Hungry? Orders are convenient for riders to pick up ) |
storeId | yes | String | The store id( Corresponding to the store logo provided by the express company ) |
additionFee | no | Int | Gratuity , Unit score , No need to bring units , example :1000 |
price | yes | Int | commodity price , Unit score , No need to bring units , example :1000 |
partnerId | no | String | Service provider authorization information , Refer to the parameter dictionary |
partnerKey | no | String | Service provider authorization information , Refer to the parameter dictionary |
goods | no | obj | Goods details ( It is strongly recommended that , It is convenient for the rider to confirm the goods information when picking up the goods ) |
goods data structure :
Parameter name | If required | type | explain |
|---|---|---|---|
name | yes | String | Name of commodity |
price | yes | Int | commodity price |
count | yes | Int | The number |
uint | yes | String | Commodity unit |
1.3 Return results
Field | type | explain | remarks |
|---|---|---|---|
result | boolean | Submit results | true Submit successfully ,false Failure |
returnCode | string | Return code | |
message | string | Return message description | |
data | data |
data data structure
Field | type | explain | remarks |
|---|---|---|---|
taskId | string | Mission ID | |
orderId | string | Order ID | |
fee | int | cost , Unit score | |
distance | int | distance , In kilometers | |
kuaidiNum | string | Express company order number |
1.4 Provide data content
param Example
{
"com": "kfw",
"recManName": " test ",
"recManMobile": "13542651579",
"recManPrintAddr": " Shenzhen Nanshan District Weiyida Daxia ",
"sendManName": " Xiao Zhang ",
"sendManMobile": "13542651579",
"sendManPrintAddr": " Shenzhen Nanshan District Gaoxin South subway station b mouth ",
"serviceType": " Hot pot ",
"weight": 1.00,
"remark": " Test order , Cancel later ",
"salt": "123",
"callBackUrl": "http://www.baiud.com",
"pickupTime": "",
"orderSourceNo": "168168168",
"orderSourceType": " Meituan ",
"storeId": "106396",
"additionFee": 1000,
"partnerId": "155555555",
"partnerKey": "1111111111"
}Return result example
{
"returnCode": "200",
"result": true,
"message": " Submit successfully ",
"data": {
"taskId": "13F873760DCB4CF28D666A13FDE6B31A",
"com": "kfw",
"orderId": "1000090",
"fee": 5000,
"distance": 1000,
"kuaidiNum": "KFWZS1476131277"
}
} 1.5 Information code meaning
Information code | Information content description | Reasons and suggestions for treatment |
|---|---|---|
200 | success | success |
400 | Parameter error, etc | The submitted data is incomplete , Check that the submitted format is x-www-form-urlencoded Of post Format |
500 | Server error | Courier 100 There is a gap or temporary exception on the server , Sometimes if the request is not submitted according to the specification , For example, the parameters of the express company are not filled in according to the document regulations , This error will also be reported |
501 | Repeated submission | Courier 100 There is a gap or temporary exception on the server , Sometimes if the request is not submitted according to the specification , For example, the parameters of the express company are not filled in according to the document regulations , This error will also be reported |
503 | Failed to verify signature | Please check the encryption ,param + t + key+ secret In the order of MD5 encryption , After encryption, the string is converted to uppercase |
601 | key Has expired | There is no single quantity available , The account needs to be recharged |
Two 、 Order callback interface
If the order status changes, the callback will be triggered , After the callback, if the partner does not return correctly , There will be repeated callbacks 2 Time , That is, the maximum number of callbacks 3 Time . interval 30 minute .
2.1 Interface format
Provide a uniform format for HTTP POST, And return to the unified format JSON data .
Ask the head of the newspaper :Content-Type=application/x-www-form-urlencoded;charset=UTF-8
2.2 Request address
Your company filled in when authorizing callbackUrl
Request parameters :
Field | type | explain | remarks |
|---|---|---|---|
taskId | String | Mission id | |
sign | String | Signature | When placing an order, I filled in salt Timing belt sign md5(param+salt) |
param | param | Parameter body |
param data structure :
Parameter name | If required | type | explain |
|---|---|---|---|
kuaidicom | yes | string | The code of the express company , All in small letters , see 《 Express company code 》, optional . |
kuaidinum | yes | string | courier number , The maximum length of the order number is 32 Characters . |
message | yes | string | State description |
orderId | yes | string | Platform order ID |
status | yes | string | The order status 0- checkout success 1- Order received 10- Picked up 13- Signed for 9- The user actively cancels 99- The order has been cancelled |
courierName | no | string | Courier name |
courierMobile | no | string | Courier phone |
weight | no | string | weight |
freight | no | string | The freight |
2.3 Return results
Field | explain | remarks |
|---|---|---|
result | Submit results | true Submit successfully ,false Failure |
returnCode | Return code | |
message | Return message description |
2.4 Provide data content
Enter the reference param Example
{
"courierMobile":"15010033036",
"courierName":"G The master ",
"kuaidiCom":"kfw",
"kuaidiNum":"KFWZS1476130507",
"message":" The order has been cancelled ",
"orderId":"1000086",
"status":99
}Request to return results
{
"returnCode": "200",
"result": true,
"message": " success "
}2.4 Push response message and error code interpretation
Field name | Field meaning |
|---|---|
result | true It means success ,false It means failure . If the address of the callback interface fails to be submitted ,30 Call back after minutes ,3 Times still failed , Give up automatically |
returnCode | 200: Submit successfully 500: Server error Please define other errors by yourself |
message | Prompt returned |
边栏推荐
- IIS WCF 808 port service access exception
- Comparator 排序函数式接口
- Yolov6: the fast and accurate target detection framework is open source
- Nifi from introduction to practice (nanny level tutorial) - environment
- Concept + formula (excluding parameter estimation)
- 8 lines of code to teach you how to build an intelligent robot platform
- 使用 Abp.Zero 搭建第三方登录模块(一):原理篇
- 1. Snake game design
- The agile way? Is agile development really out of date?
- 快速了解常用的消息摘要算法,再也不用担心面试官的刨根问底
猜你喜欢

Understanding openstack network

使用 Abp.Zero 搭建第三方登录模块(一):原理篇

The agile way? Is agile development really out of date?

Comparator 排序函数式接口

YOLOv6:又快又准的目标检测框架开源啦

DTU上报的数据值无法通过腾讯云规则引擎填入腾讯云数据库中

【数据库】期末复习(计科版)

Use terminal to activate CONDA service in pypharm (the ultimate method is definitely OK)

CVPR 2022 | 美團技術團隊精選論文解讀

Brief introduction to cluster analysis
随机推荐
青藤入选工信部网安中心“2021年数字技术融合创新应用典型解决方案”
Internet of things? Come and see Arduino on the cloud
[2022 national tournament simulation] BigBen -- determinant, Du Jiao sieve
Who is the fish and who is the bait? Summary of honeypot recognition methods from the perspective of red team
Use terminal to activate CONDA service in pypharm (the ultimate method is definitely OK)
Configuration (enable_*) parameter related to execution plan in PG
About the hacked database
8 lines of code to teach you how to build an intelligent robot platform
[data mining] final review (sample questions + a few knowledge points)
what the fuck! I'm flattered. He actually wrote down the answers to the redis interview questions that big companies often ask!
Attack Science: ARP attack
“有趣” 是新时代的竞争力
The programmer's graduation project is still bald after a year
实现领域驱动设计 - 使用ABP框架 - 创建实体
Open source monitoring system Prometheus
Implement Domain Driven Design - use ABP framework - create entities
"Interesting" is the competitiveness of the new era
Interviewer: the MySQL database is slow to query. What are the possible reasons besides the index problem?
几种常见的DoS攻击
Reset the password, and the automatic login of the website saved by chrome Google browser is lost. What is the underlying reason?