TrainSegment Data Type

An element that represents train segments of itineraries.

Properties
name data type constraints description
arrivalDate number   Arrival date for the train segment
departureDate number   Departure date for the train segment
arrivalCity TrainStation   Arrival city code.
departureCity TrainStation   Departure city code.
trainVendor TrainVendor   The train vendor that provides for the segment.
travelerName string  
directResponseLocator string   The confirmation number for this segment.
classOfService string   The class of service for this segment.
roomNumber string   The room number reserved, if any.
carNumber string   The car number that the seat/room is in.
accomodationCode string   The accomodation code. This is similar to a class of service code.
mileage string   The number of miles that this train will travel.
numberOfStops string   The number of stops that this train will take.
accumulatedTime string   The accumulated time that this segment will take.
trainNumber string max size: 32, min size: 0 The train number that the seat/room is on.
inGds boolean   Whether or not this segment exists in the GDS.
commissionAmount number   The commission amount that the agent can expect to be returned.
Properties inherited from AirportalSegment
number number   The ordering number of the segment.
status SegmentStatus   The status of the segment, like if it is confirmed or on wait list.
startDate string   The start date of the segment.
endDate string   The end date of the segment
UTCStartDate number   The start date of the segment in UTC.
UTCEndDate number   The end date of the segment in UTC.
startTimeZoneName string  
endTimeZoneName string  
startCity City   Get the starting city of the segment.
endCity City   The ending city of the segment.
domestic boolean   Whether this segment is domestic or not.
postTravel boolean   Whether this segment is in the past or not.
inGds boolean   Whether or not the segment is stored in the GDS.
itinerary Itinerary   Get the itinerary that this segment is connected to.
Properties inherited from BaseHibernateEntity
id number   The unique internal ID of the object.
version number   For internal use only. This is the serialization recorder for optimistic locking of several objects between sessions.
Properties inherited from BaseEntity
violations array of SimpleViolation   A list of constraint violations, if any, that this object has.

Example

{
  "arrivalDate" : 12345,
  "departureDate" : 12345,
  "arrivalCity" : {
    "longitude" : 12345.0,
    "latitude" : 12345.0,
    "code" : "...",
    "city" : {
      "code" : "...",
      "countryCode" : "...",
      "latitude" : 12345.0,
      "longitude" : 12345.0,
      "name" : "...",
      "stateOrCountry" : "...",
      "airportName" : "...",
      "region" : { },
      "timeZone" : { },
      "retentionOnly" : true,
      "position" : 12345,
      "unique" : true,
      "alias" : true,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "name" : "...",
    "id" : 12345,
    "version" : 12345,
    "violations" : [ {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    }, {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    } ]
  },
  "departureCity" : {
    "longitude" : 12345.0,
    "latitude" : 12345.0,
    "code" : "...",
    "city" : {
      "code" : "...",
      "countryCode" : "...",
      "latitude" : 12345.0,
      "longitude" : 12345.0,
      "name" : "...",
      "stateOrCountry" : "...",
      "airportName" : "...",
      "region" : { },
      "timeZone" : { },
      "retentionOnly" : true,
      "position" : 12345,
      "unique" : true,
      "alias" : true,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "name" : "...",
    "id" : 12345,
    "version" : 12345,
    "violations" : [ {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    }, {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    } ]
  },
  "trainVendor" : {
    "longCode" : "...",
    "code" : "...",
    "name" : "...",
    "id" : 12345,
    "version" : 12345,
    "violations" : [ {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    }, {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    } ]
  },
  "travelerName" : "...",
  "directResponseLocator" : "...",
  "classOfService" : "...",
  "roomNumber" : "...",
  "carNumber" : "...",
  "accomodationCode" : "...",
  "mileage" : "...",
  "numberOfStops" : "...",
  "accumulatedTime" : "...",
  "trainNumber" : "...",
  "inGds" : true,
  "commissionAmount" : 12345.0,
  "number" : 12345,
  "status" : {
    "code" : "...",
    "description" : "...",
    "accepted" : true,
    "confirmed" : true,
    "virtual" : true,
    "id" : 12345,
    "version" : 12345,
    "violations" : [ {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    }, {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    } ]
  },
  "startDate" : "...",
  "endDate" : "...",
  "UTCStartDate" : 12345,
  "UTCEndDate" : 12345,
  "startTimeZoneName" : "...",
  "endTimeZoneName" : "...",
  "startCity" : {
    "code" : "...",
    "countryCode" : "...",
    "latitude" : 12345.0,
    "longitude" : 12345.0,
    "name" : "...",
    "stateOrCountry" : "...",
    "airportName" : "...",
    "region" : {
      "name" : "...",
      "code" : "...",
      "country" : { },
      "position" : 12345,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "timeZone" : {
      "name" : "...",
      "offset" : 12345.0,
      "daylightSavingsOffset" : 12345.0,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "retentionOnly" : true,
    "position" : 12345,
    "unique" : true,
    "alias" : true,
    "id" : 12345,
    "version" : 12345,
    "violations" : [ {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    }, {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    } ]
  },
  "endCity" : {
    "code" : "...",
    "countryCode" : "...",
    "latitude" : 12345.0,
    "longitude" : 12345.0,
    "name" : "...",
    "stateOrCountry" : "...",
    "airportName" : "...",
    "region" : {
      "name" : "...",
      "code" : "...",
      "country" : { },
      "position" : 12345,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "timeZone" : {
      "name" : "...",
      "offset" : 12345.0,
      "daylightSavingsOffset" : 12345.0,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "retentionOnly" : true,
    "position" : 12345,
    "unique" : true,
    "alias" : true,
    "id" : 12345,
    "version" : 12345,
    "violations" : [ {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    }, {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    } ]
  },
  "domestic" : true,
  "postTravel" : true,
  "itinerary" : {
    "recordLocator" : "...",
    "agentName" : "...",
    "client" : {
      "status" : { },
      "parentClient" : { },
      "accountNumber" : "...",
      "name" : "...",
      "type" : { },
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "office" : {
      "pcc" : "...",
      "name" : "...",
      "address1" : "...",
      "address2" : "...",
      "address3" : "...",
      "city" : "...",
      "state" : "...",
      "zip" : "...",
      "parentCompany" : { },
      "active" : "...",
      "branch" : "...",
      "clientPrefix" : "...",
      "profileSettings" : { },
      "afterHoursNumber" : "...",
      "collectVoidLogs" : true,
      "gds" : { },
      "arcNumber" : "...",
      "logo" : "...",
      "logoLink" : "...",
      "afterHoursInternationalNumber" : "...",
      "tollFreeNumber" : "...",
      "phoneNumber" : "...",
      "onlineOffice" : { },
      "showTmcAppLinks" : true,
      "vipTollFree" : "...",
      "vipAfterHours" : "...",
      "cityCode" : { },
      "tmcHeadQuarters" : true,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "departureDate" : 12345,
    "completionDate" : 12345,
    "importDate" : 12345,
    "gds" : {
      "code" : "...",
      "oldCode" : "...",
      "name" : "...",
      "agressoCode" : "...",
      "enabled" : true,
      "profileSyncEnabled" : true,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "hide" : true,
    "citySummary" : "...",
    "departureCity" : {
      "code" : "...",
      "countryCode" : "...",
      "latitude" : 12345.0,
      "longitude" : 12345.0,
      "name" : "...",
      "stateOrCountry" : "...",
      "airportName" : "...",
      "region" : { },
      "timeZone" : { },
      "retentionOnly" : true,
      "position" : 12345,
      "unique" : true,
      "alias" : true,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "arrivalCity" : {
      "code" : "...",
      "countryCode" : "...",
      "latitude" : 12345.0,
      "longitude" : 12345.0,
      "name" : "...",
      "stateOrCountry" : "...",
      "airportName" : "...",
      "region" : { },
      "timeZone" : { },
      "retentionOnly" : true,
      "position" : 12345,
      "unique" : true,
      "alias" : true,
      "id" : 12345,
      "version" : 12345,
      "violations" : [ { }, { } ]
    },
    "arrivalDate" : 12345,
    "utcArrivalDate" : 12345,
    "startDate" : 12345,
    "endDate" : 12345,
    "purpose" : "...",
    "explanation" : "...",
    "authorizationCode" : "...",
    "costCenterCode" : "...",
    "departmentCode" : "...",
    "clientCode" : "...",
    "regionCode" : "...",
    "billable" : "...",
    "travelerCode" : "...",
    "managerCode" : "...",
    "projectCode" : "...",
    "id" : 12345,
    "version" : 12345,
    "violations" : [ {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    }, {
      "propertyName" : "...",
      "failureMessage" : "...",
      "stackTrace" : "..."
    } ]
  },
  "id" : 12345,
  "version" : 12345,
  "violations" : [ {
    "propertyName" : "...",
    "failureMessage" : "...",
    "stackTrace" : "..."
  }, {
    "propertyName" : "...",
    "failureMessage" : "...",
    "stackTrace" : "..."
  } ]
}