example-data.com
Menu
Browse docs and collections

Overview

flights / #68

Aug
6
Thu

United Airlines UA8969

7:58 PM – 10:39 PM

MAD → FCO

From USD 1770.13

Component variants

Related

Referenced by

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 68,
  "flightNumber": "UA8969",
  "airline": "United Airlines",
  "departureAirport": "MAD",
  "arrivalAirport": "FCO",
  "departureAt": "2026-08-06T19:58:48.708Z",
  "arrivalAt": "2026-08-06T22:39:48.708Z",
  "durationMinutes": 161,
  "status": "landed",
  "priceFrom": 1770.13,
  "currency": "USD",
  "createdAt": "2026-06-14T19:58:48.708Z"
}