After Sales List

🔒

Requires read_order access scope. More access scope

The After Sales List API retrieves a list of after-sales records (e.g., returns or exchanges) associated with orders. By specifying various query parameters, you can filter and paginate the list of after-sales items based on status, creation date, and more.

This API is especially useful for:

  1. Monitoring and managing post-purchase activities (like returns or refunds).
  2. Filtering after-sales records by status for streamlined customer service.
  3. Tracking metrics on pending, processing, and finished after-sales requests.

Request Parameters

Public Request Parameters

📘

Public Request Parameters

Query Parameters

NameTypeRequiredDescExample
statusstringNoAfter-sales status. Can be one of: pending, processing, or finished."pending"
pageint32NoPage number for pagination. Defaults to 1 if not provided.1
per_pageint32NoNumber of records per page (limit). Defaults vary (often 20) if not specified.20
created_at_startstringNoFilter to include records created after this date/time (ISO 8601)."2016-01-18T23:41:00Z"
created_at_endstringNoFilter to include records created before this date/time (ISO 8601)."2016-01-18T23:41:00Z"

Response Explanation

Public Response Parameters

📘

Public Response Parameters

Success Response

NameTypeDescriptionExample
countnumberTotal number of after-sales records matching the query.4
pending_countnumberNumber of after-sales records with status pending.2
processing_countnumberNumber of after-sales records with status processing.0
post_salesarrayAn array of after-sales objects, each containing detailed information.(See below for details.)
post_sales[].browser_ipstringThe IP address from which the after-sales request was made."183.15.177.205"
post_sales[].created_atstring (timestamp)The date/time the after-sales record was created."2024-04-22T07:22:51Z"
post_sales[].credit_card_numberstringThe last few digits of the credit card used (if any)."0000"
post_sales[].currency_codestringThe currency code (e.g., "CNY", "USD")."CNY"
post_sales[].customer_namestringThe customer’s name."zhang senjun"
post_sales[].devicestringThe device type used when placing the order."PC"
post_sales[].discount_codestringAny discount code applied to the original order.""
post_sales[].financial_statusstringThe financial status of the original order (e.g., "partially_refunded")."partially_refunded"
post_sales[].fulfillment_statusstringThe fulfillment/shipping status of the original order."waiting"
post_sales[].fulfillmentsarrayArray of fulfillment objects (if any).[]
post_sales[].idstringUnique identifier for this after-sales record."e18d1fc2-df36-4d6e-8e03-f1586d..."
post_sales[].line_itemsarrayA list of line items associated with this after-sales record.(See line item details below.)
post_sales[].numberstringThe after-sales document number (often the original order number plus a suffix)."00000013-S1"
post_sales[].order_numberstringThe original order number."00000013"
post_sales[].order_totalstringThe total price of the original order."242.00"
post_sales[].payment_methodstringThe payment method used for the original order."bogus_gateway"
post_sales[].recipient_namestringThe name of the recipient in shipping details."test test"
post_sales[].sales_platformstringThe platform on which the sale took place (e.g., "shoplazza")."shoplazza"
post_sales[].shipping_address_extra_infoobjectAny extra shipping address info provided.{}
post_sales[].shipping_countrystringThe country of the shipping address."China mainland"
post_sales[].shipping_emailstringThe email used for shipping notifications."[email protected]"
post_sales[].shipping_line_namestringThe name of the shipping method/line."test"
post_sales[].shipping_phonestringThe phone number for the shipping address."+8615014471143"
post_sales[].sourcestringThe URL or source reference for the original order."https://test-shoplazza.stg..."
post_sales[].source_namestring (JSON)A JSON string with additional source data."{\"created_at\":\"\",\"data\":\"\"}"
post_sales[].placed_atstring (timestamp)The date/time the original order was placed."2024-04-22T07:21:48Z"
post_sales[].refund_amountstringThe total amount refunded for this after-sales request."162.00"
post_sales[].post_sale_notestringAny note regarding this after-sales request.""
post_sales[].last_referrer_showstring (JSON)A JSON string describing the last referrer data, if any."{\"created_at\":\"\",\"data\":\"\"}"
post_sales[].last_landing_urlstringThe last landing page URL recorded for the order.""
post_sales[].shipping_line_descstringDescription of the shipping line, if any."11111"
post_sales[].delivery_methodnumberDelivery method identifier (custom usage).1
post_sales[].shipping_tax_totalstringTotal shipping tax for the original order."0.00"
post_sales[].shipping_tax_typenumberType of shipping tax.0
post_sales[].all_tax_totalstringThe total tax on the order."0.00"
post_sales[].shop_namestringThe shop name associated with the order.""
post_sales[].staff_contactstringContact info for any staff associated with this after-sales record.""
post_sales[].statusstringThe status of the after-sales request. Common values: pending, processing, or finished."finished"

Line Items (Inside post_sales[].line_items[])

NameTypeDescriptionExample
compare_at_pricestringOriginal price before discount, if any."97.00"
fulfillment_statusstringFulfillment status of this line item (e.g., "waiting")."waiting"
fulfillmentarrayArray of fulfillment objects (if any).[]
idstringUnique identifier for this line item."31d95f28-baf0-47c9-ad53-dbf3833f1b85"
image.altstringAlternate text for the product image.""
image.heightnumberHeight dimension of the product image.180
image.pathstringInternal path or reference for the image."ccf0794c594bad32a320eea0d6bfe40c.jpeg"
image.srcstringURL or relative path to the product image."//cdn.shoplazza.com/ccf0794c594bad32a320e..."
image.widthnumberWidth dimension of the product image.174
notestringAny note associated with this line item.""
options[]arrayArray of option objects, typically describing variant attributes (e.g., size).[{"name":"size","value":"L"}, ...]
pricestringUnit price for this item."81.00"
product_handlestringThe handle/slug for the product."shirt"
product_idstringThe ID of the product."a1a88be0-a1d4-47e4-a2f2-ba6e131cf447"
product_tags[]arrayArray of tags associated with this product.["s1-s2"]
product_titlestringThe product title."shirt"
propertiesstringAny custom properties in string or JSON format.""
quantitynumberNumber of units purchased (and reflected in the after-sales request).2
refund_discountstringDiscount portion of the refund (if any)."0.00"
refund_pricestringPrice portion of the refund (if any)."0.00"
refund_quantitynumberNumber of units refunded for this line item.1
refund_taxstringTax portion of the refund (if any)."0.00"
refund_totalstringTotal refunded amount (including price, tax, discount) for this line item."162.00"
requires_shippingbooleanIndicates if this item requires shipping.true
skustringStock Keeping Unit for the variant."T-M-L-red-S-A001011"
spustringStock Product Unit or a general product code."T-M"
taxablebooleanIndicates if the item is taxable.true
totalstringTotal cost for this line item (price * quantity)."162.00"
variant_idstringThe variant’s unique ID."cbd7a7b0-5dd7-4902-9466-e21bd02688b4"
variant_titlestringThe title describing the variant attributes."L-red-S"
vendorstringThe vendor or brand for this item."shoplazza"
weightstringThe unit weight of this item."1.10"
weight_unitstringUnit of weight measurement (e.g., "kg", "lb")."kg"
vendor_urlstringA URL pointing to the vendor site, if applicable."https://shoplazza.com"
oversold_quantitynumberQuantity sold beyond available inventory (if overselling is allowed).0
main_currency_prices.compare_at_pricestringThe compare-at price in the main/store currency."13.4"
main_currency_prices.pricestringThe unit price in the main currency."11.19"
main_currency_prices.totalstringThe total price (main_currency_prices.price * quantity)."22.38"
main_currency_prices.actual_ratestringThe actual exchange rate used for conversion."7.239804"

Error Response

Error responses in the API can be represented using two different fields: errors and error. Both fields provide details about issues encountered during request processing. Below is an explanation of the fields with their respective examples and descriptions.

FieldTypeExampleDescription
errorString "store is not active"Indicates an error encountered during the process

Error Detail

Status CodeMessagePossible ReasonExample Response
400Bad RequestInvalid input format or request structure (e.g., missing required fields or incorrect data types).Bad Request
UnauthorizedThe request is missing valid authentication credentials or the credentials provided are invalid.Unauthorized

API Structure Overview

Language
Credentials
Header
URL
Click Try It! to start a request and see the response here!