You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -24,62 +24,6 @@ global, trusted providers Esri and HERE. With affordable data, tracking and geof
24
24
capabilities, and built-in metrics for health monitoring, you can build sophisticated
25
25
location-enabled applications.
26
26
27
-
## Map
28
-
29
-
The Amazon Location Service Map resource gives you access to the underlying basemap data for a map.
30
-
You use the Map resource with a map rendering library to add an interactive map to your application.
31
-
You can add other functionality to your map, such as markers (or pins), routes, and polygon areas, as needed for your application.
32
-
33
-
For information about how to use map resources in practice, see [Using Amazon Location Maps in your application](https://docs.aws.amazon.com/location/latest/developerguide/using-maps.html).
34
-
35
-
To create a map, define a `Map`:
36
-
37
-
```ts
38
-
newlocation.Map(this, 'Map', {
39
-
mapName: 'my-map',
40
-
style: location.Style.VECTOR_ESRI_NAVIGATION,
41
-
customLayers: [location.CustomLayer.POI],
42
-
});
43
-
```
44
-
45
-
Use the `grant()` or `grantRendering()` method to grant the given identity permissions to perform actions
46
-
on the map:
47
-
48
-
```ts
49
-
declareconst role:iam.Role;
50
-
51
-
const map =newlocation.Map(this, 'Map', {
52
-
style: location.Style.VECTOR_ESRI_NAVIGATION,
53
-
});
54
-
map.grantRendering(role);
55
-
```
56
-
57
-
## Place Index
58
-
59
-
A key function of Amazon Location Service is the ability to search the geolocation information.
60
-
Amazon Location provides this functionality via the Place index resource. The place index includes
61
-
which [data provider](https://docs.aws.amazon.com/location/latest/developerguide/what-is-data-provider.html)
62
-
to use for the search.
63
-
64
-
To create a place index, define a `PlaceIndex`:
65
-
66
-
```ts
67
-
newlocation.PlaceIndex(this, 'PlaceIndex', {
68
-
placeIndexName: 'MyPlaceIndex', // optional, defaults to a generated name
69
-
dataSource: location.DataSource.HERE, // optional, defaults to Esri
70
-
});
71
-
```
72
-
73
-
Use the `grant()` or `grantSearch()` method to grant the given identity permissions to perform actions
Geofence collection resources allow you to store and manage geofences—virtual boundaries on a map.
@@ -108,33 +52,6 @@ const geofenceCollection = new location.GeofenceCollection(this, 'GeofenceCollec
108
52
geofenceCollection.grantRead(role);
109
53
```
110
54
111
-
## Route Calculator
112
-
113
-
Route calculator resources allow you to find routes and estimate travel time based on up-to-date road network and live traffic information from your chosen data provider.
114
-
115
-
For more information, see [Routes](https://docs.aws.amazon.com/location/latest/developerguide/route-concepts.html).
116
-
117
-
To create a route calculator, define a `RouteCalculator`:
A tracker stores position updates for a collection of devices. The tracker can be used to query the devices' current location or location history. It stores the updates, but reduces storage space and visual noise by filtering the locations before storing them.
@@ -152,7 +69,7 @@ new location.Tracker(this, 'Tracker', {
152
69
});
153
70
```
154
71
155
-
Use the `grant()`, `grantUpdateDevicePositions` or `grantRead()` method to grant the given identity permissions to perform actions
72
+
Use the `grant()`, `grantUpdateDevicePositions()` or `grantRead()` method to grant the given identity permissions to perform actions
AWS has released new [Enhanced Places, Routes, and Maps](https://aws.amazon.com/about-aws/whats-new/2024/11/amazon-location-service-enhanced-places-routes-maps/?nc1=h_ls). Since these use AWS-managed resources, users no longer need to create Maps, Places, and Routes resources themselves.
103
+
104
+
As a result, the following constructs are now considered legacy.
105
+
106
+
For more information, see [developer guide](https://docs.aws.amazon.com/location/latest/developerguide/what-is.html).
184
107
185
-
API keys are a key value that is associated with specific Amazon Location Service resources or API in your AWS account, and specific actions that you can perform on those resources.
186
-
You can use an API key in your application to make unauthenticated calls to the Amazon Location APIs for those resources.
108
+
### Map
187
109
188
-
For more information, see [Use API keys to authenticate](https://docs.aws.amazon.com/location/latest/developerguide/using-apikeys.html).
110
+
The Amazon Location Service Map resource gives you access to the underlying basemap data for a map.
111
+
You use the Map resource with a map rendering library to add an interactive map to your application.
112
+
You can add other functionality to your map, such as markers (or pins), routes, and polygon areas, as needed for your application.
113
+
114
+
For information about how to use map resources in practice, see [Using Amazon Location Maps in your application](https://docs.aws.amazon.com/location/latest/developerguide/using-maps.html).
189
115
190
-
To create an API key, define an `ApiKey`:
116
+
To create a map, define a `Map`:
191
117
192
118
```ts
193
-
newlocation.ApiKey(this, 'APIKeyAny', {
194
-
// specify allowed actions
195
-
allowMapsActions: [
196
-
location.AllowMapsAction.GET_STATIC_MAP,
197
-
],
198
-
allowPlacesActions: [
199
-
location.AllowPlacesAction.GET_PLACE,
200
-
],
201
-
allowRoutesActions: [
202
-
location.AllowRoutesAction.CALCULATE_ISOLINES,
203
-
],
119
+
newlocation.Map(this, 'Map', {
120
+
mapName: 'my-map',
121
+
style: location.Style.VECTOR_ESRI_NAVIGATION,
122
+
customLayers: [location.CustomLayer.POI],
204
123
});
205
124
```
206
125
207
-
> Note: `ApiKey` construct only supports [Enhanced Places, Routes, and Maps](https://aws.amazon.com/blogs/aws/announcing-new-apis-for-amazon-location-service-routes-places-and-maps/) This API key grants access to AWS-managed Places, Routes, and Maps.
126
+
Use the `grant()` or `grantRendering()` method to grant the given identity permissions to perform actions
127
+
on the map:
128
+
129
+
```ts
130
+
declareconst role:iam.Role;
131
+
132
+
const map =newlocation.Map(this, 'Map', {
133
+
style: location.Style.VECTOR_ESRI_NAVIGATION,
134
+
});
135
+
map.grantRendering(role);
136
+
```
137
+
138
+
### Place Index
139
+
140
+
A key function of Amazon Location Service is the ability to search the geolocation information.
141
+
Amazon Location provides this functionality via the Place index resource. The place index includes
142
+
which [data provider](https://docs.aws.amazon.com/location/latest/developerguide/what-is-data-provider.html)
143
+
to use for the search.
144
+
145
+
To create a place index, define a `PlaceIndex`:
146
+
147
+
```ts
148
+
newlocation.PlaceIndex(this, 'PlaceIndex', {
149
+
placeIndexName: 'MyPlaceIndex', // optional, defaults to a generated name
150
+
dataSource: location.DataSource.HERE, // optional, defaults to Esri
151
+
});
152
+
```
153
+
154
+
Use the `grant()` or `grantSearch()` method to grant the given identity permissions to perform actions
Route calculator resources allow you to find routes and estimate travel time based on up-to-date road network and live traffic information from your chosen data provider.
167
+
168
+
For more information, see [Routes](https://docs.aws.amazon.com/location/latest/developerguide/route-concepts.html).
169
+
170
+
To create a route calculator, define a `RouteCalculator`:
0 commit comments