example-data.com
Menu
Browse docs and collections

Overview

places / #68

Forest Park of Singapore

Forest Park of Singapore

park · Singapore · ★ 3.4 (3020)

Component variants

Request

curl example

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

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/places/68"
);
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/68"
);
const place = (await res.json()) as Place;

Python example

import requests

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

Response

{
  "id": 68,
  "name": "Forest Park of Singapore",
  "slug": "forest-park-of-singapore-68",
  "kind": "park",
  "city": "Singapore",
  "countryAlpha2": "SG",
  "latitude": -5.699327,
  "longitude": -122.502714,
  "rating": 3.4,
  "ratingCount": 3020,
  "description": "Confugo amo communis cura cenaculum. Suppellex sto impedit suggero cura coadunatio tot aggero. Turbo similique vero addo viscus aegre tener clarus sortitus sono.",
  "imageUrl": "https://picsum.photos/seed/place-68/1200/800",
  "createdAt": "2023-12-13T05:54:59.082Z"
}