Practise healthcare API testing on a synthetic HL7 FHIR R4 subset: Patient, Observation (LOINC vitals) and Encounter, searchset Bundles with paging links, versioned ETags, 410 after delete and OperationOutcome errors. No real patient data.
Base URL: https://funapi.dev/api/fhir/r4 · 11 endpoints · OpenAPI 3.1 spec and Postman collection available. New here? Read the getting started guide.
CapabilityStatement
GET /fhir/r4/metadata — CapabilityStatement: what this server supports · Responds with 200 Link to this endpointdemographics
GET /fhir/r4/Patient — Search patients — name, family, given, gender, birthdate (ge/le), _count, _offset · Responds with 200 400 Link to this endpointGET /fhir/r4/Patient/{id} — Read a patient (ETag W/"versionId"); deleted → 410 · Responds with 200 304 404 410 Link to this endpointPOST /fhir/r4/Patient — Create a synthetic patient (Bearer token) (requires Bearer auth) · Responds with 201 401 422 Link to this endpointPUT /fhir/r4/Patient/{id} — Update a patient; If-Match enforces the version (requires Bearer auth) · Responds with 200 404 412 422 Link to this endpointDELETE /fhir/r4/Patient/{id} — Delete a patient (admin); later reads return 410 Gone (requires Bearer auth) · Responds with 204 403 404 Link to this endpointvitals and labs
GET /fhir/r4/Observation — Search observations — patient, code (LOINC), category, date · Responds with 200 400 Link to this endpointGET /fhir/r4/Observation/{id} — Read an observation · Responds with 200 404 Link to this endpointPOST /fhir/r4/Observation — Record an observation; subject must reference an existing Patient (requires Bearer auth) · Responds with 201 422 Link to this endpointvisits
GET /fhir/r4/Encounter — Search encounters — patient, status, class · Responds with 200 Link to this endpointGET /fhir/r4/Encounter/{id} — Read an encounter · Responds with 200 404 Link to this endpointThe FHIR R4 Health Records API is a synthetic subset of HL7 FHIR R4 for practising healthcare API tests without touching real patient data. Patient, Observation and Encounter resources come back as FHIR JSON with application/fhir+json, searches return searchset Bundles with next and previous links, every write bumps meta.versionId and the ETag, and errors are OperationOutcome resources rather than ad-hoc JSON.
GET https://funapi.dev/api/fhir/r4/metadata — CapabilityStatement: what this server supports. No token, no signup:
curl -i https://funapi.dev/api/fhir/r4/metadata
Response: 200 OK
{
"resourceType": "CapabilityStatement",
"status": "active",
"date": "2026-11-06",
"kind": "instance",
"fhirVersion": "4.0.1",
"format": [
"application/fhir+json"
],
"software": {
"name": "Fun API FHIR test server (synthetic data only)",
"version": "1.0"
},
"implementation": {
"description": "Synthetic FHIR R4 subset for API testing practice. Contains no real patient data.",
"url": "https://funapi.dev/api/fhir/r4"
},
"rest": [
{
"mode": "server",
"security": {
"description": "Reads are open; writes need Authorization: Bearer qa-admin-token (or qa-viewer-token; delete is admin only)."
},
"resource": [
{
"type": "Patient",
"interaction": [
{
"code": "read"
},
{
"code": "search-type"
},
{
"code": "create"
},
{
"code": "update"
},
{
"code": "delete"
}
],
(truncated — the full response comes back when you run it)
How this differs from the HAPI FHIR public test server
Last updated