City of Toronto Open Data

Access 537+ datasets from the City of Toronto open data portal. Search, fetch, and analyze city data on transit, traffic, housing, environment, and more via...

MIT-0 · Free to use, modify, and redistribute. No attribution required.
0 · 23 · 0 current installs · 0 all-time installs
byRay Chan, PMP@raychanpmp
MIT-0
Security Scan
VirusTotalVirusTotal
Benign
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
Name/description (City of Toronto Open Data via CKAN) align with the included Python CLI which calls the CKAN API endpoint for open.toronto.ca. No unrelated binaries, credentials, or services are requested.
Instruction Scope
SKILL.md instructs running the included Python script which only performs CKAN API requests and prints results. The script writes a local cache file (.cache/catalog_cache.json) in the skill directory (1-hour TTL). It also issues package_show for each dataset name (could generate many API calls); this is behaviorally expected but may produce heavy requests.
Install Mechanism
No install spec is present (instruction-only skill with an included script). No downloads from external URLs or extraction steps; the script uses only the Python standard library.
Credentials
The skill requires no environment variables, no credentials, and no config paths. The Python script does not read env vars or secrets. This is proportionate to the stated purpose.
Persistence & Privilege
always is false and the skill does not request persistent platform privileges. The only persistent effect is a local cache file in the skill directory, which is reasonable for a CLI that caches API results.
Assessment
This skill appears coherent and limited to querying the City of Toronto CKAN API. Before installing, review that you trust the skill source (homepage is missing), and note that the included script will make many package_show requests when building its catalog and will create a .cache/catalog_cache.json file next to the script. There are no credential requests or hidden endpoints. If you are concerned about network usage or rate limits, run the script in a controlled environment or inspect/modify load_catalog to reduce how many detail requests it issues.

Like a lobster shell, security has layers — review code before you run it.

Current versionv1.0.2
Download zip
latestvk976pce26tbz172sw09jjzj3r983y9na

License

MIT-0
Free to use, modify, and redistribute. No attribution required.

SKILL.md

City of Toronto Open Data

Access and analyze 537+ open datasets from the City of Toronto via the CKAN API. Data covers transit, traffic, housing, environment, budget, community services, and more.

Portal: https://open.toronto.ca Platform: CKAN API: https://ckan0.cf.opendata.inter.prod-toronto.ca

Quick Start

# Search for datasets
python3 scripts/toronto_data.py search "traffic"

# List all datasets
python3 scripts/toronto_data.py list

# View dataset info
python3 scripts/toronto_data.py info 311-service-request-codes

# Fetch data from CKAN datastore
python3 scripts/toronto_data.py fetch traffic-volumes-at-intersections-for-all-modes --limit 5

# Fetch with filters
python3 scripts/toronto_data.py fetch traffic-volumes-at-intersections-for-all-modes --where "total_vehicle > 20000" --limit 10

# Export as CSV
python3 scripts/toronto_data.py fetch traffic-volumes-at-intersections-for-all-modes --limit 100 --csv > traffic.csv

# List datastore-enabled datasets
python3 scripts/toronto_data.py searchable

Commands Reference

CommandDescription
search <query>Search datasets by keyword
listList all datasets
info <dataset-id>Show dataset metadata and resources
fetch <dataset-id>Fetch data from datastore (opts: --limit, --where, --select, --csv)
searchableList datasets with queryable datastore resources

Query Parameters

  • --limit N — Max rows to return (default: 10)
  • --where "condition" — SQL filter (e.g., "total_vehicle > 20000")
  • --select "col1,col2" — Choose specific columns
  • --csv — Output as CSV instead of JSON
  • --resource-id ID — Specify which resource to query

Dataset IDs

Dataset IDs are URL-safe slugs (e.g., traffic-volumes-at-intersections-for-all-modes). Find them via search or list, or from the dataset URL: open.toronto.ca/dataset/{id}.

Data Sources

All data is sourced from the City of Toronto's Open Data Portal (open.toronto.ca). See references/datasets.md for a curated list of popular datasets.

Files

3 total
Select a file
Select a file to preview.

Comments

Loading comments…