Weather alerts along the route resource
This resource provides information about weather alerts.
| Method | URL format |
|---|---|
POST | https://{base_url}/v3/alerts |
You can find more details on the applicable query and path parameters in the sections below. The base_url will be provided during the process of obtaining credentials.
Authorization
Each request is authenticated and requires a valid bearer token to be included in HTTP Authorization header:
Authorization: Bearer <token>For more information about obtaining credentials, see the Identity and Access Management Developer Guide.
Request payload
Request is in geo-json format and accept LineString geometry. Corridor width can be defined throug width value in feature properties. Value in integer in range 1000 - 10000 m. Default is 50000m.
Example
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"geometry": {
"type": "LineString",
"coordinates": [
[
139.60052490234375,
37.37888785004527
],
[
139.58953857421875,
37.659906493259385
],
[
139.73785400390625,
37.81629348024509
],
[
139.9273681640625,
38.05025395161289
],
[
140.11688232421875,
38.26190641637658
],
[
139.976806640625,
38.50089258896462
],
[
140.0811767578125,
38.63189092902837
],
[
140.41351318359375,
38.67907761983558
]
]
},
"properties": {
"width": 3000
}
}
]
}Response
On success, the response status is 200 OK and the response payload contains the weather alerts that affect the specified route.
The response is in GeoJSON format (specified in RFC 7946). Each GeoJSON feature in the response describes one or multiple weather alerts. The feature geometry is defined as a polygon or a multi-polygon and describes the affected area.
Weather alerts update frequency
Minimal time between updates is 10 minutes. In practice, the update frequency depends on how national weather institutes update the data.
Example
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"id": "wa-1241114531",
"geometry": {
"type": "MultiPolygon",
"coordinates": ...,
}
"properties": {
"warnings": [
{
"startTime": 1555283514,
"endTime": 1555542714,
"type": 15,
"severity": 1,
"country": "AU",
"messages": [
{
"language":"en-AU",
"text":"Minor Flood Warning for Warrego River (NSW), Warrego River at Barringun No. 2, Warrego River at Enngonia and Warrego River at Fords Bridge Bywash"
}
]
}
]
},
},
...
}Properties data model
| Property | Required | Description |
|---|---|---|
warnings | Yes | An array of warnings. The warning data model is defined below. |
Warning data model
| Property | Required | Description |
|---|---|---|
id | Yes | Unique weather alert id. |
startTime | Yes | Start time of the event in UNIX time. |
endTime | No | End time of the event in UNIX time. If not present, warning is valid until it is not removed from the feed by national weather institutes (valid until warning is present in the response) |
severity | Yes | The severity of the event. One of: - 0 Event doesn't have significance by nature - 1 There are no alerts for the location - 2 Minor Severity, the event is potentially dangerous but not usual - 3 Medium Severity, the event is dangerous - 4 High Severity, The event is very dangerous - 5 Emergency. Take immediate action to protect life. |
type | Yes | Event type. The possible values are defined in the table below. |
country | No | ISO-3166-1 2-letter country code. |
messages | No | An array of localized textual descriptions of the event. See example above. |
Messages data model
| Property | Required | Description |
|---|---|---|
language | Yes | Lanuage code. |
text | Yes | Human readable weather warning description. |
Event types
More details about event types - see individual event region or country specific description. If some region or country is missing here, it means that National weather institues does not provide any more details when warning is issued.
On failure, the response has a different status code and may include additional information about the error. You can use this additional information to troubleshoot this issue. For more information see Response status codes
Updated 11 days ago