Trail Mix
- userId
-
Earnestine Dickinson @earnestine_dickinson
- name
- Trail Mix
- kind
- snack
- calories
- 532
- proteinGrams
- 45.5
- carbsGrams
- 55.7
- fatGrams
- 14.1
- eatenAt
- createdAt
Overview
meals / #457
Trail Mix
#457
Request
curl example
curl -sS \ "https://example-data.com/api/v1/meals/457" \ -H "Accept: application/json"
JavaScript example
const res = await fetch( "https://example-data.com/api/v1/meals/457" ); const meal = await res.json();
TypeScript example
// Download once: mkdir -p types && curl -o types/meals.d.ts https://example-data.com/types/meals.d.ts
import type { Meal } from "./types/meals";
const res = await fetch(
"https://example-data.com/api/v1/meals/457"
);
const meal = (await res.json()) as Meal; Python example
import requests
res = requests.get(
"https://example-data.com/api/v1/meals/457"
)
meal = res.json() Response
{
"id": 457,
"userId": 110,
"name": "Trail Mix",
"kind": "snack",
"calories": 532,
"proteinGrams": 45.5,
"carbsGrams": 55.7,
"fatGrams": 14.1,
"eatenAt": "2025-05-27T08:47:54.463Z",
"createdAt": "2025-05-27T09:10:23.220Z"
}