ビネット価格を除く通行料金を取得する
1ドライバーには、指定されたルートに必要なすべてのビネットがあります:tolls[vignettes]=all。次のコマンドは、ルート上のすべてのトールの合計額をリクエストします (summary,tolls¤cy=Eur&spans=tollSystems&transportMode=car&tolls[summaries]=total)。
注
ルートの通行料金情報のリクエストは、追加のトランザクションとしてカウントされます。
curl -gX GET 'https://router.hereapi.com/v8/routes?'\
'origin=49.03392,10.601304&'\
'destination=44.505213,11.229968&'\
'return=polyline,summary,tolls&'\
'currency=Eur&'\
'spans=tollSystems&'\
'transportMode=car&'\
'tolls[summaries]=total&'\
'tolls[vignettes]=all&'\
'apiKey=YOUR_API_KEY'ドライバーはこの情報を必要としないため、レスポンスではビネットの個々の価格は指定されません。
"summary": {
"duration": 26911,
"length": 674821,
"baseDuration": 26085,
"tolls": {
"total": {
"type": "value",
"currency": "EUR",
"value": 36.3
}
}
}レスポンスのspansセクションでは、ルートで発生するさまざまなトール体系の位置をポリラインへのオフセットとして指定します。
"spans": [
{
"offset": 0
},
{
"offset": 7987,
"tollSystems": [
0
]
},
{
"offset": 8303,
"tollSystems": [
1
]
},
{
"offset": 9151
},
{
"offset": 9248,
"tollSystems": [
2
]
},
{
"offset": 17156,
"tollSystems": [
3,
2
]
},
{
"offset": 17157,
"tollSystems": [
2
]
},
{
"offset": 17162
}
]トールの収集位置とトール体系関連の情報は、レスポンスの下部セクションに記載されています。
"tolls": [
{
...,
"tollCollectionLocations": [
{
"name": "Vipiteno",
"location": {
"lat": 46.88487,
"lng": 11.43465
}
},
{
"name": "Bologna",
"location": {
"lat": 44.52436,
"lng": 11.24518
}
}
]
}
],
"tollSystems": [
{
"id": 508,
"name": "VIGNETTE AUSTRIA",
"languageCode": "ENG"
},
{
"id": 5224,
"name": "ASFINAG BRENNER AUTOBAHN",
"languageCode": "ENG"
},
{
"id": 5048,
"name": "AUTOSTRADE PER L'ITALIA S.P.A.",
"languageCode": "ENG"
},
{
"id": 7311,
"name": "AUTOSTRADE PER L'ITALIA S.P.A.",
"languageCode": "ENG"
}
]関連情報
先月の更新