Query Order Details

Last Updated on : 2024-01-12 02:41:38download

Query the details of a specified order based on mall code, store code, buyer's user ID (UID), and order ID.

API address

GET: /v1.0/mall/plugin/order/{order_id}

Request parameter

Parameter nameTypeINRequiredDescription
mall_codeStringquerytrueThe code of a specified mall.
shop_codeStringquerytrueThe code of a specified store.
user_idStringquerytrueThe buyer's user ID (UID).
order_idStringuritrueThe order number.

Return parameter

Parameter nameTypeDescription
resultOrderDetailOpenApiVOThe returned result.

Description of result

Parameter nameTypeDescription
mall_codeStringThe code of a specified mall.
shop_codeStringThe code of a specified store.
order_idStringThe order number.
pay_statusStringThe status of payment.
delivery_statusStringThe status of delivery.
created_timeLongThe time when it is created.
current_total_priceBigDecimalThe current total price.
total_shipping_priceBigDecimalThe total postage fee.
total_tax_priceBigDecimalThe total tax fee.
total_priceBigDecimalThe total price.
currencyStringThe type of currency.
delivery_listListThe logistics information.
cancel_reasonStringThe reason for canceling a specified order.
canceled_timeLongThe time when a specified order is canceled.
commodity_listListThe list of commodities in the order.
billing_addressAddressModelOpenApiVOThe billing address of a specified payer.
shipping_addressAddressModelOpenApiVOThe shipping address of a specified payer.

Description of commodity_list

Parameter nameTypeDescription
titleStringThe name of a specified commodity.
skuStringThe unique code of a specified SKU.
availableBooleanIndicates whether the commodity is available for sale.
pricePriceModelOpenApiVOThe price.
weightBigDecimalThe weight.
quantityIntegerThe purchase quantity.
imageStringThe image URL of a specified commodity.
selected_optionsListThe list of commodity attributes.

Description of delivery_list

Parameter nameTypeDescription
logistics_companyStringThe express company.
logistics_noStringThe tracking number.
logistics_urlStringThe logistics URL.

Description of billing_address

Parameter nameTypeDescription
country_codeStringThe code of a specified country or region.
province_codeStringThe code of a specified province.
countryStringThe name of a specified country or region.
provinceStringThe name of a specified province.
cityStringThe name of a specified city.
addressStringThe detailed address.
zipStringThe postal code.
latitudeStringThe latitude.
longitudeStringThe longitude.
nameStringThe name.
first_nameStringThe first name.
last_nameStringThe last name.
phoneStringThe mobile phone number.

Description of shipping_address

Parameter nameTypeDescription
country_codeStringThe code of a specified country or region.
province_codeStringThe code of a specified province.
countryStringThe name of a specified country or region.
provinceStringThe name of a specified province.
cityStringThe name of a specified city.
addressStringThe detailed address.
zipStringThe postal code.
latitudeStringThe latitude.
longitudeStringThe longitude.
nameStringThe name.
first_nameStringThe first name.
last_nameStringThe last name.
phoneStringThe mobile phone number.

Description of selected_options

Parameter nameTypeDescription
nameStringThe name of a specified attribute.
valueStringThe value of a specified attribute.

Description of price

Parameter nameTypeDescription
amountBigDecimalThe amount.
currencyStringThe type of currency.

Request example

GET: /v1.0/mall/plugin/order/1234567?mall_code=MALL_CODE&shop_code=SHOP_CODE&user_id=USER_ID&order_id=ORDER_ID
{
  "mall_code": "testMallCode",
  "shop_code": "testShopCode",
  "user_id": "testUserId",
  "order_id": "testOrderId"
}

Return example

{
    "created_time": "20220901",
    "subtotal_price": 2,
    "canceled_time": "20220902",
    "total_price": 2,
    "shop_code": "testShopCode",
    "delivery_list": [
        {
            "logistics_no": "1Z2345",
            "logistics_url": "https://tools.usps.com/go/TrackConfirmAction_input?qtc_tLabels1=1Z2***",
            "logistics_company": "USPS"
        }
    ],
    "total_tax_price": 1,
    "billing_address": {
        "zip": "40202",
        "country": "United States",
        "address": "Chestnut Street ***",
        "city": "Louisville",
        "latitude": "45.41634",
        "last_name": "Norman",
        "province_code": "KY",
        "country_code": "US",
        "province": "Kentucky",
        "phone": "555-625-11**",
        "name": "Bob Norman",
        "first_name": "Bob",
        "longitude": "-75.6868"
    },
    "total_shipping_price": 1,
    "commodity_list": [
        {
            "image": "xxx",
            "quantity": 1,
            "selected_options": [
                {
                    "name": "Color",
                    "value": "Blue"
                }
            ],
            "available": true,
            "weight": 10,
            "title": "IPod Nano - 8gb",
            "price": {
                "amount": 2,
                "currency": "USD"
            },
            "id": 466157049,
            "sku": "IPOD2008*****"
        }
    ],
    "pay_status": "paid",
    "cancel_reason": "The reason for calceling a specified order",
    "mall_code": "testMallCode",
    "current_total_price": 10,
    "currency": "USD",
    "shipping_address": {
        "zip": "40202",
        "country": "United States",
        "address": "Chestnut Street **",
        "city": "Louisville",
        "latitude": "45.41634",
        "last_name": "Norman",
        "province_code": "KY",
        "country_code": "US",
        "province": "Kentucky",
        "phone": "555-625-11**",
        "name": "Bob Norman",
        "first_name": "Bob",
        "longitude": "-75.6868"
    },
    "order_id": "testOrderId",
    "delivery_status": "shipped"
}

Error code

For more information, see error code.