文档中心 > Dropshipping(已废弃)

aliexpress.trade.buy.placeorder (AE下单API)

150欧欧盟税改

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
param_place_order_request4_open_api_d_t_o PlaceOrderRequest4OpenApiDto 必须 下单具体参数
  • logistics_address
  • MaillingAddressRequestDto
  • 必须
  • 物流地址信息
  • └ address
  • String
  • 必须
  • sh Kashirskoe dom 142 (QIWI)
  • 地址信息
  • └ address2
  • String
  • 可选
  • sh Kashirskoe dom 142 (QIWI)
  • 地址扩展信息
  • └ city
  • String
  • 可选
  • Mosco
  • 城市
  • └ contact_person
  • String
  • 可选
  • RU TEST TEST
  • 联系人
  • └ country
  • String
  • 可选
  • RU
  • 国家
  • └ cpf
  • String
  • 可选
  • 111
  • cpf税号
  • └ full_name
  • String
  • 可选
  • RU TEST TEST
  • 收货人全称
  • └ locale
  • String
  • 可选
  • en_US
  • 国际化locale
  • └ mobile_no
  • String
  • 可选
  • 12334445
  • 电话号码
  • └ passport_no
  • String
  • 可选
  • 12345
  • 护照号
  • └ passport_no_date
  • String
  • 可选
  • 02-23-2018
  • 护照日期
  • └ passport_organization
  • String
  • 可选
  • xxxx
  • 护照签发机构
  • └ phone_country
  • String
  • 可选
  • +7
  • 电话所在国家区号
  • └ province
  • String
  • 可选
  • Mosco
  • 省份
  • └ tax_number
  • String
  • 可选
  • xxx
  • 税号
  • └ zip
  • String
  • 可选
  • 12222
  • 邮政编码
  • └ rut_no
  • String
  • 可选
  • 123-K
  • 智利税号
  • └ foreigner_passport_no
  • String
  • 可选
  • 123456789
  • 外籍税号(韩国外籍须填登陆证号或者护照号)
  • └ is_foreigner
  • String
  • 可选
  • true
  • 是否是外籍
  • └ vat_no
  • String
  • 可选
  • 123456778
  • vat税号
  • └ tax_company
  • String
  • 可选
  • Soceite General
  • 公司名称
  • └ location_tree_address_id
  • String
  • 可选
  • 903200190000000000-903200190137000000
  • 地址树ID
  • product_items
  • ProductBaseItem []
  • 必须
  • 商品属性
  • └ product_count
  • Number
  • 必须
  • 2
  • 商品数量
  • └ product_id
  • Number
  • 必须
  • 1223211
  • 商品id
  • └ sku_attr
  • String
  • 可选
  • 14:70221
  • 商品sku
  • └ logistics_service_name
  • String
  • 可选
  • EPAM
  • 物流服务名称
  • └ order_memo
  • String
  • 可选
  • Please put it in a gift box.
  • 用户留言

响应参数

名称 类型 示例值 描述
result PlaceOrderRes4OpenApiDto {} result
  • └ error_code
  • String
  • PARM_ILLEGL
  • errorCode
  • └ error_msg
  • String
  • param_illegl
  • errorMsg
  • └ order_list
  • Number []
  • 1000000000
  • orderList
  • └ is_success
  • Boolean
  • true
  • success

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AliexpressTradeBuyPlaceorderRequest req = new AliexpressTradeBuyPlaceorderRequest();
AliexpressTradeBuyPlaceorderRequest.PlaceOrderRequest4OpenApiDto obj1 = new AliexpressTradeBuyPlaceorderRequest.PlaceOrderRequest4OpenApiDto();
AliexpressTradeBuyPlaceorderRequest.MaillingAddressRequestDto obj2 = new AliexpressTradeBuyPlaceorderRequest.MaillingAddressRequestDto();
obj2.setAddress("sh Kashirskoe dom 142 (QIWI)");
obj2.setAddress2("sh Kashirskoe dom 142 (QIWI)");
obj2.setCity("Mosco");
obj2.setContactPerson("RU  TEST TEST");
obj2.setCountry("RU");
obj2.setCpf("111");
obj2.setFullName("RU  TEST TEST");
obj2.setLocale("en_US");
obj2.setMobileNo("12334445");
obj2.setPassportNo("12345");
obj2.setPassportNoDate("02-23-2018");
obj2.setPassportOrganization("xxxx");
obj2.setPhoneCountry("+7");
obj2.setProvince("Mosco");
obj2.setTaxNumber("xxx");
obj2.setZip("12222");
obj2.setRutNo("123-K");
obj2.setForeignerPassportNo("123456789");
obj2.setIsForeigner("true");
obj2.setVatNo("123456778");
obj2.setTaxCompany("Soceite General");
obj2.setLocationTreeAddressId("903200190000000000-903200190137000000");
obj1.setLogisticsAddress(obj2);
List<AliexpressTradeBuyPlaceorderRequest.ProductBaseItem> list4 = new ArrayList<AliexpressTradeBuyPlaceorderRequest.ProductBaseItem>();
AliexpressTradeBuyPlaceorderRequest.ProductBaseItem obj5 = new AliexpressTradeBuyPlaceorderRequest.ProductBaseItem();
list4.add(obj5);
obj5.setProductCount(2L);
obj5.setProductId(1223211L);
obj5.setSkuAttr("14:70221");
obj5.setLogisticsServiceName("EPAM");
obj5.setOrderMemo("Please put it in a gift box.");
obj1.setProductItems(list4);
req.setParamPlaceOrderRequest4OpenApiDTO(obj1);
AliexpressTradeBuyPlaceorderResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<aliexpress_trade_buy_placeorder_response>
    <result>
        <error_code>PARM_ILLEGL</error_code>
        <error_msg>param_illegl</error_msg>
        <order_list>
            <number>1000000000</number>
        </order_list>
        <is_success>true</is_success>
    </result>
</aliexpress_trade_buy_placeorder_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案
B_DROPSHIPPER_DELIVERY_ADDRESS_VALIDATE_FAIL 地址不符合规则 修改下单用户地址
BLACKLIST_BUYER_IN_LIST 黑名单买家 此用户暂时无法下单
USER_ACCOUNT_DISABLED buyer account has been disabled contact customer service for further information
PRICE_PAY_CURRENCY_ERROR products in the place order request should not be declared in different currencies products should declare as same currency
DELIVERY_METHOD_NOT_EXIST delivery method is not exist please fill valid delivery method
INVENTORY_HOLD_ERROR hold inventory error maybe inventory is insufficient or system error occured
REPEATED_ORDER_ERROR repeated placed order please check buyer order list, request already been handled successfully.
ERROR_WHEN_BUILD_FOR_PLACE_ORDER system error. please try again later.
A001_ORDER_CANNOT_BE_PLACED A001_ORDER_CANNOT_BE_PLACED A001_ORDER_CANNOT_BE_PLACED
A002_INVALID_ZONE A002_INVALID_ZONE A002_INVALID_ZONE
A003_SUSPICIOUS_BUYER A003_SUSPICIOUS_BUYER A003_SUSPICIOUS_BUYER
A004_CANNOT_USER_COUPON A004_CANNOT_USER_COUPON A004_CANNOT_USER_COUPON
A005_INVALID_COUNTRIES A005_INVALID_COUNTRIES A005_INVALID_COUNTRIES
A006_INVALID_ACCOUNT_INFO A006_INVALID_ACCOUNT_INFO A006_INVALID_ACCOUNT_INFO

API工具

如何获得此API

FAQ

返回
顶部