POST api/Village/{village}/CarePlan/Definition
Save the care plan (may result in a new plan being created)
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
village | string |
None. |
Body Parameters
CarePlanEditModelName | Description | Type | Additional information |
---|---|---|---|
CarePlanId |
ID of the care plan being created/edited |
globally unique identifier |
None. |
Activate |
If true, make this care plan version active (defaults to true) |
boolean |
None. |
Frequency |
Frequency the plan should be filled out (Daily = 0, Weekly = 1). If changing the Frequency of an existing plan which has instances, a new plan will be created and the old plan's active version will be deactivated. |
CarePlanFrequency |
None. |
Title |
Care Plan Title |
string |
None. |
RepeatsEvery |
Repeats Every N |
integer |
None. |
EndDate |
End on X date (null if no end date. If EndDate and EndCount are both null, never ends) |
date |
None. |
EndCount |
End after X occurrences (null if no end count. If EndDate and EndCount are both null, never ends) |
integer |
None. |
ReminderInterval |
Reminder N time before reset (if null, do not send a reminder) |
integer |
None. |
Questions |
list of questions for this care plan |
Collection of CarePlanQuestionEditModel |
None. |
Request Formats
application/json, text/json
{ "CarePlanId": "b002ea16-2b45-43da-8377-94d20463fbf8", "Activate": true, "Frequency": 0, "Title": "sample string 3", "RepeatsEvery": 4, "EndDate": "2025-06-03T05:26:04.673+00:00", "EndCount": 1, "ReminderInterval": 1, "Questions": [ { "Question": "sample string 1", "Sequence": 2 }, { "Question": "sample string 1", "Sequence": 2 } ] }
application/xml, text/xml
<CarePlanEditModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CaringVillage.Shared.Implementation.Models"> <Activate>true</Activate> <CarePlanId>b002ea16-2b45-43da-8377-94d20463fbf8</CarePlanId> <EndCount>1</EndCount> <EndDate>2025-06-03T05:26:04.6734496+00:00</EndDate> <Frequency>Daily</Frequency> <Questions> <CarePlanQuestionEditModel> <Question>sample string 1</Question> <Sequence>2</Sequence> </CarePlanQuestionEditModel> <CarePlanQuestionEditModel> <Question>sample string 1</Question> <Sequence>2</Sequence> </CarePlanQuestionEditModel> </Questions> <ReminderInterval>1</ReminderInterval> <RepeatsEvery>4</RepeatsEvery> <Title>sample string 3</Title> </CarePlanEditModel>
multipart/form-data
Response Information
Resource Description
Returns the new, complete Care Plan Definition which may (likely will) have different IDs than the previous care plan
CarePlanDefinitionModelName | Description | Type | Additional information |
---|---|---|---|
VersionId |
Unique ID for this version of the care plan |
globally unique identifier |
None. |
VillageId |
Unique ID of the village |
globally unique identifier |
None. |
CarePlanId |
Unique ID of this care plan (multiple versions may share the same Care Plan ID) |
globally unique identifier |
None. |
Frequency |
Frequency the plan should be filled out (Daily = 0, Weekly = 1) |
CarePlanFrequency |
None. |
RepeatsEvery |
Repeats Every N |
integer |
None. |
EndDate |
End on X date (null if no end date) |
date |
None. |
EndCount |
End after X occurrences (null if no end count) |
integer |
None. |
InstanceCount |
Number of occurrences that have happened |
integer |
None. |
ReminderInterval |
Reminder N time (in minutes) before reset |
integer |
None. |
Title |
Care Plan title |
string |
None. |
Active |
Whether or not this is the current active care plan for the village |
boolean |
None. |
Updated |
Date/Time the care plan was last updated |
date |
None. |
Questions |
Ordered list of questions for this care plan |
Collection of CarePlanQuestionDefinitionModel |
None. |
ActivatedDate |
Date the care plan version was activated |
date |
None. |
Draft |
If true, the care plan version is a draft (has never been activated) |
boolean |
None. |
Response Formats
application/json, text/json
{ "VersionId": "face4f9d-d584-442c-8c41-1584922e6ab7", "VillageId": "40c96de2-934c-451f-9bef-393c49bf1627", "CarePlanId": "023397ec-a191-47e5-9dac-f5adb2318c36", "Frequency": 0, "RepeatsEvery": 4, "EndDate": "2025-06-03T05:26:04.703+00:00", "EndCount": 1, "InstanceCount": 5, "ReminderInterval": 1, "Title": "sample string 6", "Active": true, "Updated": "2025-06-03T05:26:04.703+00:00", "Questions": [ { "CarePlanQuestionId": "6ee7f531-6a72-41ac-9c2e-ba4d21bd8e2d", "VersionId": "562e514e-4f61-4c8f-b4e2-91fd3a82c564", "QuestionId": "707823d8-936d-4d70-aabb-b67df6771310", "VillageId": "d0655379-7108-4a7d-835a-0ee9af8e153a", "Question": "sample string 5", "Sequence": 6 }, { "CarePlanQuestionId": "6ee7f531-6a72-41ac-9c2e-ba4d21bd8e2d", "VersionId": "562e514e-4f61-4c8f-b4e2-91fd3a82c564", "QuestionId": "707823d8-936d-4d70-aabb-b67df6771310", "VillageId": "d0655379-7108-4a7d-835a-0ee9af8e153a", "Question": "sample string 5", "Sequence": 6 } ], "ActivatedDate": "2025-06-03T05:26:04.703+00:00", "Draft": true }
application/xml, text/xml
<CarePlanDefinitionModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CaringVillage.Shared.Implementation.Models"> <ActivatedDate>2025-06-03T05:26:04.7034583+00:00</ActivatedDate> <Active>true</Active> <CarePlanId>023397ec-a191-47e5-9dac-f5adb2318c36</CarePlanId> <Draft>true</Draft> <EndCount>1</EndCount> <EndDate>2025-06-03T05:26:04.7034583+00:00</EndDate> <Frequency>Daily</Frequency> <InstanceCount>5</InstanceCount> <Questions> <CarePlanQuestionDefinitionModel> <CarePlanQuestionId>6ee7f531-6a72-41ac-9c2e-ba4d21bd8e2d</CarePlanQuestionId> <Question>sample string 5</Question> <QuestionId>707823d8-936d-4d70-aabb-b67df6771310</QuestionId> <Sequence>6</Sequence> <VersionId>562e514e-4f61-4c8f-b4e2-91fd3a82c564</VersionId> <VillageId>d0655379-7108-4a7d-835a-0ee9af8e153a</VillageId> </CarePlanQuestionDefinitionModel> <CarePlanQuestionDefinitionModel> <CarePlanQuestionId>6ee7f531-6a72-41ac-9c2e-ba4d21bd8e2d</CarePlanQuestionId> <Question>sample string 5</Question> <QuestionId>707823d8-936d-4d70-aabb-b67df6771310</QuestionId> <Sequence>6</Sequence> <VersionId>562e514e-4f61-4c8f-b4e2-91fd3a82c564</VersionId> <VillageId>d0655379-7108-4a7d-835a-0ee9af8e153a</VillageId> </CarePlanQuestionDefinitionModel> </Questions> <ReminderInterval>1</ReminderInterval> <RepeatsEvery>4</RepeatsEvery> <Title>sample string 6</Title> <Updated>2025-06-03T05:26:04.7034583+00:00</Updated> <VersionId>face4f9d-d584-442c-8c41-1584922e6ab7</VersionId> <VillageId>40c96de2-934c-451f-9bef-393c49bf1627</VillageId> </CarePlanDefinitionModel>