example-data.com
Menu
Browse docs and collections

Overview

flights / #28

Oct
14
Tue

Delta Air Lines DL719

10:26 AM – 12:37 PM

ICN → JFK

From SGD 2373.48

Component variants

Request

curl example

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

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/flights/28"
);
const flight = await res.json();

TypeScript example

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

const res = await fetch(
  "https://example-data.com/api/v1/flights/28"
);
const flight = (await res.json()) as Flight;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/flights/28"
)
flight = res.json()

Response

{
  "id": 28,
  "flightNumber": "DL719",
  "airline": "Delta Air Lines",
  "departureAirport": "ICN",
  "arrivalAirport": "JFK",
  "departureAt": "2025-10-14T10:26:28.937Z",
  "arrivalAt": "2025-10-14T12:37:28.937Z",
  "durationMinutes": 131,
  "status": "in_air",
  "priceFrom": 2373.48,
  "currency": "SGD",
  "createdAt": "2025-07-30T10:26:28.937Z"
}