Skip to content

Commit 5ce7330

Browse files
committed
Add info on creating an Azure Maps account with a global region
1 parent 1a25984 commit 5ce7330

File tree

2 files changed

+24
-4
lines changed

2 files changed

+24
-4
lines changed

articles/azure-maps/azure-maps-event-grid-integration.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ The following example shows the schema for GeofenceResult:
6868

6969
Applications that handle Azure Maps geofence events should follow a few recommended practices:
7070

71+
* The Geofence API async event requires the region property of your Azure Maps account be set to ***Global***. When creating an Azure Maps account in the Azure portal, this is not given as an option. See [Create an Azure Maps account with a global region](tutorial-geofence#create-an-azure-maps-account-with-a-global-region) for more information.
7172
* Configure multiple subscriptions to route events to the same event handler. It's important not to assume that events are from a particular source. Always check the message topic to ensure that the message came from the source that you expect.
7273
* Use the `X-Correlation-id` field in the response header to understand if your information about objects is up to date. Messages can arrive out of order or after a delay.
7374
* When a GET or a POST request in the Geofence API is called with the mode parameter set to `EnterAndExit`, then an Enter or Exit event is generated for each geometry in the geofence for which the status has changed from the previous Geofence API call.

articles/azure-maps/tutorial-geofence.md

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: 'Tutorial: Create a geofence and track devices on a Microsoft Azure Map'
33
description: Tutorial on how to set up a geofence. See how to track devices relative to the geofence by using the Azure Maps Spatial service
44
author: stevemunk
55
ms.author: v-munksteve
6-
ms.date: 10/28/2021
6+
ms.date: 02/28/2021
77
ms.topic: tutorial
88
ms.service: azure-maps
99
services: azure-maps
@@ -22,17 +22,36 @@ Azure Maps provides a number of services to support the tracking of equipment en
2222

2323
> [!div class="checklist"]
2424
>
25+
> * Create an Azure Maps account with a global region.
2526
> * Upload [Geofencing GeoJSON data](geofence-geojson.md) that defines the construction site areas you want to monitor. You'll use the [Data Upload API](/rest/api/maps/data-v2/upload-preview) to upload geofences as polygon coordinates to your Azure Maps account.
2627
> * Set up two [logic apps](../event-grid/handler-webhooks.md#logic-apps) that, when triggered, send email notifications to the construction site operations manager when equipment enters and exits the geofence area.
2728
> * Use [Azure Event Grid](../event-grid/overview.md) to subscribe to enter and exit events for your Azure Maps geofence. You set up two webhook event subscriptions that call the HTTP endpoints defined in your two logic apps. The logic apps then send the appropriate email notifications of equipment moving beyond or entering the geofence.
2829
> * Use [Search Geofence Get API](/rest/api/maps/spatial/getgeofence) to receive notifications when a piece of equipment exits and enters the geofence areas.
2930
3031
## Prerequisites
3132

32-
1. [Create an Azure Maps account](quick-demo-map-app.md#create-an-azure-maps-account).
33-
2. [Obtain a primary subscription key](quick-demo-map-app.md#get-the-primary-key-for-your-account), also known as the primary key or the subscription key.
33+
* This tutorial uses the [Postman](https://www.postman.com/) application, but you can use a different API development environment.
3434

35-
This tutorial uses the [Postman](https://www.postman.com/) application, but you can use a different API development environment.
35+
## Create an Azure Maps account with a global region
36+
37+
The Geofence API async event requires the region property of your Azure Maps account be set to ***Global***. When creating an Azure Maps account in the Azure portal, this is not given as an option, however you do have several other options for creating a new Azure Maps account with the *global* region setting. This section lists the three methods that can be used to create and Azure Maps account with teh region set to global.
38+
39+
> [!NOTE]
40+
> The `location` property in both the ARM template and PowerShell `New-AzMapsAccount` command refer to the same property as the `Region` field in the Azure portal.
41+
42+
### Use an ARM template to create an Azure Maps account with a global region
43+
44+
You will need to [Create your Azure Maps account using an ARM template](how-to-create-template), making sure to set `location` to `global` in the `resources` section of the ARM template.
45+
46+
### Use PowerShell to create an Azure Maps account with a global region
47+
48+
```powershell
49+
New-AzMapsAccount -ResourceGroupName your-Resource-Group -Name name-of-maps-account -SkuName g2 -Location global
50+
```
51+
52+
### Use Azure CLI to create an Azure Maps account with a global region
53+
54+
The Azure CLI command [az maps account create](/cli/azure/maps/account?view=azure-cli-latest#az-maps-account-create) doesn’t have a location property, but defaults to “global”, making it useful for creating an Azure Maps account with a global region setting for use with the Geofence API async event.
3655

3756
## Upload geofencing GeoJSON data
3857

0 commit comments

Comments
 (0)