List Schools

Returns GreatSchools schools around a point, with ratings, levels and distance in miles. Use it for the nearby schools section of a listing or building page.

GET/v1/schools

Authentication

Public key?key=pk_…

Public key in the `key` query parameter. No OAuth, no secret.

Edge cache: public, max-age=3600, s-maxage=86400, stale-while-revalidate=604800

Query Parameters

keystring
required

The site's public key (pk_…). It selects the account. Safe to ship to the browser.

latnumber
required

Latitude of the point, between -90 and 90. Rounded to 3 decimals.

lngnumber
required

Longitude of the point, between -180 and 180. Rounded to 3 decimals.

radiusnumber
optional

Search radius in miles, from 1 to 50. Out-of-range values are clamped.

Default:5
typestring (CSV)
optional

School types, comma-separated. Empty or unknown values return all types.

publicprivatecharter

Responses

200Success
application/json
availableboolean

False when the schools provider is down. Show "not available", not "no schools".

schoolsarray

Up to 50 schools. `gsRating` is 1 to 10. `levelName` is `elementary`, `middle`, `high` or `unknown`. `distance` is in miles.

totalnumber

Number of schools returned.

Errors

400`lat` and `lng` are missing or out of range.
401Missing or invalid public key.
403The account is not active. The body also has `code: "TENANT_INACTIVE"`.
429Too many requests. The limit is 60 per minute per visitor IP and account. `Retry-After` is 60 seconds.
500Internal Server Error.

Notes

  • Show "Powered by GreatSchools" and link each school to `overviewLink`. GreatSchools requires it.
  • A provider failure answers 200 with `available: false` and is not cached.
Request
curl --request GET \
--url "https://api.pandaidx.com/v1/schools?key={{public_key}}&lat=25.7617&lng=-80.1918"
Response200 OK
{
"available": true,
"schools": [
{
"gsId": "12345",
"name": "Example Elementary School",
"address": "100 Example St",
"city": "Miami",
"state": "FL",
"zip": "33131",
"phone": null,
"website": null,
"geometry": {
"location": {
"lat": 25.766,
"lng": -80.19
}
},
"gsRating": 8,
"ratingBand": "Above average",
"level": "e",
"levelName": "elementary",
"type": "public",
"gradeRange": "PK-5",
"district": "Example County Public Schools",
"overviewLink": "https://www.greatschools.org/school?id=12345",
"distance": 0.4,
"county": "Miami-Dade",
"summary": null
}
],
"total": 1
}