Hospitals All docs

Hospitals API Reference

2 routes under /v1/hospitals. Base URL https://api.apifor.dev, authenticated with x-api-key, one credit per request. Coverage and licence are on the Hospitals page.

GET/v1/hospitals

List hospitals with filters and paging.

ParameterInTypeRules
pagequeryintegermin 1 · default 1
limitqueryinteger1 to 200 · default 50
countryquerystringISO 3166-1 alpha-2
qquerystring2 to 100 chars
province_idquerystringNone
regency_idquerystringNone
GET/v1/hospitals
curl 'https://api.apifor.dev/v1/hospitals' \
  -G -d country=ID -d limit=1 \
  -H 'x-api-key: YOUR_API_KEY'
Example response · 200
{
  "success": true,
  "data": [
    {
      "country_code": "ID",
      "id": "rs-0",
      "name": "RS LAPANGAN INDRAPURA",
      "type": "RSUM",
      "class": null,
      "ownership": null,
      "is_blu": 0,
      "province_id": null,
      "regency_id": null,
      "address": null,
      "postal_code": null,
      "lat": null,
      "lng": null,
      "website": null,
      "beds_total": 361,
      "icu_beds": null,
      "doctors_gp": null,
      "doctors_spec": null,
      "is_active": 1,
      "created_at": "2026-07-01 10:49:01",
      "updated_at": "2026-07-01 10:49:01",
      "code": null,
      "hospital_type": null,
      "blu_status": null,
      "director": null,
      "land_area": null,
      "building_area": null,
      "source_region_name": null,
      "source_province_name": null,
      "source_name": null,
      "source_url": null,
      "source_updated_at": null,
      "synced_at": null,
      "provenance": null
    }
  ]
}
  • 200Successful response. Pagination is explicit; no silent truncation.
  • 400Invalid query parameters
  • 404Record not found
  • 500Dataset unavailable
GET/v1/hospitals/{id}

Find hospitals by identifier.

ParameterInTypeRules
id *pathstringNone
GET/v1/hospitals/{id}
curl 'https://api.apifor.dev/v1/hospitals/{id}' \
  -H 'x-api-key: YOUR_API_KEY'
Example response · 200
{
  "success": true,
  "data": {
    "country_code": "ID",
    "id": "rs-0",
    "name": "RS LAPANGAN INDRAPURA",
    "type": "RSUM",
    "class": null,
    "ownership": null,
    "is_blu": 0,
    "province_id": null,
    "regency_id": null,
    "address": null,
    "postal_code": null,
    "lat": null,
    "lng": null,
    "website": null,
    "beds_total": 361,
    "icu_beds": null,
    "doctors_gp": null,
    "doctors_spec": null,
    "is_active": 1,
    "created_at": "2026-07-01 10:49:01",
    "updated_at": "2026-07-01 10:49:01",
    "code": null,
    "hospital_type": null,
    "blu_status": null,
    "director": null,
    "land_area": null,
    "building_area": null,
    "source_region_name": null,
    "source_province_name": null,
    "source_name": null,
    "source_url": null,
    "source_updated_at": null,
    "synced_at": null,
    "provenance": null
  }
}
  • 200Successful response. Pagination is explicit; no silent truncation.
  • 400Invalid query parameters
  • 404Record not found
  • 500Dataset unavailable

Error handling · Rate limits · Source licences