Here you can do an ETA request, which can also use the shift data of the driver and the current position of the vehicle.

This function is only available if the company has booked the module "truck routing".

Description

POST /eta/get_info.php?company=RTI_COMPANYKEY&vehicle=RTI_VEHICLEKEY

Parameters

Query parameters

ParametersDescriptionTypeHintMandatory
companyRTI company keystring
yes
vehicleRTI vehicle keystring
yes

Body parameters

ParametersDescriptionTypeHintMandatory
target

Target coordinate

Struktur:

"target": {
	"coordinates": {
		"latitude": 0,
		"longitude": 0
	}
}
object
yes
departure

Start coordinate for routing

"departure": {
	"coordinates": {
		"latitude": 0,
		"longitude": 0
	},
	"time": "YYYY-MM-DDTHH:ii:ss+HH:ii"
}
object

If departure is not given, the last known position of the vehicle will be used.

If departure is given, the coordinates are mandatory. Giving a time value is optional. Time is formatted as ISO 8601.

no
options

Routing options

"options": {
	"traffic_incidents": false,
	"driving_regulation_ec_561": false,
	"historic_speed": false
}
object

By default all options are deactivated. You can also use only some of these options. The following options are available:

  • traffic_incidents: Indicates if current traffic info (traffic jams, construction work etc.) should be used.
  • driving_regulation_ec_561: Indicates if rules regarding steer and rest times according to EC 561/2006 should be used. Only if this is activated, the data given at driver_info will be used. If driver_info is not given, the data of the current driver of the vehicle will be used.
  • historic_speed: Indicates if historical traffic info should be used, e.g. that driving during rush hour usually takes longer.
no
driver_info

Driver data

"driver_info": {
	"last_time_the_driver_worked": "YYYY-MM-DDTHH:ii:ss+HH:ii",
	"accumulated_driving_time_since_last_break": 0,
	"accumulated_driving_time_since_last_daily_rest": 0,
	"elapsed_time_since_end_of_last_daily_rest": 0
}
object

If driver_info is not given, the data of the current driver of the vehicle will be used.

The option driving_regulation_ec_561 has to be activated in order to use the driver data.

The following infos can be given:

  • last_time_the_driver_worked: Time of last work time booking. Everything after that will be assumed as rest time. Is a timestamp in ISO 8601 format.
  • accumulated_driving_time_since_last_break: Steering time since end of last break in seconds. The driver is not allowed to drive longer than 4.5 hours without break. If 4.5 hours have already been exceeded, the request will do the same as if the time is 4.5 hours.
  • accumulated_driving_time_since_last_daily_rest: Steering time since end of last daily rest time in seconds. The driver is not allowed to drive longer than 9 hours before doing his next daily rest time. If 9 hours have already been exceeded, the request will do the same as if the time is 9 hours.
  • elapsed_time_since_end_of_last_daily_rest: Time since end of last daily rest time in seconds. The driver has to do the next daily rest time 13 hours after shift begin at maximum. If 13 hours have already been exceeded, the request will do the same as if the time is 13 hours. This value can not be greater than accumulated_driving_time_since_last_daily_rest.
no

Return value

If an error occured "ERROR:description" will be returned. Else the data is formatted as JSON.

You can find a detailled description of the structure of the return value as JSON schema here.

Return value example
{
    "etaInfo": {
        "successful": true,
        "distance": 27159,
        "duration": 2392,
        "arrivalTime": "2024-03-13T13:39:07+01:00",
        "events": [],
        "errorInfo": null
    },
    "etaCalculationBase": {
        "startPosition": {
            "coordinate": {
                "longitude": 13.35057,
                "latitude": 50.9218
            }
        },
        "endPosition": {
            "coordinate": {
                "longitude": 13.59894,
                "latitude": 51.03615
            }
        },
        "startTime": "2024-03-13T12:59:15+01:00",
        "options": {
            "traffic_incidents": false,
            "driving_regulation_ec_561": true,
            "historic_speed": false
        },
        "driverInfo": {
            "lastTimeWorked": "2024-03-13T11:24:00+01:00",
            "accumulatedDrivingTimeSinceLastBreak": 15480,
            "accumulatedDrivingTimeSinceLastDailyRest": 15480,
            "elapsedTimeSinceEndOfLastDailyRest": 15480
        },
        "routingProfile": {
            "speedProfile": "carfast",
            "optimization": 0,
            "lowEmissionZoneType": "GREEN",
            "totalPermittedWeight": 0,
            "axleLoad": 0,
            "numberOfAxles": 0,
            "height": 0,
            "length": 0,
            "width": 0,
            "isDelivery": false,
            "isEmergency": false,
            "isMaintenance": false,
            "hazardousGoodsType": "NONE",
            "tunnelRestrictionCode": "NONE",
            "loadType": "PASSENGER",
            "avoidMotorway": false,
            "avoidToll": false,
            "avoidFerry": false,
            "emissionClass": "EURO_0",
            "particleReductionClass": ""
        }
    },
    "queryDate": "2024-03-13T12:59:15+01:00",
    "duration": 0.6310160160064697
}

Example calls

Request with RTI key

https://map.yellowfox.de/rti/eta/get_info.php?company=COMPANY_RTIKEY&vehicle=VEHICLE_RTIKEY

Request with RTI ident

https://map.yellowfox.de/rti/eta/get_info.php?company=COMPANY_RTIKEY={"type":"car_ident","groupKey":"GROUP_RTIKEY","ident":"VEHICLE_IDENT"}

  • No labels