Autocomplete

The Autocomplete endpoint allows you to retrieve a list of the most popular ingredients and products in a specific language. You can use it to add the autocomplete functionality to your application.

get
Get

https://cdn.whisk.com/autocomplete/v1/{language-tag}/{file-type}.json
This endpoint allows you to get free cakes.
Request
Response
Request
Query Parameters
language-tag
required
string
The language and locale tag. See the detailed description below.
file-type
required
object
The amount of data you will be getting in the product list. See the detailed description below.
Response
200: OK
{
"products": [
{
"name": "ANCHOVY",
"displayName": "Acciuga",
"imageUrl": "https://whisk-res.cloudinary.com/image/upload/v1550764890/graph/fooddb/cdd6c37ccd140664a46573d10e2fde25.jpg",
"metadata": {
"category": "MEATS AND SEAFOOD",
"storing": {
"pantry": {
"metric": "Years",
"min": 1,
"max": 1
},
"defaultLocation": "Pantry"
}
},
"nounForm": "singular"
}
]
}

language-tag

This parameter determines the language and locale of the autocomplete list. For example, en-us.

Supported Languages and Locales

Language Code

Locale Code

Default Locale

en

gb, us

gb

es

es, mx

es

fr

fr

-

sv

se

-

de

de

-

zh

cn

-

ko

-

-

it

-

-

no

-

-

For English, the tag could be:

Tag

Description

en-us

US product names in English.

en-gb

GB product names in English.

en

Defaults to en-gb

file-type

This parameter allows you to control the amount of data you will be getting in the product list. The available options are:

Option

Description

all

Complete data (all items with full content).

all-slim

All items are returned but they do not include metadata information.

food

Only food items with metadata are returned. Check the sample response below for more information.

food-slim

Only food items are returned but they do not include metadata.

Sample Request and Response

Curl Request
Response
Curl Request
curl "https://cdn.whisk.com/autocomplete/v1/it/all.json" \
-H "Accept-Encoding: deflate, gzip" \
-H "If-Modified-Since: Wed, 04 Mar 2020 10:30:58"

Response
{
"products": [
{
"name": "ANCHOVY",
"displayName": "Acciuga",
"imageUrl": "https://whisk-res.cloudinary.com/image/upload/v1550764890/graph/fooddb/cdd6c37ccd140664a46573d10e2fde25.jpg",
"metadata": {
"category": "MEATS AND SEAFOOD",
"storing": {
"pantry": {
"metric": "Years",
"min": 1,
"max": 1
},
"defaultLocation": "Pantry"
}
},
"nounForm": "singular"
}
]
}

Attribute

Type

Description

name

string

The canonical name of the product, identical for all languages.

displayName

string

The name of the product in the selected language.

imageUrl

string

The link to the product’s image.

nounForm

string

Indicates if the product name is singular, plural or invariant.

metadata

array

See the description below.

Metadata

Attribute

Type

Description

category

string

The product’s category.

sorting

string

The product’s storing recommendation.