Skip to main content

Data model

Zentake's data model has one tenancy hierarchy (Organization → Team → User) and one intake hierarchy hanging off of Patient. This page shows how the resources relate; each has its own Concept page with real field names and lifecycle notes.

Naming

This documentation and the primary resource are called Patient. Note: some CSV export column keys and a few legacy field labels in the API reference still read customer. They refer to the same Patient resource.

Entity relationship diagram

Reading the diagram

  • Organization → Team → User is the tenancy hierarchy. Team is the primary isolation unit: every API request authenticates as a team (via X-API-KEY / X-API-SECRET), and every Patient, Form, Packet, Response, Message, and PDF Document belongs to exactly one team. Organization and Team are not resources you fetch through the REST API today, see Team & Organization.
  • Team → Patient, Team → Form, Team → Packet are one-to-many. A Form is made of pages of questions; a Packet bundles multiple Forms into one reusable send.
  • Patient → Response and Patient → Packet Response are one-to-many: a patient can submit the same form or packet more than once over time (e.g., updated medical history at a later visit).
  • Packet Response groups Responses. Sending a Packet produces one Packet Response, which in turn contains one Response per Form in that packet.
  • Message represents an SMS/email delivery of a Form or Packet to a Patient (including scheduled sends); it is not itself intake data.
  • PDF Document has two roles: it's the fillable PDF template (/docs/api/documents) some forms are built on, and the same shape is used for the filled PDF you can download for a completed Response or Packet Response. See PDF Document for the distinction.
  • Appointment is part of Zentake's scheduling domain (used to trigger intake sends ahead of a visit) but is not yet exposed in the public REST API covered by this reference, see Appointment.