Methods
Last updated
Was this helpful?
Last updated
Was this helpful?
Basic shopping list methods will allow you to open or add products and recipes to the Whisk shopping list or open the Whisk add to basket screen.
viewList
method opens the shopping list.
addProductsToList
method allows you to add products not bound to any recipe to a shopping list.
ATTRIBUTE
TYPE
DESCRIPTION
products*
array [string]
List of products to add.
addProductsToBasket
method allows you to add products to online checkout basket. Note: this does not add products to the shopping list.
addRecipeToList
method allows you to add a recipe to the shopping list.
ATTRIBUTE
TYPE
DESCRIPTION
recipeUrl*
string
Recipe URL to add. Recipe should be recognized by the recipe validator.
scale
number
All ingredient quantities will be multiplied by this number
addRecipesToList
method allows you to add multiple recipes to the shopping list.
ATTRIBUTE
TYPE
DESCRIPTION
recipes*
Recipes URLs to add. Recipes should be recognized by the recipe validator.
ATTRIBUTE
TYPE
DESCRIPTION
recipeUrl*
string
Recipes URL. Recipe should be recognized by the recipe validator.
scale
number
All ingredient quantities will be multiplied by this number
addRecipeToBasket
method allows you to add a recipe to an online checkout basket. Note: this does not add the recipe to the shopping list.
ATTRIBUTE
TYPE
DESCRIPTION
language
enum
Shopping list app language. Possible values: en, de, fr. Default value: automatically defined based on browser language.
country
enum
Shopping list app country. Possible values: us, gb, de. Default value: automatically defined based on user location.
whiteLabel
string
Shopping list app design customisations. This is a premium feature for our partners.
trackingId
string
Unique identifier for your business (optional). This is a premium feature for our partners. Contact us to get one.
onlineCheckout
Object which configures shopping list app online checkout preferences.
styles
styles
Object which changes shopping list app appearance.
utm
Object with tracking params.
ATTRIBUTE
TYPE
DESCRIPTION
enabled
boolean
Set it to false if you want to disable online checkout completely. Default value: true.
allowedRetailers
array [enum]
List of available retailers in the shopping list app. [] - is equal to enabled: false. Default value: all available retailers.
defaultRetailer
enum
Default retailer for the shopping list app. You can find list of available retailers here. Note: you can pass null to unset a default value for new users. Default value: is defined by Whisk API.
autoPick
string
Set it to true to go straight to checkout in addRecipeToBasket and addProductsToBasket methods
ATTRIBUTE
TYPE
DESCRIPTION
campaign
string
Identifies a specific product promotion or strategic campaign.
source
string
Identifies which site sent the traffic, and is a required parameter.
medium
string
Identifies what type of link was used, such as cost per click or email.
content
string
Identifies what specifically was clicked to bring the user to the site, such as a banner ad or a text link.
term
string
Identifies search terms.
Supported list of parameters is under the section.
addProductsToList
method supports all , plus one extra required parameter:
addProductsToBasket
method supports all parameters from the method.
addRecipeToList method supports all , plus one extra required parameter:
addRecipesToList method supports all plus one extra required parameter:
array [string | ]
addRecipeToBasket
method supports all parameters from the method.