publicsafetyapi-mcp
OfficialAn MCP server that lets AI assistants look up US public safety facilities (police, fire, EMS, hospitals) using federal data.
Find the nearest facilities to a US street address, sorted by distance, with optional type filter, radius (0.1–50 miles), and limit.
Find the nearest facilities from latitude/longitude, skipping geocoding for faster results.
Get a full facility record by ID, including address, phone, coordinates, and for hospitals beds, trauma level, and ownership.
List or search facilities by type, state, name, or ZIP, with pagination.
Determine which city/town (or county) contains a location and which agencies likely serve it.
Get state-level facility counts by type.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@publicsafetyapi-mcp What's the closest fire station to 350 Fifth Ave, New York?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
publicsafetyapi-mcp
mcp-name: dev.publicsafetyapi/publicsafetyapi-mcp
MCP server for publicsafetyapi.dev — US police stations, fire departments, EMS bases, and hospitals for AI agents.
Expose public safety facility lookups as tools to any MCP-compatible AI assistant (Claude, Cursor, Copilot, etc.). Built on federal HIFLD, USFA, and CMS data — public domain, commercially usable.
Installation
pip install publicsafetyapi-mcpOr run directly with uvx (no install needed):
uvx publicsafetyapi-mcpRelated MCP server: civic-library-mcp
Configuration
Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"publicsafetyapi": {
"command": "uvx",
"args": ["publicsafetyapi-mcp"],
"env": {
"PUBLICSAFETYAPI_KEY": "your_api_key_here"
}
}
}
}Cursor / other MCP clients
{
"mcpServers": {
"publicsafetyapi": {
"command": "uvx",
"args": ["publicsafetyapi-mcp"],
"env": {
"PUBLICSAFETYAPI_KEY": "your_api_key_here"
}
}
}
}Get a free API key at publicsafetyapi.dev — 500 requests/month, no credit card.
Available Tools
Tool | Description |
| Find the nearest facilities to a US street address |
| Same, but from a lat/lng (skips geocoding) |
| Full record for one facility by ID |
| List/search facilities by type, state, name, or ZIP |
| Which city/town (or county, if unincorporated) contains a location, and which agencies of one type likely serve it |
| Facility counts by type for a state |
Facility types: fire, police, ems, hospital.
Examples
Once configured, you can ask your AI assistant:
"What's the closest fire station to 350 Fifth Ave, New York?"
"How many hospitals are in Montana, and which have trauma centers?"
"I'm building an emergency-response app — find every police and fire station within 5 miles of downtown Austin."
The assistant calls the matching tool and gets structured JSON back — addresses, phone numbers, coordinates, and for hospitals, beds, trauma level, and ownership.
Links
Website: publicsafetyapi.dev
REST API docs: publicsafetyapi.dev/docs
License
MIT
Available Tools
6 toolsfind_stations_near_addressA
Find the public safety facilities nearest to a US street address, sorted by distance.
Args: address: Full US street address, e.g. "350 Fifth Ave, New York, NY" type: Optional filter — "fire", "police", "ems", or "hospital". Comma-separate for several; omit to return all types. radius_miles: Search radius in miles (0.1–50, default 10) limit: Maximum facilities to return (1–25, default 5)
Inputs: address (required), type, limit, radius_miles.
find_stations_near_coordinatesA
Find the public safety facilities nearest to a latitude/longitude, sorted by distance. Use this when you already have coordinates; it skips geocoding and is faster than find_stations_near_address.
Args: lat: Latitude (WGS84) lng: Longitude (WGS84) type: Optional filter — "fire", "police", "ems", or "hospital" radius_miles: Search radius in miles (0.1–50, default 10) limit: Maximum facilities to return (1–25, default 5)
Inputs: lat (required), lng (required), type, limit, +1 more.
get_jurisdictionA
Determine which Census-defined place (city/town) contains a location, and
which agencies most likely respond there. Returns the place name, state,
Census GEOID, boundary type, and a likelyAgencies list of nearby police,
fire, EMS, and hospital facilities. Useful for routing, coverage reporting,
or working out which local government and responders serve an address.
Provide either an address, or a lat/lng pair.
Args: address: Full US street address (geocoded automatically) lat: Latitude (WGS84) — use with lng instead of address lng: Longitude (WGS84) — use with lat instead of address
Inputs: lat, lng, address.
get_state_summaryA
Get facility counts by type (fire, police, EMS, hospital) for one state.
Args: state_code: Two-letter state abbreviation, e.g. "CA"
Inputs: state_code (required).
get_stationA
Get the full record for one facility by its ID, including address, phone, coordinates, and (for hospitals) beds, trauma level, and ownership.
Args: station_id: Facility ID, e.g. "fire_CA_12345"
Inputs: station_id (required).
list_stationsA
List or search public safety facilities by type, state, name, or ZIP. Use this for questions like "how many fire stations are in Kansas" or to find a facility by name. For "what's nearest to X", use find_stations_near_address instead.
Args: type: "fire", "police", "ems", or "hospital" (comma-separate for several) state: Two-letter state code, e.g. "CA" name: Full-text search on the facility name zip: 5-digit ZIP code limit: Results per page (1–100, default 25) offset: Pagination offset (default 0)
Inputs: zip, name, type, limit, +2 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
The tools are mostly distinct: find_stations_near_address vs find_stations_near_coordinates differ only by input method, but both are clearly explained. get_jurisdiction returns nearby agencies alongside place info, which slightly overlaps with find_stations, but the descriptions explicitly differentiate use cases.
All tool names follow a consistent verb_noun pattern in snake_case (find_, get_, list_). The action verbs are semantically appropriate, and naming conventions are uniform throughout.
With 6 tools, the server is well-scoped for a public safety facility lookup API. Each tool serves a distinct query need (proximity, detail, search, jurisdiction, summary), and none are redundant.
The read-only query surface covers the expected operations: proximity search by address or coordinates, detail by ID, filtered/paginated listing, jurisdiction lookup, and state-level aggregation. No critical gaps appear for the stated purpose.
Maintenance
Related MCP Connectors
Hosted MCP server for live public-data APIs and Skills for AI agents.
Agent-native MCP server over 49M+ US public and government records, privacy-first, always current.
Hosted MCP server exposing US hospital procedure cost data to AI assistants
MCP server for querying Tulsa County, Oklahoma property and parcel data for AI agents.
Related MCP Servers
- AlicenseAqualityDmaintenanceOpen-source MCP server providing real estate regulatory intelligence (zoning, permits, entitlements, deal scoring) for US properties, enabling AI agents to access 10 callable tools.127 npmMIT
- AlicenseAqualityDmaintenanceAn MCP server that gives AI agents clean, token-efficient access to US civic & property data — geocoding, census tracts, Opportunity Zones, ACS demographics, and FEMA flood zones — sourced entirely from free federal open data.51MIT
- AlicenseNot gradedqualityBmaintenanceProvides complete world location data (countries, states, cities) as an MCP server for AI assistants, enabling search and retrieval of geographic information through 11 tools and 5 resources.699 npm1MIT
- AlicenseAqualityDmaintenanceMCP server for the loc8n Geographic Data API. Exposes U.S. demographics, housing, mortgage, migration, employment, and geographic data as tools.23MIT