Skip to main content

clinik.persons

Persons represent a common demographic record that may be linked to multiple patient, practitioner, or related person records across the system.

create

const { data, meta } = await clinik.persons.create(request): Promise<ApiResponse<Person>>
FieldTypeRequiredDescription
firstNamestringYesFirst name
lastNamestringYesLast name
phonestringNoPhone number
emailstringNoEmail address
genderstringNomale, female, other, unknown
birthDatestringNoDate of birth (YYYY-MM-DD)
addressAddressNoPhysical address
photoobjectNoPhoto ()
managingOrganizationIdstringNoManaging organization ID
activebooleanNoWhether active (default: true)
linkArrayNoLinks to other records ()

Example

const { data } = await clinik.persons.create({
  firstName: 'Maria',
  lastName: 'Garcia',
  phone: '555-0142',
  email: '[email protected]',
  gender: 'female',
  birthDate: '1985-07-22',
  address: {
    line: ['456 Oak Avenue'],
    city: 'San Antonio',
    state: 'TX',
    postalCode: '78205',
  },
  managingOrganizationId: 'org_sunrise',
  link: [
    { targetId: 'Patient/pt_maria_garcia', assurance: 'level4' },
  ],
});
Same pattern as other resources. Search supports name, email, phone, active filters.