InstantMessage

The FHIR R4 InstantMessage resource represents messages exchanged between healthcare providers, care teams, or patients. It is used to document communication for audit, coordination, or workflow purposes.

Health Gorilla exposes InstantMessage as part of its FHIR R4 API to support secure messaging and care coordination workflows.

Use Cases

  • Fetching messages exchanged between care team members
  • Posting a new communication record for a patient
  • Receiving notifications when a new secure message is created

Scope and Behavior

This documentation describes the FHIR R4 API interface for InstantMessage. Health Gorilla’s platform may use additional internal services and data standards to acquire, normalize, and route communication data. Only the FHIR R4–exposed behavior is documented here.

The InstantMessage resource represents a Health Gorilla–specific extension and is not part of the HL7 FHIR R4 core specification.

Authentication

All requests require OAuth 2.0 authentication using a Bearer Token. Unauthorized requests return a 401 Unauthorized response.

Required Scope: instantmessage.read for GET

For more information, go to: OAuth 2.0 Authentication.

Search Behavior

Searches are scoped to the authenticated tenant. The patient parameter is required for patient-scoped searches and is recommended for most search use cases.

Results are returned as a FHIR Bundle. Pagination may be applied. Use standard FHIR pagination links (Bundle.link) to retrieve additional result pages.

Note: Supported parameters and behavior may vary by configuration.

Search Parameters

Messages are retrieved by identifier, which Health Gorilla assigns.

ParameterRequiredDescription
identifierYesReturns the message carrying the given Health Gorilla identifier.
directionNoFilters on whether the message was sent or received.
_lastUpdatedNoFilters on when the record was last written in the Health Gorilla FHIR server. Accepts a comparison prefix, for example ge2025-01-01.
_offsetNoSkips the given number of results.
_countNoLimits the number of results returned per page.

Resource Attributes

AttributeDescriptionExample ValuesFHIR Data Type
statusStatus of the messagecompleted, in-progresscode
categoryClassification of message contentnotification, instructionCodeableConcept[]
senderPerson or device sending the messagePractitioner/{id}Reference
recipientMessage recipientsPatient/{id}, Practitioner/{id}Reference[]
sentDate/time message was sent2024-10-01T10:20:30ZdateTime
receivedDate/time message was received2024-10-01T10:21:00ZdateTime
subjectSubject of the communication (typically a patient)Patient/{id}Reference
payloadMessage content or attachmentsText content or attachment entriesBackboneElement[]

Notifications

The FHIR R4 API does not provide direct resource-change subscriptions for InstantMessage. Changes to messaging data may surface through broader notification workflows, depending on enabled Health Gorilla products and configuration.

Error Handling

All InstantMessage operations follow standard Health Gorilla error handling, including use of FHIR OperationOutcome for structured responses. For more information, go to: Error Handling.

Additional Resources

HL7 FHIR Communication Resource