DriveBC's Open511 API
gov · Government
This API is DriveBC's implementation of the Open511 specification. It provides information about known road events (traffic accidents, construction, etc.) in British Columbia, Canada. Please note that you may experience issues when submitting requests to the delivery or test environment if using this [OpenAPI specification](https://github.com/bcgov/api-specs) in other API console viewers.
Authentication
Sample Requests
Lists the geographical areas (e.g. districts) that can be used to filter events.
Hover any highlighted part to learn what it does
curl -X GET "https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/areas?format=json"
import requests
params = {
"format": "json"
}
response = requests.get(
"https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/areas",
params=params,
)
print(response.json())const url = new URL('https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/areas');
url.searchParams.set('format', 'json');
const response = await fetch(url);
const data = await response.json();
console.log(data);package main
import (
"fmt"
"io"
"net/http"
"net/url"
)
func main() {
baseURL, _ := url.Parse("https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/areas")
q := baseURL.Query()
q.Set("format", "json")
baseURL.RawQuery = q.Encode()
targetURL := baseURL.String()
req, _ := http.NewRequest("GET", targetURL, nil)
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}require "net/http"
require "json"
uri = URI("https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/areas")
uri.query = URI.encode_www_form({
"format" => "json"
})
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
req = Net::HTTP::Get.new(uri)
res = http.request(req)
puts JSON.parse(res.body)<?php
$url = "https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/areas?" . http_build_query([
"format" => "json"
]);
$opts = ["http" => [
"method" => "GET",
]];
$ctx = stream_context_create($opts);
$res = file_get_contents($url, false, $ctx);
print_r(json_decode($res, true));The events resource provides information about road events (e.g. accidents, construction, special events). The response is a list of event elements matching the filtering parameters if any are provided.
Hover any highlighted part to learn what it does
curl -X GET "https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/events?bbox=-130%2C48%2C-116%2C60&format=json&status=ALL&area_id=drivebc.ca%2F1&created=%3E2015-09-01T12%3A00%3A00Z&updated=%3E2015-09-01T12%3A00%3A00Z&severity=MAJOR&road_name=Highway%2099&event_type=INCIDENT&jurisdiction=drivebc.ca"
import requests
params = {
"bbox": "-130,48,-116,60",
"format": "json",
"status": "ALL",
"area_id": "drivebc.ca/1",
"created": ">2015-09-01T12:00:00Z",
"updated": ">2015-09-01T12:00:00Z",
"severity": "MAJOR",
"road_name": "Highway 99",
"event_type": "INCIDENT",
"jurisdiction": "drivebc.ca"
}
response = requests.get(
"https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/events",
params=params,
)
print(response.json())const url = new URL('https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/events');
url.searchParams.set('bbox', '-130,48,-116,60');
url.searchParams.set('format', 'json');
url.searchParams.set('status', 'ALL');
url.searchParams.set('area_id', 'drivebc.ca/1');
url.searchParams.set('created', '>2015-09-01T12:00:00Z');
url.searchParams.set('updated', '>2015-09-01T12:00:00Z');
url.searchParams.set('severity', 'MAJOR');
url.searchParams.set('road_name', 'Highway 99');
url.searchParams.set('event_type', 'INCIDENT');
url.searchParams.set('jurisdiction', 'drivebc.ca');
const response = await fetch(url);
const data = await response.json();
console.log(data);package main
import (
"fmt"
"io"
"net/http"
"net/url"
)
func main() {
baseURL, _ := url.Parse("https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/events")
q := baseURL.Query()
q.Set("bbox", "-130,48,-116,60")
q.Set("format", "json")
q.Set("status", "ALL")
q.Set("area_id", "drivebc.ca/1")
q.Set("created", ">2015-09-01T12:00:00Z")
q.Set("updated", ">2015-09-01T12:00:00Z")
q.Set("severity", "MAJOR")
q.Set("road_name", "Highway 99")
q.Set("event_type", "INCIDENT")
q.Set("jurisdiction", "drivebc.ca")
baseURL.RawQuery = q.Encode()
targetURL := baseURL.String()
req, _ := http.NewRequest("GET", targetURL, nil)
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}require "net/http"
require "json"
uri = URI("https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/events")
uri.query = URI.encode_www_form({
"bbox" => "-130,48,-116,60",
"format" => "json",
"status" => "ALL",
"area_id" => "drivebc.ca/1",
"created" => ">2015-09-01T12:00:00Z",
"updated" => ">2015-09-01T12:00:00Z",
"severity" => "MAJOR",
"road_name" => "Highway 99",
"event_type" => "INCIDENT",
"jurisdiction" => "drivebc.ca"
})
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
req = Net::HTTP::Get.new(uri)
res = http.request(req)
puts JSON.parse(res.body)<?php
$url = "https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/events?" . http_build_query([
"bbox" => "-130,48,-116,60",
"format" => "json",
"status" => "ALL",
"area_id" => "drivebc.ca/1",
"created" => ">2015-09-01T12:00:00Z",
"updated" => ">2015-09-01T12:00:00Z",
"severity" => "MAJOR",
"road_name" => "Highway 99",
"event_type" => "INCIDENT",
"jurisdiction" => "drivebc.ca"
]);
$opts = ["http" => [
"method" => "GET",
]];
$ctx = stream_context_create($opts);
$res = file_get_contents($url, false, $ctx);
print_r(json_decode($res, true));Lists the jurisdictions publishing data through this Open511 API implementation
Hover any highlighted part to learn what it does
curl -X GET "https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/jurisdiction?format=json"
import requests
params = {
"format": "json"
}
response = requests.get(
"https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/jurisdiction",
params=params,
)
print(response.json())const url = new URL('https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/jurisdiction');
url.searchParams.set('format', 'json');
const response = await fetch(url);
const data = await response.json();
console.log(data);package main
import (
"fmt"
"io"
"net/http"
"net/url"
)
func main() {
baseURL, _ := url.Parse("https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/jurisdiction")
q := baseURL.Query()
q.Set("format", "json")
baseURL.RawQuery = q.Encode()
targetURL := baseURL.String()
req, _ := http.NewRequest("GET", targetURL, nil)
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}require "net/http"
require "json"
uri = URI("https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/jurisdiction")
uri.query = URI.encode_www_form({
"format" => "json"
})
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
req = Net::HTTP::Get.new(uri)
res = http.request(req)
puts JSON.parse(res.body)<?php
$url = "https://api.apis.guru/v2/specs/gov.bc.ca/open511/1.0.0/jurisdiction?" . http_build_query([
"format" => "json"
]);
$opts = ["http" => [
"method" => "GET",
]];
$ctx = stream_context_create($opts);
$res = file_get_contents($url, false, $ctx);
print_r(json_decode($res, true));Postman Setup Guide
- See official documentation for authentication and setup.
What can you build with DriveBC's Open511 API?
DriveBC's Open511 API is a Government API. Developers commonly use government APIs for:
- surfacing public datasets in citizen-facing apps
- building transparency and civic engagement tools
- accessing legislation, court records, and official data
- powering research and journalism tools
- creating compliance and regulatory monitoring dashboards
No authentication required. This API is open — no signup or key needed. Ideal for quick prototypes and public-facing features. DriveBC's Open511 API is free to use, making it a low-risk choice to experiment with.
New to APIs? Read our beginner's guide · Learn about API keys · What is REST?