The Conversation object
Conversations with patients, one per patient and clinic phone number. Patient API.
Attributes
idUUIDRequiredUnique ID of the conversation.
organization_idUUIDRequiredOrganization the conversation belongs to.
typepatient, direct, group, broadcastRequiredA conversation with a patient, or a staff direct message, group, or broadcast.
titlestringRequiredThe conversation’s name as the user sees it in BloomText.
patientPatientRef or nullThe patient, for patient conversations. Null otherwise.
Show child attributes
idUUIDRequiredID of the patient.
namestringRequiredThe patient’s name, or their phone number if they have no name yet.
phone_numberPhoneNumberRef or nullThe clinic phone number, for patient conversations by SMS. Null otherwise.
Show child attributes
numberstringRequiredThe phone number.
teamstringRequiredThe team it belongs to.
channelsecure, sms, nullHow the patient receives messages, for patient conversations. Null otherwise.
created_attimestampRequiredWhen the conversation was created.
last_message_attimestamp or nullRequiredWhen the latest message was sent. Null for a conversation with no messages.
unread_countintegerRequiredMessages the user hasn’t read.
seen_attimestamp or nullRequiredWhen the user last read the conversation. Null if they never have.
messages_in_rangeinteger or nullOn List conversations with after or before: how many of its messages fell in the range. Null otherwise.
latest_messageMessage or nullOn List conversations: the conversation’s latest message in the range. Null otherwise.
Show child attributes
idUUIDRequiredUnique ID of the message.
conversationConversationRefRequiredThe conversation a message belongs to.
Show child attributes
idUUIDRequiredID of the conversation.
titlestringRequiredThe conversation’s name as the user sees it.
senderSenderRequiredWho sent a message.
Show child attributes
idUUIDRequiredID of the sender.
namestringRequiredThe sender’s display name.
kindstaff, patient, api_keyRequiredA staff member, a patient, or an organization API key (name is the key’s name, like “Reminder service”).
patientPatientRef or nullRequiredThe patient in the conversation, for patient conversations. Null otherwise.
Show child attributes
idUUIDRequiredID of the patient.
namestringRequiredThe patient’s name, or their phone number if they have no name yet.
channelapp, secure, smsRequiredHow the message traveled: inside BloomText (app), by secure link, or by plain SMS.
phone_numberPhoneNumberRef or nullThe clinic phone number, for SMS messages. Null otherwise.
Show child attributes
numberstringRequiredThe phone number.
teamstringRequiredThe team it belongs to.
deliveryDelivery or nullDelivery status, for messages sent to a patient. Null otherwise.
Show child attributes
statusqueued, sent, delivered, opened, failed, undeliveredRequiredWhere the message is. opened means the patient opened a secure link.
errorstring or nullWhy delivery failed, like landline, invalid_number, or opted_out. Null otherwise.
updated_attimestampRequiredWhen the status last changed.
campaign_idUUID or nullThe campaign that sent this message. Null otherwise.
created_attimestampRequiredWhen the message was sent.
edited_attimestamp or nullWhen the message was last edited. Null if it never was.
typetext, fileRequiredWhether the message carries text or a file.
bodystring or nullMessage text. Null for file messages.
fileFileReference or nullFile metadata. Null for text messages.
Show child attributes
idUUIDRequiredUnique ID of the file.
namestringRequiredOriginal file name.
mimestring or nullMIME type, such as application/pdf.
size_bytesinteger or nullFile size in bytes.
reply_to_message_idUUID or nullMessage this is a reply to. Null for top-level messages.
unreadbooleanRequiredWhether the connected admin hasn’t read this message yet. Always false with an API key, which has no read state.
sent_viaApp or nullThe app that sent the message on an admin’s behalf through OAuth. Null for messages sent in BloomText or with an API key. Staff see this; patients don’t.
Show child attributes
client_idstringRequiredYour app’s OAuth client ID.
namestringRequiredYour app’s name as users and staff see it.
Endpoints
| Method | Path | Endpoint |
|---|---|---|
| GET | /patient-conversations | List patient conversations |
| GET | /patient-conversations/{conversationId} | Retrieve a patient conversation |
| GET | /me/conversations | List conversations |
| GET | /me/conversations/{conversationId} | Retrieve a conversation |