Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Weekly Challenges

Solve the challenge, share your solution and summit the ranks of our Community!

Also available in | Français | Português | Español | 日本語
IDEAS WANTED

Want to get involved? We're always looking for ideas and content for Weekly Challenges.

SUBMIT YOUR IDEA

Challenge #139: Spooky API Connection

AngelosPachis
16 - Nebula

My solution for challenge #139

 

Spoiler
Annotation 2020-06-22 165611.png
JethroChen
10 - Fireball
Spoiler
challenge_139_jc.PNG
AkimasaKajitani
17 - Castor
17 - Castor

My solution.

 

I use another API(https://fdc.nal.usda.gov/api-guide.html ) by DEMO_KEY.

But downloaded data don't have calories of the Snickers.

 

Spoiler

AkimasaKajitani_0-1601994694657.png

 

soroosj
8 - Asteroid

Here is my solution.

 

Really interesting learning more about APIs.

 

As other have noted, the results are a bit different than original poster because of the new USDA API and food identifiers.

Capture.PNG

 

mpennington
11 - Bolide

Like others, I had to revise provided IDs.  Otherwise, seemed straightforward enough. Pleased that I was able to keep the tool count low.

 

Spoiler
MP 139.jpg
phottovy
13 - Pulsar
13 - Pulsar

Thank you to @mpennington for the updated IDs. Attached is my solution.

JasonHu
8 - Asteroid
Spoiler
workflow.png

Here is my submission; I spend a long time looking for the NDB ID, but then I realised that it is from the old system, then the only way is to use the search parameter and pick the first one from each candy, the total calories is slightly less than the answer. But I think the logic is correct. Also, the calories are per 100g, not per bag that shows from the website.

Qiu
20 - Arcturus
20 - Arcturus
Spoiler
Challenge_139.PNG
Watermark
12 - Quasar
12 - Quasar
Spoiler
MT Solution 139.png

LiuZhang
9 - Comet
Spoiler
139.png

It's all about find the correct api call now.

Used: https://fdc.nal.usda.gov/api-guide.html#bkmk-1

Got reasonable close to the answer