Appearance
查询报价 Price
接口说明
通过此接口可查询指定客户的订单价格信息。
接口地址: http://tms.gateway.sc-express.cn/api/searchPrice
请求方式: POST
请求参数
字段名称 | 字段类型 | 字段长度 | 是否必需 | 字段说明 | ||
---|---|---|---|---|---|---|
authorization | JSONObject | 接口校验信息 | ||||
code | String | 5-20 | Y | 客户编码 | ||
token | String | 50 | Y | API授权码 | ||
datas | JSONObject | |||||
dest | String | Y | 目的地编码,通过调用 [查询目的地] 接口获取 | |||
desttype | String | Y | 目的地类型, [ country:国家,port:港口,airport:机场 ] | |||
volumetype | String | N | 材积格式, [ lwh:单件材积,lwhs:多件材积 ] | |||
volumes | JSONArray | N | 材积信息, 数组 | |||
length | number | N | 单件长 | |||
width | number | N | 单件宽 | |||
height | number | N | 单件高 | |||
weight | number | N | 单件重 | |||
piece | number | N | 件数,单件材积时件数设为1 | |||
weight | number | Y | 总重量 | |||
piece | number | Y | 总件数 | |||
goodstype | String | Y | 货物类型 [ WPX:包裹,DOC:文件,PAK:PAK袋 ] | |||
channelid | String | N | 渠道代码;通过调用 [查询渠道] 接口获取 | |||
city | String | N | 城市 | |||
zipcode | String | N | 邮编 | |||
fbacode | String | N | FBA仓码 | |||
validate | String | N | 查价时间,默认当前时间,时间格式:yyyy-MM-dd HH:mm:ss |
请求报文示例
json
{
"authorization": {
"code": "KJHB",
"token": "c60bf762-01f7-470e-8c8f-acde06c81fed"
},
"datas": {
"dest": "US",
"desttype": "country",
"goodstype": "WPX",
"validate": "2021-05-19 14:29:37",
"volumetype": "lwhs",
"volumes": [
{
"height": "10",
"length": "10",
"piece": "1",
"weight": "10",
"width": "10"
},
{
"height": "20",
"length": "20",
"piece": "3",
"weight": "20",
"width": "20"
}
],
"weight": "70.000",
"piece": "4",
"city": "test",
"zipcode": "123"
}
}
{
"authorization": {
"code": "KJHB",
"token": "c60bf762-01f7-470e-8c8f-acde06c81fed"
},
"datas": {
"dest": "US",
"desttype": "country",
"goodstype": "WPX",
"validate": "2021-05-19 14:29:37",
"volumetype": "lwhs",
"volumes": [
{
"height": "10",
"length": "10",
"piece": "1",
"weight": "10",
"width": "10"
},
{
"height": "20",
"length": "20",
"piece": "3",
"weight": "20",
"width": "20"
}
],
"weight": "70.000",
"piece": "4",
"city": "test",
"zipcode": "123"
}
}
响应数据
字段名称 | 字段说明 | ||
---|---|---|---|
code | 接口请求是否通过 0:表示接口请求通过,其他表示失败 | ||
msg | 说明信息 | ||
data | |||
channel | 渠道信息 | ||
channelid | 渠道编码 | ||
channelname | 渠道名称 | ||
channelnameen | 渠道英文名 | ||
channelnamecn | 渠道中文名 | ||
label | 渠道标签 | ||
volume | 渠道材积除 | ||
aging | 渠道时效 | ||
note | 渠道备注 | ||
... | 其他一些信息字段 | ||
channel_productypes | 渠道支持的物品类别,json数组。若为空表示不限制任何物品类别 | ||
code | 物品类别;可通过调用[获取物品类别]接口查看详细信息 | ||
channelid | 渠道代码;可通过调用[查询渠道]接口查看详细信息 | ||
channeltypename | 承运商 | ||
shiptype | 渠道运输类型 | ||
destName | 目的地 | ||
goodstype | 货物类型 | ||
price | 报价信息 | ||
pricepk | 报价ID | ||
pricename | 报价名称 | ||
validbegin | 报价起始时间 | ||
validend | 报价截止时间 | ||
calcflag | 计价类型, 1: 按票计算,2:按件计算 | ||
note | 报价备注 | ||
... | 其他一些信息字段 | ||
priceUpdatetime | 报价最近更新时间 | ||
totalCost | 总金额 | ||
totalCostCcy | 总金额币别 | ||
totalCostFormula | 总金额计算公式 | ||
weight | 计费重 | ||
weightInfos | 重量计算信息 | ||
totalWeight | 总实重 | ||
totalFinalWeight | 结算重 | ||
weight | 计费重 | ||
weightFormula | 计费重计算公式 | ||
totalPiece | 总件数 | ||
totalVolume | 总材积 | ||
m3 | 方数 | ||
tranCost | 运费 | ||
tranCostUnitprice | 单价,运费除以计费重 | ||
tranCostCcy | 运费币别 | ||
trancostCalcDetail | 数组,运费计算细节,按件计算的每个单件运费,按票的为总体运费 | ||
calcFormula | 计算公式 | ||
tranCost | 计算运费 | ||
calcWeight | 计价重量 | ||
calcNum | 计价数量 | ||
unitprice | 单价, 运费除以数量 | ||
priceWeightInfos | 报价重量段, 计价重量匹配的重量段报价数据信息, 详见priceWeightInfos节点 | ||
fuelCost | 燃油费, 费用币别同运费币别 | ||
fuelCostRate | 燃油费率 | ||
costList | 其他费用,json数组 | ||
costtype | 费用类型 | ||
amount | 费用金额 | ||
ccy | 币别 | ||
formula | 计算公式 | ||
priceWeightInfos节点 | json数组 | ||
weightname | 重量段名称 | ||
type | 重量段类型。1:单价; 2:金额; 3:首重价格; 4:续重价格;5:续首重价格 | ||
priceWeightType | 报价计算方式 | ||
goodstype | 重量段包裹类型 | ||
lowweight | 最低重量, 单位KG | ||
highweight | 最高重量, 单位KG | ||
unit | 单位重量, 单位KG | ||
calcpricedata | 报价计算金额 | ||
calcformula | 报价计算公式 |
响应数据示例
json
{
"msg": "success",
"code": 0,
"data": [
{
"dest_area_name": "1区",
"destName": "美国",
"costList": [],
"channeltypecode": "Ocean Shipp",
"channel": {
"volume": "1000000",
"channelname": "YR美国海运收货",
"channelid": "yrhy"
},
"weightInfos": {
"totalVolume": "0.025",
"totalFinalWeight": "70",
"totalPiece": "4",
"m3": "0.025000",
"totalWeight": "70",
"weightFormula": "如果 结算重 < 21\n那么 返回 向上进位(结算重,0.5)\n否则 返回 向上进位(结算重,1)"
},
"weight": "70",
"shiptype": "专线",
"fuelCostRate": "含燃油",
"channel_productypes": [
{
"code": 1,
"channelid": "yrhy"
}
],
"unitprice": null,
"priceAging": "",
"channeltypename": "海运",
"trancostCalcDetail": [
{
"calcFormula": "70*11.5",
"realTransUnitprice": 11.5,
"tranCost": 805.0,
"priceWeightInfos": [
{
"calcpriceweight": 70.0,
"unit": 1.0,
"highweight": 99.0,
"lowweight": 0.0,
"serialid": 1,
"calcformula": "70*11.5",
"priceWeightType": "单价",
"pricepk": 162,
"type": 1,
"weightname": "21-99",
"goodstype": "WPX",
"calcpricedata": "11.5"
}
],
"unitprice": 11.5,
"calcNum": 1,
"calcWeight": 70.0
}
],
"priceUpdatetime": "2022-02-21 14:42:40",
"price": {
"note": "",
"pricename": "YR美国海运收货_20210323164359",
"ccycode": "RMB",
"pricepk": 162,
"calcflag": "1"
},
"totalCostFormula": null,
"totalCostCcy": "RMB",
"tranCost": 805.0,
"tranCostCcy": "RMB",
"goodstype": "包裹",
"totalCost": 805.0,
"fuelCost": null
}
]
}
{
"msg": "success",
"code": 0,
"data": [
{
"dest_area_name": "1区",
"destName": "美国",
"costList": [],
"channeltypecode": "Ocean Shipp",
"channel": {
"volume": "1000000",
"channelname": "YR美国海运收货",
"channelid": "yrhy"
},
"weightInfos": {
"totalVolume": "0.025",
"totalFinalWeight": "70",
"totalPiece": "4",
"m3": "0.025000",
"totalWeight": "70",
"weightFormula": "如果 结算重 < 21\n那么 返回 向上进位(结算重,0.5)\n否则 返回 向上进位(结算重,1)"
},
"weight": "70",
"shiptype": "专线",
"fuelCostRate": "含燃油",
"channel_productypes": [
{
"code": 1,
"channelid": "yrhy"
}
],
"unitprice": null,
"priceAging": "",
"channeltypename": "海运",
"trancostCalcDetail": [
{
"calcFormula": "70*11.5",
"realTransUnitprice": 11.5,
"tranCost": 805.0,
"priceWeightInfos": [
{
"calcpriceweight": 70.0,
"unit": 1.0,
"highweight": 99.0,
"lowweight": 0.0,
"serialid": 1,
"calcformula": "70*11.5",
"priceWeightType": "单价",
"pricepk": 162,
"type": 1,
"weightname": "21-99",
"goodstype": "WPX",
"calcpricedata": "11.5"
}
],
"unitprice": 11.5,
"calcNum": 1,
"calcWeight": 70.0
}
],
"priceUpdatetime": "2022-02-21 14:42:40",
"price": {
"note": "",
"pricename": "YR美国海运收货_20210323164359",
"ccycode": "RMB",
"pricepk": 162,
"calcflag": "1"
},
"totalCostFormula": null,
"totalCostCcy": "RMB",
"tranCost": 805.0,
"tranCostCcy": "RMB",
"goodstype": "包裹",
"totalCost": 805.0,
"fuelCost": null
}
]
}