Skip to main content

Get an Existing Site

Contents

The ContentTools API has been deprecated and replaced by the Places API.

GET /Sites/{SiteId}

Gets the site information for a place using the siteId. If the site includes gate information entered in the ContentTools web tool, it will also be returned.

Request

Authorization: bearer {token}

Parameters:

Name Description Data Type
SiteId (Required) Unique Site id
Int

Response Body

Name Description Data Type
SiteId Unique Site identifier
Int
SiteName Name of the site
string
ModifiedOn The last time the site was modified
DateTime
Polygon An array containing the latitude/longitude pairs that define the boundaries of the site
Array of decimals
SitesGates Array of gates information associated with the site
Complex

SiteGate

Name Description Data Type
GateType The type of gate. Valid values include:
  • Two way
  • Entry Only
  • Exit Only
string
GateNote Driver notes to be displayed when approaching the gate
string
SiteSnapCoords Coords on the Site polygon where the gate is located
Coords
RoadSnapCoords Coords on the road network to access the gate
Coords
TruckRestricted Indicates if the gate is truck restricted
boolean
AutoRestricted Indicates if the gate is auto restricted
boolean

Coords

Data Description Data Type
Lat Latitude up to 6 digit precision
string
Lon Longitude up to 6 digit precision
string

Sample Response

{
  "data": [
    {
      "Id": 131928,
      "SiteName": "Company site",
      "ModifiedOn": "2019-02-26T20:57:33.177+00:00",
      "Polygon": [
        [
          [-74.575495708167878, 40.382754195334741],
          [-74.574809062659838, 40.382137167831516],
          [-74.573006618202, 40.383436596653695],
          [-74.5739883067018, 40.383996405747617],
          [-74.575495708167878, 40.382754195334741]
        ]
      ],
      "SiteGates": [
        {
          "AutoRestricted": false,
          "GateNote": "Sample notes",
          "GateType": "Two Way",
          "SiteSnapCoords": {
            "Lat": "40.38385",
            "Lon": "-74.573732"
          },
          "RoadSnapCoords": {
            "Lat": "40.383919",
            "Lon": "-74.573676"
          },
          "TruckRestricted": false
        },
        {
          "AutoRestricted": false,
          "GateType": "Entry Only",
          "SiteSnapCoords": {
            "Lat": "40.383465",
            "Lon": "-74.573057"
          },
          "RoadSnapCoords": {
            "Lat": "40.383502",
            "Lon": "-74.573027"
          },
          "TruckRestricted": false
        }
      ]
    }
  ]
}

Error Codes

Message Description
401 Unauthorized This error is thrown when Authorization token is invalid or expired.
Last updated January 9, 2023.
API Endpoint:

Contents