Recipe - Food - Nutrition

FREEMIUM
Verified
Par David | Mise à jour 24 दिन पहले | Food
Popularité

9.9 / 10

Latence

1,479ms

Niveau de service

100%

Health Check

N/A

Retour à toutes les discussions

How to get the recipes for the category?

Rapid account: Wsawalhi
wsawalhi
7 वर्ष पहले

Hi

I used the Search Recipes API to get the recipes for the category such as breakfast, lunch, dinner, dessert, vegan, healthy, salad, soups, drinks.
I filled the Type field with one of categories.
But I didn’t get any result.

And I didn’t get the same result when I call this API with the parameters in doc.
Request:
https://spoonacular-recipe-food-nutrition-v1.p.mashape.com/recipes/search?diet=vegetarian&excludeIngredients=coconut&intolerances=egg%2C+gluten&limitLicense=false&number=10&offset=0&query=burger&type=main+course

Result:
{
“results”: [],
“baseUri”: “https://spoonacular.com/recipeImages/”,
“offset”: 0,
“number”: 10,
“totalResults”: 0,
“processingTimeMs”: 381,
“expires”: 1480487790002,
“isStale”: false
}

My Requirements:

  1. Is this API right to get the recipes for the category?
  2. If this API is not right, please tell me what API I should use.
  3. If this API is right, please check the sample request and tell me how to use this API.

Thanks.

Rapid account: Spoonacular
spoonacular Commented 7 वर्ष पहले

All this information comes when you call the recipe information endpoint or you can use the complex search endpoint and set the addRecipeInformation parameter to true.

Best,
David

Rapid account: Wsawalhi
wsawalhi Commented 7 वर्ष पहले

Hi

I want to get the recipes for the several kinds of category such as breakfast, lunch, dinner, dessert, vegan, healthy, salad, soups, drinks.
Please let me know about the API for that.

Thanks

Rapid account: Spoonacular
spoonacular Commented 7 वर्ष पहले

Hi,

  1. Yes it is, your example request also works for me. I get burgers (which are main courses) as responses.
  2. does not apply (you can however also use the complex search endpoint for more options)
  3. You use it correctly. Maybe I didn’t quite understand you current problem. Please let me know if I’m not understanding something correctly.

Best,
David

Participez à la discussion - ajoutez un commentaire ci-dessous:

Connectez-vous / Inscrivez-vous pour publier de nouveaux commentaires