example-data.com

ingredients

ingredients

Page 9 of 9.

curl -sS \
  "https://example-data.com/api/v1/ingredients?limit=25"
const res = await fetch(
  "https://example-data.com/api/v1/ingredients?limit=25"
);
const { data, meta } = await res.json();
import type { Ingredient, ListEnvelope } from "https://example-data.com/types/ingredients.d.ts";

const res = await fetch(
  "https://example-data.com/api/v1/ingredients?limit=25"
);
const { data, meta } = (await res.json()) as ListEnvelope<Ingredient>;
import requests

res = requests.get(
    "https://example-data.com/api/v1/ingredients",
    params={"limit": 25},
)
data = res.json()
{
  "data": [
    {
      "id": 193,
      "name": "Honey",
      "slug": "honey-193",
      "foodCategoryId": null,
      "unit": "ml",
      "defaultPricePerUnit": 16.13,
      "currency": "USD"
    },
    {
      "id": 194,
      "name": "Maple Syrup",
      "slug": "maple-syrup-194",
      "foodCategoryId": 12,
      "unit": "ml",
      "defaultPricePerUnit": 4.12,
      "currency": "USD"
    },
    {
      "id": 195,
      "name": "Agave Syrup",
      "slug": "agave-syrup-195",
      "foodCategoryId": 3,
      "unit": "ml",
      "defaultPricePerUnit": 10.62,
      "currency": "USD"
    }
  ],
  "meta": {
    "page": 9,
    "limit": 24,
    "total": 200,
    "totalPages": 9
  },
  "links": {
    "self": "/api/v1/ingredients?page=9",
    "next": null,
    "prev": "/api/v1/ingredients?page=8"
  }
}
Draftbit