TomTom Maps for JavaScript
    Preparing search index...

    Type Alias SummaryBase

    Common summary type for a route or route leg. Contains departure/arrival times, lengths and durations.

    type SummaryBase = {
        arrivalTime: Date;
        departureTime: Date;
        deviationDistanceInMeters?: number;
        deviationPoint?: Position;
        deviationTimeInSeconds?: number;
        historicTrafficTravelTimeInSeconds?: number;
        lengthInMeters: number;
        liveTrafficIncidentsTravelTimeInSeconds?: number;
        noTrafficTravelTimeInSeconds?: number;
        trafficDelayInSeconds: number;
        trafficLengthInMeters: number;
        travelTimeInSeconds: number;
    }
    Index

    Properties

    arrivalTime: Date

    Estimated arrival time at the end of the route or leg.

    Calculated from departure time plus travel time, accounting for traffic conditions.

    departureTime: Date

    Departure time from the beginning of the route or leg.

    Based on the departure time specified in the routing request.

    deviationDistanceInMeters?: number

    The distance (in meters) from the origin point to the first point where this route forks off from the reference route.

    • If the route is identical to the reference route, then this field is set to the length of the route.
    • Included in all alternative (but not reference) route summary fields.
    deviationPoint?: Position

    The coordinates of the first point where this route forks off from the reference route.

    • If the route is identical to the reference route, then this field is set to the coordinates of the last point on the route.
    • Included in all alternative (but not reference) route summary fields.
    deviationTimeInSeconds?: number

    The travel time (in seconds) from the origin point to the first point where this route forks off from the reference route.

    • If the route is identical to the reference route, then this field is set to the estimated travel time of the route.
    • Included in all alternative (but not reference) route summary fields.
    historicTrafficTravelTimeInSeconds?: number

    Estimated travel time in seconds using time-dependent historic traffic data.

    Represents the expected travel time based on typical traffic patterns for the requested departure time (e.g., rush hour vs off-peak). Only included if requested using the computeTravelTimeFor parameter.

    lengthInMeters: number

    Total length of the route or leg in meters.

    liveTrafficIncidentsTravelTimeInSeconds?: number

    Estimated travel time in seconds using real-time traffic speed data.

    Based on current live traffic conditions and incidents. Only included if requested using the computeTravelTimeFor parameter.

    noTrafficTravelTimeInSeconds?: number

    Estimated travel time in seconds assuming free-flow conditions.

    Calculated as if there were no traffic delays (no congestion). Only included if requested using the computeTravelTimeFor parameter.

    trafficDelayInSeconds: number

    Additional delay in seconds caused by current traffic conditions.

    Represents the extra time compared to free-flow conditions. A value of 0 means no traffic delays.

    trafficLengthInMeters: number

    Length in meters of the route affected by traffic events causing delays.

    Indicates the portion of the route experiencing congestion or incidents.

    travelTimeInSeconds: number

    Estimated travel time in seconds for the route or leg.

    This value includes delays due to real-time traffic, even when considerTraffic=false. Use noTrafficTravelTimeInSeconds for free-flow travel time without traffic delays.