Get an Existing Site

GET /Sites/{SiteId}

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

Request

Authorization: bearer {token}

Parameters:

NameDescriptionData Type
SiteId(Required) Unique Site idInt

Response Body

NameDescriptionData Type
SiteIdUnique Site identifierInt
SiteNameName of the sitestring
ModifiedOnThe last time the site was modifiedDateTime
PolygonAn array containing the latitude/longitude pairs that define the boundaries of the siteArray of decimals
SitesGatesArray of gates information associated with the siteComplex

SiteGate

NameDescriptionData Type
GateTypeThe type of gate. Valid values include:
  • Two way
  • Entry Only
  • Exit Only
string
GateNoteDriver notes to be displayed when approaching the gatestring
SiteSnapCoordsCoords on the Site polygon where the gate is locatedCoords
RoadSnapCoordsCoords on the road network to access the gateCoords
TruckRestrictedIndicates if the gate is truck restrictedboolean
AutoRestrictedIndicates if the gate is auto restrictedboolean

Coords

DataDescriptionData Type
LatLatitude up to 6 digit precisionstring
LonLongitude up to 6 digit precisionstring

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

MessageDescription
401 UnauthorizedThis error is thrown when Authorization token is invalid or expired.