queryType: getZonesData*
The getZonesData queryType is passed through the API to get information about all provided zones.
Parameters
| Parameter | Description | Type | Defined Value Set | Value Req’d |
|---|---|---|---|---|
| queryType | Must equal getZonesData. | STRING | getZonesData | Y |
| asOfDate | The date for which OSM base map version to use. This parameter is required if you have included “Segment” or “RelatedRoad” zone inputs. This date should be reflective of the first day of the last month in the date range for which you plan to use any zones returned by this API. The value should be provided in YYYY-MM-DD string format. The default value is the latest basemap. | STRING | - | N |
| zones |
An array of objects representing the zones for which you want information. Each object contains:
| ARRAY | ZoneType - “Custom”, “Segment”, ”RelatedRoad”, “State”, “County”, “City”, “TAZ”, “ZIP”, “CTR”, or “FSA” | Y |
Responses
| Code | Type | Description |
|---|---|---|
| 200 | JSON | The requested data. |
| 401 | JSON | Occurs for various unauthorized tasks e.g. if you didn’t provide credentials in your parameters. |
| 500 | JSON | Occurs if an internal server error occurs. Contact altitudesupport@geotab.com if this occurs. |
Response Schema
| Attribute | Description | Data Type | Defined Value Set |
|---|---|---|---|
| AsOfDate | The date when the map snapshot was created for OSM. | DATE | - |
| Counties |
An array of objects for counties the zone intersects. Each object contains:
| ARRAY | - |
| Country | The name of the country. | STRING | - |
| Geography | A GeoJSON string representing the geography of the zone. | STRING | - |
| ISO_3166_2 | The ISO 3166:2 code for the state or province. | STRING | - |
| ISO_A3 | ISO-A3 code for the country. | STRING | - |
| MaxLatitude | Maximum latitude of the zone. | FLOAT64 | - |
| MaxLongitude | Maximum longitude of the zone. | FLOAT64 | - |
| MinLatitude | Minimum latitude of the zone. | FLOAT64 | - |
| MinLongitude | Minimum longitude of the zone. | FLOAT64 | - |
| State | The name of the state or province. | STRING | - |
| StateId | Id of the state or province. | STRING | - |
| ZoneDescription |
Description of the passed in zone when available. The value is set based on the
| STRING | - |
| ZoneDetails | A JSON string of various metadata about the zone. | STRING | - |
| ZoneId | Identifies the zone Id of the passed in zone. | STRING | - |
| ZoneSubType |
The subtype value of the passed in zone, where available. The
| STRING | - |
| ZoneType | The zone type of the passed in zone. | STRING | “State”, ”County”, ”City”, ”CTR”, ”ZIP”, “TAZ”, “FSA”, “Custom”, “Segment”, “RelatedRoad” |
Sample parameters
{
"queryType": "getZonesData",
"zones": [{
"ZoneId": "32003",
"ISO_3166_2": "US-NV",
"ZoneType": "County"
}]
}