GET api/GetCameras

Returns all cameras.

Request Information

https://www.i-traffic.co.za/api/getcameras?key={key}&format={format}

URI Parameters

Api Call
NameDescriptionTypeAdditional information
key

string

Required

format

Valid values are xml or json.

string

Required

Response Information

Resource Description


Api Call
NameDescriptionTypeAdditional information
ID

string

None.

Name

A name assigned to the camera. It will contain a fairly good description of the location where the camera is deployed.

string

None.

DirectionOfTravel

One of the following directions of travel: None, All Directions, Northbound, Eastbound, Southbound, Westbound, Inbound, Outbound, Both Directions.

string

None.

RoadwayName

string

None.

Url

The url to fetch the camera image.

string

None.

Disabled

boolean

None.

Blocked

boolean

None.

Latitude

decimal number

None.

Longitude

decimal number

None.

Response Formats

application/xml, text/xml

Sample:
<ArrayOfCamera xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <Camera>
    <Latitude>1.1</Latitude>
    <Longitude>2.1</Longitude>
    <ID>sample string 1</ID>
    <Name>sample string 2</Name>
    <DirectionOfTravel>sample string 3</DirectionOfTravel>
    <RoadwayName>sample string 4</RoadwayName>
    <Url>sample string 5</Url>
    <Disabled>true</Disabled>
    <Blocked>true</Blocked>
  </Camera>
  <Camera>
    <Latitude>1.1</Latitude>
    <Longitude>2.1</Longitude>
    <ID>sample string 1</ID>
    <Name>sample string 2</Name>
    <DirectionOfTravel>sample string 3</DirectionOfTravel>
    <RoadwayName>sample string 4</RoadwayName>
    <Url>sample string 5</Url>
    <Disabled>true</Disabled>
    <Blocked>true</Blocked>
  </Camera>
</ArrayOfCamera>

application/json, text/json

Sample:
[
  {
    "Latitude": 1.1,
    "Longitude": 2.1,
    "ID": "sample string 1",
    "Name": "sample string 2",
    "DirectionOfTravel": "sample string 3",
    "RoadwayName": "sample string 4",
    "Url": "sample string 5",
    "Disabled": true,
    "Blocked": true
  },
  {
    "Latitude": 1.1,
    "Longitude": 2.1,
    "ID": "sample string 1",
    "Name": "sample string 2",
    "DirectionOfTravel": "sample string 3",
    "RoadwayName": "sample string 4",
    "Url": "sample string 5",
    "Disabled": true,
    "Blocked": true
  }
]
Sanral, Western Cape Gov and City of Cape Town Logos