MENU navbar-image

Introduction

Welcome to the Transit Tracker API Documentation! The API is completely free, as long as it is used without excess. Transit Tracker data is free of charge, but it is mandatory to credit agency data when specified. Credits are registered in the v2/agencies API, in the license object.

Bienvenue à la documentation de l'API de Transit Tracker! L'API est complètement gratuite, tant qu'elle est utilisée sans excès. Les données de Transit Tracker sont libre de droit, mais il est obligatoire de créditer les données des agences lorsque spécifié. Les crédits sont inscrit dans l'API v2/agencies, dans l'objet license.

Authenticating requests

This API is not authenticated.

Agencies

GET v2/agencies

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/agencies"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/agencies';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/agencies'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/agencies

GET v2/agencies/{agency_slug}

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/agencies/stm"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/agencies/stm';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/agencies/stm'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/agencies/{agency_slug}

URL Parameters

agency_slug   string   

The slug of the agency. Example: stm

Alerts

GET v2/alerts

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/alerts"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/alerts';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/alerts'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/alerts

GET v2/alerts/{alert_id}

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/alerts/2"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/alerts/2';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/alerts/2'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/alerts/{alert_id}

URL Parameters

alert_id   integer   

The ID of the alert. Example: 2

GET v2/regions/{region_slug}/alerts

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/regions/mtl/alerts"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/regions/mtl/alerts';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/regions/mtl/alerts'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/regions/{region_slug}/alerts

URL Parameters

region_slug   string   

The slug of the region. Example: mtl

Endpoints

GET v2/health

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/health"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/health';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/health'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/health

Landing

GeoJSON ressources used on the landing page

GET v2/landing

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/landing"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/landing';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/landing'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/landing

GET v2/landing/vehicles

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/landing/vehicles"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/landing/vehicles';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/landing/vehicles'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/landing/vehicles

Link

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/links"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/links';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/links'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/links/ea"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/links/ea';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/links/ea'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Regions

GET v2/regions

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/regions"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/regions';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/regions'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/regions

GET v2/regions/{region_slug}

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/regions/mtl"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/regions/mtl';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/regions/mtl'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/regions/{region_slug}

URL Parameters

region_slug   string   

The slug of the region. Example: mtl

Tags

GET v2/tags

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/tags"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/tags';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/tags'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/tags

GET v2/tags/{tag_id}

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/tags/1"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/tags/1';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/tags/1'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/tags/{tag_id}

URL Parameters

tag_id   integer   

The ID of the tag. Example: 1

Trips

Related trips / Voyages liées

Only available for some agencies. Disponible pour quelques agences seulement.

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/agencies/stm/trips/951057/blocks"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/agencies/stm/trips/951057/blocks';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/agencies/stm/trips/951057/blocks'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/agencies/{agencySlug}/trips/{tripId}/blocks

URL Parameters

agencySlug   string   

Example: stm

tripId   string   

Example: 951057

GeoJSON Shape

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/agencies/stm/shapes/praesentium"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/agencies/stm/shapes/praesentium';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/agencies/stm/shapes/praesentium'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/agencies/{agencySlug}/shapes/{shapeId}

URL Parameters

agencySlug   string   

Example: stm

shapeId   1000238   

Example: praesentium

Vehicles

GET v2/agencies/{agency_slug}/vehicles

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/agencies/stm/vehicles?geojson="
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/agencies/stm/vehicles';
$response = $client->get(
    $url,
    [
        'query' => [
            'geojson' => '0',
        ],
    ]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/agencies/stm/vehicles'
params = {
  'geojson': '0',
}
response = requests.request('GET', url, params=params)
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/agencies/{agency_slug}/vehicles

URL Parameters

agency_slug   string   

The slug of the agency. Example: stm

Query Parameters

geojson   boolean  optional  

Include a GeoJSON FeatureCollection to the response. Defaults to true. Example: false

GET v2/agencies/{agency}/vehicles.geojson

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/agencies/stm/vehicles.geojson"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/agencies/stm/vehicles.geojson';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/agencies/stm/vehicles.geojson'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/agencies/{agency}/vehicles.geojson

URL Parameters

agency   string   

The agency. Example: stm

GET v2/agencies/{agency_slug}/vehicles/{vehicle}

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/agencies/stm/vehicles/et"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/agencies/stm/vehicles/et';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/agencies/stm/vehicles/et'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/agencies/{agency_slug}/vehicles/{vehicle}

URL Parameters

agency_slug   string   

The slug of the agency. Example: stm

vehicle   string   

The vehicle. Example: et

GET v2/vehicles

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/vehicles"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/vehicles';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/vehicles'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/vehicles

GET v2/vehicles.geojson

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/vehicles.geojson"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/vehicles.geojson';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/vehicles.geojson'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/vehicles.geojson

GET v2/vehicles/{vehicle_id}

Example request:
curl --request GET \
    --get "https://api.transittracker.ca/v2/vehicles/1"
$client = new \GuzzleHttp\Client();
$url = 'https://api.transittracker.ca/v2/vehicles/1';
$response = $client->get($url);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json

url = 'https://api.transittracker.ca/v2/vehicles/1'
response = requests.request('GET', url, )
response.json()

Example response (503):

Show headers
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
vary: Origin
 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Service Unavailable</title>

        <!-- Fonts -->
        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        <!-- Styles -->
        <style>
            html, body {
                background-color: #fff;
                color: #636b6f;
                font-family: 'Nunito', sans-serif;
                font-weight: 100;
                height: 100vh;
                margin: 0;
            }

            .full-height {
                height: 100vh;
            }

            .flex-center {
                align-items: center;
                display: flex;
                justify-content: center;
            }

            .position-ref {
                position: relative;
            }

            .code {
                border-right: 2px solid;
                font-size: 26px;
                padding: 0 15px 0 15px;
                text-align: center;
            }

            .message {
                font-size: 18px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div class="flex-center position-ref full-height">
            <div class="code">
                503            </div>

            <div class="message" style="padding: 10px;">
                Service Unavailable            </div>
        </div>
    </body>
</html>

 

Request   

GET v2/vehicles/{vehicle_id}

URL Parameters

vehicle_id   integer   

The ID of the vehicle. Example: 1