Meal - MealsMadeEasy/Backend GitHub Wiki

Meal

The /meal/ endpoint is used to query information about individual meals. For queries involving several meals, see the /meals/ endpoint. A meal object contains the following fields:

class Meal(
    id: String /* A unique ID for this meal */
    name: String /* A user-presentable name for this meal */
    description: String /* A user-presentable description of this meal */
    thumbnailUrl: String? /* (Optional) A URL to an image for this meal. This image is an arbitrary size, so be sure to scale it appropriately. */
)

/meal/{id}

This endpoint returns the meal object associated with a meal id. Replace the entire {id} component in the endpoint URL with a URL-encoded meal id for the desired meal.

This endpoint is read only, so use the GET verb to access it. If the call is successful, then a JSON formatted Meal object will be returned with a 200 OK response code. If no ID is provided, a 400 BAD REQUEST response code will be returned. If no meal exists with the given ID, a 404 NOT FOUND response code will be returned.