example-data.com
Menu
Browse docs and collections

Overview

places / #23

The Daily Grind of Netherlands

The Daily Grind of Netherlands

cafe · Amsterdam · ★ 3.2 (342)

Component variants

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/places/23" \
  -H "Accept: application/json"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/places/23"
);
const place = await res.json();

TypeScript example

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

const res = await fetch(
  "https://example-data.com/api/v1/places/23"
);
const place = (await res.json()) as Place;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/places/23"
)
place = res.json()

Response

{
  "id": 23,
  "name": "The Daily Grind of Netherlands",
  "slug": "the-daily-grind-of-netherlands-23",
  "kind": "cafe",
  "city": "Amsterdam",
  "countryAlpha2": "NL",
  "latitude": 30.218984,
  "longitude": 62.171271,
  "rating": 3.2,
  "ratingCount": 342,
  "description": "Deludo taedium abduco trepide. Unus amita capio considero viscus comis. Turbo comes concido totidem tot depereo varietas damnatio cuius antepono.",
  "imageUrl": "https://picsum.photos/seed/place-23/1200/800",
  "createdAt": "2023-07-27T11:59:36.989Z"
}