-
Notifications
You must be signed in to change notification settings - Fork 5.1k
/
mobility.json
2588 lines (2588 loc) · 95.3 KB
/
mobility.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
{
"swagger": "2.0",
"info": {
"title": "Azure Maps Mobility Service",
"version": "1.0"
},
"host": "atlas.microsoft.com",
"schemes": [
"https"
],
"consumes": [],
"produces": [
"application/json"
],
"securityDefinitions": {
"azure_auth": {
"type": "oauth2",
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
"flow": "implicit",
"description": "These are the [Azure Active Directory OAuth2](https://docs.microsoft.com/en-us/azure/active-directory/develop/v1-overview) Flows. When paired with [Azure Role Based Access](https://docs.microsoft.com/en-us/azure/role-based-access-control/overview) control it can be used to control access to Azure Maps REST APIs. Azure Role based access controls are used to designate access to one or more Azure Maps resource account or sub-resources. Any user, group, or service principal can be granted access via a built in role or a custom role composed of one or more permissions to Azure Maps REST APIs.\n\nTo implement scenarios we recommend viewing [authentication concepts](https://aka.ms/amauth). In summary, this security definition provides a solution for modeling application(s) via objects capable of access control on specific APIs and scopes.\n\n#### Note\n* This security definition **requires** the use of the `x-ms-client-id` header to indicate which Azure Maps resource the application is requesting access to. This can be acquired from the [Maps management API](https://aka.ms/amauthdetails).\n* The `Authorization URL` is specific to the Azure public cloud instance. Sovereign clouds have unique Authorization URLs and Azure Active directory configurations. \n* The Azure role based access control is configured from the [Azure management plane](https://aka.ms/amrbac) via Azure portal, Powershell, CLI, Azure SDKs, or REST APIs.\n* Usage of the [Azure Maps Web SDK](https://aka.ms/amaadmc) allows for configuration based setup of an application for multiple use cases.\n* Currently Azure Active Directory [v1.0](https://docs.microsoft.com/en-us/azure/active-directory/develop/azure-ad-endpoint-comparison) tokens are supported.",
"scopes": {
"user_impersonation": "Impersonates a user's Azure Active Directory account."
}
},
"apiKeyQuery": {
"type": "apiKey",
"description": "This is a shared key which is provisioned when creating an [Azure Maps resource](https://aka.ms/amauth) through the Azure management plane via Azure portal, Powershell, CLI, Azure SDKs, or REST APIs. With this key, any application is authorized to access all REST APIs. In other words, these can currently be treated as master keys to the account which they are issued for. For publicly exposed applications our recommendation is to use server to server access of Azure Maps REST APIs where this key can be securely stored.",
"name": "subscription-key",
"in": "query"
}
},
"security": [
{
"azure_auth": []
},
{
"apiKeyQuery": []
}
],
"responses": {
"400": {
"description": "Bad request: one or more parameters were incorrectly specified or are mutually exclusive.",
"schema": {
"$ref": "#/definitions/ODataErrorResponse"
}
},
"401": {
"description": "Access denied due to invalid subscription key or invalid Azure Active Directory bearer token. Make sure to provide a valid key for an active Azure subscription and Maps resource. Otherwise, verify the [WWW-Authenticate](https://tools.ietf.org/html/rfc6750#section-3.1) header for error code and description of the provided AAD bearer token.",
"schema": {
"$ref": "#/definitions/ODataErrorResponse"
},
"headers": {
"WWW-Authenticate": {
"type": "string",
"description": "Bearer realm=\"https://atlas.microsoft.com/\", error=\"invalid_token\", error_description=\"The access token expired\""
}
}
},
"403": {
"description": "Permission, capacity, or authentication issues.",
"schema": {
"$ref": "#/definitions/ODataErrorResponse"
}
},
"404": {
"description": "Not Found: the requested resource could not be found, but it may be available again in the future.",
"schema": {
"$ref": "#/definitions/ODataErrorResponse"
}
},
"500": {
"description": "An error occurred while processing the request. Please try again later.",
"schema": {
"$ref": "#/definitions/ODataErrorResponse"
}
}
},
"parameters": {
"ClientId": {
"name": "x-ms-client-id",
"description": "Specifies which account is intended for usage in conjunction with the Azure AD security model. It represents a unique ID for the Azure Maps account and can be retrieved from Azure Maps management plane Account API. To use Azure AD security in Azure Maps see the following [articles](https://aka.ms/amauthdetails) for guidance.",
"type": "string",
"in": "header",
"required": false,
"x-ms-parameter-location": "client"
},
"SubscriptionKey": {
"name": "subscription-key",
"description": "One of the Azure Maps keys provided from an Azure Map Account. Please refer to this [article](https://docs.microsoft.com/azure/azure-maps/how-to-manage-authentication) for details on how to manage authentication.",
"type": "string",
"in": "query",
"required": false,
"x-ms-parameter-location": "client"
},
"ApiVersion": {
"name": "api-version",
"description": "Version number of Azure Maps API. Current version is 1.0",
"type": "string",
"in": "query",
"required": true,
"default": "1.0",
"x-ms-parameter-location": "client"
},
"JsonFormat": {
"name": "format",
"description": "Desired format of the response. Only `json` format is supported.",
"type": "string",
"in": "path",
"required": true,
"enum": [
"json"
],
"x-ms-enum": {
"name": "JsonFormat",
"modelAsString": true,
"values": [
{
"value": "json",
"description": "[The JavaScript Object Notation Data Interchange Format](https://tools.ietf.org/html/rfc8259)"
}
]
},
"x-ms-parameter-location": "method"
},
"MetroId": {
"name": "metroId",
"description": "The unique id of the metro area. Can be retrieved via [Get Metro Area API](https://aka.ms/AzureMapsMobilityMetro).",
"type": "integer",
"format": "int32",
"in": "query",
"required": false,
"x-ms-parameter-location": "method"
},
"MobilityLanguage": {
"name": "language",
"description": "Language in which search results will be returned. Only NGT is supported. Please refer to [Supported languages](https://docs.microsoft.com/azure/azure-maps/supported-languages) for details.",
"type": "string",
"in": "query",
"required": false,
"x-ms-parameter-location": "method"
}
},
"paths": {
"/mobility/metroArea/id/{format}": {
"get": {
"x-publish": true,
"operationId": "Mobility_GetMetroAreaPreview",
"description": "**Metro Area API**\n\n**Applies to**: S1 pricing tier.\n\nService allows users to request metro areas in which the Azure Maps Mobility Service is available. The service supports filtering results by country or coordinate location. Information returned includes Metro Area details such as metro Id, name and a representation of the metro area geometry in GeoJSON format.",
"x-ms-examples": {
"MetroArea": {
"$ref": "./examples/GetMetroArea.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ClientId"
},
{
"$ref": "#/parameters/SubscriptionKey"
},
{
"$ref": "#/parameters/ApiVersion"
},
{
"$ref": "#/parameters/JsonFormat"
},
{
"name": "query",
"description": "The applicable location input. Can be position (specified as a comma separated string composed by latitude followed by longitude e.g. \"47.641268,-122.125679\") or countryCode (2-character ISO country code).",
"in": "query",
"required": true,
"type": "string"
},
{
"name": "queryType",
"description": "The type of the query. By default originType=position, specified as a comma separated string composed by latitude followed by longitude, e.g. \"47.641268,-122.125679”.",
"in": "query",
"required": false,
"type": "string",
"default": "position",
"enum": [
"position",
"countryCode"
],
"x-ms-enum": {
"name": "MetroAreaQueryType",
"modelAsString": true,
"values": [
{
"value": "position",
"description": "The origin of the route as a comma separated string composed by latitude followed by longitude e.g. \"47.641268,-122.125679\"."
},
{
"value": "countryCode",
"description": "2-character [ISO 3166-1](https://www.iso.org/iso-3166-country-codes.html) alpha-2 country code. E.g. US."
}
]
},
"x-ms-parameter-location": "method"
},
{
"$ref": "#/parameters/MobilityLanguage"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/MetroAreaResponse"
}
},
"400": {
"$ref": "#/responses/400"
},
"401": {
"$ref": "#/responses/401"
},
"403": {
"$ref": "#/responses/403"
},
"404": {
"$ref": "#/responses/404"
},
"500": {
"$ref": "#/responses/500"
}
}
}
},
"/mobility/metroArea/info/{format}": {
"get": {
"x-publish": true,
"operationId": "Mobility_GetMetroAreaInfoPreview",
"description": "**Metro Area Info API**\n\n**Applies to**: S1 pricing tier.\n\nService allows users to request additional information for metro areas in which the Azure Maps Mobility services are available. Information such as supported transit types, transit agencies and active alerts is available, depending on the options selected. Also, the service returns information if the public transit fare information is available for the requested metro area.",
"x-ms-examples": {
"MetroAreaInfo": {
"$ref": "./examples/GetMetroAreaInfo.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ClientId"
},
{
"$ref": "#/parameters/SubscriptionKey"
},
{
"$ref": "#/parameters/ApiVersion"
},
{
"$ref": "#/parameters/JsonFormat"
},
{
"name": "query",
"description": "metroId. The unique id of the metro area. Required parameter specifying the required metro area to search in. Can be retrieved via [Get Metro Area API](https://aka.ms/AzureMapsMobilityTransitRoute).",
"in": "query",
"required": true,
"type": "integer",
"format": "int32"
},
{
"name": "detailType",
"description": "Specify details requested respective to the metro area as a comma separated list. Supported values are:\n * `agencies` - Return a list of all public transit agencies operating in the given metro area.\n * `alerts` - Returns a list of all active service alerts, that are defined in the metro or agency level, and are not connected to a specific line or stop.\n * `alertDetails` - Applicable only when alerts are requested. Returns details of the alerts.\n * `transitTypes` - Returns a list of all supported transit types in the given metro area.",
"in": "query",
"required": true,
"type": "array",
"items": {
"type": "string",
"enum": [
"agencies",
"alerts",
"alertDetails",
"transitTypes"
],
"x-ms-enum": {
"name": "MetroAreaDetailType",
"modelAsString": true,
"values": [
{
"value": "agencies",
"description": "Return a list of all public transit agencies operating in the given metro area."
},
{
"value": "alerts",
"description": "Returns a list of all active service alerts, that are defined in the metro or agency level, and are not connected to a specific line or stop."
},
{
"value": "alertDetails",
"description": "Applicable only when alerts are requested. Returns details of the alerts."
},
{
"value": "transitTypes",
"description": "Returns a list of all supported transit types in the given metro area."
}
]
}
},
"x-ms-parameter-location": "method"
},
{
"$ref": "#/parameters/MobilityLanguage"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/MetroAreaInfoResponse"
}
},
"400": {
"$ref": "#/responses/400"
},
"401": {
"$ref": "#/responses/401"
},
"403": {
"$ref": "#/responses/403"
},
"404": {
"$ref": "#/responses/404"
},
"500": {
"$ref": "#/responses/500"
}
}
}
},
"/mobility/transit/nearby/{format}": {
"get": {
"x-publish": true,
"operationId": "Mobility_GetNearbyTransitPreview",
"description": "**Find Nearby Transit API**\n\n**Applies to**: S1 pricing tier.\n\nGet Nearby Transit service allows you to search public transit stops around a given location returning the transit object details. Service allows users to search for public transit stops within a given radius returning a set of stops with stop details. Additional information such as transit operator information is returned depending on the options selected. The returned information can be used for further processing such as requesting [real-time arrivals](https://aka.ms/AzureMapsMobilityRealTimeArrivals) for the stop or [transit stop details](https://aka.ms/AzureMapsMobilityTransitStop) such as main transit type of most lines stopping for a given public, active service alerts or main transport agency.",
"x-ms-examples": {
"NearbyTransit": {
"$ref": "./examples/GetNearbyTransit.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ClientId"
},
{
"$ref": "#/parameters/SubscriptionKey"
},
{
"$ref": "#/parameters/ApiVersion"
},
{
"$ref": "#/parameters/JsonFormat"
},
{
"$ref": "#/parameters/MetroId"
},
{
"name": "query",
"description": "Location input from user. The applicable location query specified as a comma separated string composed by latitude followed by longitude e.g. \"47.641268,-122.125679\".",
"in": "query",
"required": true,
"type": "string"
},
{
"name": "limit",
"description": "Maximum number of responses that will be returned. Default is 3, minimum 1 and maximum 100. Sort order is based on distance from input location.",
"in": "query",
"required": false,
"type": "integer",
"format": "int32"
},
{
"name": "radius",
"description": "Specifies the search area to constrain a search. The radius in meters to for the results to be constrained to the defined area. Default value is 30 meters, minimum 1 meter and maximum 5000 meters (5km).",
"in": "query",
"required": false,
"type": "integer",
"format": "int32"
},
{
"name": "objectType",
"description": "The transit object type. By default, objectType is set to `stop`",
"in": "query",
"required": false,
"default": "stop",
"type": "string"
},
{
"$ref": "#/parameters/MobilityLanguage"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/NearbyTransitResponse"
}
},
"400": {
"$ref": "#/responses/400"
},
"401": {
"$ref": "#/responses/401"
},
"403": {
"$ref": "#/responses/403"
},
"404": {
"$ref": "#/responses/404"
},
"500": {
"$ref": "#/responses/500"
}
}
}
},
"/mobility/transit/line/{format}": {
"get": {
"x-publish": true,
"operationId": "Mobility_GetTransitLineInfoPreview",
"description": "**Transit Line Info API**\n\n**Applies to**: S1 pricing tier.\n\nYour scenario might require requesting transit line specific data such as stops and line geometry. Transit Line Info service allows you to request line group by line group id returning a line group comprised a set of lines. Additional information such as 24 hours static schedule, active alerts for the line group and line patterns is also available, depending on the options selected. Mobility services uses a parallel data model for public transit lines and line groups. Usually line group contains 2 lines, one going from A to B, and the other returning from B to A, both operating by the same Public Transport Agency having the same line number. We recommend you review our guidance [article](https://aka.ms/AMapsPublicTRansitConcepts) to understand the concepts of lines and line groups.",
"x-ms-examples": {
"TransitLineInfo": {
"$ref": "./examples/GetTransitLineInfo.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ClientId"
},
{
"$ref": "#/parameters/SubscriptionKey"
},
{
"$ref": "#/parameters/ApiVersion"
},
{
"$ref": "#/parameters/JsonFormat"
},
{
"$ref": "#/parameters/MetroId"
},
{
"name": "query",
"description": "lineGroupId, for example,'666074'. Typically contains 2 lines having the same agency and line, one going from A to B, and the other from B to A.",
"in": "query",
"required": true,
"type": "string"
},
{
"name": "detailType",
"description": "Specify additional details requested respective to the line group as a comma separated list. As a default service returns line basic info. Supported values are:\n * `alerts` - Return any active service alerts for the specified stop. Response provides brief information for disruption in service and all basic data associated with the alert.\n * `alertDetails` - Can only be used in conjunction with detailType=alerts.Return additional details associated with the active service alerts.\n * `lines` - Return transit lines that stops at the specified stop.\n * `stops` - Return list of stops the line group goes through.\n * `schedule` - Return a 24h static schedule for the specified line group from the current time of the day to the end of the current day.\n * `patterns` - Return list of patterns this group is comprised of. A pattern consists of a stop sequence and shape per line.",
"in": "query",
"required": false,
"type": "array",
"items": {
"type": "string",
"enum": [
"alerts",
"alertDetails",
"lines",
"stops",
"schedule",
"patterns"
],
"x-ms-enum": {
"name": "TransitLineDetailType",
"modelAsString": true,
"values": [
{
"value": "alerts",
"description": "Return any active service alerts for the specified stop. Response provides brief information for disruption in service and all basic data associated with the alert."
},
{
"value": "alertDetails",
"description": "Can only be used in conjunction with detailType=alerts.Return additional details associated with the active service alerts."
},
{
"value": "lines",
"description": "Return transit lines that stops at the specified stop."
},
{
"value": "stops",
"description": "Return list of stops the line group goes through."
},
{
"value": "schedule",
"description": "Return a 24h static schedule for the specified line group from the current time of the day to the end of the current day."
},
{
"value": "patterns",
"description": "Return list of patterns this group is comprised of. A pattern consists of a stop sequence and shape per line."
}
]
}
}
},
{
"$ref": "#/parameters/MobilityLanguage"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/TransitLineInfoResponse"
}
},
"400": {
"$ref": "#/responses/400"
},
"401": {
"$ref": "#/responses/401"
},
"403": {
"$ref": "#/responses/403"
},
"404": {
"$ref": "#/responses/404"
},
"500": {
"$ref": "#/responses/500"
}
}
}
},
"/mobility/transit/stop/{format}": {
"get": {
"x-publish": true,
"operationId": "Mobility_GetTransitStopInfoPreview",
"description": "**Transit Stop Info API**\n\n**Applies to**: S1 pricing tier.\n\nGet Transit Stop Info service allows you to request information for a given public transit stop. Basic information returned includes details such as main transit type of most lines stopping for a given public and main transport agency. Additional details such as stop lines and active service alerts for specified stop are also available, depending on the options selected.",
"x-ms-examples": {
"TransitStopInfo": {
"$ref": "./examples/GetTransitStopInfo.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ClientId"
},
{
"$ref": "#/parameters/SubscriptionKey"
},
{
"$ref": "#/parameters/ApiVersion"
},
{
"$ref": "#/parameters/JsonFormat"
},
{
"$ref": "#/parameters/MetroId"
},
{
"name": "query",
"description": "The stopId or stopKey for which the user is requesting transit stop details.",
"in": "query",
"required": true,
"type": "string"
},
{
"name": "queryType",
"description": "The type of the unique query parameter of the stop. By default queryType=stopId.",
"in": "query",
"required": false,
"type": "string",
"enum": [
"stopId",
"stopKey"
],
"default": "stopId",
"x-ms-enum": {
"name": "TransitStopQueryType",
"modelAsString": true,
"values": [
{
"value": "stopId",
"description": "The unique Azure Maps identifier for the respective public transit stop. When referring to public transit stops over time, it is recommended to use `stopId` since it will not change, as long as the physical stop exists"
},
{
"value": "stopKey",
"description": "The GTFS stop Id. GTFS stop Ids are provided by the transit authority and are subject to change.<br> **Note**: When this value is used, the metroId parameter is required."
}
]
},
"x-ms-parameter-location": "method"
},
{
"name": "detailType",
"description": "Specify additional details requested respective to the transit stop as a comma separated list. Supported values are:\n * `alerts` - Return any active service alerts for the specified stop. Response provides brief information for disruption in service and all basic data associated with the alert.\n * `alertDetails` - Can only be used in conjunction with detailType=alerts.Return additional details associated with the active service alerts.\n * `lines` - Return transit lines that stops at the specified stop.\n * `lineGroups` - Return line groups that stops at the specified stop.",
"in": "query",
"required": false,
"type": "array",
"items": {
"type": "string",
"enum": [
"alerts",
"alertDetails",
"lines",
"lineGroups"
],
"x-ms-enum": {
"name": "TransitStopDetailType",
"modelAsString": true,
"values": [
{
"value": "alerts",
"description": "Return any active service alerts for the specified stop. Response provides brief information for disruption in service and all basic data associated with the alert."
},
{
"value": "alertDetails",
"description": "Can only be used in conjunction with detailType=alerts.Return additional details associated with the active service alerts."
},
{
"value": "lines",
"description": "Return transit lines that stops at the specified stop."
},
{
"value": "lineGroups",
"description": "Return line groups that stops at the specified stop."
}
]
}
}
},
{
"$ref": "#/parameters/MobilityLanguage"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/TransitStopInfoResponse"
}
},
"400": {
"$ref": "#/responses/400"
},
"401": {
"$ref": "#/responses/401"
},
"403": {
"$ref": "#/responses/403"
},
"404": {
"$ref": "#/responses/404"
},
"500": {
"$ref": "#/responses/500"
}
}
}
},
"/mobility/transit/route/{format}": {
"get": {
"x-publish": true,
"operationId": "Mobility_GetTransitRoutePreview",
"description": "**Transit Route API**\n\n**Applies to**: S1 pricing tier.\n\nGet Transit Route API will allow trip planning returning the best possible route options between an origin and destination by using multi-modal search. Service provides a variety of travel modes, including walk, bike, and public transit. The API supports parameters to request one or multiple public transit types such as bus, tram and subway, and prefer a specific transit agency operating in the area. Also, service provides transit fare details and options to choose optimal route with least walk or transfers and specify arrival or departure times when user need to be at a specific destination by a certain time.",
"x-ms-examples": {
"TransitRoute": {
"$ref": "./examples/GetTransitRoute.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ClientId"
},
{
"$ref": "#/parameters/SubscriptionKey"
},
{
"$ref": "#/parameters/ApiVersion"
},
{
"$ref": "#/parameters/JsonFormat"
},
{
"$ref": "#/parameters/MetroId"
},
{
"name": "origin",
"description": "The origin of the route. By default originType=position, specified as a comma separated string composed by latitude followed by longitude, e.g. \"47.641268,-122.125679”.",
"in": "query",
"required": true,
"type": "string"
},
{
"name": "originType",
"description": "The type of the origin. By default originType=position, specified as a comma separated string composed by latitude followed by longitude, e.g., \"47.641268,-122.125679”.",
"in": "query",
"required": false,
"type": "string",
"enum": [
"position",
"stopId",
"stopKey"
],
"default": "position",
"x-ms-enum": {
"name": "OriginType",
"modelAsString": true,
"values": [
{
"value": "position",
"description": "The origin of the route as a comma separated string composed by latitude followed by longitude e.g. \"47.641268,-122.125679\"."
},
{
"value": "stopId",
"description": "The unique Azure Maps identifier for the respective public transit stop. When referring to public transit stops over time, it is recommended to use `stopId` since it will not change, as long as the physical stop exists"
},
{
"value": "stopKey",
"description": "The GTFS stop Id. GTFS stop Ids are provided by the transit authority and are subject to change.<br> **Note**: When this value is used, the metroId parameter is required."
}
]
},
"x-ms-parameter-location": "method"
},
{
"name": "destination",
"description": "The destination of the route. By default the destinationType=position, specified as a comma separated string composed by latitude followed by longitude, e.g. \"47.641268,-122.125679”.",
"in": "query",
"required": true,
"type": "string"
},
{
"name": "destinationType",
"description": "The type of the destination.",
"in": "query",
"required": false,
"type": "string",
"default": "position",
"enum": [
"position",
"stopId",
"stopKey"
],
"x-ms-enum": {
"name": "DestinationType",
"modelAsString": true,
"values": [
{
"value": "position",
"description": "The destination of the route as a comma separated string composed by latitude followed by longitude e.g. \"47.641268,-122.125679\"."
},
{
"value": "stopId",
"description": "The unique Azure Maps identifier for the respective public transit stop. When referring to public transit stops over time, it is recommended to use `stopId` since it will not change, as long as the physical stop exists."
},
{
"value": "stopKey",
"description": "The GTFS stop Id. GTFS stop Ids are provided by the transit authority and are subject to change.<br> **Note**: When this value is used, the metroId parameter is required."
}
]
},
"x-ms-parameter-location": "method"
},
{
"name": "modeType",
"description": "The mode of travel for the requested route; as comma separated list. If not specified, all modes will be allowed. All modes might not be available in all metro areas. If valid trip is not found, empty result will be returned. Supported values are:\n * `walk` - Walk (pedestrian)\n * `bike` - Bike\n * `publicTransit` - Public transit",
"required": false,
"in": "query",
"type": "array",
"items": {
"type": "string",
"enum": [
"walk",
"bike",
"publicTransit"
],
"x-ms-enum": {
"name": "ModeType",
"modelAsString": true,
"values": [
{
"value": "walk",
"description": "walk (pedestrian)"
},
{
"value": "bike",
"description": "bike"
},
{
"value": "publicTransit",
"description": "public transit"
}
]
}
},
"x-ms-parameter-location": "method"
},
{
"name": "transitType",
"description": "Applicable only with modeType = publicTransit. Allow only a specific set of public transit types (as a comma separated list) to be returned for the route. Note that the requested transitType may not be available for the entire route. If not specified, all modes will be allowed. Supported values are:\n * `bus` - Bus\n * `cableCar` - Cable car\n * `ferry` - Ferry\n * `funicular` - Funicular\n * `gondola` - Gondola\n * `rail` - Rail\n * `tram` - Tram\n * `subway` - Subway/Metro",
"in": "query",
"required": false,
"type": "array",
"items": {
"type": "string",
"enum": [
"bus",
"cableCar",
"ferry",
"funicular",
"gondola",
"rail",
"tram",
"subway"
],
"x-ms-enum": {
"name": "TransitTypeFilter",
"modelAsString": true,
"values": [
{
"value": "bus",
"description": "bus"
},
{
"value": "cableCar",
"description": "cableCar"
},
{
"value": "ferry",
"description": "ferry"
},
{
"value": "funicular",
"description": "funicular"
},
{
"value": "gondola",
"description": "gondola"
},
{
"value": "rail",
"description": "rail"
},
{
"value": "tram",
"description": "tram"
},
{
"value": "subway",
"description": "subway"
}
]
}
},
"x-ms-parameter-location": "method"
},
{
"name": "agency",
"description": "Specifies whether to prefer routes from a specific set of agencies if possible; as a comma separated list. If valid trip isn’t found with the preferred agency, or only one with very long trips or with large number of transfers, itineraries with other agencies will be returned.",
"in": "query",
"required": false,
"type": "array",
"items": {
"type": "string"
}
},
{
"name": "agencyType",
"description": "Specifies the agency identifier to request routes from preferred agencies. By default the agencyType=agencyId.",
"in": "query",
"required": false,
"type": "string",
"default": "agencyId",
"enum": [
"agencyId",
"agencyKey",
"agencyName"
],
"x-ms-enum": {
"name": "AgencyType",
"modelAsString": true,
"values": [
{
"value": "agencyId",
"description": "The Id of the transit agency, e.g. '5872'"
},
{
"value": "agencyKey",
"description": "The agency’s GTFS Id.<br> **Note**: When this value is used, the metroId parameter is required."
},
{
"value": "agencyName",
"description": "The name of the transit agency, e.g. Metro Transit."
}
]
},
"x-ms-parameter-location": "method"
},
{
"name": "time",
"description": "The time of departure or arrival in the local time in ISO format (2019-04-05T14:24:18-04:00). If timeType is not specified, it will be assumed to be 'departure' and time is the current local time at the origin point.",
"in": "query",
"required": false,
"type": "string"
},
{
"name": "timeType",
"description": "Specifies whether the time signifies departure time or arrival time. If not defined, default value is 'departure'.",
"in": "query",
"required": false,
"type": "string",
"default": "departure",
"enum": [
"arrival",
"departure",
"last"
],
"x-ms-enum": {
"name": "TimeType",
"modelAsString": true,
"values": [
{
"value": "arrival",
"description": "arrival at the destination point. Requires that 'time' value must be in the future."
},
{
"value": "departure",
"description": "Request departure at the destination point. Requires that 'time' value must be now or in the future."
},
{
"value": "last",
"description": "Request the last lines for the day."
}
]
}
},
{
"name": "routeType",
"description": "The type of route requested. If not specified, 'optimal' will be used.",
"in": "query",
"required": false,
"type": "string",
"default": "optimal",
"enum": [
"optimal",
"leastWalk",
"leastTransfers"
],
"x-ms-enum": {
"name": "TransitRouteType",
"modelAsString": true,
"values": [
{
"value": "optimal",
"description": "The best optimal route."
},
{
"value": "leastWalk",
"description": "Route with least walk."
},
{
"value": "leastTransfers",
"description": "Route with least transfers."
}
]
}
},
{
"name": "bikeType",
"description": "Bike type of the bike. Specifies which type of bikes will be used. Only private bikes are supported.",
"in": "query",
"required": false,
"type": "string",
"default": "privateBike"
},
{
"$ref": "#/parameters/MobilityLanguage"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/TransitRouteResponse"
}
},
"400": {
"$ref": "#/responses/400"
},
"401": {
"$ref": "#/responses/401"
},
"403": {
"$ref": "#/responses/403"
},
"404": {
"$ref": "#/responses/404"
},
"500": {
"$ref": "#/responses/500"
}
}
}
},
"/mobility/transit/itinerary/{format}": {
"get": {
"x-publish": true,
"operationId": "Mobility_GetTransitItineraryPreview",