# Huli Developers — llms.txt # Generated: 2026-09-23T17:01:06.001Z # Base: https://developers.huli.ai # Total pages: 73 ## Pages - [Huli Developers](https://developers.huli.ai/) Developer documentation for the Huli Public API (SMART on FHIR R4 and R5) and the huli CLI. Run your first FHIR request in the browser in under a minute — no key required. Source: https://developers.huli.ai/index.md - [AI Agents](https://developers.huli.ai/v1/agents) Downloadable, model-agnostic artifacts for wiring the Huli Public API into an LLM agent — a ready-to-use system prompt and OpenAI/Anthropic tool definitions. Source: https://developers.huli.ai/v1/agents.md - [API Reference](https://developers.huli.ai/v1/api) The Huli Public API is a standards-based FHIR REST surface — the safest bet for an EHR, lab, or billing integration. Browse resources, auth, and scopes. Source: https://developers.huli.ai/v1/api.md - [Authentication](https://developers.huli.ai/v1/api/authentication) OAuth 2.0 token endpoint for SMART Backend Services. Source: https://developers.huli.ai/v1/api/authentication.md - [Discovery](https://developers.huli.ai/v1/api/discovery) Public endpoints for SMART configuration and FHIR capability discovery. Source: https://developers.huli.ai/v1/api/discovery.md - [FHIR Implementation Guide](https://developers.huli.ai/v1/api/fhir-ig) The Huli FHIR Implementation Guide — canonical profiles, extensions, and value sets for FHIR R4 and R5. Source: https://developers.huli.ai/v1/api/fhir-ig.md - [Choosing R4 vs R5](https://developers.huli.ai/v1/api/fhir-versions) When to target FHIR R4 vs R5 on the Huli Public API — both are supported; pick by wire shape and integration maturity. Source: https://developers.huli.ai/v1/api/fhir-versions.md - [Appointment (FHIR R4)](https://developers.huli.ai/v1/api/r4/appointment) A booking of a healthcare event between patient(s) and practitioner(s) for a specific date/time. Maps to HuliPractice ap Source: https://developers.huli.ai/v1/api/r4/appointment.md - [CodeSystem (FHIR R4)](https://developers.huli.ai/v1/api/r4/codesystem) FHIR R4 CodeSystem resource. Source: https://developers.huli.ai/v1/api/r4/codesystem.md - [Composition (FHIR R4)](https://developers.huli.ai/v1/api/r4/composition) FHIR R4 Composition resource. Source: https://developers.huli.ai/v1/api/r4/composition.md - [Device (FHIR R4)](https://developers.huli.ai/v1/api/r4/device) FHIR R4 Device resource. Source: https://developers.huli.ai/v1/api/r4/device.md - [DocumentReference (FHIR R4)](https://developers.huli.ai/v1/api/r4/documentreference) FHIR R4 DocumentReference resource. Source: https://developers.huli.ai/v1/api/r4/documentreference.md - [Encounter (FHIR R4)](https://developers.huli.ai/v1/api/r4/encounter) An interaction between a patient and healthcare provider for the purpose of providing healthcare service. Maps to HuliPr Source: https://developers.huli.ai/v1/api/r4/encounter.md - [HealthcareService (FHIR R4)](https://developers.huli.ai/v1/api/r4/healthcareservice) FHIR R4 HealthcareService resource. Source: https://developers.huli.ai/v1/api/r4/healthcareservice.md - [Location (FHIR R4)](https://developers.huli.ai/v1/api/r4/location) FHIR R4 Location resource. Source: https://developers.huli.ai/v1/api/r4/location.md - [MedicationRequest (FHIR R4)](https://developers.huli.ai/v1/api/r4/medicationrequest) FHIR R4 MedicationRequest resource. Source: https://developers.huli.ai/v1/api/r4/medicationrequest.md - [Observation (FHIR R4)](https://developers.huli.ai/v1/api/r4/observation) Measurements and simple assertions made about a patient, device, or other subject. Used for vital signs (heart rate, tem Source: https://developers.huli.ai/v1/api/r4/observation.md - [Organization (FHIR R4)](https://developers.huli.ai/v1/api/r4/organization) A formally or informally recognised grouping of people or organisations formed for healthcare purposes. Read-only in the Source: https://developers.huli.ai/v1/api/r4/organization.md - [Patient (FHIR R4)](https://developers.huli.ai/v1/api/r4/patient) Demographic and administrative information about an individual receiving healthcare services. Maps to HuliPractice patie Source: https://developers.huli.ai/v1/api/r4/patient.md - [Practitioner (FHIR R4)](https://developers.huli.ai/v1/api/r4/practitioner) A person who is directly or indirectly involved in providing healthcare. Read-only in the public API — practitioner reco Source: https://developers.huli.ai/v1/api/r4/practitioner.md - [PractitionerRole (FHIR R4)](https://developers.huli.ai/v1/api/r4/practitionerrole) FHIR R4 PractitionerRole resource. Source: https://developers.huli.ai/v1/api/r4/practitionerrole.md - [Schedule (FHIR R4)](https://developers.huli.ai/v1/api/r4/schedule) FHIR R4 Schedule resource. Source: https://developers.huli.ai/v1/api/r4/schedule.md - [ServiceRequest (FHIR R4)](https://developers.huli.ai/v1/api/r4/servicerequest) FHIR R4 ServiceRequest resource. Source: https://developers.huli.ai/v1/api/r4/servicerequest.md - [Slot (FHIR R4)](https://developers.huli.ai/v1/api/r4/slot) FHIR R4 Slot resource. Source: https://developers.huli.ai/v1/api/r4/slot.md - [Subscription (FHIR R4)](https://developers.huli.ai/v1/api/r4/subscription) FHIR R4 Subscription resource. Source: https://developers.huli.ai/v1/api/r4/subscription.md - [ValueSet (FHIR R4)](https://developers.huli.ai/v1/api/r4/valueset) FHIR R4 ValueSet resource. Source: https://developers.huli.ai/v1/api/r4/valueset.md - [Appointment (FHIR R5)](https://developers.huli.ai/v1/api/r5/appointment) A booking of a healthcare event between patient(s) and practitioner(s) for a specific date/time. Maps to HuliPractice ap Source: https://developers.huli.ai/v1/api/r5/appointment.md - [Composition (FHIR R5)](https://developers.huli.ai/v1/api/r5/composition) FHIR R5 Composition resource. Source: https://developers.huli.ai/v1/api/r5/composition.md - [DocumentReference (FHIR R5)](https://developers.huli.ai/v1/api/r5/documentreference) FHIR R5 DocumentReference resource. Source: https://developers.huli.ai/v1/api/r5/documentreference.md - [Encounter (FHIR R5)](https://developers.huli.ai/v1/api/r5/encounter) An interaction between a patient and healthcare provider for the purpose of providing healthcare service. Maps to HuliPr Source: https://developers.huli.ai/v1/api/r5/encounter.md - [HealthcareService (FHIR R5)](https://developers.huli.ai/v1/api/r5/healthcareservice) FHIR R5 HealthcareService resource. Source: https://developers.huli.ai/v1/api/r5/healthcareservice.md - [MedicationRequest (FHIR R5)](https://developers.huli.ai/v1/api/r5/medicationrequest) FHIR R5 MedicationRequest resource. Source: https://developers.huli.ai/v1/api/r5/medicationrequest.md - [Observation (FHIR R5)](https://developers.huli.ai/v1/api/r5/observation) Measurements and simple assertions made about a patient, device, or other subject. Used for vital signs (heart rate, tem Source: https://developers.huli.ai/v1/api/r5/observation.md - [Organization (FHIR R5)](https://developers.huli.ai/v1/api/r5/organization) A formally or informally recognised grouping of people or organisations formed for healthcare purposes. Read-only in the Source: https://developers.huli.ai/v1/api/r5/organization.md - [Patient (FHIR R5)](https://developers.huli.ai/v1/api/r5/patient) Demographic and administrative information about an individual receiving healthcare services. Maps to HuliPractice patie Source: https://developers.huli.ai/v1/api/r5/patient.md - [Practitioner (FHIR R5)](https://developers.huli.ai/v1/api/r5/practitioner) A person who is directly or indirectly involved in providing healthcare. Read-only in the public API — practitioner reco Source: https://developers.huli.ai/v1/api/r5/practitioner.md - [PractitionerRole (FHIR R5)](https://developers.huli.ai/v1/api/r5/practitionerrole) FHIR R5 PractitionerRole resource. Source: https://developers.huli.ai/v1/api/r5/practitionerrole.md - [Schedule (FHIR R5)](https://developers.huli.ai/v1/api/r5/schedule) FHIR R5 Schedule resource. Source: https://developers.huli.ai/v1/api/r5/schedule.md - [ServiceRequest (FHIR R5)](https://developers.huli.ai/v1/api/r5/servicerequest) FHIR R5 ServiceRequest resource. Source: https://developers.huli.ai/v1/api/r5/servicerequest.md - [Slot (FHIR R5)](https://developers.huli.ai/v1/api/r5/slot) FHIR R5 Slot resource. Source: https://developers.huli.ai/v1/api/r5/slot.md - [FHIR resources](https://developers.huli.ai/v1/api/resources) Every FHIR resource on the Huli Public API — both R4 and R5 — with its interactions, scopes, and per-version reference page. Source: https://developers.huli.ai/v1/api/resources.md - [Auth](https://developers.huli.ai/v1/auth) Three authentication modes for the Huli Public API — admin-managed bearer tokens, SMART backend services (M2M), and interactive OAuth with PKCE. Pick the right one for your integration. Source: https://developers.huli.ai/v1/auth.md - [Bearer Tokens](https://developers.huli.ai/v1/auth/bearer) Admin-managed bearer tokens for server-to-server integrations — provisioning, usage, and rotation. Source: https://developers.huli.ai/v1/auth/bearer.md - [SMART Backend Services](https://developers.huli.ai/v1/auth/jwks) M2M authentication via client_credentials + private_key_jwt signed with RS384 — key generation, JWKS endpoint setup, client assertion format, and token exchange. Source: https://developers.huli.ai/v1/auth/jwks.md - [Interactive OAuth](https://developers.huli.ai/v1/auth/oauth) Authorization code flow with PKCE for user-facing applications — app registration, redirect URIs, consent screen, token lifecycle. Source: https://developers.huli.ai/v1/auth/oauth.md - [Changelog](https://developers.huli.ai/v1/changelog) Release history for the Huli Public API — dated, versioned, and flagged for breaking changes. Source: https://developers.huli.ai/v1/changelog.md - [CLI](https://developers.huli.ai/v1/cli) The huli command-line interface — install, authenticate, and work against the Public FHIR R4 + R5 API. Source: https://developers.huli.ai/v1/cli.md - [Concepts](https://developers.huli.ai/v1/concepts) Mental models for working with the Huli Public API — organizations, pagination, rate limiting, and audit. Source: https://developers.huli.ai/v1/concepts.md - [Organizations](https://developers.huli.ai/v1/concepts/organizations) How the organization boundary works in the Huli Public API — every resource belongs to one organization, and every API key is scoped to one organization. Source: https://developers.huli.ai/v1/concepts/organizations.md - [Pagination](https://developers.huli.ai/v1/concepts/pagination) Cursor-based pagination on all FHIR list endpoints — how _count, _cursor, and the next link work. Source: https://developers.huli.ai/v1/concepts/pagination.md - [Rate Limiting](https://developers.huli.ai/v1/concepts/rate-limiting) Per-key and per-organization rate limits, the Retry-After header, and the audit log written on every authenticated request. Source: https://developers.huli.ai/v1/concepts/rate-limiting.md - [Webhooks](https://developers.huli.ai/v1/concepts/webhooks) Outbound webhooks via the FHIR R4 Subscription resource — create a rest-hook subscription, verify HMAC-signed deliveries, and recover missed events with replay. Source: https://developers.huli.ai/v1/concepts/webhooks.md - [Error Codes](https://developers.huli.ai/v1/errors) Complete reference for all error codes returned by the Huli Public FHIR API. Source: https://developers.huli.ai/v1/errors.md - [Recipes](https://developers.huli.ai/v1/recipes) End-to-end integration workflows for the Huli Public API — each one ships a working result against the v1 FHIR R4 surface. Source: https://developers.huli.ai/v1/recipes.md - [Booking an appointment end-to-end](https://developers.huli.ai/v1/recipes/booking-an-appointment) Discover a bookable service, a practitioner and their room, a free slot, then POST a FHIR R4 Appointment — with the booking preconditions the discovery steps exist to satisfy. Source: https://developers.huli.ai/v1/recipes/booking-an-appointment.md - [Choosing a CLI authentication path](https://developers.huli.ai/v1/recipes/cli-authentication-paths) Decide between interactive OAuth (no CLI subcommand today), M2M client_credentials, and a one-off bearer token for the huli CLI — a decision table and the exact command for each. Source: https://developers.huli.ai/v1/recipes/cli-authentication-paths.md - [Creating a clinical encounter](https://developers.huli.ai/v1/recipes/creating-an-encounter) Record a visit as a FHIR R4 Encounter — discover the practitioner the create requires as a participant, then POST the Encounter with its status, ActCode class, patient subject, and period. Source: https://developers.huli.ai/v1/recipes/creating-an-encounter.md - [Creating and sharing an API key as a clinic admin](https://developers.huli.ai/v1/recipes/creating-and-sharing-an-api-key) Mint an admin bearer API key in Practice Settings, choose its scopes, capture the one-time secret, then share it with an integration partner and rotate it on a schedule. Source: https://developers.huli.ai/v1/recipes/creating-and-sharing-an-api-key.md - [Sync a daily patient list with the huli CLI](https://developers.huli.ai/v1/recipes/daily-roster-sync-cli) Pull each day's patients and appointments with the huli CLI on a cron schedule — cursor-based pagination that resumes mid-walk on restart, plus 429 Retry-After backoff and id-level dedup at load. Source: https://developers.huli.ai/v1/recipes/daily-roster-sync-cli.md - [Debugging a failed FHIR search](https://developers.huli.ai/v1/recipes/debugging-a-failed-fhir-search) Read the OperationOutcome a failed FHIR R4 search returns, map each status to its HPB code and fix, and trace the correlation id to the audit record Huli support needs. Source: https://developers.huli.ai/v1/recipes/debugging-a-failed-fhir-search.md - [Fetching a patient's full record](https://developers.huli.ai/v1/recipes/fetching-a-patient-record) Pull a patient's whole clinical record — encounters, observations, notes, documents, medications, and orders — in one Patient/$everything Bundle, scope-filtered, with date and type narrowing. Source: https://developers.huli.ai/v1/recipes/fetching-a-patient-record.md - [Run your first authenticated Patient search](https://developers.huli.ai/v1/recipes/getting-started-patient-search) Send a FHIR R4 Patient name search with an admin bearer token — request, searchset Bundle, and the four errors you'll hit first. Source: https://developers.huli.ai/v1/recipes/getting-started-patient-search.md - [Send lab results to the chart](https://developers.huli.ai/v1/recipes/posting-lab-observations-lis) POST a LOINC-coded, UCUM-quantified Observation from your lab system — link it to the Patient and decode the validation errors that block most first writes. Source: https://developers.huli.ai/v1/recipes/posting-lab-observations-lis.md - [Receive webhooks](https://developers.huli.ai/v1/recipes/receiving-webhooks) React to appointments and clinical events as they happen — register a rest-hook Subscription, verify the HMAC signature on every delivery, dedupe on the event id, and recover missed events with $replay. Source: https://developers.huli.ai/v1/recipes/receiving-webhooks.md - [Registering a patient](https://developers.huli.ai/v1/recipes/registering-a-patient) Onboard a patient from an external system into a Mexican clinic — discover the NOM-024 address codes via the terminology ValueSets, then POST a FHIR R4 Patient with CURP/RFC identifiers and the second-lastname extension. Source: https://developers.huli.ai/v1/recipes/registering-a-patient.md - [Sandbox quickstart](https://developers.huli.ai/v1/recipes/sandbox-quickstart) Get a sandbox organization pre-seeded with fake FHIR data from a Huli admin, receive your bearer credential through a one-time link, and make your first authenticated call. Source: https://developers.huli.ai/v1/recipes/sandbox-quickstart.md - [Scheduling an administrative meeting](https://developers.huli.ai/v1/recipes/scheduling-an-administrative-meeting) Book an internal meeting as a FHIR R4 Appointment with no patient — a required title, optional all-day flag, and external email invitees — against a service whose appointment type is administrative. Source: https://developers.huli.ai/v1/recipes/scheduling-an-administrative-meeting.md - [Uploading a document](https://developers.huli.ai/v1/recipes/uploading-a-document) Attach a lab PDF, scan, or image to a patient as a FHIR R4 DocumentReference — multipart $upload or inline base64 — then read it back via a 30-minute signed URL. Uses the BAA-gated system/DocumentReference.cru scope. Source: https://developers.huli.ai/v1/recipes/uploading-a-document.md - [Wire a read-only partner — appointments and encounters](https://developers.huli.ai/v1/recipes/wiring-a-read-only-partner) Give an analytics or reporting tool least-privilege read access to the Appointment + Encounter feed with system/Appointment.rs and system/Encounter.rs — search, read, paginate, and resolve the Practitioner/Organization references they point at. Request only .rs scopes. Source: https://developers.huli.ai/v1/recipes/wiring-a-read-only-partner.md - [Writing and amending a clinical note](https://developers.huli.ai/v1/recipes/writing-a-clinical-note) Create a FHIR R4 Composition — the LOINC-sectioned clinical narrative of a visit — then amend it safely with If-Match optimistic concurrency. Uses the BAA-gated system/Composition.cru scope. Source: https://developers.huli.ai/v1/recipes/writing-a-clinical-note.md - [Reference](https://developers.huli.ai/v1/reference) OpenAPI specification, FHIR CapabilityStatement, and generated endpoint pages for the Huli Public API v1. Source: https://developers.huli.ai/v1/reference.md - [Scopes](https://developers.huli.ai/v1/scopes) SMART on FHIR scope reference for the Huli Public API v1. Source: https://developers.huli.ai/v1/scopes.md - [Start building](https://developers.huli.ai/v1/start) Run a real FHIR search in your browser with no key, and learn to read the response — success and failure — with a guided walkthrough. Source: https://developers.huli.ai/v1/start.md