GnistAI GnistAI
Log in

Open Data (Government Portals)

Search over 460,000 government datasets across the US, UK, and Canada. Find public data on any topic from official open data portals — from health statistics to transportation records.

Overview   |   MCP   |   REST API   |   OpenAPI   |   CLI   |   Tutorial   |   Toolkits   |   Home
status: healthy status status healthy healthy tools: 5 tools tools 5 5 type: api wrapper type type api wrapper api wrapper lifecycle: maintained lifecycle lifecycle maintained maintained Government

Data source: CKAN Open Data Portals

MCP Endpoint (Streamable HTTP) https://context.gnist.ai/mcp/opendata/
Authentication

All requests require a Gnist-API-Key header (or api_key query parameter).

Free tier: 100 calls/day. Get your API key.

Tools (5)

search_datasets

Search government open data datasets across US (data.gov), UK (data.gov.uk), or Canada (open.canada.ca).

Covers 460K+ datasets published by government agencies — CSV, JSON, GeoJSON, and API
endpoints for climate, transportation, health, economics, geospatial, and more. All free,
no API key required. Each result includes download links, formats, and organization info.

Args:
query: Keyword or topic to search for.
portal: Which country portal to search.
limit: Number of results (1-50, default 20).
offset: Pagination offset.

Returns:
List of matching datasets with title, description, organization, resources (download links),
tags, and license. Use get_dataset for full details on a specific result.

ParameterTypeRequiredDescription
querystringrequiredSearch query for datasets (e.g. "climate change", "transportation safety", "public health spending").
portalstringoptionalPortal to search: 'us' (data.gov, 290K+ datasets), 'uk' (data.gov.uk, 55K+), 'ca' (open.canada.ca, 115K+). Default 'us'. (default: "us")
limitintegeroptionalNumber of results (1-50, default 20). (default: 20)
offsetintegeroptionalResult offset for pagination (default 0). (default: 0)
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "search_datasets",
    "arguments": {
      "query": "example"
    }
  }
}
get_dataset

Get full details for a single government dataset by its name or ID.

Returns complete metadata including all download resources (CSV, JSON, API endpoints),
description, organization, tags, license, and last-modified date.

Args:
dataset_id: Dataset name or UUID from search results.
portal: Which country portal.

Returns:
Full dataset record with resources, or found=false if not found.

ParameterTypeRequiredDescription
dataset_idstringrequiredDataset name or ID (e.g. 'annual-enterprise-survey-2021'). Found in search_datasets results.
portalstringoptionalPortal: 'us', 'uk', or 'ca'. Default 'us'. (default: "us")
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_dataset",
    "arguments": {
      "dataset_id": "example"
    }
  }
}
list_organizations

List government organizations that publish open data on a portal.

Browse the publishing organizations (agencies, departments, offices) on a specific
portal. Each entry shows the organization name, description, and number of datasets published.

Args:
portal: Which country portal.
limit: Number of results (1-50, default 20).

Returns:
List of organizations with name, description, and dataset count.

ParameterTypeRequiredDescription
portalstringoptionalPortal: 'us', 'uk', or 'ca'. Default 'us'. (default: "us")
limitintegeroptionalNumber of results (1-50, default 20). (default: 20)
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "list_organizations",
    "arguments": {}
  }
}
get_organization

Get details for a specific government data-publishing organization.

Returns organization metadata including description, logo, and total dataset count.

Args:
org_id: Organization name or UUID.
portal: Which country portal.

Returns:
Organization details with dataset count, or found=false if not found.

ParameterTypeRequiredDescription
org_idstringrequiredOrganization name or ID (e.g. 'nasa-gov', 'department-of-energy'). Found in list_organizations results.
portalstringoptionalPortal: 'us', 'uk', or 'ca'. Default 'us'. (default: "us")
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "get_organization",
    "arguments": {
      "org_id": "123456789"
    }
  }
}
report_feedback

Report a bug, feature request, or general feedback for this data source.

Use this when something doesn't work as expected, when you'd like
a new feature, or when you have suggestions for improvement.

Args:
feedback: Describe the issue or suggestion.
feedback_type: One of 'bug', 'feature_request', or 'general'.

ParameterTypeRequiredDescription
feedbackstringrequired
feedback_typestringoptional (default: "general")
JSON-RPC Request
{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "report_feedback",
    "arguments": {
      "feedback": "example"
    }
  }
}

Quick Start

Shell
curl -X POST "https://context.gnist.ai/mcp/opendata/" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -H "Gnist-API-Key: YOUR_API_KEY" \
  -d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "search_datasets", "arguments": {"query": "example"}}}'
Python
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/opendata/",
    headers={"Gnist-API-Key": "YOUR_API_KEY", "Content-Type": "application/json"},
    json={
  "jsonrpc": "2.0",
  "method": "tools/call",
  "id": 1,
  "params": {
    "name": "search_datasets",
    "arguments": {
      "query": "example"
    }
  }
},
)
print(resp.json())

Related Toolkits (Government)

Resources