Skip to main content
GET
/
api
/
v1
/
infrastructure_projects
/
stats
curl -H "X-API-Key: your_api_key_here" \
  "https://api.northaxiumdata.ca/api/v1/infrastructure_projects/stats?group_by=province"
{
  "data": [
    {
      "group_by": "province",
      "group_value": "ON",
      "record_count": 4821,
      "sum_field": "federal_contribution",
      "sum_value": 12400000000.00
    },
    {
      "group_by": "province",
      "group_value": "QC",
      "record_count": 3104,
      "sum_field": "federal_contribution",
      "sum_value": 8750000000.00
    }
  ],
  "meta": {
    "total": 13,
    "limit": 100,
    "offset": 0
  }
}

Overview

Returns grouped aggregate statistics over the Infrastructure Canada projects dataset. Use this to answer questions like “how much federal infrastructure funding has gone to Quebec?” or “which programs have the highest total contribution?” Accepts the same filter parameters as Infrastructure Projects, so you can scope statistics to any subset before grouping.

Query Parameters

group_by
string
Field to group results by. One of province, program, status. Default: province. Example: vendor.
sum_field
string
Field to sum. Only federal_contribution is currently supported. Default: federal_contribution. Example: amount.
q
string
Full-text match across title, recipient, and location — applied before grouping. Example: University of Toronto.
province
string
Two-letter province code filter applied before grouping. Example: ON.
program
string
Partial match on program_en applied before grouping. Example: Canada Summer Jobs.
status
string
Exact match on project status applied before grouping. Example: issued.
min_value
number
Minimum federal contribution filter applied before grouping. Example: 100000.
max_value
number
Maximum federal contribution filter applied before grouping. Example: 5000000.
issued_after
string
ISO 8601 approved-date lower bound applied before grouping. Example: 2023-01-01.
issued_before
string
ISO 8601 approved-date upper bound applied before grouping. Example: 2023-12-31.
limit
integer
Max groups to return. Default: 100. Max: 200. Example: 25.
offset
integer
Result offset. Default: 0. Example: 50.
curl -H "X-API-Key: your_api_key_here" \
  "https://api.northaxiumdata.ca/api/v1/infrastructure_projects/stats?group_by=province"
{
  "data": [
    {
      "group_by": "province",
      "group_value": "ON",
      "record_count": 4821,
      "sum_field": "federal_contribution",
      "sum_value": 12400000000.00
    },
    {
      "group_by": "province",
      "group_value": "QC",
      "record_count": 3104,
      "sum_field": "federal_contribution",
      "sum_value": 8750000000.00
    }
  ],
  "meta": {
    "total": 13,
    "limit": 100,
    "offset": 0
  }
}