Explore documentation

Practitioner

Learn about the Practitioner resource for healthcare professionals.

Set up the SDK server client to run the examples using esus. The REST examples use a session token. To run them with the SDK’s API key, send X-API-Key instead of Authorization.

The Practitioner resource represents a person directly or indirectly involved in providing healthcare: doctors, nurses, technicians, and any other professional.

When to Use Practitioner

Use Practitioner when you need to:

  • Identify who performed a procedure or administered a vaccine
  • Record which professionals took part in an encounter
  • Represent your organization’s professionals and their credentials

Fields

No body field is required. The API accepts active, identifier, name, telecom, gender (male, female, other, unknown), birthDate (YYYY, YYYY-MM, or YYYY-MM-DD), address, qualification, and communication. If you omit active, it is stored as true.

Creating a Practitioner

REST
curl -X POST https://api.esus.health/fhir/Practitioner \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/fhir+json" \
  -d '{
    "resourceType": "Practitioner",
    "active": true,
    "name": [
      {
        "use": "official",
        "family": "Rodríguez",
        "given": ["Carlos", "Alberto"],
        "prefix": ["Dr."]
      }
    ],
    "qualification": [
      {
        "code": {
          "text": "Physician - Internal Medicine"
        }
      }
    ]
  }'
SDK
const created = await esus.fhir.create("Practitioner", {
  "active": true,
  "name": [
    {
      "use": "official",
      "family": "Rodríguez",
      "given": [
        "Carlos",
        "Alberto"
      ],
      "prefix": [
        "Dr."
      ]
    }
  ],
  "qualification": [
    {
      "code": {
        "text": "Physician - Internal Medicine"
      }
    }
  ]
});

The API answers 201 Created with the created resource (including id and meta.versionId). Each qualification entry needs a code.

Creating practitioners counts toward your plan quota: once you reach it, the POST answers 402 with an OperationOutcome (code: "too-costly"). Reading, updating, and deleting existing practitioners keeps working.

Searching Practitioners

REST
curl "https://api.esus.health/fhir/Practitioner?name=rodriguez&active=true" \
  -H "Authorization: Bearer YOUR_TOKEN"
SDK
const { resources, total } = await esus.fhir.search("Practitioner", {
  "name": "rodriguez",
  "active": true
});
ParameterBehavior
_idExact id
name, family, givenWhole word of the name (case-insensitive, accent-sensitive). All three search every part of the name
identifierExact, by value or system|value
activetrue or false
phone, emailExact match

Page with _count and _offset, and sort with _sort=_lastUpdated or _sort=active (prefix - for descending).

Read, update (PUT/PATCH with optional If-Match), delete, and _history work the same as for Patient: see CRUD Operations.

Linking to Clinical Records

Other resources reference Practitioners with the standard FHIR reference shape ({ "reference": "Practitioner/<uuid>" }), for example in an Encounter’s participants or a Procedure’s performers:

{
  "participant": [
    {
      "individual": {
        "reference": "Practitioner/a7b1c2d3-e4f5-6789-abcd-ef0123456789",
        "display": "Dr. Carlos Rodríguez"
      }
    }
  ]
}

Id format: all resource ids are raw UUIDs (v4). There are no type prefixes like prac_ or pat_.

Practitioner vs PractitionerRole

  • Practitioner — who the person is (name, credentials, identifiers)
  • PractitionerRole — how they work (role, specialty, location, available hours)

One Practitioner can have several PractitionerRoles, for example one per location or specialty. Manage them at /fhir/PractitionerRole (the body carries practitionerId) or from the practitioner with GET / POST /fhir/Practitioner/{id}/roles.