Sizebay Tracker via API
Starter Guide
ATTENTION: The asterisk (*
) symbol, when placed next to a field or item in forms or documentation, typically denotes that the information is mandatory or required.
ATTENTION: Sending the country value is only mandatory if you want to segregate the data by country. If there is no need to segregate by country, you can proceed without providing this information.
1. Adding products to the cart
An important step in the process is when the user adds a product to the shopping cart. This a very important moment and indicates that the user has actually engaged with the product (or with the offer).
Cart
POST
https://vfr-v3-production.sizebay.technology/plugin/new/cart?sid=*
Endpoint for adding the product in the cart.
Headers Parameters
x-szb-country
string
Country running plugin (ex: BR, US, MX, DE)
x-szb-device*
string
User device
Possible values: DESKTOP, MOBILE, TABLET, APP
x-szb-tenant-id*
string
Store ID
referer*
string
The referer must be the (domain) of the store, for example: “store.sizebay.com”, without https://.
Query Parameters
sid
string
User identification
Request Body
payload
object
Payload with all products added to cart
The SID must me retrieved from the cookies, identified as SIZEBAY_SESSION_ID_V4
Payload Example:
Field
Type
Description
tenantId
string
Sizebay Store ID
products
array
Array containing the product permalink
permalink
string
Product URL
Important: The tenantId should be provided by our Support Team (support@sizebay.com)
2. Finalizing the order
The checkout page is the most important page in the process, as it represents the sale itself. It is through the sales indicators that the exchanges/returns rate of the products sold are analyzed.
ATTENTION: Sending the country value is only mandatory if you want to segregate the data by country. If there is no need to segregate by country, you can proceed without providing this information.
Ordered
POST
https://vfr-v3-production.sizebay.technology/plugin/new/ordered?sid=*
Endpoint to register a new order.
Headers Parameters
x-szb-country
string
Country running plugin (ex: BR, US, MX, DE)
x-szb-device*
string
User device
Possible values: DESKTOP, MOBILE, TABLET, APP
x-szb-tenant-id*
string
Store ID
referer*
string
The referer must be the (domain) of the store, for example: “store.sizebay.com”, without https://.
Query Parameters
sid
string
User identification
Request Body
payload
object
Payload with the order information
The SID must me retrieved from the cookies, identified as SIZEBAY_SESSION_ID_V4
Field
Type
Description
tenantId
string
Sizebay Store ID
orderId
string
Must be filled in with the order code generated as soon as the purchase is made. It is with this information that we will be able to track this shopping experience in case of a future exchanged/returned product
items
array
Array with the various items that were sold in this purchased order. There are no product limits to be included. Each product has the attributes described below:
permalink
string
Product URL. It must be the same used in the shopping cart
price
float
The price of the product sold
quantity
int
Number of itens
size
string
Clothing size ordered
feedProductId
string
global product id (id for all variations)
sku
string
Id of product variation
currency
string
Currency applied to the ordered item
Important: For the complete list of supported countries and currencies, please head over to the session Sizebay Tracker - Supported Countries and Currencies
Important: The tenantId should be provided by our Support Team (support@sizebay.com)
Important: The price of the product sold must be sent in your store's default currency. If your store sells in different currencies, convert the product price and send the value in the default currency. The values sent will be added up and shown in your store's reports, so it is very important that they are sent in a single currency.
Last updated