Inspiration
I make this for vanhackathon BROADBANDTV mealnutrition challenge
What it does
restfull api to get nutrition information for ingredient from a recipe
How I built it
Using PHP with slim framework.
How to run:
routes:
/recipes - return 1 result(using regex to match) for a ingredient with nutrients. /recipesfull - return all result of ingredient with nutrients.
How use:
The simple way is using php internal server inside public folder
php -S 0.0.0.0:8000
Then make a post with this:
Method: POST
Header Content-Type: application/json
Json: {"recipes":["ingredient1","ingredient2"], "api_key":"yourkey"}
Example CURL: curl -H "Content-Type: application/json" -X POST -d '{"recipes":["cider"],"api_key":"DEMO_KEY" }' http://localhost:8000/recipes
Built With
- php
- slim-php

Log in or sign up for Devpost to join the conversation.