Data source: Curated dataset (CMS, AHA)
https://context.gnist.ai/rest/hospital-directory/
AuthenticationAll requests require a Gnist-API-Key header (or api_key query parameter).
Free tier: 100 calls/day. Get your API key.
Tools (10)
get_hospitalsearch_hospitalslist_hospitals_by_statelist_hospitals_by_typelist_hospitals_by_specialtylist_trauma_centersget_hospital_statesget_hospital_typesget_medical_specialtiesreport_feedback
get_hospitalGet detailed information about a hospital.
Returns name, location, type, beds, trauma level, specialties, and accreditation.
| Parameter | Type | Required | Description |
|---|---|---|---|
hospital_id | string | required | Hospital ID slug (e.g. mayo-clinic-rochester, johns-hopkins). |
{
"hospital_id": "example"
}search_hospitalsSearch the hospital directory.
| Parameter | Type | Required | Description |
|---|---|---|---|
query | string | required | Search by name, city, or specialty. |
limit | integer | optional | (default: 20) |
{
"query": "example"
}list_hospitals_by_stateList hospitals in a US state.
| Parameter | Type | Required | Description |
|---|---|---|---|
state | string | required | US state abbreviation (e.g. MA, CA, NY). |
limit | integer | optional | (default: 50) |
{
"state": "example"
}list_hospitals_by_typeList hospitals by type.
| Parameter | Type | Required | Description |
|---|---|---|---|
hospital_type | string | required | Hospital type (Teaching, General, Children's, VA). |
limit | integer | optional | (default: 50) |
{
"hospital_type": "example"
}list_hospitals_by_specialtyList hospitals with a given medical specialty.
| Parameter | Type | Required | Description |
|---|---|---|---|
specialty | string | required | Medical specialty (e.g. Cardiology, Oncology, Neurology). |
limit | integer | optional | (default: 50) |
{
"specialty": "example"
}list_trauma_centersList trauma centers by level.
| Parameter | Type | Required | Description |
|---|---|---|---|
level | string | optional | (default: "Level I") |
limit | integer | optional | (default: 50) |
{
"query": "example"
}get_hospital_statesList all US states with hospitals in the directory.
{
"query": "example"
}get_hospital_typesList all hospital types in the directory.
{
"query": "example"
}get_medical_specialtiesList all medical specialties in the directory.
{
"query": "example"
}report_feedbackReport 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'.
| Parameter | Type | Required | Description |
|---|---|---|---|
feedback | string | required | |
feedback_type | string | optional | (default: "general") |
{
"feedback": "example"
}Quick Start
curl -X POST "https://context.gnist.ai/rest/hospital-directory/get_hospital" \
-H "Content-Type: application/json" \
-H "Gnist-API-Key: YOUR_API_KEY" \
-d '{"hospital_id": "example"}'
import httpx
resp = httpx.post(
"https://context.gnist.ai/rest/hospital-directory/get_hospital",
headers={"Gnist-API-Key": "YOUR_API_KEY"},
json={
"hospital_id": "example"
},
)
print(resp.json())