---
title: "Creates a product recommendation"
method: POST
path: "/recommendation/product"
tags: ["Recommendation"]
---

# Creates a product recommendation

`POST /recommendation/product`

## Request

- The document declares no server URL.
- Auth: API key in header `TWN-InstanceKey` and API key in header `TWN-Authentication`

## Request body

- ProductRecommendationSubmitApiModel: Submit model for creating or updating a product recommendation.
  - `RecommendationId` integer, nullable: Product recommendation identifier. Required for update, ignored for create.
  - `Name` string: Name of the product recommendation.
  - `SourceCategoryId` integer, nullable: Source category identifier. Optional.
  - `ResultCategoryId` integer, nullable: Result category identifier. Optional.
  - `AmountOfResults` integer: Number of products to return.
  - `BuilderId` integer, nullable: Builder (Personal Merchandising) identifier. Optional.
  - `RecommendationRefinedSelection` 'None' | 'Category' | 'Attribute': Type of refined selection for featured and product recommendations.
  - `RefinedSelectionAttributeId` integer, nullable: Attribute identifier for refined selection when RefinedSelection is Attribute.
  - `GroupKeys` string[]: List of group keys. Non-nullable.
  - `Priority` integer, nullable: Priority. Optional.
  - `SourceFilters` ProductRecommendationSourceFilterApiModel[]: List of source filters (SourceFilters) for this recommendation.
    - `AttributeId` integer: Attribute identifier for this filter.
    - `Type` 'MultiValue' | 'Range': Type of filter for featured recommendation filters.
    - `Operator` 'Equals' | 'NotEquals': Operator for product recommendation source filters.
    - `Values` string[], nullable: Values for MultiValue filter type. Null for Range type.
    - `Min` integer, nullable: Minimum value for Range filter type. Null for MultiValue type.
    - `Max` integer, nullable: Maximum value for Range filter type. Null for MultiValue type.
  - `Filters` ProductRecommendationResultFilterApiModel[]: List of result filters (Filters) for this recommendation.
    - `AttributeId` integer: Attribute identifier for this filter.
    - `Operator` 'EqualsSource' | 'GreaterOrEqualSource' | 'LessThanSourceOrEqual' | 'OneOf' | 'Range' | 'NotEqualsSource' | 'RangePercentage' | 'NoneOf' | 'EqualsSourceAttribute': Operator for product recommendation result filters.
    - `Values` string[], nullable: Values for 'Equals' and 'NotEquals' operators only. Null otherwise.
    - `Min` integer, nullable: Minimum value for 'Range' and 'RangePercentage' operators only. Null otherwise.
    - `Max` integer, nullable: Maximum value for 'Range' and 'RangePercentage' operators only. Null otherwise.
    - `SourceAttributeId` integer, nullable: Source attribute identifier for 'EqualsSourceAttribute' operator only. Null otherwise.
  - `SortingId` integer: Sort option identifier. Required.
  - `IncludeExcludeParameters` integer[]: List of dynamic parameter attribute identifiers (IncludeExcludeParameters).

## Response `200`

OK

- integer

## Other responses

- `400`: Bad Request

---

[API](https://skmtc.dev/tweakwise/apis/app-api.md) - [All operations](https://skmtc.dev/tweakwise/apis/app-api/llms.txt) - [OpenAPI document](https://skmtc.dev/tweakwise/apis/app-api/revisions/dc936bf76941?raw)
