API reference

HTS APIs

Every endpoint, schema and error code, rendered from the published OpenAPI files, in the order you integrate them.

Schema

geo_json_polygon

GeoJSON Polygon geometry strictly adhering to RFC 7946.

IMPORTANT: Coordinates follow the GeoJSON standard: [longitude, latitude]. This is the reverse of the other selectors in this API.

Fields

type
string enum
required

Must be set to polygon. This field identifies the selector as a GeoJSON geometry.

Values polygon · Example polygon
coordinates
array of array of array of number
required

An array of linear ring coordinate arrays.

  • Index 0: Exterior ring (boundary).
  • Index 1+: Interior rings (holes).
Items ≥ 1
center
coordinates

Geographic coordinates

Show fields
latitude
number
required

Latitude coordinate. Note: Precision is capped at 6 decimal places (~11cm). Higher precision is truncated.

Range ≥ -90, ≤ 90 · Example 40.7128
longitude
number
required

Longitude coordinate. Note: Precision is capped at 6 decimal places (~11cm). Higher precision is truncated.

Range ≥ -180, ≤ 180 · Example -74.006
Example
{
  "type": "polygon",
  "center": {
    "latitude": 40.7128,
    "longitude": -74.006
  },
  "coordinates": [
    [
      [
        -74.006,
        40.7128
      ]
    ]
  ]
}