example-data.com
Menu
Browse docs and collections

Overview

flights / #317

May
4
Mon

American Airlines AA1043

7:09 AM – 8:26 PM

GRU → CDG

From EUR 433.22

Component variants

Related

Referenced by

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 317,
  "flightNumber": "AA1043",
  "airline": "American Airlines",
  "departureAirport": "GRU",
  "arrivalAirport": "CDG",
  "departureAt": "2026-05-04T07:09:37.845Z",
  "arrivalAt": "2026-05-04T20:26:37.845Z",
  "durationMinutes": 797,
  "status": "landed",
  "priceFrom": 433.22,
  "currency": "EUR",
  "createdAt": "2026-03-09T07:09:37.845Z"
}