Consult notes
Generate Consult Note
Method: POST
Path: /sessions/{session_id}/consult-note
Description: Generates a consult note using a Heidi template.
Request
POST /sessions/1234567890/consult-note
Authorization: Bearer <your_token>
Content-Type: application/json
{
"generation_method":"TEMPLATE",
"addition":"",
"template_id":"659b8042fe093d6592b41ef7",
"voice_style":"GOLDILOCKS",
"brain":"LEFT"
}Request Fields:
generation_method(string, required): How to generate the note. Typical partner value isTEMPLATE. Accepted values:TEMPLATE,THIRD_PARTY_TEMPLATE,DICTATION,AUTO_MODE.template_id(string, optional): The ID of the template to use. Required whengeneration_methodisTEMPLATE. Mutually exclusive withthird_party_template.third_party_template(string, optional): Third-party template JSON. Mutually exclusive withtemplate_id.addition(string, optional): Extra text to include in generation. Defaults to"".voice_style(string, required): One ofGOLDILOCKS,DETAILED,BRIEF,SUPER_DETAILED,MY_VOICE. Refer to the Heidi documentation (opens in a new tab) for more information on voice styles.brain(string, optional):LEFTorRIGHT. If omitted, Heidi uses the linked user's saved preference. Refer to the Heidi documentation (opens in a new tab) for more information on brain options.content_type(string, optional):MARKDOWNorHTML.
Response
This endpoint will return a stream of the generated consult note, in the format:
{
"data": "Consult note text..."
}Generate Consult Note with a Custom Template
Method: POST
Path: /sessions/{session_id}/client-customised-template/response
Description: Generates a consult note using a custom JSON template. Note: you will need to generate a free text note using a template before you can generate a structured note using a template.
Request
POST /sessions/1234567890/client-customised-template/response
Authorization: Bearer <your_token>
Content-Type: application/json
{
...JSON template content
}Response
This endpoint will return a template JSON response.
Edit the latest consult note
Method: PATCH
Path: /sessions/{session_id}/consult-note
Description: Updates the latest consult note for the session (for example after the clinician edits the generated text).
Request
PATCH /sessions/1234567890/consult-note
Authorization: Bearer <your_token>
Content-Type: application/json
{
"edited_note": "Updated consult note text..."
}Request Fields:
All fields are optional. Only include the fields you want to change.
edited_note(string, optional): Replacement note text.voice_style(string, optional): Voice style.generation_method(string, optional): One ofTEMPLATE,THIRD_PARTY_TEMPLATE,DICTATION,AUTO_MODE.brain(string, optional):LEFTorRIGHT.template_id(string, optional): Template ID.content_type(string, optional):MARKDOWNorHTML.
Response
{
"consult_note": {
"status": "COMPLETED",
"result": "Updated consult note text...",
"heading": "Note",
"brain": "LEFT",
"voice_style": "GOLDILOCKS",
"generation_method": "TEMPLATE",
"template_id": "659b8042fe093d6592b41ef7"
},
"total_replacement_count": 0
}