example-data.com
Menu
Browse docs and collections

Overview

flights / #353

Nov
12
Wed

Singapore Airlines SQ1425

9:03 PM – 7:29 AM

BCN → YYZ

From JPY 1332.00

Component variants

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 353,
  "flightNumber": "SQ1425",
  "airline": "Singapore Airlines",
  "departureAirport": "BCN",
  "arrivalAirport": "YYZ",
  "departureAt": "2025-11-12T21:03:31.473Z",
  "arrivalAt": "2025-11-13T07:29:31.473Z",
  "durationMinutes": 626,
  "status": "cancelled",
  "priceFrom": 1332,
  "currency": "JPY",
  "createdAt": "2025-10-07T21:03:31.473Z"
}