Checkout updated
| Event Group | Event Identification |
|---|---|
| checkouts | checkouts/update |
Occurs whenever a checkout page is updated.
Request Headers
- Content-Type string requiredThe field must be set to the fixed value
application/json; charset=utf-8. - X-Shopline-Topic string requiredThe unique identifier for the event.Example:
orders/edited - X-Shopline-Hmac-Sha256 string requiredThe signature of the request. Upon receiving the request, you must verify the signature to confirm the authenticity and integrity of the data.Example:
XWmrwMey6OsLMeiZKwP4FppHH3cmAiiJJAweH5Jo4bM= - X-Shopline-Shop-Domain string requiredThe store domain.Example:
example.myshopline.com - X-Shopline-Shop-Id string requiredThe store ID.Example:
1610418123456 - X-Shopline-Merchant-Id string requiredThe merchant ID.Example:
2000001234 - X-Shopline-API-Version string requiredThe API version.Example:
v20250601 - X-Shopline-Webhook-Id string requiredThe ID of this Webhook event.Example:
b54557e48a5fbf7d70bcd043
Request Body
- abandoned_checkout_url stringThe link to the abandoned checkout.Example:
https://example.myshopline.com/trade/checkouts/c2c4a7b0c586a273f781c271f6a1b6f6?mark=345B5E216A2080FBA20456099D2B8468A895199B21CA87BAE83141EF693C0033 applied_discountsobject[]
Discounts or promotions applied at the order level.amount stringThe discount amount, rounded to two decimal places and displayed in the currency corresponding topresentment_currency.Example:8.00application_type stringDiscount type. Valid values are:MANUAL_DISCOUNT: manual discountFULL_DISCOUNT: bulk discount or free shippingTIME_LIMITED: time-limited promotionBUNDLED: bundle combinationDISCOUNT_CODE: discount codeGIFT: gift promotionPRE_ORDER: pre-order
target_selection stringThe discount scope. Valid values are:explicit: Applies to an individual productentitled: Applies to the entire line itemall: Iftarget_typeisline_item, the discount applies to the entire order. Iftarget_typeisshipping_line, the discount applies to the shipping fee.
target_type stringThe target that the discount applies to. Valid values:line_item: The discount applies to the line item.shipping_line: The discount applies to the shipping fee.
title stringThe title of the discount promotion.value stringThe specific value of the discount.- When
value_typeisfix_amount, this field value represents a specific discount amount. For example, if the value is10and the currency is CNY, it means a discount of 10 yuan. - When
value_typeispercentage, the value of this field value represents a specific discount percentage. For example,10means 10% off of the order amount.
value_type stringThe type of discountvalue. Valid values are:fix_amount: Fixed amount discount. For example, ifvalueis10in CNY, it means a discount of 10 yuan.percentage: Percentage-based discount. For example, ifvalueis10, it means 10% off of the order amount.
billing_addressobject
The address for sending billing invoices.address1 stringThe first line of the address. This typically includes information such as the street address or a post office box number.address2 stringThe second line of the address. This typically includes information such as apartment, suite, or unit number.city stringThe city in the address.Example:New Yorkcountry stringThe country or region in the address.Example:USAcountry_code stringA two-letter country or region code that follows the ISO 3166-1 standard, used to identify a specific country or region in the address.Example:USfirst_name stringThe first name of the billing recipient.last_name stringThe last name of the billing recipient.name stringThe full name of the billing recipient.phone stringThe phone number of the billing recipient.province stringThe province in the address.Example:Californiaprovince_code stringThe code for the province in the address, which can be a custom code or a two-character ISO 3166-2 international code.Example:4200006zip stringThe postal code information of the billing address.- buyer_accepts_marketing booleanWhether the buyer has subscribed to promotion and order update information.
true: subscribedfalse: not subscribed
- cart_token stringThe unique credential for shopping cart data.Example:
c4a54360f2b2460fbb6973bb80406111 - closed_at stringThe date and time when the checkout was closed. Format: ISO 8601. The closing process occurs in the following two ways:
- Automatic closing: The system automatically closes the checkout if the order is not completed within 60 days.
- Order generation: Closing is triggered when an order is generated through the abandoned checkout.
Example:2024-08-31T02:20:26+08:00 - completed_at stringThe date and time when the checkout was completed. Format: ISO 8601.Example:
2024-08-31T02:20:26+08:00 - created_at stringThe date and time when the checkout was created. Format: ISO 8601.Example:
2024-08-31T02:20:26+08:00 - currency stringThree-letter currency code, displayed in the store's currency and following the ISO 4217 international standard.Example:
USD customerobject
Buyer information.addressesobject
Buyer's address information.address1 stringThe first line of the buyer address. This typically includes information such as the street address or a post office box number.address2 stringThe second line of the buyer address. This typically includes information such as apartment, suite, or unit number.city stringThe city in the address.Example:New Yorkcountry stringThe country or region in the address.Example:USAcountry_code stringA two-letter country or region code that follows the ISO 3166-1 standard, used to identify a specific country or region in the address.Example:USfirst_name stringThe first name of the buyer.last_name stringThe last name of the buyer.name stringThe full name of the buyer.phone stringThe phone number of the buyer.province stringThe province in the address.Example:Californiaprovince_code stringThe code for the province in the address, which can be a custom code or a two-character ISO 3166-2 international code.Example:4200006zip stringThe postal code information of the address.Example:92503currency stringThree-letter currency code, displayed in the store's currency and following the ISO 4217 international standard.Example:USDemail stringThe email of the buyer.Example:example@example.comfirst_name stringThe first name of the buyer.id stringBuyer's ID.Example:4201057495last_name stringThe last name of the buyer.phone stringThe phone number of the buyer.discount_codesobject[]
List of discount codes.amount doubleDiscount code amount. The value is rounded to two decimal places and displayed in the currency corresponding topresentment_currency.Example:8title stringThe title of the discount code promotion.type integerActivity type at the order level. Valid values are:1: Amount reduction2: Discount(percentage off)3: Free shipping4: Marked-up item5: Preferential price for any N items6: Preferential price for A+B combination7: Free gift8: Fixed selling price9: Lowest-priced item free10: Bundle price11: Discount for Nth item12: Buy X get Y free13: Customized
- email stringCustomer's contact email.Example:
email@example.cpm - id stringThe unique credential for the checkout.Example:
c2c4a7b1e182e894f6e194a99489f870 line_itemsobject[]
Checkout item information list.applied_discountsobject[]
Discounts or promotions applied at the line item level.amount stringThe discount amount, rounded to two decimal places and displayed in the currency corresponding topresentment_currency.Example:8.00application_type stringDiscount type. Valid values are:MANUAL_DISCOUNT: manual discountFULL_DISCOUNT: bulk discount or free shippingTIME_LIMITED: time-limited promotionBUNDLED: bundle combinationDISCOUNT_CODE: discount codeGIFT: gift promotionPRE_ORDER: pre-order
target_selection stringThe discount scope. Valid values are:explicit: Applies to an individual productentitled: Applies to the entire line itemall: Iftarget_typeisline_item, the discount applies to the entire order. Iftarget_typeisshipping_line, the discount applies to the shipping fee.
target_type stringThe target that the discount applies to. Valid values:line_item: The discount applies to the line item.shipping_line: The discount applies to the shipping fee.
title stringThe title of the discount promotion.value stringThe specific value of the discount.- When
value_typeisfix_amount, this field value represents a specific discount amount. For example, if the value is10and the currency is CNY, it means a discount of 10 yuan. - When
value_typeispercentage, the value of this field value represents a specific discount percentage. For example,10means 10% off of the order amount.
value_type stringThe type of discount value. Valid values are:fix_amount: Fixed amount discount. For example, ifvalueis10in CNY, it means a discount of 10 yuan.percentage: Percentage-based discount. For example, ifvalueis10, it means 10% off of the order amount.
gift_card booleanWhether the product is a gift card.true: gift cardfalse: not a gift card
grams doubleThe weight of the product in grams(g).Example:100line_price doubleLine item price. The amount is calculated by multiplying the product's selling price by quantity. The value is rounded to two decimal places and displayed in the currency corresponding topresentment_currency.presentment_title stringThe title of the current product.Example:8.00price doubleThe price of the products, rounded to two decimal places and displayed in the currency corresponding topresentment_currency.product_id stringThe unique identifier for the product.Example:16060214426601453066501487propertiesobject[]
A list of product customization information.name stringCustom attribute name.show booleanWhether the customized information is visible.true: visiblefalse: not visible
urls arrayURL list.- If
typeispicture, thumbnails are retrieved via theurlsvalues. - If
typeislink, the hyperlink is the first URL in theurlsvalues.
value stringCustom attribute value.quantity integerQuantity of items in the order.requires_shipping booleanIndicates whether the product is subject to shipping.true: Shipping is required.false: Shipping is not required.
sku stringProduct SKU serial number.Example:18065562457702740835053185tax_linesobject[]
A list of tax information.price doubleThe tax amount, rounded to two decimal places and displayed in the currency corresponding topresentment_currency.Example:8tax_no stringThe tax identification number.Example:385642title stringThe title for the tax description, for display only.type stringOrder tax type. Valid values are:product_tax: product taxshipping_tax: shipping taxduty_tax: duty tax
taxable booleanWhether the product is subject to tax.true: Tax is required.false: No tax is required.
title stringThe title of the product.user_id stringBuyer's ID.Example:4603327877variant_id stringThe unique identifier for the variant.variant_price doubleThe price of the product, rounded to two decimal places and displayed in the currency corresponding topresentment_currency.Example:8- name stringThe string formed by concatenating a
#with the unique checkout credential.Example:#c2c4a7b1e182e894f6e194a99489f870 - note stringBuyer's note.
note_attributesobject[]
Information added by the merchant to the checkout.name stringThe name of the custom attribute.value stringThe value of the custom attribute.- phone stringThe user's contact phone number.
- phone_area_code stringThe international dialing code for the phone number.Example:
+1 - presentment_currency stringCurrency of the current checkout. If the merchant has set up the multi-market currency, it refers to the currency of the corresponding market for the checkout; otherwise, it is the store's currency. It is a three-letter currency code following the ISO 4217 international standard.Example:
USD shipping_addressobject
The address used for receiving packages.address1 stringThe first line of the address. This typically includes information such as the street address or a post office box number.address2 stringThe second line of the address. This typically includes information such as apartment, suite, or unit number.city stringThe city in the address.Example:New Yorkcountry stringThe country or region in the address.Example:USAcountry_code stringA two-letter country or region code that follows the ISO 3166-1 standard, used to identify a specific country or region in the address.Example:USfirst_name stringThe first name of the recipient.last_name stringThe last name of the recipient.name stringThe full name of the recipient.phone stringThe phone number of the recipient.province stringThe province in the address.Example:Californiaprovince_code stringThe code for the province in the address, which can be a custom code or a two-character ISO 3166-2 international code.Example:4200006zip stringThe postal code information of the address.Example:92503shipping_linesobject[]
A list of shipping fees.code stringReturnsLocal deliveryonly for local shipping methods.delivery_name stringThe name of the shipping fee plan.delivery_seq stringThe delivery method ID.Example:DP7026099381353365514logistics_amount doubleThe shipping fee amount. The value is rounded to two decimal places and displayed in the currency corresponding topresentment_currency.Example:8phone stringBuyer's phone.- sub_total_price doubleThe discounted price of the product. The value is rounded to two decimal places and displayed in the currency corresponding to
presentment_currency.Example:8 - taxes_included booleanWhether the order includes a tax amount.
true: tax amount includedfalse: tax amount not included
- token stringThe unique credential for the checkout.Example:
c2c4a7b1e182e894f6e194a99489f870 - total_discount stringThe total discount amount. The value is rounded to two decimal places and displayed in the currency corresponding to
presentment_currency. - total_duties stringThe total tariff amount. The value is rounded to two decimal places and displayed in the currency corresponding to
presentment_currency.Example:8.00 - total_price doubleThe total discounted order amount, including shipping fees and taxes. The value is rounded to two decimal places and displayed in the currency corresponding to
presentment_currency. - total_tax stringThe total tax amount of the order. The value is rounded to two decimal places and displayed in the currency corresponding to
presentment_currency.Example:8.00 - total_weight doubleThe total weight of the products, in grams (g).
- update_at stringThe date and time when the checkout was updated. Format: ISO 8601.Example:
2024-08-31T02:20:26+08:00 - user_id stringBuyer's ID.Example:
4603327877
Status Codes
After receiving a webhook notification from SHOPLINE, you must respond with the following format:
HTTP/1.1 200 OKFor more information about how to subscribe to webhooks and webhook response rules, refer to Webhook overview.
Was this article helpful to you?