Skip to main content

Care teams

Komodo Care Connect automatically builds a care team for a patient when the patient enrolls into a program and a care plan is created. The care team consists of both contacts and accounts in Komodo Care Connect who support the patient throughout their treatment journey, including the accounts manually identified during enrollment and the individuals automatically assigned via the Zip To Team functionality.

Accounts and relationships

Care teams are first created with the accounts and relationships identified during a patient's enrollment. The accounts added to the care team are managed by the Case Field Configuration (mvn__PJN_Case_Field_Configuration__mdt) custom metadata type, which maps the accounts selected in Account Search on the original Request (Case) record to the new Care Plan (Case) record. On the other hand, the relationships identified in the care team are managed by the Relationship Role Configuration (mvn__PJN_Relationship_Role_Configuration__mdt) custom metadata type, which drives the creation of both Account Contact Relationship (AccountContactRelation) and Contact-Contact Relationship (HealthCloudGA__ContactContactRelation__c) records. For contact-contact relationships, the reciprocal, or inverse, roles are identified in the Reciprocal Role (HealthCloudGA__ReciprocalRole__c) Health Cloud object.

Warning

When creating reciprocal roles, the HealthCloudGA__CreateInverseRole__c field on the Reciprocal Role object must be set to true in order for Salesforce to correctly populate the HealthCloudGA__InverseRelationship__c field and create the necessary corresponding Contact-Contact Relationship records for the care team.

Care teams can be modified and updated with additional accounts, contacts, and relationships as needed. Users can see a patient's care team in the Care Map subtab.

Warning

To remove an account or contact from a patient's care team, users must remove it from the care plan. If the account or contact is no longer part of any of the patient's care teams, users must also remove it from the patient's care map. This is because a patient's care map is not specific to one care plan or care team.

Zip To Team

Zip To Team is a functionality within Komodo Care Connect that uses zip codes to assign users to a patient's care team. Out of the box, Zip To Team assigns case managers to new care plans during the enrollment process, but it can be disabled or configured to build and update care teams based on specific triggers and mappings.

Setup

To set up Zip To Team, you must have a set of alignment data as well as a mapping job for each program.

Alignment data

Zip To Team uses alignment data stored in the Zip To Team (mvn__PJN_Zip_To_Team__c) object to identify the case managers for programs across multiple countries and zip codes. Komodo Health recommends uploading a complete dataset file for each program using the Data Loader before enrollment begins to ensure the greatest alignment coverage for patients. An example load file is as follows:

Sample alignment data for zip to team

For each Zip To Team (mvn__PJN_Zip_To_Team__c) record that is created or updated, Zip To Team automatically generates a unique key in the format of <zipCode>_<country>_<programDeveloperName> to ensure that each zip code is only used once per program. The key is created via the Zip To Team - KCC After Create Update (PJN_Zip_To_Team_After_Create_Update) flow and set in the Key (mvn__PJN_Key__c) field on each Zip To Team record.

Corresponding addresses

In Komodo Care Connect V2 and above, Zip To Team also uses specific address lookup fields on the Case object to compare with the alignment data and determine the case manager for a program. For each care program, enter a list of Case fields on the Zip to Team Address Field Paths (mvn__PJN_Zip_to_Team_Address_Field_Paths__c) field on the Program (mvn__PJN_Program__mdt) metadata record. Each Case field listed should be a lookup to a Contact Information (mvn__PJN_Contact_Information__c) record of the Address (PJN_Address) record type and should be separated by a comma. Zip To Team will use the first Case field with a populated address (i.e., not null) to determine the case manager. For example, the sample Program metadata record below tells Zip To Team to first check if the physician's enrollment address is populated and then check if the patient's primary address second is populated to determine what zip code to use and which case manager to assign to a care plan.

Table 69. Sample Zip To Team mvn__PJN_Program__mdt record

Field label

Sample value

Zip to Team Address Field Paths

mvn__PJN_Enrollment_Address__c,Account.mvn__PJN_Primary_Address__c



For more information about how Zip To Team builds out the initial care team for a new care plan, reference Initial assignment and mapping below.

Mapping job and mappings

Zip To Team relies on a mapping job to appropriately stamp information from a Zip To Team record to a Care Plan (Case) record. The required Mapping Job (mvn__PJN_Mapping_Job__mdt) and Mapping (mvn__PJN_Mapping__mdt) metadata records shown below are provided in the initial installation script. The sample region and territory Mapping Field (mvn__PJN_Mapping_Field__mdt) metadata records are also provided in the initial installation script, though they can be removed, modified, or extended with other mapping type records.

Table 70. Required Zip To Team mvn__PJN_Mapping_Job__mdt record

Field label

Required value

Is Active

true

Mapping Job Name

PJN_Care_Team_Mapping

Warning

The Mapping Job Name value must equal PJN_Care_Team_Mapping in order for the Zip To Team functionality to work.

Target Object API Name

Case



Table 71. Required Zip To Team mvn__PJN_Mapping__mdt record

Field label

Required value

Always Runs

false

Warning

The Always Runs value must equal false in order for the Zip To Team functionality to run only upon record creation.

Mapping Job

The Mapping Job (mvn__PJN_Mapping_Job__mdt) metadata record created above.

Mapping Type

Field

Source Object API Name

mvn__PJN_Zip_to_Team__c

Source Object Type Name

zipToTeam

Warning

The Source Object Type Name value must equal zipToTeam in order for the Zip To Team functionality to work.



Table 72. Sample Zip To Team region mvn__PJN_Mapping_Field__mdt record

Field label

Sample value

Mapping

The Mapping (mvn__PJN_Mapping__mdt) metadata record created above.

Source Field API Name

mvn__PJN_Region__c

Target Field API Name

mvn__PJN_Region__c



Table 73. Sample Zip To Team territory mvn__PJN_Mapping_Field__mdt record

Field label

Sample value

Mapping

The Mapping (mvn__PJN_Mapping__mdt) metadata record created above.

Source Field API Name

mvn__PJN_Territory__c

Target Field API Name

mvn__PJN_Territory__c



Initial assignment and mapping

Out of the box, the Before Insert: Zip to Team (PJN_Before_Insert_Zip_to_Team) Trigger Handler Setting (mvn__PJN_Trigger_Handler_Setting__mdt) metadata record calls Zip To Team before a new Care Plan (Case) record is saved. This enables Zip To Team to run automatically when a patient is newly enrolled into a program to assign a case manager to the care plan. When Zip To Team runs, it does the following:

  1. Finds a corresponding Zip To Team record based on a given patient or physician address and its zip code.

  2. Updates the Care Plan record based on the Zip To Team record.

    Table 74. Zip To Team assignment on care plans

    Care plan (Case) field

    Zip To Team (mvn__PJN_Zip_To_Team__c) field

    OwnerId

    mvn__PJN_Case_Manager__c

    Note

    If no Zip To Team record matches, this field is set to the current user.

    mvn__PJN_Zip_To_Team__c

    Id

    Note

    If no Zip To Team record matches, this field is left blank and equals null.



  3. Calls the Care Team Mapping (PJN_Care_Team_Mapping) Mapping Job metadata record to stamp any other configured fields from the Zip To Team record onto the Care Plan record.

However, the specific logic behind how Zip To Team builds the initial care team, such as determining and assigning the case manager on a new care plan in Step 1, differs depending on the version of the Komodo Care Connect product in your Salesforce environment.

Logic in Komodo Care Connect V2 and above

In Komodo Care Connect V2 and above, Zip To Team is managed by the non-global Zip To Team Handler (PJN_ZipToTeamHdlr) Apex class. This means that upon the creation of a new Care Plan record, the Trigger Handler Setting metadata record calls the Zip To Team Handler Apex class. This class then:

  1. Checks each of the Case fields listed in the Zip To Team Address Field Paths (mvn__PJN_Zip_to_Team_Address_Field_Paths__c) field on the Program (mvn__PJN_Program__mdt) metadata record to find the first lookup field that contains an address (i.e., the address does not equal null).

  2. Uses the address and its zip code to find a corresponding Zip To Team record.

  3. Takes the Case Manager (mvn__PJN_Case_Manager__c) field on the Zip To Team record to populate the Case Owner (OwnerId) field on the Care Plan record.

  4. Updates the Run Zip to Team (mvn__PJN_Run_Zip_to_Team__c) picklist field on the Care Plan record from the default Update Case Manager value to No. This prevents Zip To Team from running again until otherwise specified.

Logic in Komodo Care Connect V1

In Komodo Care Connect V1, Zip To Team is managed by the non-global Zip To Team Assignment (PJN_ZipToTeamAssignment) Apex class. This means that upon the creation of a new Care Plan record, the Trigger Handler Setting metadata record calls the Zip To Team Assignment Apex class to perform the predefined logic shown in the decision tree diagram below.

Zip To Team logic flowchart

In other words, the Zip To Team Assignment Apex class first checks if the Enrollment Address (mvn__PJN_Enrollment_Address__c) field on the Care Plan record was set during enrollment. If so, the class uses that address to find a corresponding Zip To Team record and populate the Case Owner (OwnerId) field on the Care Plan record accordingly. If not, Zip To Team then checks if the Primary Address (mvn__PJN_Primary_Address__c) field on the Account record was set during enrollment. If so, the class uses that address instead to find and assign the case manager accordingly. If neither a physician enrollment address nor a patient primary address exists such that the Zip Code (mvn__PJN_Zip_Code__c field on the Zip To Team record does not match any address, then the current user is set as the owner of the care plan.

Reassignment

Out of the box, the Before Update: Zip to Team (PJN_Before_Update_Zip_to_Team) Trigger Handler Setting metadata record calls Zip To Team before an existing Care Plan record is saved. This enables Zip To Team to re-run when changes are made to an existing care plan. However, similar to the initial assignment and mapping of the care team, the logic behind how Zip To Team updates a care team, such as potentially reassigning the case manager, differs depending on the version of the Komodo Care Connect product in your Salesforce environment.

Logic in Komodo Care Connect V2 and above

In Komodo Care Connect V2 and above, Zip To Team can run again when the Run Zip to Team (mvn__PJN_Run_Zip_to_Team__c) picklist field on the Care Plan record equals either Update Case Manager or Keep Case Manager. The Trigger Handler Setting metadata record calls the Zip To Team Handler Apex class to perform similar steps as the initial assignment and mapping logic. However, if the Run Zip to Team field equals Update Case Manager, then the case manager is reassigned. On the other hand, if the Run Zip to Team field equals Keep Case Manager, then the case manager is not reassigned so that the patient can continue working with the case manager whom they have already established a relationship with.

Logic in Komodo Care Connect V1

In Komodo Care Connect V1, Zip To Team can run again when the Run ZTT Against Enrollment Address (mvn__PJN_Run_ZTT_Against_Enrollment_Address__c) checkbox field on the Care Plan record equals true. The Trigger Handler Setting metadata record calls the Zip To Team Assignment Apex class to update the care team. However, the class will only remap the configured fields on the Care Plan record if the Physician (mvn__PJN_Physician__c) field was updated. Additionally, the class will only use the physician's enrollment address to update the care team and will not use the patient's primary address. This means that Zip To Team will never reassign the case manager so that the patient can continue working with the case manager whom they have already established a relationship with.

Configuration

To configure the Zip To Team assignment logic, such as to set additional or other attribute assignments to a care plan, clone either the Zip To Team Handler Apex class or the Zip To Team Assignment Apex class, depending on the version of the Komodo Care Connect product in your Salesforce environment, and modify the cloned class. Reference Customization guidelines for general configuration instructions and recommendations.

To disable the Zip To Team functionality, inactivate the Zip To Team triggers. This includes both the Before Insert: Zip to Team (PJN_Before_Insert_Zip_to_Team) and the Before Update: Zip to Team (PJN_Before_Update_Zip_to_Team) Trigger Handler Setting metadata records.

To map and stamp additional fields on a care plan after a Zip To Team record is assigned to the care plan, add additional mappings to the PJN_Care_Team_Mapping mapping job.