Skip to content

Create Customization

POST
View MD

Create a new recommendation customization with a target scope and list of pin definitions.

ParameterTypeRequiredDescription
TRACKER_IDstringYour unique tracker identifier.
HeaderValueDescription
Content-Typeapplication/json; charset=utf-8Required.
DateHTTP dateRequired for HMAC.
AuthorizationApiAuth {TRACKER_ID}:{SIGNATURE}Required for HMAC.
ParameterTypeRequiredDescription
modelstringRecommender model, for example basket.
target_typestringScope type: item, criteria, or all.
target_identitystringCond.Target item ID when target_type is item.
target_criteriaobjectCond.Criteria definition when target_type is criteria.
tagsarrayOrganizational tags for the scope.
target_metadataobjectCond.Optional item metadata, commonly title or image data.
pin_definitionsarrayList of pin objects to apply.
ParameterTypeRequiredDescription
positionintegerPin position. Use -1 for global and 0 for block.
pin_typestringitem or criteria.
pin_identitystringCond.Item ID when pin_type is item.
pin_criteriaobjectCond.Criteria definition when pin_type is criteria.
widget_idstringWidget identifier for the pin.
is_block_pinbooleanExcludes matching items when true.
is_bundle_pinbooleanMarks the pin as a bundle pin.
active_fromdate-timeISO 8601 start time.
active_todate-timeISO 8601 end time.
  1. Build the HMAC string from the method, content type, date, and request path.
  2. Generate the Base64-encoded HMAC SHA-256 signature with your private key.
  3. Send the JSON body together with Date, Content-Type, and Authorization headers.

The response returns the created customization object with its generated ID.

FieldTypeDescription
idstringUnique identifier of the customization.
modelstringRecommender model.
target_typestringTarget scope type.
created_atstringCreation timestamp.
HTTP StatusDescription
201 CreatedCustomization created successfully.
400 Bad RequestInvalid configuration provided.
401 UnauthorizedMissing or invalid authentication.
404 Not FoundTracker not found.
422 Unprocessable EntityInvalid pin definition provided.