Enables AI agents to access US school district and school data, including enrollment, demographics, and boundaries via address lookups.
Also known as DistrictAPI/districtapi-mcp, districtapi-mcp
- Stars
- 0
- Tools
- 6
- Downloads, 30 days
- 160
- Latest version
- 0.1.3
- Last commit
- Oct 4, 2026
- License
- —
What is DistrictAPI MCP?
DistrictAPI enables AI agents to access US school district and school data, including enrollment, demographics, and boundaries via address lookups. It exposes 6 tools, such as lookup_district_by_address, get_district, search_districts.
Summary generated from the project's README
About DistrictAPI MCP server
DistrictAPI provides AI agents with access to comprehensive United States school district and school information. This MCP server allows assistants like Claude, Cursor, or Copilot to retrieve specific data points such as enrollment numbers, demographics, and geographic boundaries. Developers can integrate this server into their local environments using pip or uvx to connect their AI clients to the districtapi.dev data source.
Users must provide a DISTRICTAPI_KEY in their configuration to authenticate requests. The server offers several specialized tools for data retrieval, including lookup_district_by_address for finding districts via street addresses and find_schools_near_address for radius-based searches. It also supports searching by name or state, retrieving full profiles using NCES LEA or school IDs, and listing all schools within a specific district.
What you can do with it
- 1Identify local school districtsFind which school district serves a specific street address in the United States.
- 2Retrieve district enrollment dataAsk an AI assistant to determine the student enrollment numbers for a particular district.
- 3Locate nearby educational institutionsSearch for schools located within a certain distance of a specific location.
- 4Access detailed school profilesGet complete information about a specific school using its NCES school ID.
Written from the project's README. Every use case is checked against a quote from it.
How to install DistrictAPI MCP
Formats verified 10 Nov 2026Add to CursorAdd to GooseInstall DistrictAPI MCP in Claude Code
$ claude mcp add --env 'DISTRICTAPI_KEY=<YOUR_DISTRICTAPI_KEY>' districtapi-mcp -- uvx districtapi-mcpInstall DistrictAPI MCP in Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"districtapi-mcp": {
"command": "uvx",
"args": [
"districtapi-mcp"
],
"env": {
"DISTRICTAPI_KEY": "<YOUR_DISTRICTAPI_KEY>"
}
}
}
}Install DistrictAPI MCP in VS Code
.vscode/mcp.json
{
"servers": {
"districtapi-mcp": {
"type": "stdio",
"command": "uvx",
"args": [
"districtapi-mcp"
],
"env": {
"DISTRICTAPI_KEY": "<YOUR_DISTRICTAPI_KEY>"
}
}
}
}Install DistrictAPI MCP in VS Code CLI
$ code --add-mcp '{"name":"districtapi-mcp","type":"stdio","command":"uvx","args":["districtapi-mcp"],"env":{"DISTRICTAPI_KEY":"<YOUR_DISTRICTAPI_KEY>"}}'Install DistrictAPI MCP in Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"districtapi-mcp": {
"command": "uvx",
"args": [
"districtapi-mcp"
],
"env": {
"DISTRICTAPI_KEY": "<YOUR_DISTRICTAPI_KEY>"
}
}
}
}Install DistrictAPI MCP in Codex
$ codex mcp add districtapi-mcp --env 'DISTRICTAPI_KEY=<YOUR_DISTRICTAPI_KEY>' -- uvx districtapi-mcpInstall DistrictAPI MCP in Codex config.toml
~/.codex/config.toml
[mcp_servers.districtapi-mcp] command = "uvx" args = ["districtapi-mcp"] [mcp_servers.districtapi-mcp.env] DISTRICTAPI_KEY = "<YOUR_DISTRICTAPI_KEY>"
Install DistrictAPI MCP in Gemini CLI
$ gemini mcp add -s user -e 'DISTRICTAPI_KEY=<YOUR_DISTRICTAPI_KEY>' districtapi-mcp uvx -- districtapi-mcpInstall DistrictAPI MCP in Gemini settings.json
~/.gemini/settings.json
{
"mcpServers": {
"districtapi-mcp": {
"command": "uvx",
"args": [
"districtapi-mcp"
],
"env": {
"DISTRICTAPI_KEY": "<YOUR_DISTRICTAPI_KEY>"
}
}
}
}DistrictAPI MCP tools 6
Detected from the READMElookup_district_by_addressget_districtsearch_districtsget_district_schoolsget_schoolfind_schools_near_address
| lookup_district_by_address | — | |
| get_district | — | |
| search_districts | — | |
| get_district_schools | — | |
| get_school | — | |
| find_schools_near_address | — |
Configuration
DISTRICTAPI_KEYRequiredSecretAPI key from https://districtapi.dev (free tier: 500 requests/month)
| Name | Description | |
|---|---|---|
| DISTRICTAPI_KEY | API key from https://districtapi.dev (free tier: 500 requests/month) | RequiredSecret |
Automated checks
Ran Nov 14, 2026Full report →Passed our automated checks. That is not a security audit: read the code and give the server the narrowest access it needs. How checks work · What to fix for more points
- Source repository linked and reachabledistrictapi/districtapi-mcp is public and reachablegithub.com/districtapi/districtapi-mcp ↗Pass
- Package names this repository as its sourcedistrictapi-mcp names districtapi/districtapi-mcp as sourcepypi.org/project/districtapi-mcp/ ↗Pass
- Build provenance (Sigstore attestation)No build attestation published for this releaseNot checked
- Open source license (OSI)No licenseFinding
- Commit or release in the last yearLast commit or release 2026-10-04github.com/districtapi/districtapi-mcp ↗Pass
- OpenSSF ScorecardNot checked
- Package name not close to a popular packageNo popular package one edit away from districtapi-mcpPass
- No critical advisory in the package or its dependencies30 resolved dependencies checked; no critical advisoryosv.dev ↗Pass
- No hidden instructions to the model6 tool descriptions and the README read; no override phrases, credential paths or hidden charactersPass
- Destructive tools are labelledNo tool named like delete, drop or execPass
- Remote endpoint answers the MCP handshakeNot checked
README
View on GitHubdistrictapi-mcp
mcp-name: dev.districtapi/districtapi-mcp
MCP server for districtapi.dev — US school district and school data for AI agents.
Expose school district lookups as tools to any MCP-compatible AI assistant (Claude, Cursor, Copilot, etc.).
Installation
pip install districtapi-mcp
Or run directly with uvx (no install needed):
uvx districtapi-mcp
Configuration
Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"districtapi": {
"command": "uvx",
"args": ["districtapi-mcp"],
"env": {
"DISTRICTAPI_KEY": "your_api_key_here"
}
}
}
}
Cursor / other MCP clients
{
"mcpServers": {
"districtapi": {
"command": "uvx",
"args": ["districtapi-mcp"],
"env": {
"DISTRICTAPI_KEY": "your_api_key_here"
}
}
}
}
Get a free API key at districtapi.dev.
Available Tools
| Tool | Description |
|---|---|
lookup_district_by_address |
Find the district serving a US street address |
get_district |
Get full district profile by NCES LEA ID |
search_districts |
Search districts by name and/or state |
get_district_schools |
List all schools in a district |
get_school |
Get full school profile by NCES school ID |
find_schools_near_address |
Find schools within a radius of an address |
Example
Once configured, you can ask your AI assistant:
"What school district serves 1600 Pennsylvania Ave, Austin TX, and how many students are enrolled?"
The assistant will call lookup_district_by_address and return the full district profile.
Links
- Website: districtapi.dev
- PyPI: pypi.org/project/districtapi-mcp
- REST API docs: districtapi.dev/docs
License
MIT
DistrictAPI MCP questions
How do I add DistrictAPI MCP to Claude Code?
Run claude mcp add --env 'DISTRICTAPI_KEY=<YOUR_DISTRICTAPI_KEY>' districtapi-mcp -- uvx districtapi-mcp in your terminal. Add --scope user to make it available in every project.
How do I add DistrictAPI MCP to Cursor?
Open ~/.cursor/mcp.json and add the server under mcpServers, using the Cursor config shown in the install section above.
What tools does DistrictAPI MCP provide?
It exposes 6 tools, including lookup_district_by_address, get_district, search_districts, get_district_schools, get_school.