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
Copy file name to clipboardExpand all lines: articles/azure-maps/how-to-request-weather-data.md
+50-19Lines changed: 50 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,26 +37,33 @@ This video provides examples for making REST calls to Azure Maps Weather service
37
37
* An [Azure Maps account]
38
38
* A [subscription key]
39
39
40
-
>[!IMPORTANT]
41
-
>The [Get Minute Forecast API] requires a Gen1 (S1) or Gen2 pricing tier.
40
+
>[!IMPORTANT]
41
+
>
42
+
> - In the URL examples in this article you will need to replace `{Your-Azure-Maps-Subscription-key}` with your Azure Maps subscription key.
42
43
43
-
This tutorial uses the [Postman] application, but you may choose a different API development environment.
44
+
This tutorial uses the [bruno] application, but you may choose a different API development environment.
44
45
45
46
## Request real-time weather data
46
47
47
48
The [Get Current Conditions API] returns detailed weather conditions such as precipitation, temperature, and wind for a given coordinate location. Also, observations from the past 6 or 24 hours for a particular location can be retrieved. The response includes details like observation date and time, description of weather conditions, weather icon, precipitation indicator flags, and temperature. RealFeel™ Temperature and ultraviolet(UV) index are also returned.
48
49
49
50
In this example, you use the [Get Current Conditions API] to retrieve current weather conditions at coordinates located in Seattle, WA.
50
51
51
-
1. Open the Postman app. Select**New** to create the request. In the **Create New** window, select**HTTP Request**. Enter a **Request name** for the request.
52
+
1. Open the bruno app, select**NEW REQUEST** to create the request. In the **NEW REQUEST** window, set**Type** to **HTTP**. Enter a **Name** for the request.
52
53
53
-
2. Select the **GET** HTTP method in the builder tab and enter the following URL. For this request, and other requests mentioned in this article, replace `{Your-Azure-Maps-Subscription-key}` with your Azure Maps subscription key.
54
+
1. Select the **GET** HTTP method in the **URL** drop-down list, then enter the following URL:
3. Select the blue **Send** button. The response body contains current weather information.
60
+
1. Select the blue **Create** button.
61
+
62
+
1. Select the run button.
63
+
64
+
:::image type="content" source="./media/weather-service/bruno-run.png" alt-text="A screenshot showing the Request real-time weather data URL with the run button highlighted in the bruno app.":::
65
+
66
+
The response body contains current weather information.
60
67
61
68
```json
62
69
{
@@ -238,15 +245,21 @@ In this example, you use the [Get Severe Weather Alerts API] to retrieve current
238
245
>[!NOTE]
239
246
>This example retrieves severe weather alerts at the time of this writing. It is likely that there are no longer any severe weather alerts at the requested location. To retrieve actual severe alert data when running this example, you'll need to retrieve data at a different coordinate location.
240
247
241
-
1. In the Postman app, select **New** to create the request. In the **Create New** window, select **HTTP Request**. Enter a **Request name** for the request.
248
+
1. In the bruno app, select **NEW REQUEST** to create the request. In the **NEW REQUEST** window, set **Type** to **HTTP**. Enter a **Name** for the request.
242
249
243
-
2. Select the **GET** HTTP method in the builder tab and enter the following URL. For this request, and other requests mentioned in this article, replace `{Your-Azure-Maps-Subscription-key}` with your Azure Maps subscription key.
250
+
1. Select the **GET** HTTP method in the **URL** drop-down list, then enter the following URL:
3. Select the blue **Send** button. If there are no severe weather alerts, the response body contains an empty `results[]` array. If there are severe weather alerts, the response body contains something like the following JSON response:
256
+
1. Select the blue **Create** button.
257
+
258
+
1. Select the run button.
259
+
260
+
:::image type="content" source="./media/weather-service/bruno-run-request-severe-weather-alerts.png" alt-text="A screenshot showing the Request severe weather alerts URL with the run button highlighted in the bruno app.":::
261
+
262
+
If there are no severe weather alerts, the response body contains an empty `results[]` array. If there are severe weather alerts, the response body contains something like the following JSON response:
250
263
251
264
```json
252
265
{
@@ -294,15 +307,21 @@ The [Get Daily Forecast API] returns detailed daily weather forecast such as tem
294
307
295
308
In this example, you use the [Get Daily Forecast API] to retrieve the five-day weather forecast for coordinates located in Seattle, WA.
296
309
297
-
1. In the Postman app, select **New** to create the request. In the **Create New** window, select **HTTP Request**. Enter a **Request name** for the request.
310
+
1. In the bruno app, select **NEW REQUEST** to create the request. In the **NEW REQUEST** window, set **Type** to **HTTP**. Enter a **Name** for the request.
298
311
299
-
2. Select the **GET** HTTP method in the builder tab and enter the following URL. For this request, and other requests mentioned in this article, replace `{Your-Azure-Maps-Subscription-key}` with your Azure Maps subscription key.
312
+
1. Select the **GET** HTTP method in the **URL** drop-down list, then enter the following URL:
3. Select the blue **Send** button. The response body contains the five-day weather forecast data. For the sake of brevity, the following JSON response shows the forecast for the first day.
318
+
1. Select the blue **Create** button.
319
+
320
+
1. Select the run button.
321
+
322
+
:::image type="content" source="./media/weather-service/bruno-run-request-daily-weather-forecast-data.png" alt-text="A screenshot showing the Request daily weather forecast data URL with the run button highlighted in the bruno app.":::
323
+
324
+
The response body contains the five-day weather forecast data. For the sake of brevity, the following JSON response shows the forecast for the first day.
306
325
307
326
```json
308
327
{
@@ -543,15 +562,21 @@ The [Get Hourly Forecast API] returns detailed weather forecast by the hour for
543
562
544
563
In this example, you use the [Get Hourly Forecast API] to retrieve the hourly weather forecast for the next 12 hours at coordinates located in Seattle, WA.
545
564
546
-
1. In the Postman app, select **New** to create the request. In the **Create New** window, select **HTTP Request**. Enter a **Request name** for the request.
565
+
1. In the bruno app, select **NEW REQUEST** to create the request. In the **NEW REQUEST** window, set **Type** to **HTTP**. Enter a **Name** for the request.
547
566
548
-
2. Select the **GET** HTTP method in the builder tab and enter the following URL. For this request, and other requests mentioned in this article, replace `{Your-Azure-Maps-Subscription-key}` with your Azure Maps subscription key.
567
+
1. Select the **GET** HTTP method in the **URL** drop-down list, then enter the following URL:
3. Select the blue **Send** button. The response body contains weather forecast data for the next 12 hours. For the sake of brevity, the following JSON response shows the forecast for the first hour.
573
+
1. Select the blue **Create** button.
574
+
575
+
1. Select the run button.
576
+
577
+
:::image type="content" source="./media/weather-service/bruno-run-request-hourly-weather-forecast-data.png" alt-text=""A screenshot showing the Request hourly weather forecast data URL with the run button highlighted in the bruno app."":::
578
+
579
+
The response body contains weather forecast data for the next 12 hours. For the sake of brevity, the following JSON response shows the forecast for the first hour.
555
580
556
581
```json
557
582
{
@@ -651,15 +676,21 @@ In this example, you use the [Get Hourly Forecast API] to retrieve the hourly we
651
676
652
677
In this example, you use the [Get Minute Forecast API] to retrieve the minute-by-minute weather forecast at coordinates located in Seattle, WA. The weather forecast is given for the next 120 minutes. Our query requests that the forecast is given at 15-minute intervals, but you can adjust the parameter to be either 1 or 5 minutes.
653
678
654
-
1. In the Postman app, select **New** to create the request. In the **Create New** window, select **HTTP Request**. Enter a **Request name** for the request.
679
+
1. In the bruno app, select **NEW REQUEST** to create the request. In the **NEW REQUEST** window, set **Type** to **HTTP**. Enter a **Name** for the request.
655
680
656
-
2. Select the **GET** HTTP method in the builder tab and enter the following URL. For this request, and other requests mentioned in this article, replace `{Your-Azure-Maps-Subscription-key}` with your Azure Maps subscription key.
681
+
1. Select the **GET** HTTP method in the **URL** drop-down list, then enter the following URL:
3. Select the blue **Send** button. The response body contains weather forecast data for the next 120 minutes, in 15-minute intervals.
687
+
1. Select the blue **Create** button.
688
+
689
+
1. Select the run button.
690
+
691
+
:::image type="content" source="./media/weather-service/bruno-run-request-minute-by-minute-weather-forecast-data.png" alt-text=""A screenshot showing the Request minute-by-minute weather forecast data URL with the run button highlighted in the bruno app."":::
692
+
693
+
The response body contains weather forecast data for the next 120 minutes, in 15-minute intervals.
663
694
664
695
```json
665
696
{
@@ -765,7 +796,7 @@ In this example, you use the [Get Minute Forecast API] to retrieve the minute-by
0 commit comments