GET Events
Returns all traffic events.
Request Information
https://511yukon.ca/api/v2/get/event
URI Parameters
| Name | Description | Type | Additional information | 
|---|---|---|---|
| key | 
                                         Developer Key  | 
                                    string | 
                                         Required  | 
                                
| format | 
                                     Valid values are 'xml' or 'json', default 'json'.  | 
                                string | 
                                     Optional  | 
                            
| lang | 
                                         Valid values are 'en' or 'fr', default 'en'.  | 
                                    string | 
                                         Optional  | 
                                
Response Information
Resource Description
| Name | Description | Type | 
|---|---|---|
| ID | 
                                             A unique identifier.  | 
                                        integer | 
| SourceId | 
                                             The source id of the event.  | 
                                        string | 
| Organization | 
                                             The name of the organization that provided this event.  | 
                                        string | 
| RoadwayName | 
                                             The roadway on which the event occurred.  | 
                                        string | 
| DirectionOfTravel | 
                                             One of the following directions of travel: None, All Directions, Northbound, Eastbound, Southbound, Westbound, Inbound, Outbound, Both Directions.  | 
                                        string | 
| Description | 
                                             A summary of the event details which often includes type of event, dates and lanes affected.  | 
                                        string | 
| Reported | 
                                             The date the event was reported in Unix time. More information  | 
                                        integer | 
| LastUpdated | 
                                             The date the event's details were last updated in Unix time. More information  | 
                                        integer | 
| StartDate | 
                                             The start date of the event in Unix time. More information  | 
                                        integer | 
| PlannedEndDate | 
                                             The date the event is expected to end in Unix time. More information  | 
                                        integer | 
| LanesAffected | 
                                             Describes the lane or number of lanes affected by the event. For example: all lanes.  | 
                                        string | 
| Latitude | 
                                             The latitude describing the location. Format: double between -90 and 90.  | 
                                        double | 
| Longitude | 
                                             The longitude describing the location. Format: double between -180 and 180.  | 
                                        double | 
| LatitudeSecondary | 
                                             Secondary latitude.  | 
                                        double | 
| LongitudeSecondary | 
                                             Secondary Longitude.  | 
                                        double | 
| EventType | 
                                             The type of event. One of the following: roadwork, closures or accidentsAndIncidents.  | 
                                        string | 
| EventSubType | 
                                             A more detailed and descriptive event type. No fixed list of sub types.  | 
                                        string | 
| IsFullClosure | 
                                             True if all lanes are blocked for this event.  | 
                                        boolean | 
| Severity | 
                                             Describes the severity of the event with default value of Unknown.  | 
                                        string | 
| EncodedPolyline | 
                                             A single string storing a series of coordinates. More information  | 
                                        string | 
| Restrictions | 
                                             Different types of restriction: Width (metres), Height (metres), Weight (tonnes) and Speed (km/h).  | 
                                        list | 
| DetourPolyline | 
                                             Google Encoded Polyline for the detour  | 
                                        string | 
| DetourInstructions | 
                                             Turn by turn instructions for the detour  | 
                                        string | 
| Recurrence | 
                                             Describes the schedule of the event.  | 
                                        string | 
| RecurrenceSchedules | 
                                             More information about recurring events. Event start and end dates, times and day(s) of the week event is active.  | 
                                        string | 
| Details | 
                                             Event Details  | 
                                        string | 
Response Formats
JSON
[
    {
        "ID": 216,
        "SourceId": "483",
        "Organization": "ERS",
        "RoadwayName": "HWY-2",
        "DirectionOfTravel": "North",
        "Description": "Object on freeway on HWY-2 Northbound  near roadway marker 422. Shoulder Closed.    Width Restriction: 5.5m Height Restriction: 7.2m Length Restriction: 10.5m Single-Unit GVW Restriction: 28.6kg Two-Unit GVW Restriction: 32.5kg Vehicle Train GVW Restriction: 42.7kg Maximum GVW Restriction: 50.8kg  Additional Restrictions: Hazmat Prohibited, Escort Vehicle Required, No Oversized Loads",
        "Reported": 1648834765,
        "LastUpdated": 1649361245,
        "StartDate": 1648834765,
        "PlannedEndDate": null,
        "LanesAffected": "All Shoulders Closed",
        "Latitude": 62.5353433419136,
        "Longitude": -136.762421880206,
        "LatitudeSecondary": null,
        "LongitudeSecondary": null,
        "EventType": "accidentsAndIncidents",
        "EventSubType": "objectOnFreeway",
        "IsFullClosure": false,
        "Severity": "Major",
        "EncodedPolyline": null,
        "Restrictions": {
            "Width": 5.50,
            "Height": 7.20,
            "Length": 10.50,
            "Weight": null,
            "Speed": null
        },
        "DetourPolyline": "",
        "DetourInstructions": "",
        "Recurrence": "",
        "RecurrenceSchedules": "",
        "Details": null
    }
]
                            XML
<EventList>
    <Event>
        <ID>216</ID>
        <SourceId>483</SourceId>
        <Organization>ERS</Organization>
        <RoadwayName>HWY-2</RoadwayName>
        <DirectionOfTravel>North</DirectionOfTravel>
        <Description>Object on freeway on HWY-2 Northbound  near roadway marker 422. Shoulder Closed.    Width Restriction: 5.5m Height Restriction: 7.2m Length Restriction: 10.5m Single-Unit GVW Restriction: 28.6kg Two-Unit GVW Restriction: 32.5kg Vehicle Train GVW Restriction: 42.7kg Maximum GVW Restriction: 50.8kg  Additional Restrictions: Hazmat Prohibited, Escort Vehicle Required, No Oversized Loads</Description>
        <Reported>1648834765</Reported>
        <LastUpdated>1649361245</LastUpdated>
        <StartDate>1648834765</StartDate>
        <PlannedEndDate />
        <LanesAffected>All Shoulders Closed</LanesAffected>
        <Latitude>62.5353433419136</Latitude>
        <Longitude>-136.762421880206</Longitude>
        <LatitudeSecondary />
        <LongitudeSecondary />
        <EventType>accidentsAndIncidents</EventType>
        <EventSubType>objectOnFreeway</EventSubType>
        <IsFullClosure>false</IsFullClosure>
        <Severity>Major</Severity>
        <EncodedPolyline />
        <Restrictions>
            <Width>5.50</Width>
            <Height>7.20</Height>
            <Length>10.50</Length>
            <Weight />
            <Speed />
        </Restrictions>
        <DetourPolyline></DetourPolyline>
        <DetourInstructions></DetourInstructions>
        <Recurrence></Recurrence>
        <RecurrenceSchedules></RecurrenceSchedules>
        <Details />
    </Event>
</EventList>