---
title: "Create a new advisor chat session for the patient with an initial message"
method: POST
path: "/patients/{patient_id}/advisor-chat/sessions"
tags: ["advisor-chat"]
---

# Create a new advisor chat session for the patient with an initial message

`POST /patients/{patient_id}/advisor-chat/sessions`

## Path parameters

- `patient_id` integer, required

## Query parameters

- `session_type` string

## Request body

- AdvisorChatMessageRequest
  - `client_subject_type` string, nullable — Internal-only client classification for analytics/debug (not returned).
  - `content` string
  - `context_options` object, nullable
  - `meal_id` integer, nullable — Meal id used when start_mode=assistant_meal_reflection.
  - `opening_question` string, nullable — Client-provided opening question used when start_mode=assistant_question.
  - `start_mode` 'user_message' | 'assistant_question' | 'assistant_meal_reflection', nullable — How this session should start. When set to assistant_question, content is optional and opening_question is required. When set to assistant_meal_reflection, meal_id is required.
  - `subject_id` string, nullable
  - `subject_type` 'general' | 'patient_daily_insight' | 'sms_message' | 'pinned_health_targets' | 'client_prompt' | 'meal_reflection'

## Response `200`

successful operation, session created

- AdvisorChatMessageResponse
  - `content` string, required
  - `content_type` 'text/plain' | 'text/markdown', required
  - `has_follow_up_question` boolean, nullable
  - `id` integer, required
  - `role` 'user' | 'assistant', required
  - `session_id` integer, required
  - `timestamp` string, date-time, required
  - `title` string, nullable

---

[API](https://skmtc.dev/rxfoodapp/apis/inneranalytics-mnt-server.md) · [All operations](https://skmtc.dev/rxfoodapp/apis/inneranalytics-mnt-server/llms.txt) · [OpenAPI document](https://skmtc.dev/rxfoodapp/apis/inneranalytics-mnt-server/revisions/a229b18839a0?raw)
