example-data.com
Menu
Browse docs and collections

pets

pets

Page 6 of 9.

Overview

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/pets?limit=25"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/pets?limit=25"
);
const { data, meta } = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/pets.d.ts https://example-data.com/types/pets.d.ts
import type { Pet, ListEnvelope } from "./types/pets";

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

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/pets",
    params={"limit": 25},
)
data = res.json()

Response

{
  "data": [
    {
      "id": 121,
      "ownerUserId": 131,
      "name": "Madisen",
      "species": "dog",
      "breedId": null,
      "gender": "unknown",
      "birthDate": null,
      "weightKg": 50.8,
      "color": "Gray",
      "imageUrl": "https://picsum.photos/seed/pet-121/600/600",
      "createdAt": "2022-12-10T16:28:06.740Z",
      "updatedAt": "2025-07-01T06:17:29.691Z"
    },
    {
      "id": 122,
      "ownerUserId": 132,
      "name": "Veronica",
      "species": "dog",
      "breedId": 24,
      "gender": "male",
      "birthDate": "2018-09-22",
      "weightKg": 59.2,
      "color": "Black",
      "imageUrl": "https://picsum.photos/seed/pet-122/600/600",
      "createdAt": "2017-05-24T23:36:29.380Z",
      "updatedAt": "2017-07-18T02:34:39.611Z"
    },
    {
      "id": 123,
      "ownerUserId": 133,
      "name": "Clementina",
      "species": "dog",
      "breedId": 20,
      "gender": "female",
      "birthDate": "2022-05-28",
      "weightKg": 59.9,
      "color": "Golden",
      "imageUrl": "https://picsum.photos/seed/pet-123/600/600",
      "createdAt": "2020-11-11T18:52:46.105Z",
      "updatedAt": "2023-02-23T15:49:26.426Z"
    }
  ],
  "meta": {
    "page": 6,
    "limit": 24,
    "total": 200,
    "totalPages": 9
  },
  "links": {
    "self": "/api/v1/pets?page=6&limit=24",
    "first": "/api/v1/pets?page=1&limit=24",
    "last": "/api/v1/pets?page=9&limit=24",
    "next": "/api/v1/pets?page=7&limit=24",
    "prev": "/api/v1/pets?page=5&limit=24"
  }
}