example-data.com
Menu
Browse docs and collections

destinations

destinations

Browse 80 destinations records. Explore sample records and fetch JSON over a free REST API for prototypes, tests, and learning.

Overview

Request

curl example

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

JavaScript example

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

TypeScript example

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

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

Python example

import requests

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

Response

{
  "data": [
    {
      "id": 1,
      "name": "Singapore",
      "slug": "singapore-1",
      "countryAlpha2": "SG",
      "description": "A must-visit for its natural wonders, welcoming locals, and unique character.",
      "imageUrl": "https://picsum.photos/seed/dest-1/800/600",
      "popularity": 98
    },
    {
      "id": 2,
      "name": "Paris",
      "slug": "paris-2",
      "countryAlpha2": "FR",
      "description": "A vibrant destination known for its rich culture, stunning architecture, and world-class cuisine.",
      "imageUrl": "https://picsum.photos/seed/dest-2/800/600",
      "popularity": 92
    },
    {
      "id": 3,
      "name": "Istanbul",
      "slug": "istanbul-3",
      "countryAlpha2": "TR",
      "description": "A must-visit for its natural wonders, welcoming locals, and unique character.",
      "imageUrl": "https://picsum.photos/seed/dest-3/800/600",
      "popularity": 85
    }
  ],
  "meta": {
    "page": 1,
    "limit": 25,
    "total": 80,
    "totalPages": 4
  },
  "links": {
    "self": "/api/v1/destinations?page=1",
    "first": "/api/v1/destinations?page=1",
    "last": "/api/v1/destinations?page=4",
    "next": "/api/v1/destinations?page=2",
    "prev": null
  }
}

View full response →