Skip to main content
POST
/
product
/
events
Send product events
curl --request POST \
  --url https://eu-data.kameleoon.io/product/events \
  --header 'Content-Type: */*' \
  --data '"<string>"'

Documentation Index

Fetch the complete documentation index at: https://docs.kameleoon.com/llms.txt

Use this file to discover all available pages before exploring further.

Query Parameters

siteCode
string
required

Id of the Kameleoon project

ean
string

Product Id / EAN. Note: if EAN is provided here, then it is assumed as the common value for all events in the body (bulk posting of several events restricted to the same product EAN). On the contrary, if you would like to bulk post several events across several different products EAN, then you must provide the EAN with every event in the body

json
boolean
default:false

Set to true if you provide the body content in JSON format, else URL query format is assumed. See body schema

Body

*/*

Save events. The body size limit is 3 MB.

If the json query parameter is missing or set to false, the body consists of one or more lines. Each line represents an event in the following format: <parameter 1 name>=<parameter 1 value>&<parameter 2 name>=<parameter 2 value> and so on. Escape values that may contain characters = or &, for example, using the encodeURIComponent JavaScript function.

If the json query parameter is set to true, provide the body as a JSON array of events. Represent each event as a JSON object, formatted like this: { "<parameter 1 name>": <parameter 1 value>, "<parameter 2 name>": <parameter 2 value>, etc. }.

In all cases, the body contains the following parameters:

NameTypeRequiredDescription
eanstringRequiredProduct code
Limit to 100 characters
noncestringRequiredA random string of 16 hexadecimal characters, unique to each event.
eventTypestringRequiredOne of the following: PRODUCTPAGE, PRODUCTADDTOCART, PRODUCTBUY


List of parameters for the eventType PRODUCTPAGE:
NameTypeRequiredDescription
namestringOptionalProduct name
Limit to 250 characters
categoriesJSON arrayOptionalA JSON array of product categories. Limit to 100 categories.
urlstringOptionalProduct URL
Limit to 2048 characters
imageURLstringOptionalURL of product picture
Limit to 2048 characters
availablebooleanOptionalIs the product available?
availableQuantityint32OptionalProduct quantity available
brandstringOptionalProduct brand
Limit to 250 characters
isChildbooleanOptionalIs the product for children?
isFashionbooleanOptionalDoes the product follow fashion trends?
fashionJSON objectOptionalFashion details.
skustringOptionalProduct SKU
Limit to 100 characters
merchantIDstringOptionalProduct merchant ID
Limit to 100 characters
pricefloat64OptionalProduct price
oldPricefloat64OptionalProduct old price
tagsJSON arrayOptionalA JSON array of product tags.
ratingfloat64OptionalProduct rating
descriptionstringOptionalProduct description
Limit to 4000 characters
paramsJSON arrayOptionalA JSON array of product params.
groupIdstringOptionalProduct group ID
Limit to 100 characters
accessoriesJSON arrayOptionalA JSON array of product accessories.
seasonalityJSON arrayOptionalA JSON array of months (1-12).
priceMarginint32OptionalProduct price margin
isNewbooleanOptionalIs the product new?
autoJSON objectOptionalAuto details.
modelstringOptionalProduct model
Limit to 100 characters
leftoversstringOptionalProduct leftovers
Limit to 100 characters
typePrefixstringOptionalProduct type prefix
Limit to 100 characters


List of parameters for the eventType PRODUCTADDTOCART:
NameTypeRequiredDescription
quantityint32RequiredQuantity of product added to cart


List of parameters for the eventType PRODUCTBUY:
NameTypeRequiredDescription
quantityint32RequiredQuantity of product bought


Note: In these examples, Kameleoon assumes you provide the ean parameter in the URL query part.

Body example if the URL query parameter json is missing or its value is false:
eventType=PRODUCTPAGE&name=Marvelous%20product&available=true&availableQuantity=50&sizes=%5B%22S%22%2C%20%22M%22%2C%20%22L%22%5D
eventType=PRODUCTADDTOCART&quantity=2

Body example if the URL query parameter json is true (pretty representation):
[
{
"eventType": "PRODUCTPAGE",
"name": "Marvelous product",
"available": true,
"availableQuantity": 50,
"isFashion": true,
"fashion": {
"sizes": [
"S",
"M",
"L"
]
}
},
{
"eventType": "PRODUCTADDTOCART",
"quantity": 2
}
]

Body example if the URL query parameter json is true (compact representation):
[{"eventType":"PRODUCTPAGE","name":"Marvelous product","available":true,"availableQuantity":50,"isFashion":true,"fashion":{"sizes":["S","M","L"]}},{"eventType":"PRODUCTADDTOCART","quantity":2}]

The body is of type string<UTF-8>.

Response

Kameleoon processed the URL query and accepted the request. The response returns no content.
Kameleoon processes the body asynchronously and has not checked the body syntax yet.