ZapietId
What is the ZapietId?
The _ZapietId is integral to our Rates functionality. At least one item in your customers basket must contain a valid _ZapietId line item property otherwise rates will fail to generate correctly within the checkout process.
The _ZapietId is made up of the following three parameters:
Adding the _ZapietId to a line item
If you are using our default widget the _ZapietId property is automatically added to your order. Should you be building your own storefront widget you can use Shopify's Cart API https://shopify.dev/docs/themes/ajax-api/reference/cart.
Alternatively if you are building a mobile app or using a headless commerce solution you may prefer to use the Draft Orders API https://shopify.dev/docs/admin-api/rest/reference/orders/draftorder.
The line item must be called _ZapietId including the prepending underscore.
Generating the _ZapietId
Below is a javascript example of how you might generate a _ZapietId.
Last updated