世联翻译公司完成接口开发规范中文翻译_世联翻译公司

首页 > 新闻中心 > 翻译公司资讯 >

世联翻译公司完成接口开发规范中文翻译

世联翻译公司完成接口开发规范中文翻译
1 关于本手册
1.1 资源
http://www.w3.org/XML/
1.2 支持
Please contact 599943@fedex.com
2 货物跟踪
2.1 货物跟踪服务介绍
您可以使用联邦快递国内限时货物跟踪服务获得实时的货物跟踪信息。
2.2 根据运单号进行货物跟踪
2.2.1 说明
您可以通过运单号跟踪国内限时服务的包裹。
2.2.2 请求格式
采用GET方法请求,具体样例参见
2.2.3 应答格式
共有3种应答格式,详见如下:
2.2.3.1 单件货物详细信息
样例:
<?xml version="1.0" encoding="UTF-8"?>
<fedex-express>
<tracking>
<detail>
<tn>120120136268</tn>
<ptn></ptn>
<destination>深圳</destination>
<shipdate>2007-05-28 18:00:00</shipdate>
<sentby>颜红霞</sentby>
<deliveredto>廖正宏</deliveredto>
<signedforby>杨昌元</signedforby>
<service>优先达</service>
<deliverydate>2007-05-29 15:23:00</deliverydate>
<status>到达联邦快递工作地点</status>
<activities>
<activity>
<datetime>2008-05-06 10:41:40</datetime>
<scan>到达联邦快递工作地点</scan>
<location>上海</location>
联邦快递国内服务接口开发规范
Page 3 Printed 12/21/2012
<details></details>
</activity>
<activity>
<datetime>2007-05-29 15:23:00</datetime>
<scan>已送达</scan>
<location>深圳</location>
<details></details>
</activity>
<activity>
<datetime>2007-05-29 08:30:52</datetime>
<scan>货件已装车,派送途中</scan>
<location>深圳</location>
<details></details>
</activity>
<activity>
<datetime>2007-05-29 07:40:18</datetime>
<scan>位于当地的联邦快递递送站</scan>
<location>深圳</location>
<details></details>
</activity>
<activity>
<datetime>2007-05-28 18:00:00</datetime>
<scan>已取件</scan>
<location>上海</location>
<details></details>
</activity>
</activities>
</detail>
</tracking>
</fedex-express>
 
字段含义:
字段名 含义 类型
tn  运单号 String 
ptn  主运单号,为空时表示改件为一票一件 String 
destination  目的地 String 
shipdate  寄件日期 String 
sentby  寄件人 String 
deliveredto  收件人 String 
signedforby  签收人 String 
servicetype  服务类型 String 
deliverydate  收件日期 String 
status  该件货物最新状态 String 
datetime  该件货物该次活动时间 String 
scancode  该件货物该次活动内容 String 
location  该件货物该次活动地点 String 
details  该件货物该次活动详细信息 String 
 
2.2.3.2 多件货物汇总
样例:
<?xml version="1.0" encoding="UTF-8"?>
<fedex-express>
<tracking>
<summary>
<single>
<ts>
<tn>120120136268</tn>
<status>到达联邦快递工作地点</status>
<datetime>2008-05-06 10:41:40</datetime>
<destination>深圳</destination>
<service>优先达</service>
</ts>
<ts>
<tn>120120136268</tn>
<status>到达联邦快递工作地点</status>
<datetime>2008-05-06 10:41:40</datetime>
<destination>深圳</destination>
<service>优先达</service>
</ts>
</single>
<mps>
<ts>
<tn>120120004950</tn>
<status>递送例外情况</status>
<datetime>2007-06-18 12:27:49</datetime>
<destination>长沙</destination>
<service>优先达</service>
</ts>
</mps>
<missing>
<tn>230120136268</tn>
<tn>230120136268</tn>
</missing>
<invalid>
<tn>123</tn>
</invalid>
<exception></exception>
</summary>
</tracking>
</fedex-express>
 
字段含义:
字段名 含义 类型
tn  运单号 String 
status  该件货物最新状态 String 
datetime  该件货物最新状态时间 String 
destination  目的地 String 
service  服务 String 
2.2.3.3 一票多件汇总
样例:
<?xml version="1.0" encoding="UTF-8"?>
<fedex-express>
<tracking>
<mps>
<ts isp="true">
<tn>120120004950</tn>
<status>递送例外情况</status>
<datetime>2007-06-18 12:27:49</datetime>
<destination>长沙</destination>
<service>优先达</service>
</ts>
<ts isp="false">
<tn>210116898750</tn>
<status>递送例外情况</status>
<datetime>2007-06-18 12:27:49</datetime>
<destination>长沙</destination>
<service>优先达</service>
</ts>
</mps>
</tracking>
</fedex-express>
 
字段含义:
字段名 含义 类型
tn  运单号 String 
status  该件货物最新状态 String 
datetime  该件货物最新状态时间 String 
destination  目的地 String 
service  服务 String 
 
2.2.4 查询单个运单
2.2.4.1 请求方法:
本查询支持中文和英文,默认为中文:
GET http://example.example.ex/service/track/xxxxxxxxxxxx
英文访问地址为:
GET http://example.example.ex/service/track.en/xxxxxxxxxxxx
2.2.4.2 应答:
如果该件货物为一票多件,返回内容为汇总信息,参见2.2.3.3,如欲查询该票货物下某一件货物详细信息,需要再次发送请求,请求方法为:
GET http://example.example.ex/service/track/xxxxxxxxxxxx/XXXXXXXXXXXX
获得的应答内容参见2.2.3.1
 
如果该件货物为一票一件,返回内容参见2.2.3.1
如果该件货物未能正常查询出来,返回内容参见2.2.3.2
2.2.5 查询多个运单
2.2.5.1 请求方法
GET http://example.example.ex/service/track/xxxxxxxxxxxx,xxxxxxxxxxxx
运单号之间以“,”分隔。
2.2.5.2 应答
返回内容为汇总信息,参见2.2.3.2,如欲查询其中某一件货物详细信息,需要再次发送请求,请求方法为:
GET http://example.example.ex/service/track/xxxxxxxxxxxx,xxxxxxxxxxxx/XXXXXXXXXX如果该件货物为一票一件,返回内容参见2.2.3.1
如果该件货物为一票多件,返回内容为汇总信息,参见2.2.3.3,如欲查询该票货物下某一件货物详细信息,需要再次发送请求,请求方法为:
GET
http://example.example.ex/service/track/xxxxxxxxxxxx,xxxxxxxxxxxx/XXXXXXXXXXXX/xxxxxxxxxxxx
获得的应答内容参见2.2.3.1
2.3 根据订单号进行货物跟踪请求接口及应答
2.3.1 说明
您可以通过订单号跟踪国内限时服务的包裹。
2.3.2 请求格式
采用GET方法请求,具体样例参见
2.3.3 应答格式
共有2种应答格式,详见如下:
2.3.3.1 单件货物详细信息
样例:
<?xml version="1.0" encoding="UTF-8"?>
<fedex-express>
<tracking order=”0953770932427”>
<detail>
<tn>120120136268</tn>
<ptn></ptn>
<destination>深圳</destination>
<shipdate>2007-05-28 18:00:00</shipdate>
<sentby>颜红霞</sentby>
<deliveredto>廖正宏</deliveredto>
<signedforby>杨昌元</signedforby>
<service>优先达</service>
<deliverydate>2007-05-29 15:23:00</deliverydate>
<status>到达联邦快递工作地点</status>
<activities>
<activity>
<datetime>2008-05-06 10:41:40</datetime>
<scan>到达联邦快递工作地点</scan>
<location>上海</location>
<details></details>
</activity>
<activity>
<datetime>2007-05-29 15:23:00</datetime>
<scan>已送达</scan>
<location>深圳</location>
<details></details>
</activity>
<activity>
<datetime>2007-05-29 08:30:52</datetime>
<scan>货件已装车,派送途中</scan>
<location>深圳</location>
<details></details>
</activity>
<activity>
<datetime>2007-05-29 07:40:18</datetime>
<scan>位于当地的联邦快递递送站</scan>
<location>深圳</location>
<details></details>
</activity>
<activity>
<datetime>2007-05-28 18:00:00</datetime>
<scan>已取件</scan>
<location>上海</location>
字段含义:
字段名 含义 类型
order  订单号 String 
tn  运单号 String 
ptn  主运单号,为空时表示改件为一票一件 String 
destination  目的地 String 
shipdate  寄件日期 String 
sentby  寄件人 String 
deliveredto  收件人 String 
signedforby  签收人 String 
servicetype  服务类型 String 
deliverydate  收件日期 String 
status  该件货物最新状态 String 
datetime  该件货物该次活动时间 String 
scancode  该件货物该次活动内容 String 
location  该件货物该次活动地点 String 
details  该件货物该次活动详细信息 String 
 
2.3.3.2 一票多件汇总
样例:
<?xml version="1.0" encoding="UTF-8"?>
<fedex-express order=”0953770932427”>
<tracking>
<mps>
<ts isp="true">
<tn>120120004950</tn>
<status>递送例外情况</status>
<datetime>2007-06-18 12:27:49</datetime>
<destination>长沙</destination>
<details></details>
</activity>
</activities>
</detail>
</tracking>
</fedex-express>
<service>优先达</service>
</ts>
<ts isp="false">
<tn>210116898750</tn>
<status>递送例外情况</status>
<datetime>2007-06-18 12:27:49</datetime>
<destination>长沙</destination>
<service>优先达</service>
</ts>
</mps>
</tracking>
</fedex-express>
字段含义:
字段名 含义 类型
order  订单号 String 
tn  运单号 String 
status  该件货物最新状态 String 
datetime  该件货物最新状态时间 String 
destination  目的地 String 
service  服务 String 
2.3.4 查询订单
2.3.4.1 请求方法:
本查询支持中文和英文,默认为中文:
GET http://example.example.ex/service/mctrack/xxxx/xxxxxxxxxxxx
英文访问地址为:
GET http://example.example.ex/service/mctrack.en/xxxx/xxxxxxxxxxxx
2.3.4.2 应答:
如果该件货物为一票多件,返回内容为汇总信息,参见2.3.3.2,如欲查询该票货物下某一件货物详细信息,需要再次发送请求,请求方法为:
GET http://example.example.ex/service/mctrack/xxxx/xxxxxxxxxxxx/XXXXXXXXXXXX
获得的应答内容参见2.3.3.1
如果该件货物为一票一件,返回内容参见2.3.3.1
2.4 访问地址
由于不同客户使用的访问地址可能不同,具体地址请和销售部门联系,谢谢。
 
3 SERVICE CHECKING
3.1 Service Checking 服务v1.2介绍
您可以通过提供一个邮编对(始发地邮编及目的地邮编)来查询两个邮编对之间存在的服务、递送时限、电话取件截止时间等信息。
3.2 请求格式
采用POST 方法请求/ecs/service/
3.2.1 请求头格式:
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified">
<xs:element name="RequestDocument" type="RequestDocumentType" />
<xs:complexType name="RequestDocumentType">
<xs:sequence>
<xs:element name="head" type="RequestDocumentHeadType"
minOccurs="1" maxOccurs="1" /> <!-- head of request -->
<xs:element name="body" type="xs:anyType" minOccurs="1"
maxOccurs="1" /> <!-- content of request -->
</xs:sequence>
</xs:complexType>
<xs:complexType name="RequestDocumentHeadType">
<xs:sequence>
<xs:element name="serialId" minOccurs="0" maxOccurs="1"
nillable="true"> <!-- serial id to match with the message request/response
pair -->
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern
value="[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}" />
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="serviceId" type="xs:string" minOccurs="1"
maxOccurs="1" /> <!-- service id -->
<xs:element name="requesterId" type="xs:string" minOccurs="1"
maxOccurs="1" /> <!-- requester id -->
</xs:sequence>
<xs:attribute name="version" type="xs:string" default="1.0" /> <!-- schema version -->
</xs:complexType>
</xs:schema>
3.2.2 请求体格式
即RequestDocument的body内部的格式
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://cndxp.apac.fedex.com/ecs/remote/schema"
xmlns="http://cndxp.apac.fedex.com/ecs/remote/schema"
elementFormDefault="qualified">
<xs:complexType name="LogisticServicePublicRequestType">
<xs:sequence>
<xs:element name="senderPostalCode" type="xs:string"
minOccurs="1" maxOccurs="1" />
<xs:element name="recipientPostalCode" type="xs:string"
minOccurs="1" maxOccurs="1" />
<xs:element name="pickupDate" type="xs:string"
minOccurs="1" maxOccurs="1" />
</xs:sequence>
<xs:attribute name="version" type="xs:string" default="1.0" /> <!-- schema version -->
</xs:complexType>
</xs:schema>
具体参见样例
3.2.3 请求样例:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<RequestDocument xmlns:sch="http://cndxp.apac.fedex.com/ecs/remote/schema">
<head version="1.0"> 请求消息头版本号,缺省为1.0
 
<serialId>1e690757-87e1-4b0a-84fa-2352f724ddd6</serialId> 消息对编号,uuid格式
<serviceId>SERVICE_0002</serviceId> 服务代码,必填
<requesterId>CUSTOMER_ID</requesterId> 请求方代码,必填,大小写敏感
</head>
<body xsi:type="LogisticCodServicePublicRequestType" version="1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<senderPostalCode>200042</senderPostalCode> 始发地邮编,必填
<recipientPostalCode>100017</recipientPostalCode> 目的地邮编,必填
<pickupDate>2013-01-05</pickupDate> 取件日期,必填
</body>
</RequestDocument>
 
3.2.4 字段含义:
字段名 含义 类型
serialId  消息对编号 UUID 
serviceId  服务代码 String 
requesterId  请求方代码 String 
senderPostalCode  始发地邮编 String 
recipientPostalCode  目的地邮编 String 
pickupDate  取件日期 String 
 
3.3 应答格式
共有2 类应答格式,正常应答格式和异常应答格式。
3.3.1 应答头格式:
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified">
<xs:element name="ResponseDocument" type="ResponseDocumentType" />
<xs:complexType name="ResponseDocumentType">
<xs:sequence>
<xs:element name="head" type="ResponseDocumentHeadType"
minOccurs="1" maxOccurs="1" /> <!-- head of response -->
<xs:element name="body" type="xs:anyType" minOccurs="1"
maxOccurs="1" nillable="true" /> <!-- content of response -->
</xs:sequence>
</xs:complexType>
<xs:complexType name="ResponseDocumentHeadType">
<xs:sequence>
<xs:element name="serialId" minOccurs="0" maxOccurs="1"
nillable="true"> <!-- serial id to match with the message request/response
pair -->
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern
value="[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}" />
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="serviceId" type="xs:string" minOccurs="1"
maxOccurs="1" /> <!-- service id -->
<xs:element name="successFlag" type="xs:boolean"
minOccurs="1" maxOccurs="1" /> <!-- "true": success; "false": fail -->
<xs:element name="errorCode" type="xs:string" minOccurs="0"
maxOccurs="1" nillable="true" /> <!-- predefined error code if the
successFlag is false -->
<xs:element name="errorMessage" type="xs:string"
minOccurs="0" maxOccurs="1" nillable="true" /> <!-- the detail error
message of the error code -->
</xs:sequence>
<xs:attribute name="version" type="xs:string" default="1.0" /> <!-- schema version -->
</xs:complexType>
</xs:schema>
 
3.3.2 应答体格式:
即ResponseDocument的body 内部的格式
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://cndxp.apac.fedex.com/ecs/remote/schema"
xmlns="http://cndxp.apac.fedex.com/ecs/remote/schema"
elementFormDefault="qualified">
<xs:complexType name="LogisticServicePublicResponseType">
<xs:sequence>
<xs:element name="logisticService" type="LogisticServicePublicType"
minOccurs="0" maxOccurs="unbounded" nillable="true" />
</xs:sequence>
<xs:attribute name="version" type="xs:string" default="1.0" /> <!-- schema version -->
</xs:complexType>
<xs:complexType name="LogisticServicePublicType">
<xs:sequence>
<xs:element name="serviceCode" type="xs:string" minOccurs="1"
maxOccurs="1" /> <!-- FedEx logistic service code -->
<xs:element name="cutOffTime" type="xs:string" minOccurs="1"
maxOccurs="1" /> <!-- latest pickup time -->
<xs:element name="isCod" type=”xs:int"
minOccurs="1" maxOccurs="1" />
<xs:element name="transitDays" type=”xs:int"
minOccurs="1" maxOccurs="1" />
<xs:element name="transitDate" type="xs:string"
minOccurs=”1” maxOccurs=”1”/>
</xs:sequence>
</xs:complexType>
</xs:schema>
 
详见如下样例
3.3.3 正常应答样例:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ResponseDocument xmlns:sch="http://cndxp.apac.fedex.com/ecs/remote/schema">
<head version="1.0"> 响应消息头版本号,缺省为1.0
<serialId>1e690757-87e1-4b0a-84fa-2352f724ddd6</serialId> 消息对编号,UUID格式(与所处理的请求消息的消息编号一致)
<serviceId>SERVICE_0002</serviceId> 服务代码
<successFlag>true</successFlag> 服务是否正常响应,若为true,则从body 中获取响应内容
</head>
<body xsi:type="sch:LogisticServicePublicResponseType" version="1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">响应消息体版本号,缺省为1.0
<logisticService>
<serviceCode>PDS</serviceCode> 服务代码
<cutOffTime>17:30:00</cutOffTime> 截止取件时间
<isCod>1</isCod> 有COD 业务
<transitDays>1</transitDays> 运送天数
<transitDate>2013-01-03 18:00:00</transitDate> 预计送达日期时间
</logisticService>
<logisticService>
<serviceCode>99TS</serviceCode> 服务代码
<cutOffTime>17:30:00</cutOffTime> 截止取件时间
<isCod>1</ isCod> 有COD 业务
<transitDays>3</transitDays> 运送天数
<transitDate>2013-01-05 18:00:00</transitDate> 预计送达日期时间
</logisticService>
</body>
</ResponseDocument>
 
3.3.4 异常应答样例(请求中没有填写始发地邮编):
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ResponseDocument xmlns:sch="http://cndxp.apac.fedex.com/ecs/remote/schema">
<head version="1.0">
<serviceId>SERVICE_0002</serviceId>
<successFlag>false</successFlag> 服务是否正常响应,若为false,则从errorCode中获取异常代码,从errorMessage中获取异常信息
<errorCode>BUS_ERR_000004</errorCode> 异常代码,BUS前缀为业务异常,SYS前缀为系统异常
<errorMessage>Not found sender postal code!</errorMessage> 异常消息
</head>
<body xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
</ResponseDocument>
 
3.3.5 异常应答样例(请求中没有填写目的地邮编):
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ResponseDocument xmlns:sch="http://cndxp.apac.fedex.com/ecs/remote/schema">
<head version="1.0">
<serviceId>SERVICE_0002</serviceId>
<successFlag>false</successFlag>
<errorCode>BUS_ERR_000005</errorCode>
<errorMessage>Not found recipient postal code!</errorMessage>
</head>
<body xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
</ResponseDocument>
 
3.3.6 字段含义:
字段名 含义 类型
serialId  消息对编号 UUID 
serviceId  服务代码 String 
successFlag  服务是否正常响应(若为false, 则从errorCode 中获取异 Boolean 
常代码,从errorMessage 中获取异常信息) 
serviceCode  服务代码 String 
cutOffTime  截至取件时间 String 
isCod  COD 业务:1=有,0=无 Int 
transitDays  运输天数 Int 
TransitDate  预计派送日期时间YYYY-MM-DD hh24:mi:ss  String 
errorCode  异常代码(BUS 前缀为业务异常,SYS 前缀为系统异常)  String 
errorMessage  异常消息 String 
3.4 异常代码
3.4.1 业务异常代码:
异常代码 含义
BUS_ERR_000001  NOT_FOUND_REQUEST_SERVICE 
BUS_ERR_000002  NOT_FOUND_REQUEST_BODY 
BUS_ERR_000003  MISMATCH_REQUEST_BODY_TYPE 
BUS_ERR_000004  NOT_FOUND_SENDER_POSTAL 
BUS_ERR_000005  NOT_FOUND_RECIPIENT_POSTAL 
BUS_ERR_000006  RAISED_BY_INERNAL_SERVICE_QUERY_LOGISTIC_SERVICE 
BUS_ERR_000007  ILLEGAL_INTERNAL_SERVICE_REQUEST_FORMAT 
BUS_ERR_000008  ILLEGAL_INTERNAL_SERVICE_RESPONSE_FORMAT 
BUS_ERR_000009  FAIL_CONVERT_INTERNAL_SERVICE_RESPONSE_TO_XML 
BUS_ERR_0000010  NOT_FOUND_PICKUP_DATE 
BUS_ERR_0000011  NOT_FOUND_SERVICE_SUPPORT_MESSAGE 
BUS_ERR_0000012  NOT_FOUND_MSG_FROM_POSTAL_SERVICE 
BUS_ERR_0000013  ERR_FORMAT_PICKUP_DATE 
 
3.4.2 系统异常代码:
异常代码 含义
SYS_ERR_0000  CAUSED_BY_SYSTEM_OF_SERVICE_QUERY_LOGISTIC_SERVICE 
01 
SYS_ERR_0000  CAUSED_BY_SYSTEM_OF_INERNAL_SERVICE_QUERY_LOGISTIC_S 
02  ERVICE 
 
3.5 服务地址
请和Sales 联系。
Version  Date  Description of Change  By 
V 1.0  March 16, 2009  First Draft  Li-xi  Yao 
V 1.1  August16, 2009  Adding tracking by order  Li-xi  Yao 
V 1.2  Sep 26, 2009  Example update  Xing-Kun Tang 
V 1.3  Sep 22, 2011  Append Service Checking  Ian Bao 
V 1.3.1  Oct 11, 2011  CUSTOMER_ID  Ian Bao 
V 1.3.2  Dec 29, 2011  Change Key Contact & Doc Management  Han-Yue Li 
V 1.3.3  Dec 21, 2012  PDS  Han-Yue Li 
 
世联翻译-让世界自由沟通!专业的全球语言翻译供应商,上海翻译公司专业品牌。丝路沿线56种语言一站式翻译与技术解决方案,专业英语翻译日语翻译等文档翻译、同传口译、视频翻译、出国外派服务,加速您的全球交付。 世联翻译公司在北京、上海、深圳等国际交往城市设有翻译基地,业务覆盖全国城市。每天有近百万字节的信息和贸易通过世联走向全球!积累了大量政商用户数据,翻译人才库数据,多语种语料库大数据。世联品牌和服务品质已得到政务防务和国际组织、跨国公司和大中型企业等近万用户的认可。