pets
pets
Page 5 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": 97,
"ownerUserId": 112,
"name": "Lurline",
"species": "dog",
"breedId": 7,
"gender": "female",
"birthDate": "2019-01-26",
"weightKg": 42.7,
"color": "Brown",
"imageUrl": "https://picsum.photos/seed/pet-97/600/600",
"createdAt": "2012-05-11T14:08:23.528Z",
"updatedAt": "2023-09-01T13:38:11.449Z"
},
{
"id": 98,
"ownerUserId": 113,
"name": "Keanu",
"species": "dog",
"breedId": 20,
"gender": "female",
"birthDate": null,
"weightKg": 27.9,
"color": "Tan",
"imageUrl": "https://picsum.photos/seed/pet-98/600/600",
"createdAt": "2019-04-23T13:27:58.637Z",
"updatedAt": "2020-03-29T04:33:19.373Z"
},
{
"id": 99,
"ownerUserId": 114,
"name": "Buddy",
"species": "bird",
"breedId": 60,
"gender": "male",
"birthDate": "2013-03-24",
"weightKg": 0.34,
"color": "Yellow",
"imageUrl": "https://picsum.photos/seed/pet-99/600/600",
"createdAt": "2025-04-24T11:26:00.695Z",
"updatedAt": "2026-01-19T04:33:29.360Z"
}
],
"meta": {
"page": 5,
"limit": 24,
"total": 200,
"totalPages": 9
},
"links": {
"self": "/api/v1/pets?page=5&limit=24",
"first": "/api/v1/pets?page=1&limit=24",
"last": "/api/v1/pets?page=9&limit=24",
"next": "/api/v1/pets?page=6&limit=24",
"prev": "/api/v1/pets?page=4&limit=24"
}
}