Recipe - Food - Nutrition

FREEMIUM
Verified
By David | Updated לפני 4 ימים | Food
Popularity

9.9 / 10

Latency

536ms

Service Level

100%

Health Check

N/A

Back to All Discussions

Cannot make fillIngredients= true when I call this API using Alamofire

Rapid account: Msun 36
msun36
לפני 8 שנים

Hi, I found a problem when I try to call complex search method:
var parameters = String:AnyObject
parameters[“cusine”] = cusine
parameters[“diet”]=diet
parameters[ “excludeIngredients”]=excludeIngredients
parameters[“fillIngredients”]=true
parameters[ “includeIngredients”]=includeIngredients
parameters [“intolerances”]=intolerances
parameters[“limitLicense”]=false
checkNutritions()
parameters[ “maxCalories”]=maxCalories
parameters[ “maxCarbs”]=maxCarbs
parameters[“maxFat”]=maxFat
parameters[“maxProtein”]=maxProtein
parameters[“minCalories”]=minCalories
parameters[“minCarbs”]=minCarbs
parameters[“minFat”]=minFat
parameters[“minProtein”]=minProtein
parameters[“number”]=30
parameters[“offset”]=0
parameters[“query”]=query
parameters[“ranking”]=1
parameters[“type”]=type
var servingPeople:Int?
var readyTimeMinutes:Int?
Alamofire.request(.GET, “https://spoonacular-recipe-food-nutrition-v1.p.mashape.com/recipes/searchComplex”, parameters: parameters, encoding: ParameterEncoding.URL,headers: head) .responseJSON{ response in……

my code is like that and I set fillIngredients as true but when I call this method the result doesn’t give me any information about missing ingredients. Does anyone know swift/alamofire could help me with this?

Rapid account: Spoonacular
spoonacular Commented לפני 8 שנים

Sorry, I have no experience with alamofire 😕 Maybe they have forums where you can ask? If it turns out to be a problem with the API feel free to reopen this ticket.

Best,
David

Join in the discussion - add comment below:

Login / Signup to post new comments