Plan-My-Dinner / plan_my_dinner_be

Backend Service Repo for the Plan My Dinner Application
https://planmydinner.fly.dev/
0 stars 0 forks source link

[Route]: GET - Random Recipes #13

Open aleish-m opened 1 year ago

aleish-m commented 1 year ago

Feature description

This route should make a call to look up a random recipe using TheMealDB.

Is this a route?

CRUD Action

{"GET"}

Route Path / Description

v1/random_recipes?count=4

Success - JSON Contract Example

{ Recipes: 
  [
    { ID: "67721"
      Title: "English Breakfast",
      Image_URL: "www.themealdb.com/images/media/meals/qysyss1511558054.jpg"},
    { ID: "73308"
      Title: "Steak and Kidney Pie",
      Image_URL: "www.themealdb.com/images/media/meals/utxryw1511721587.jpg"},
    { ID: "52847"
      Title: "Pork Cassoulet",
      Image_URL: "www.themealdb.com/images/media/meals/wxuvuv1511299147.jpg"}
  ]
}

Success - Return status code

200

Fail - JSON Contract Example(s)

Unacceptable Parameter:
Status: 400 (Bad Request) or 416 (Range Not Satisfiable)
Error Message for Invalid request

API Unavailable:
Status: 503 (Service Unavailable)
Error Message for Service Unavailable

Anything else?

Remember: Use GitHub branch creation for naming Image

wanderlust-create commented 1 year ago

per team meeting default should be 5