Skip to main content

clinik.goals

Goals represent intended objectives for a patient’s care, including clinical targets, behavioral goals, and treatment milestones.

create

const { data, meta } = await clinik.goals.create(request): Promise<ApiResponse<Goal>>
FieldTypeRequiredDescription
lifecycleStatusstringYesproposed, planned, accepted, active, on-hold, completed, cancelled, rejected
descriptionstringYesWhat the goal is
patientIdstringYesPatient ID
achievementStatusstringNoin-progress, improving, worsening, achieved, etc.
categorystring[]NoGoal categories (treatment, dietary, behavioral)
prioritystringNohigh-priority, medium-priority, low-priority
startDatestringNoWhen pursuit of the goal began
targetArrayNoTarget outcomes with measures and due dates
statusDatestringNoWhen status was last changed
statusReasonstringNoReason for current status
expressedByIdstringNoWho created the goal
addressesIdsstring[]NoCondition/Observation IDs this goal addresses
notestringNoAdditional notes
outcomeCodestring[]NoOutcome codes

Example

const { data } = await clinik.goals.create({
  lifecycleStatus: 'active',
  description: 'Reduce HbA1c to below 7%',
  patientId: 'pt_abc123',
  achievementStatus: 'in-progress',
  category: ['treatment'],
  priority: 'high-priority',
  startDate: '2024-01-01',
  target: [
    {
      measure: 'HbA1c',
      detailQuantity: { value: 7, unit: '%' },
      dueDate: '2024-06-30',
    },
  ],
  expressedById: 'prac_dr456',
  addressesIds: ['cond_diabetes789'],
  note: 'Patient motivated, starting metformin and dietary changes',
});
Same pattern as other resources. Update supports lifecycleStatus, achievementStatus, statusReason, note, target. Search supports patientId, lifecycleStatus, achievementStatus, category filters.