Skip to main content

Message

A Message is an SMS or email delivery of a Form, Packet, or PDF Document to a Patient. This is how intake actually gets sent. It's the resource your integration creates to kick off the flow described in Common EHR integration patterns.

Key fields

FieldNotes
idRead-only
patientRecipient
form / packet / documentExactly one must be set, what's being sent
message_typeform_response_request, packet_response_request, or reminder
target_email / target_phoneOverride the patient's stored contact info, if needed
preferred_delivery_methodemail or sms
delivery_method_usedRead-only, which method was actually used
is_waitingtrue if the message hasn't gone out yet (e.g., scheduled)
statusRead-only delivery status
message_codeRead-only, the short code/link identifier the patient uses to open the form
remindersRead-only, history of reminder sends for this message
scheduled_atSet to schedule delivery instead of sending immediately
scheduled_messageRead-only nested object once scheduled, its own status (pending, processing, completed, failed, cancelled, already_sent)
response / packet_responsePopulated by Zentake once the patient completes what was sent. Writable only when creating a reminder, where exactly one of them identifies the outstanding response. Ignored on any other create or update

Lifecycle

  1. Your integration (or dashboard user) creates a Message with a Patient and a Form, Packet, or Document, either to send now or with scheduled_at set for later.
  2. Zentake delivers it by SMS or email and tracks status and delivery_method_used.
  3. Reminders are sent for an existing message, never as a new one. To send a reminder, POST /v2/messages with message_type: "reminder" and exactly one of response or packet_response identifying the outstanding response. The patient receives their original link, the response body is the original message, and the send is appended to that message's reminders history.
  4. Once the patient completes the linked Form/Packet, the Message's response / packet_response fields point at the resulting submission.
  5. A scheduled Message can be updated or cancelled before it goes out via the scheduled-message endpoint.
This is the send side

Message is how intake goes out to the patient. What comes back is a Response or Packet Response, Message is not intake data itself.

See in API Reference