Goals & Mood Tracking (1.0.0)

Download OpenAPI specification:

Goal setting, tracking, reminders and mood logging with statistics

Create or Update Goal

Creates a new goal or updates an existing one for a user. Supports one-time and recurring goals with frequency tracking.

Used when:

  • Client sets a new therapy goal
  • Updating an existing goal's details or frequency
  • AI-generated goals from treatment plans

Input:

  • is_onetime (required): Whether this is a one-time goal
  • frequency (optional): Goal frequency (auto-set to "One Time" if is_onetime=true)
  • goalid (optional): Include to update an existing goal

Returns: goalid of the created or updated goal

Common errors:

  • 400: Invalid parameters or unable to create goal
  • 201: Goal created successfully
Authorizations:
cookieAuthbasicAuth
Request Body schema:
required
userid
integer or null
status
string or null <= 50 characters
title
string or null <= 255 characters
is_onetime
required
boolean
criticality
string or null <= 255 characters
reminder
boolean or null
frequency
string or null <= 255 characters
targetdate
string or null <date-time>
days
any or null
required
Array of objects (GoalTrackingCreateUpdate)
reminderdate
required
string or null <date>
remindertime
required
string or null <time>
startdate
string or null <date-time>
description
string or null
is_therapist_approved
boolean

Responses

Request samples

Content type
{
  • "userid": 0,
  • "status": "string",
  • "title": "string",
  • "is_onetime": true,
  • "criticality": "string",
  • "reminder": true,
  • "frequency": "string",
  • "targetdate": "2019-08-24T14:15:22Z",
  • "days": null,
  • "goaltracking": [
    ],
  • "reminderdate": "2019-08-24",
  • "remindertime": "14:15:22Z",
  • "startdate": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "is_therapist_approved": true
}

Response samples

Content type
application/json
{
  • "userid": 0,
  • "goalid": 0,
  • "status": "string",
  • "title": "string",
  • "is_onetime": true,
  • "criticality": "string",
  • "reminder": true,
  • "frequency": "string",
  • "targetdate": "2019-08-24T14:15:22Z",
  • "days": null,
  • "goaltracking": [
    ],
  • "description": "string",
  • "is_therapist_approved": true
}

Update an existing goal

Updates the details of an existing goal identified by goalid in the URL path. If is_onetime is true, frequency is automatically set to "One Time". Future goal tracking entries (after today) are deleted and regenerated based on the updated schedule. Returns 204 if the goal is not found.

Authorizations:
cookieAuthbasicAuth
path Parameters
goalid
required
integer

A unique integer value identifying this goal.

Request Body schema:
required
userid
integer or null
status
string or null <= 50 characters
title
string or null <= 255 characters
is_onetime
required
boolean
criticality
string or null <= 255 characters
reminder
boolean or null
frequency
string or null <= 255 characters
targetdate
string or null <date-time>
days
any or null
required
Array of objects (GoalTrackingCreateUpdate)
reminderdate
required
string or null <date>
remindertime
required
string or null <time>
startdate
string or null <date-time>
description
string or null
is_therapist_approved
boolean

Responses

Request samples

Content type
{
  • "userid": 0,
  • "status": "string",
  • "title": "string",
  • "is_onetime": true,
  • "criticality": "string",
  • "reminder": true,
  • "frequency": "string",
  • "targetdate": "2019-08-24T14:15:22Z",
  • "days": null,
  • "goaltracking": [
    ],
  • "reminderdate": "2019-08-24",
  • "remindertime": "14:15:22Z",
  • "startdate": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "is_therapist_approved": true
}

Delete a goal

Soft-deletes a goal and all its associated goal tracking entries by setting is_deleted=True. Requires the goalid as a URL path parameter. Returns 204 if no goal with the given ID exists.

Authorizations:
cookieAuthbasicAuth
path Parameters
goalid
required
integer

A unique integer value identifying this goal.

Responses

Create Multiple Goals in Bulk

Create or update multiple therapy goals for a client in a single request. Ideal for syncing a full care plan from an EHR, or when Kana's AI generates a batch of goals from a treatment plan. For each goal, if id is non-zero and the goal exists, it is updated; otherwise a new goal is created.

Use this when:

  • Importing a client's care plan goals from an external system
  • Applying AI-generated goals (from /generate_goals_from_treatment_plan/) in bulk
  • Seeding initial goals during client onboarding

Returns a list of all created or updated goal IDs.

Authorizations:
cookieAuthbasicAuthNone
Request Body schema:
required
Array
userid
integer or null
status
string or null <= 50 characters
title
string or null <= 255 characters
is_onetime
required
boolean
criticality
string or null <= 255 characters
reminder
boolean or null
frequency
string or null <= 255 characters
targetdate
string or null <date-time>
days
any or null
required
Array of objects (GoalTrackingCreateUpdate)
reminderdate
required
string or null <date>
remindertime
required
string or null <time>
startdate
string or null <date-time>
description
string or null
is_therapist_approved
boolean

Responses

Request samples

Content type
[
  • [
    ]
]

Update Goal Reminder Settings

Update the reminder schedule for a client's therapy goal. When reminders are enabled, Kana will notify the client at the specified time. Reminder settings are automatically propagated to all associated goal tracking entries.

Input:

  • goalid (required): ID of the goal to update
  • reminder (required): true to enable, false to disable reminders
  • remindertime (required): Time for the reminder in HH:MM:SS format
Authorizations:
cookieAuthbasicAuthNone
Request Body schema:
goalid
integer
remindertime
string or null <time>
reminder
boolean or null

Responses

Request samples

Content type
{
  • "goalid": 0,
  • "remindertime": "14:15:22Z",
  • "reminder": true
}

Retrieve All Goals for a Client

Retrieve all active therapy goals for a client. Returns a complete list of goals including title, frequency, criticality, reminder settings, completion status, target date, and therapist approval flag. Use this to display a client's full goal list in your application or to sync goals into your system.

Use this when:

  • Displaying a client's therapy goals in your interface
  • Syncing goal data into your care management or EHR system
  • Building progress tracking dashboards
Authorizations:
cookieAuthbasicAuthNone
path Parameters
userid
required
integer

The unique identifier of the user whose goals are being retrieved.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve All Goals for a Client

Retrieve all active therapy goals for a client. Returns a complete list of goals including title, frequency, criticality, reminder settings, completion status, target date, and therapist approval flag. Use this to display a client's full goal list in your application or to sync goals into your system.

Use this when:

  • Displaying a client's therapy goals in your interface
  • Syncing goal data into your care management or EHR system
  • Building progress tracking dashboards
Authorizations:
cookieAuthbasicAuthNone
path Parameters
goalid
required
integer

A unique integer value identifying this goal.

userid
required
integer

The unique identifier of the user whose goals are being retrieved.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Mark a Goal as Completed

Mark a specific goal tracking entry as completed or incomplete. When all tracking entries for a goal are completed, Kana automatically marks the overall goal as "Completed". This is the key endpoint for recording client progress.

Use this when:

  • A client checks off a goal in your application
  • Syncing goal completion events from a wearable or third-party platform
  • Recording goal adherence for care coordination or reporting

Input:

  • goalTrackId (required): ID of the specific tracking entry to update
  • iscompleted (required): true to mark completed, false to unmark
Authorizations:
cookieAuthbasicAuthNone
path Parameters
goalid
required
integer

A unique integer value identifying this goal.

Request Body schema:
property name*
additional property
any

Responses

Request samples

Content type
{
  • "goalTrackId": 101,
  • "iscompleted": true
}

Retrieve Goal Tracking Schedule for a Client

Retrieve a client's goal tracking schedule for a date range — showing which goals are scheduled for each day, their completion status, and reminder time. Use this to build a calendar or daily task view of a client's therapy goals in your application.

Use this when:

  • Displaying a client's daily goal schedule in your app
  • Building a weekly or monthly goal completion view
  • Checking completion rates for care coordination reporting

Response is timezone-aware (pass time_zone to get local dates). Returns goal entries grouped by due date.

Authorizations:
cookieAuthbasicAuthNone
Request Body schema:
property name*
additional property
any

Responses

Request samples

Content type
{
  • "userid": 1,
  • "fromdate": "2024-01-01",
  • "todate": "2024-01-07",
  • "time_zone": "America/New_York"
}

Log a Client Mood Entry

Record a mood check-in for a client. Kana uses mood data as part of its clinical intelligence — mood trends inform AI session summaries, goal recommendations, and risk assessments. Partners can log mood entries on behalf of clients from any platform, including wearables, mobile apps, or EHR integrations.

Use this when:

  • Your app captures patient mood and you want to sync it into Kana
  • Building a mood tracking integration for client wellness monitoring
  • Feeding mood data into Kana's clinical context for AI insights

Each entry records the user ID, log date/time, mood type, and optional reasons.

Authorizations:
cookieAuthbasicAuth
Request Body schema:
userid
integer or null
logdate
string or null <date-time>
mood
string or null <= 255 characters
reasons
any or null

Responses

Request samples

Content type
{
  • "userid": 0,
  • "logdate": "2019-08-24T14:15:22Z",
  • "mood": "string",
  • "reasons": null
}

Get Mood Analytics for a Client Over a Date Range

Retrieve aggregated mood statistics for a client over a specified date range. Returns mood counts grouped by day and mood type, with associated reasons — useful for building mood trend charts, clinical progress reports, or generating insights for care plan reviews.

Use this when:

  • Building mood trend visualizations in your clinical dashboard
  • Generating a mood summary report for a client's care review
  • Feeding mood analytics into a risk or progress scoring model

Dates can be YYYY-MM-DD or full ISO 8601 format. Returns 204 if no mood data exists for the specified range.

Authorizations:
cookieAuthbasicAuthNone
Request Body schema:
property name*
additional property
any

Responses

Request samples

Content type
{
  • "userid": 1,
  • "fromdate": "2024-01-01",
  • "todate": "2024-01-31"
}

Retrieve Mood Logs for a Client

Retrieve all mood log entries for a client. Use this to display a client's mood history in your application, sync mood data to your system, or analyze patterns for clinical decision support.

Use this when:

  • Displaying mood history in a client care timeline
  • Syncing Kana mood data back into your EHR or analytics platform
  • Building a wellness monitoring dashboard for a client

Each record includes the user ID, log date/time, mood type, and reasons.

Authorizations:
cookieAuthbasicAuthNone
path Parameters
userid
required
integer

The unique identifier of the user whose mood logs are being retrieved.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve Mood Logs for a Client

Retrieve all mood log entries for a client. Use this to display a client's mood history in your application, sync mood data to your system, or analyze patterns for clinical decision support.

Use this when:

  • Displaying mood history in a client care timeline
  • Syncing Kana mood data back into your EHR or analytics platform
  • Building a wellness monitoring dashboard for a client

Each record includes the user ID, log date/time, mood type, and reasons.

Authorizations:
cookieAuthbasicAuthNone
path Parameters
moodid
required
integer

A unique integer value identifying this mood tracker.

userid
required
integer

The unique identifier of the user whose mood logs are being retrieved.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve Pending Therapist-Approved Goals for a Client

Retrieve goals that have been approved by a therapist but not yet started by the client. These are goals ready to be presented to the client — use this to surface newly assigned goals in your application so the client can begin working on them.

Use this when:

  • Checking if a clinician has assigned new goals to a client
  • Displaying pending goals on a client dashboard in your application

Returns non-started, therapist-approved goals with their earliest scheduled start date.

Authorizations:
cookieAuthbasicAuthNone
path Parameters
userid
required
integer

The unique identifier of the user whose pending goals are being retrieved.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve Pending Therapist-Approved Goals for a Client

Retrieve goals that have been approved by a therapist but not yet started by the client. These are goals ready to be presented to the client — use this to surface newly assigned goals in your application so the client can begin working on them.

Use this when:

  • Checking if a clinician has assigned new goals to a client
  • Displaying pending goals on a client dashboard in your application

Returns non-started, therapist-approved goals with their earliest scheduled start date.

Authorizations:
cookieAuthbasicAuthNone
path Parameters
id
required
string
userid
required
integer

The unique identifier of the user whose pending goals are being retrieved.

Responses

Response samples

Content type
application/json
[
  • {
    }
]