The Recipe API provides access to hundreds of thousands of creative recipes from all cuisines.
https://api.api-ninjas.com/v2/recipe
Get a list of recipes for a given recipe name or ingredient(s). Returns a list of recipes. To access more results, use the limit
parameter to limit the number of results and the offset
parameter to offset results for pagination in multiple API calls.
Either title
or ingredients
parameter must be provided.
title
optionalRecipe title to search for.
ingredients
optionalComma-separated list of ingredients to search for.
limit
optionalpremium onlyNumber of results to return. Must be between 1
and 30
. If not set, a default value of 1
will be used.
offset
optionalpremium onlyNumber of results to offset for pagination.
X-Api-Key
requiredAPI Key associated with your account.
https://api.api-ninjas.com/v2/recipe?title=lentil soup
Headers
X-Api-Key
Log in or sign up to get your API Key
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
[
{
"title": "Gramma's Lentil Soup with Garlic Bread",
"ingredients": [
"2 tb Oil",
"1 lg Onion; chopped",
"3 Garlic cloves; finely grated or pureed",
"1 Leek; finely chopped",
"3 lg Carrots; diced",
"3 Celery stalks; finely chopped",
"1 ts Paprika",
"1 ts Died mixed herbs",
"1 ts Gramma's Mild Pepper Sauce",
"2 ts Wine vinegar",
"3 oz Red lentils; rinsed",
"1 4 oz can tomatoes",
"2 pt Vegetable stock"
],
"servings": "6 servings",
"instructions": "1. Heat the oil in a pan and fry the onions until soft (about 5 minutes). 2. Add the garlic, leeks, carrots and celery and cook for 5 minutes, stirring occasionally. 3. Add the paprika, herbs, pepper sauce, vinegar, lentils, tomatoes and stock. Stir well. 4. Bring to the boil, then reduce heat and simmer for 40-50 minutes, stirring occasionally. 5. Remove from heat, leave to cool slightly, then liquidise in a food processor or blender, or pass through a large sieve. 6. Pour back into pan and reheat. Serve with hot toasted garlic bread."
}
]
1
2
curl -X GET "https://api.api-ninjas.com/v2/recipe?title=lentil%20soup" \
-H "X-Api-Key: YOUR_API_KEY"
If your programming language is not listed in the Code Example above, you can still make API calls by using a HTTP request library written in your programming language and following the above documentation.