social.passports.travel.leg

passports.social

Documentation

One transport segment of a trip — a single origin-to-destination movement. Part of a social.passports.travel.trip.

main record

One transport segment of a trip — a single origin-to-destination movement. Part of a social.passports.travel.trip.

Record Key tid Timestamp-based ID

Properties

carrier string Optional

Carrier name, e.g. 'Japan Airlines' or 'Amtrak'.

maxLength: 100 bytes
carrierCode string Optional

Transport-agnostic carrier code — IATA airline code for flights (e.g. 'JL'), route abbreviation for non-IATA carriers (e.g. 'ACE' for Acela).

maxLength: 10 bytes
createdAt string datetime Required

An RFC 3339 formatted timestamp.

description string Optional

Free-text notes about this leg.

maxLength: 3000 bytes
destination ref social.passports.place Required

Inline destination place object. Self-contained — no external fetch required.

destinationTransportCode string Optional

Terminal code at destination — IATA airport code for flights (e.g. 'CDG'), station code for rail, etc. Overrides the place record's transport_code for this specific leg.

maxLength: 10 bytes
endDate string Optional

Arrival date in YYYY-MM-DD format.

maxLength: 10 bytes
origin ref social.passports.place Required

Inline origin place object. Self-contained — no external fetch required.

originTransportCode string Optional

Terminal code at origin — IATA airport code for flights (e.g. 'JFK'), station code for rail (e.g. 'NYP'), etc. Overrides the place record's transport_code for this specific leg.

maxLength: 10 bytes
serviceNumber string Optional

Flight number, train number, or equivalent service identifier, e.g. 'JL006' or 'Acela 2151'.

maxLength: 20 bytes
startDate string Optional

Departure date in YYYY-MM-DD format. Stored as a date string rather than datetime to avoid timezone ambiguity — travel dates are calendar-day concepts.

maxLength: 10 bytes
transportation string Required

Mode of transportation.

Known values: flight, train, bus, car, ferry, walking, cycling, other
View raw schema
{
  "key": "tid",
  "type": "record",
  "record": {
    "type": "object",
    "required": [
      "origin",
      "destination",
      "transportation",
      "createdAt"
    ],
    "properties": {
      "origin": {
        "ref": "social.passports.place",
        "type": "ref",
        "description": "Inline origin place object. Self-contained — no external fetch required."
      },
      "carrier": {
        "type": "string",
        "maxLength": 100,
        "description": "Carrier name, e.g. 'Japan Airlines' or 'Amtrak'."
      },
      "endDate": {
        "type": "string",
        "maxLength": 10,
        "description": "Arrival date in YYYY-MM-DD format."
      },
      "createdAt": {
        "type": "string",
        "format": "datetime"
      },
      "startDate": {
        "type": "string",
        "maxLength": 10,
        "description": "Departure date in YYYY-MM-DD format. Stored as a date string rather than datetime to avoid timezone ambiguity — travel dates are calendar-day concepts."
      },
      "carrierCode": {
        "type": "string",
        "maxLength": 10,
        "description": "Transport-agnostic carrier code — IATA airline code for flights (e.g. 'JL'), route abbreviation for non-IATA carriers (e.g. 'ACE' for Acela)."
      },
      "description": {
        "type": "string",
        "maxLength": 3000,
        "description": "Free-text notes about this leg."
      },
      "destination": {
        "ref": "social.passports.place",
        "type": "ref",
        "description": "Inline destination place object. Self-contained — no external fetch required."
      },
      "serviceNumber": {
        "type": "string",
        "maxLength": 20,
        "description": "Flight number, train number, or equivalent service identifier, e.g. 'JL006' or 'Acela 2151'."
      },
      "transportation": {
        "type": "string",
        "description": "Mode of transportation.",
        "knownValues": [
          "flight",
          "train",
          "bus",
          "car",
          "ferry",
          "walking",
          "cycling",
          "other"
        ]
      },
      "originTransportCode": {
        "type": "string",
        "maxLength": 10,
        "description": "Terminal code at origin — IATA airport code for flights (e.g. 'JFK'), station code for rail (e.g. 'NYP'), etc. Overrides the place record's transport_code for this specific leg."
      },
      "destinationTransportCode": {
        "type": "string",
        "maxLength": 10,
        "description": "Terminal code at destination — IATA airport code for flights (e.g. 'CDG'), station code for rail, etc. Overrides the place record's transport_code for this specific leg."
      }
    }
  },
  "description": "One transport segment of a trip — a single origin-to-destination movement. Part of a social.passports.travel.trip."
}

Lexicon Garden

@