Home Schema Example JSON Schema

MiniApp Settings

Type: object

Chernobyl MiniApps define the schema of their source data and how the data should be displayed on the frontend.

Hospitals

Type: array

Array of Hospital keys that will have access to the resource. Defaults to allow any hospital if not specified. Empty array (i.e., []) will deny all access.

Must contain a minimum of 1 items

All items must be unique

No Additional Items

Tuple Validation

Item at 1 must be:

Organization Keys

Type: object

List of organization keys that double up as tags. These tags are for access control at the hospital and organizational level.

Alexandra

Type: const

Alexandra Hospital

Specific value: "alexandra"

AHI

Type: const

Association of Healthtech Indonesia

Specific value: "ahi"

Digihealth

Type: const

Digihealth

Specific value: "digihealth"

Bot MD Demo Hospital

Type: const

Bot MD Demo Hospital for our internal testing purposes.

Specific value: "bdh"

CGH

Type: const

Changi General Hospital

Specific value: "cgh"

Cleo

Type: const

All cleo dialogues are nested under this hospital. Permissions to different clinics are separated by tags of the form cleo:<domain>.

Specific value: "cleo"

Dharmais

Type: const

Rumah Sakit Kanker Dharmais

Specific value: "dharmais"

Fleming Hospital

Type: const

Fleming Hospital is our hospital for public users.

Specific value: "fleminghospital"

Bot MD

Type: const

Bot MD.

Specific value: "botmd"

Bot MD ID Web

Type: const

Bot MD ID Demo Web

Specific value: "botmd_id_web"

EB Medicine Demo

Type: const

EB Medicine Demo

Specific value: "eb_medicine"

Faithful Empire

Type: const

Faithful Empire Webbot

Specific value: "faithful_empire_web"

Harapan Kita

Type: const

Pusat Jantung Nasional Harapan Kita

Specific value: "pjnhk"

ICC

Type: const

Icon Cancer Centre

Specific value: "icc"

IDI

Type: const

Indonesian Medical Association

Specific value: "idi"

IDI Web

Type: const

Indonesian Medical Association Web

Specific value: "idi_web"

IDI Whatsapp

Type: const

Indonesian Medical Association Whatsapp

Specific value: "idi_whatsapp"

Iskandar Demo

Type: enum (of string)

Iskandar demo project.

Must be one of:

  • "iskandar_demo"
  • "iskandar"

Indonesia Care

Type: const

Indonesia care

Specific value: "indonesia_care"

Indonesia Hospital

Type: const

Indonesia hospital

Specific value: "indonesia_hospital"

Klinik In Harmony

Type: const

Klinik In Harmony

Specific value: "inharmony"

KONSULTAMD

Type: const

Konsulta MD

Specific value: "konsultamd"

KKWCH

Type: const

KK Women's and Children's Hospital

Specific value: "kkwch"

KTPH

Type: const

Khoo Teck Puat Hospital

Specific value: "ktph"

MOH Singapore

Type: const

Ministry of Health (Singapore)

Specific value: "moh_sg"

National Hospital

Type: const

National Hospital

Specific value: "nationalhospital"

NCCS

Type: const

National Cancer Centre Singapore

Specific value: "nccs"

NCIS

Type: const

National University Cancer Institute Singapore

Specific value: "ncis"

NCIS Engage

Type: const

NCIS Engage

Specific value: "ncis_engage"

NCIS Engage Web

Type: const

NCIS Engage Web

Specific value: "ncis_engage_web"

NEMG

Type: const

Northeast Medical Group

Specific value: "nemg"

NEMG WEB

Type: const

NEMG WEB

Specific value: "nemg_web"

NKTI

Type: const

National Kidney Transplant Institute

Specific value: "nkti"

NTFGH

Type: const

Ng Teng Fong General Hospital

Specific value: "ntfgh"

NUHS

Type: const

National University Health System

Specific value: "nuhs"

NUH

Type: const

National University Hospital

Specific value: "nuh"

NUS Med

Type: const

NUS School of Medicine

Specific value: "nus_med"

Parkway Radiology

Type: const

Parkway Radiology

Specific value: "parkwayradio"

Philippine General Hospital

Type: const

Philippine General Hospital

Specific value: "pgh"

Prodia Demo

Type: const

Prodia Demo

Specific value: "prodia_demo"

PPhA

Type: const

Philippine Pharmacists Association, Inc

Specific value: "ppha"

Roche Singapore

Type: const

Roche Singapore

Specific value: "roche"

Roche Brunei

Type: const

Roche Brunei

Specific value: "roche_brunei"

Roche HCP

Type: const

Roche HCP is the public bot hosted on https://roche.com.sg

Specific value: "roche_hcp"

Roche HCP Private

Type: const

Roche HCP Private is the private bot hosted on https://roche.com.sg

Specific value: "roche_hcp_private"

Philippine General Hospital

Type: const

Philippine General Hospital

Specific value: "upcm"

Sanglah

Type: const

Sanglah General Hospital

Specific value: "sanglah"

SGH

Type: const

Singapore General Hospital

Specific value: "sgh"

SKH

Type: const

Sengkang General Hospital

Specific value: "skh"

SingHealth

Type: const

SingHealth

Specific value: "singhealth"

Siloam Hospitals

Type: const

Siloam Hospitals

Specific value: "siloam"

Speedoc

Type: const

Speedoc

Specific value: "speedoc"

Stanford

Type: const

Stanford Health Care

Specific value: "stanford"

Sunway

Type: const

Sunway

Specific value: "sunway"

TTSH

Type: const

Tan Tock Seng Hospital

Specific value: "ttsh"

Ultravioleta

Type: const

Ultravioleta hospital

Specific value: "ultravioleta"

UPCM

Type: object

College of Medicine - University of the Philippines Manila

Profile Tags

Type: array

Profile tags are used to identify certain properties of users and control their access to data.

All items must be unique

No Additional Items

Each item of this array must be:


Accessible Tags

Type: object

Tags for controlling access to information. These tags are for gating at the module level and unaffilated with any hospital or organizations.

AHFS

Type: const

Profile can access AHFS DI monographs.

Specific value: "AHFS_accessible"

Calculators

Type: const

Profile can access calculators.

Specific value: "calculators_accessible"

EB Medicine

Type: const

Profile can access EB medicine module.

Specific value: "ebmedicine_accessible"

Guidelines

Type: const

Profile can access guidelines module.

Specific value: "guidelines_accessible"

Sanford

Type: const

Profile can access Sanford module.

Specific value: "Sanford_accessible"

NCIS ChemoCalc

Type: const

Profile can access NCIS chemocalc module.

Specific value: "ncis_chemocalc_accessible"

UpToDate

Type: const

Profile can access Uptodate module.

Specific value: "Uptodate_accessible"

Mediview

Type: const

Profile can access Mediview module.

Specific value: "Mediview_accessible"

MIMS

Type: const

Profile can access MIMS monographs.

Specific value: "MIMS_accessible"

Bot MD Tags

Type: object

Our internal tags for managing users. Usually used for testing and billing purposes.

Internal User

Type: const

This profile belongs to an internal user.

Specific value: "botmd:internal"

Jarvis

Type: const

Users with this tag will be redirected to Jarvis instead.

Specific value: "botmd:jarvis"

Jarvis V2

Type: const

Users with this tag will be redirected to Jarvis v2 for certain queries.

Specific value: "botmd:jarvisv2"

Test

Type: const

This tag is used for testing purpose (e.g., unit tests).

Specific value: "botmd:testtag"

Documents Beta

Type: const

This profile is on the waitlist for the documents Beta programme

Specific value: "botmd:beta-documents-waitlist"

Documents Beta

Type: const

This profile is enrolled onto the documents Beta programme

Specific value: "botmd:beta-documents"

Directory Assistant

Type: const

This profile has access to the directory Jarvis V2 assistant

Specific value: "botmd:assistant-directory"

Organization Keys

Type: object

List of organization keys that double up as tags. These tags are for access control at the hospital and organizational level.

Same definition as Organization Keys

Department Tags

Type: object

List of departments we count as tags.

BDH

Type: string

This represents demo-groups within BDH (e.g. bdh_upcn, bdh_healthway, etc)

Must match regular expression: ^bdh\_\w+$

CGH

Type: string

This represents departments, services, or content-groups within CGH (e.g. cgh_rccm, cgh_edgeri, etc)

Must match regular expression: ^cgh\_\w+$

Cleo

Type: string

This separates various clinics within Cleo using their domain.

Must match regular expression: ^cleo\:\w+$

KKWCH

Type: string

This represents departments, services, or content-groups within KKWCH (e.g. kkwch_rccm, kkwch_edgeri, etc)

Must match regular expression: ^kkwch\_\w+$

NCIS

Type: string

This represents departments, services, or content-groups within NCIS (e.g. ncis_rccm etc)

Must match regular expression: ^ncis\_\w+$

NTFGH

Type: string

This represents departments, services, or content-groups within NTFGH (e.g. ntfgh_rccm, ntfgh_edgeri, etc)

Must match regular expression: ^ntfgh\_\w+$

NUHS

Type: string

This represents departments, services, or content-groups within NUHS (e.g. nuhs_rccm, nuhs_edgeri, etc)

Must match regular expression: ^nuhs\_\w+$

NUH

Type: string

This represents departments, services, or content-groups within NUH (e.g. nuh_rccm, nuh_edgeri, etc)

Must match regular expression: ^nuh\_\w+$

Alexandra

Type: string

This represents departments, services, or content-groups within AH (e.g. alexandra_rccm, alexandra_edgeri, etc)

Must match regular expression: ^alexandra\_\w+$

SKH

Type: string

This represents departments, services, or content-groups within SKH (e.g. skh_rccm, skh_edgeri, etc)

Must match regular expression: ^skh\_\w+$

TTSH

Type: string

This represents departments, services, or content-groups within TTSH (e.g. ttsh_rccm, ttsh_edgeri, etc)

Must match regular expression: ^ttsh\_\w+$

National University Polyclinics (Deprecated)

Type: const

NUHS polyclinics

Specific value: "nupoly"

Bot MD Philippines

Type: const

For users in Philippines.

Specific value: "botmdphilippines"

Intents

Type: array of string

Intent phrases that will trigger this module.

Must contain a minimum of 1 items

All items must be unique

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Rank

Type: number

Rank of the miniapp used for deconflicting ties (default: 0)

Rank Group

Type: string

Rank group used for grouping several miniapps together when clustering such that lower score miniapps with higher rank can still get priority

Must be at least 1 characters long

F1 Beta Parameter

Type: number

F1 beta parameter used for tuning precision/recall in the miniapp (default: 0.5). Higher value puts more emphasis in precision (w.r.t query)

Perfect Requires Intent

Type: boolean

Determines if intent is required for an answer to be is_perfect, when an answer is exact, it is_perfect and can cause it to swamp other answers (default: False)

Specificity

Type: number

Specificity parameter used for tuning the level of culling relevant answers in the miniapp (default: 0.5). Higher value will cull off more relevant answer

Denoise (keep only best answers after segmentation/clustering)

Type: boolean

Determines if only the top segment after clustering is kept (default: true)

Timezone

Type: string

Default timezone (eg. Asia/Singapore) if not specified in hospital settings (to be used for time related display information such as last synced time).

Must be at least 1 characters long

Airtable

Type: object

Settings for using scalpel.externals.Airtable.

Type: object

The following properties are required:

  • url
Type: object

The following properties are required:

  • urls

URL

Type: string

The URL containing tabular data.

Must be at least 1 characters long

URLs

Type: array of string

URLs containing tabular data (for use when data is split into multiple tables).

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Sheet Name

Type: string

Name of the sheet in a workbook

Must be at least 1 characters long

Status Column

Type: string

Used to denote which is the Status column. Defaults to Status.

If any of development, staging, production, test appears in the status column, the row will be ignored unless it is executed in the same environment (as denoted by settings.ENVIRONMENT).

If ignore appears in the status column, the row is ignored.

Must be at least 1 characters long

Headers

Type: array of string

An array of string to denote the headers for the TabularInterface. Useful if the source data does not define headers.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Skip Header Row

Type: boolean

Whether to skip the header row.

This is a misnomer. It refers to whether the source data contains a header row.

When set to true, every row of the source data is read.

When set to false (default behavior), the first row of the data is treated as the headers value and data starts from the 2nd row onwards.

Each additional property must conform to the following schema

Type: object

Additional properties will be passed on to the __init__ for the TabularInterface reader.

Google Sheets

Type: object

Settings for using scalpel.externals.GoogleSheets.

Type: object

The following properties are required:

  • url
Type: object

The following properties are required:

  • urls

URL

Type: string

The URL containing tabular data.

Must be at least 1 characters long

URLs

Type: array of string

URLs containing tabular data (for use when data is split into multiple tables).

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Sheet Name

Type: string

Name of the sheet in a workbook

Must be at least 1 characters long

Status Column

Type: string

Used to denote which is the Status column. Defaults to Status.

If any of development, staging, production, test appears in the status column, the row will be ignored unless it is executed in the same environment (as denoted by settings.ENVIRONMENT).

If ignore appears in the status column, the row is ignored.

Must be at least 1 characters long

Headers

Type: array of string

An array of string to denote the headers for the TabularInterface. Useful if the source data does not define headers.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Skip Header Row

Type: boolean

Whether to skip the header row.

This is a misnomer. It refers to whether the source data contains a header row.

When set to true, every row of the source data is read.

When set to false (default behavior), the first row of the data is treated as the headers value and data starts from the 2nd row onwards.

Each additional property must conform to the following schema

Type: object

Additional properties will be passed on to the __init__ for the TabularInterface reader.

Einstein Module

Type: object

Configuration settings when used with Einstein.

Einstein Module UID

Type: string

The corresponding Einstein Module's data sources will be used during syncing

Must be at least 1 characters long

Einstein DataSource UID

Type: string

The corresponding Einstein DataSource will be used during syncing

Must be at least 1 characters long

Chemocalc Settings

Type: object

Settings related to chemocalc

Regimen Table

Type: object

Table containing the regimens names and synonyms

Type: object

The following properties are required:

  • url
Type: object

The following properties are required:

  • urls

URL

Type: string

The URL containing tabular data.

Must be at least 1 characters long

URLs

Type: array of string

URLs containing tabular data (for use when data is split into multiple tables).

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Sheet Name

Type: string

Name of the sheet in a workbook

Must be at least 1 characters long

Status Column

Type: string

Used to denote which is the Status column. Defaults to Status.

If any of development, staging, production, test appears in the status column, the row will be ignored unless it is executed in the same environment (as denoted by settings.ENVIRONMENT).

If ignore appears in the status column, the row is ignored.

Must be at least 1 characters long

Headers

Type: array of string

An array of string to denote the headers for the TabularInterface. Useful if the source data does not define headers.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Skip Header Row

Type: boolean

Whether to skip the header row.

This is a misnomer. It refers to whether the source data contains a header row.

When set to true, every row of the source data is read.

When set to false (default behavior), the first row of the data is treated as the headers value and data starts from the 2nd row onwards.

Each additional property must conform to the following schema

Type: object

Additional properties will be passed on to the __init__ for the TabularInterface reader.

Drug Dose Table

Type: object

Table containing drug information (eg. regimen, dosage information, indications, etc ...)

Type: object

The following properties are required:

  • url
Type: object

The following properties are required:

  • urls

URL

Type: string

The URL containing tabular data.

Must be at least 1 characters long

URLs

Type: array of string

URLs containing tabular data (for use when data is split into multiple tables).

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Sheet Name

Type: string

Name of the sheet in a workbook

Must be at least 1 characters long

Status Column

Type: string

Used to denote which is the Status column. Defaults to Status.

If any of development, staging, production, test appears in the status column, the row will be ignored unless it is executed in the same environment (as denoted by settings.ENVIRONMENT).

If ignore appears in the status column, the row is ignored.

Must be at least 1 characters long

Headers

Type: array of string

An array of string to denote the headers for the TabularInterface. Useful if the source data does not define headers.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Skip Header Row

Type: boolean

Whether to skip the header row.

This is a misnomer. It refers to whether the source data contains a header row.

When set to true, every row of the source data is read.

When set to false (default behavior), the first row of the data is treated as the headers value and data starts from the 2nd row onwards.

Each additional property must conform to the following schema

Type: object

Additional properties will be passed on to the __init__ for the TabularInterface reader.

Price List Table

Type: object

Table containing formulary item information (eg. drug, price, subsidies, etc ...)

Type: object

The following properties are required:

  • url
Type: object

The following properties are required:

  • urls

URL

Type: string

The URL containing tabular data.

Must be at least 1 characters long

URLs

Type: array of string

URLs containing tabular data (for use when data is split into multiple tables).

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Sheet Name

Type: string

Name of the sheet in a workbook

Must be at least 1 characters long

Status Column

Type: string

Used to denote which is the Status column. Defaults to Status.

If any of development, staging, production, test appears in the status column, the row will be ignored unless it is executed in the same environment (as denoted by settings.ENVIRONMENT).

If ignore appears in the status column, the row is ignored.

Must be at least 1 characters long

Headers

Type: array of string

An array of string to denote the headers for the TabularInterface. Useful if the source data does not define headers.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Skip Header Row

Type: boolean

Whether to skip the header row.

This is a misnomer. It refers to whether the source data contains a header row.

When set to true, every row of the source data is read.

When set to false (default behavior), the first row of the data is treated as the headers value and data starts from the 2nd row onwards.

Each additional property must conform to the following schema

Type: object

Additional properties will be passed on to the __init__ for the TabularInterface reader.

Report

Type: object

Settings to configure the exportable chemocalc report.

Left Logo

Type: string

URL for the left logo in report header.

Must be at least 1 characters long

Right Logo

Type: string

URL for the right logo in report header.

Must be at least 1 characters long

Center Logo

Type: string

URL for the center logo in report header.

Must be at least 1 characters long

Header

Type: string

HTML fragment string to display in the UI header.

Must be at least 1 characters long

Fields

Type: array

The list of fields mapped to the table columns that are searchable by Jarvis in this mini-app.

Must contain a minimum of 1 items

All items must be unique

No Additional Items

Each item of this array must be:

Type: object
No Additional Properties

Key

Type: string

Uniquely identifiable key used internally for this field. It will be used as the key when storing values associated with this field.

Must be at least 1 characters long

Field Path

Type: string

If the value of the cell must be a JSON. The fieldpath specifies the path to get to the value (eg. usermetadata.stitch_url).

Must be at least 1 characters long

Column

Type: string

The corresponding column name used in Airtable, CSV, or any Tabular interfaces. Defaults to the value of key.

Type

Type: enum (of string)

The type of this field. This is used by Chernobyl to determine how to parse values from the source data. Defaults to string.
The boolean type will parse the raw field value into boolean true iff it is one of [true, yes, 1, ok] (case insensitive).
The number and string type will parse the raw field value into a float and string respectively.
The file type will assume the raw field value is a URL and download it to our private S3 bucket protected by Stitch.
The object type will assume the raw field value is a well-formed JSON or YAML and parse it as such. An exception will be raised if it is neither.
The json_url type assume the raw field is a url link to a JSON file. The contents will be read and stored internally as an object
The ignore type specifies that this column is the ignore column. If this row has a value of 'ignore', then the entire row is not indexed.
In certain Tabular interfaces which provides an "attachment" field, the type should be set to file or an error will be raised.

Must be one of:

  • "boolean"
  • "number"
  • "string"
  • "strings"
  • "object"
  • "files"
  • "json_url"
  • "ignore"

Synonyms

Type: object

Replaces the field value with list from the synonyms.

Each additional property must conform to the following schema

Type: array of string

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Sorry Message


Optional sorry message to display if there is an intent present without answers.

Type: object

Type: object

Title

Type: object

Title primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "title"

Title

Type: string

Title content.

Must be at least 1 characters long

Subtitle

Type: object

Subtitle primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "subtitle"

Subtitle

Type: string

Subtitle content.

Must be at least 1 characters long

Text

Type: object

Text primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "text"

Text

Type: string

Text content.

Must be at least 1 characters long

Type: object

Image

Type: object

Image primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "image"

Image Metadata

Type: object

Image element metadata.

URL

Type: object

URL to the image file.

Scale

Type: enum (of string)

Overrides frontend's default image scaling algorithm.

Must be one of:

  • "center"
  • "center-crop"
  • "center-inside"

Actionable

Type: object

Action to take when clicking on the image (or preview image). Defaults to opening the image in viewer.

URL

Type: string

URL to the link file. Could be application internal links too. Currently supported internal links are: botmd://hospital/postMessage, botmd://hospital/emobot, botmd://hospital/gql, and `botmd://hospital/jarvisQuery.

Must be at least 1 characters long

External Browser

Type: boolean

Whether to open the url in an external browser instead of our own webview. Defaults to false.

Content Type

Type: string

The MIME type of the content at URL. This is guessed from the extension of the url. If it is a http/https URL and there are no file extensions, text/html is assumed.
This is useful to override the default app responsible for opening it.
See scalpel.messages.url.ContentTypeMixin for content type guessing logic.

Must be at least 1 characters long

Event Metadata

Type: object

Metadata to describe an event that can be posted to Shadowfax. This is usually part of an Actionable.

No Additional Properties

Type

Type: string

Event type that will be posted to Shadowfax (i.e., event_type) when this action is taken.

Must be at least 1 characters long

Properties

Type: object

Optional event properties that will be posted to Shadowfax (i.e., event_properties) when this action is taken.

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Audio

Type: object

Audio primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "audio"

Audio Metadata

Type: object

Audio element metadata.

URL

Type: object

URL to the audio file.

Preview Image

Type: object

Preview image of audio. Defaults to a generic audio icon.

URL

Type: object

URL to the image file.

Scale

Type: enum (of string)

Overrides frontend's default image scaling algorithm.

Must be one of:

  • "center"
  • "center-crop"
  • "center-inside"

Actionable

Type: object

Action to take when clicking on the image (or preview image). Defaults to opening the image in viewer.

URL

Type: string

URL to the link file. Could be application internal links too. Currently supported internal links are: botmd://hospital/postMessage, botmd://hospital/emobot, botmd://hospital/gql, and `botmd://hospital/jarvisQuery.

Must be at least 1 characters long

External Browser

Type: boolean

Whether to open the url in an external browser instead of our own webview. Defaults to false.

Content Type

Type: string

The MIME type of the content at URL. This is guessed from the extension of the url. If it is a http/https URL and there are no file extensions, text/html is assumed.
This is useful to override the default app responsible for opening it.
See scalpel.messages.url.ContentTypeMixin for content type guessing logic.

Must be at least 1 characters long

Event Metadata

Type: object

Metadata to describe an event that can be posted to Shadowfax. This is usually part of an Actionable.

No Additional Properties

Type

Type: string

Event type that will be posted to Shadowfax (i.e., event_type) when this action is taken.

Must be at least 1 characters long

Properties

Type: object

Optional event properties that will be posted to Shadowfax (i.e., event_properties) when this action is taken.

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Video

Type: object

Video primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "video"

Video Metadata

Type: object

Video element metadata.

URL

Type: object

URL to the video file.

Preview Image

Type: object

Preview image of video. Defaults to first frame of video.

URL

Type: object

URL to the image file.

Scale

Type: enum (of string)

Overrides frontend's default image scaling algorithm.

Must be one of:

  • "center"
  • "center-crop"
  • "center-inside"

Actionable

Type: object

Action to take when clicking on the image (or preview image). Defaults to opening the image in viewer.

URL

Type: string

URL to the link file. Could be application internal links too. Currently supported internal links are: botmd://hospital/postMessage, botmd://hospital/emobot, botmd://hospital/gql, and `botmd://hospital/jarvisQuery.

Must be at least 1 characters long

External Browser

Type: boolean

Whether to open the url in an external browser instead of our own webview. Defaults to false.

Content Type

Type: string

The MIME type of the content at URL. This is guessed from the extension of the url. If it is a http/https URL and there are no file extensions, text/html is assumed.
This is useful to override the default app responsible for opening it.
See scalpel.messages.url.ContentTypeMixin for content type guessing logic.

Must be at least 1 characters long

Event Metadata

Type: object

Metadata to describe an event that can be posted to Shadowfax. This is usually part of an Actionable.

No Additional Properties

Type

Type: string

Event type that will be posted to Shadowfax (i.e., event_type) when this action is taken.

Must be at least 1 characters long

Properties

Type: object

Optional event properties that will be posted to Shadowfax (i.e., event_properties) when this action is taken.

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Preview Autostart

Type: boolean

Whether to auto play video in preview view. Defaults to false.

Additional Properties of any type are allowed.

Type: object

Attachment

Type: object

Attachment primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "attachment"

Attachment Metadata

Type: object

Attachment element metadata.

No Additional Properties

URL

Type: string

URL to the attachment file.

Must match regular expression: ^((https|s3|gs|file)\:\/\/|\$)

Filename

Type: string

Filename for attachment. This is useful when the filename cannot be inferred from the URL.

Must be at least 1 characters long

Content Type

Type: string

The MIME type of the attachment. This is guessed from the extension of the filename followed by the url. See scalpel.messages.url.ContentTypeMixin for content type guessing logic.

Must be at least 1 characters long

Preview Image

Type: object

Preview image of attachment. Defaults to first frame of attachment.

URL

Type: object

URL to the image file.

Scale

Type: enum (of string)

Overrides frontend's default image scaling algorithm.

Must be one of:

  • "center"
  • "center-crop"
  • "center-inside"

Actionable

Type: object

Action to take when clicking on the image (or preview image). Defaults to opening the image in viewer.

URL

Type: string

URL to the link file. Could be application internal links too. Currently supported internal links are: botmd://hospital/postMessage, botmd://hospital/emobot, botmd://hospital/gql, and `botmd://hospital/jarvisQuery.

Must be at least 1 characters long

External Browser

Type: boolean

Whether to open the url in an external browser instead of our own webview. Defaults to false.

Content Type

Type: string

The MIME type of the content at URL. This is guessed from the extension of the url. If it is a http/https URL and there are no file extensions, text/html is assumed.
This is useful to override the default app responsible for opening it.
See scalpel.messages.url.ContentTypeMixin for content type guessing logic.

Must be at least 1 characters long

Event Metadata

Type: object

Metadata to describe an event that can be posted to Shadowfax. This is usually part of an Actionable.

No Additional Properties

Type

Type: string

Event type that will be posted to Shadowfax (i.e., event_type) when this action is taken.

Must be at least 1 characters long

Properties

Type: object

Optional event properties that will be posted to Shadowfax (i.e., event_properties) when this action is taken.

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Additional Properties of any type are allowed.

Type: object

Einstein attachment metadata

Type: object

Einstein-specific metadata for this attachment

Document UID

Type: string

Einstein Document UID for attachment.

Must be at least 1 characters long

Type: object

Button

Type: object

Button action primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "button"

Button Metadata

Type: object

Button action element metadata.

Visuals

Type: object

Metadata to describe the visual aspect of a button.

Text

Type: string

Display text.

Must be at least 1 characters long

Style

Type: enum (of string)

Button styling options. cta refers to call to action buttons that have a blue background, while link buttons have white background. Defaults to link.

Must be one of:

  • "cta"
  • "link"

Additional Properties of any type are allowed.

Type: object

Actionable metadata

Type: object

Metadata to describe actions that are taken when a UI element is triggered (e.g., tapped, clicked, etc).

Same definition as actionable
Type: object

Quick Reply

Type: object

Quick reply primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "quick_reply"

Quick Reply Metadata

Type: object

Quick reply element metadata.

Visuals

Type: object

Metadata to describe the visual aspect of a quick reply.

Text

Type: string

Display text.

Must be at least 1 characters long

Additional Properties of any type are allowed.

Type: object

Actionable metadata

Type: object

Metadata to describe actions that are taken when a UI element is triggered (e.g., tapped, clicked, etc).

Same definition as actionable
Type: object

Location Request

Type: object

Location request primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "location_request"

Location Request Metadata

Type: object

Location request element metadata.

No Additional Properties

Text

Type: string

Prompt for the user when requesting for location.

Must be at least 1 characters long

Location Response

Type: object

Location request primitive element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "location_response"

Location Response Metadata

Type: object

Location response element metadata.

No Additional Properties

Longitude

Type: number

Location longitude.

Name

Type: string

Name of the location.

Must be at least 1 characters long

Address

Type: string

Human-readable address of the location.

Must be at least 1 characters long

Container Types

Type: object

Container types wrap around other primitive types.

Quick Replies

Type: object

Quick replies container element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "quick_replies"

Quick Replies

Type: array

Array of quick replys.

Must contain a minimum of 1 items

Must contain a maximum of 16 items

No Additional Items

Each item of this array must be:

Sections

Type: object

Sections are container types for up to at most 3 elements. These are most likely to be used for rich messages that include media, paragraphs, and actions.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "sections"

Sections

Type: array

An array of section elements.

Must contain a minimum of 1 items

Must contain a maximum of 5 items

No Additional Items

Each item of this array must be:


Paragraphs

Type: object

Paragraphs container element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "paragraphs"

Favorite metadata

Type: object

When specified, the message / carousel item can be favorited on the frontend.

No Additional Properties

Title

Type: string

Title to show in the favorites menu.

Must be at least 1 characters long

URL

Type: string

URL to favorite item. This could be an internal botmd:// link or an external link.

Must be at least 1 characters long

Expires On

Type: stringFormat: date-time

This is used with botmd://hospital/jarvisQuery links using uids. If frontend decides to cache the content of this favorite message, it should be refreshed against the backend after the expiry.

Actions

Type: object

Actions container element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "actions"

Actions

Type: array

An array of action elements.

Must contain a minimum of 1 items

Must contain a maximum of 8 items

No Additional Items

Each item of this array must be:

Favorite metadata

Type: object

When specified, the message / carousel item can be favorited on the frontend.

Same definition as favorite

Favorite metadata

Type: object

When specified, the message / carousel item can be favorited on the frontend.

Same definition as favorite

Paragraphs

Type: object

Paragraphs container element.

Same definition as Paragraphs

Actions

Type: object

Actions container element.

Same definition as Actions

Carousel

Type: object

Carousel container element.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "carousel"

Application Payload

Type: object

Application payload message.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "application_payload"

Application Payload Metadata

Type: object

Application payload element metadata.

No Additional Properties

Application

Type: string

Application origin of the data payload

Must be at least 1 characters long

Payload

Type: object or string

Arbitrary payload to be used by application. Can be any JSON object.

Additional Properties of any type are allowed.

Type: object

Email

Type: object

This is a high level representation of MIME emails.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "email"

Email Metadata

Type: object

Email element metadata.

Subject

Type: string

A short string identifying the topic of the message (RFC 2822).

Must be at least 1 characters long

Text

Type: string

The main body of the email in plain text.

HTML

Type: string

The main body of the email in HTML.

Must be at least 1 characters long

Attachments

Type: array

Attachments to the email.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Attachment Metadata

Type: object

Attachment element metadata.

Same definition as attachment

Empty Message

Type: object

An empty message with no content whatsoever.

No Additional Properties

Type

Type: const

The type of this element.

Specific value: "empty"

Array of Messages

Type: array

Used to support more than 1 message (eg. Text and Quick Reply)

No Additional Items

Each item of this array must be:

Stop Words

Type: array of string

Stop words to apply to this miniapp only.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: string

Must be at least 1 characters long

Style

Type: object

Configurations that affect how the data is presented to the user.

Table

Type: object

Used in the table miniapp view such as for formularies, directories and documents. Displays data as a table with rows and columns that are customizable.

No Additional Properties

Title

Type: string

Header title to be shown below the logo in the table view. It can be used for the name of the miniapp, the table, etc.

Must be at least 1 characters long

Subtitle

Type: string

Header subtitle to be shown below the title in the table view. It can be used to display more information about the miniapp.

Must be at least 1 characters long

Prefix

Type: string

Prefix to be shown below the subtitle in the table view. It can be used to display more information about the miniapp.

Must be at least 1 characters long

Logo URL

Type: stringFormat: uri

Logo of the hospital to be shown in the header of the table view.

Row

Type: object

Title

Type: string

Title of the row.

Subtitle

Type: string

Subtitle displayed below the title to provide additional information to the row.

Content

Type: string

Content appears below the subtitle and is collapsible.

Document URL

Type: string

Appears as a linked document icon on the right. If the document has searchable pages, an additional linked magnifying glass icon will be presented which links to the document search page.

Image URL

Type: string

Image to display when row is expanded

Document

Type: object

Used in the document search miniapp view when searching for text inside a document. Displays data as sections which are linked to certain page of the document.

No Additional Properties

Title

Type: string

Header title to be shown below the logo in the document search view.

Must be at least 1 characters long

Subtitle

Type: string

Header subtitle to be shown below the title in the document search view. It can be used to display more information about the document.

Must be at least 1 characters long

Prefix

Type: string

Prefix to be shown below the subtitle in the table view. It can be used to display more information about the miniapp.

Must be at least 1 characters long

Logo URL

Type: stringFormat: uri

Logo of the hospital to be shown in the header of the document search view.

Quick Reply

Type: object

Used to customize how the quick replies looks in the chat application.

Type: string

Must be at least 1 characters long

Message

Type: object

Used to define and customize the actual chernobyl message (text, carousel, section, etc ...) in the chat application.

No Additional Properties

Message Body


Template for the message body to be displayed in the mini-app. The message can be carousel or text message, depending on carousel_mode. Variables can be used here. See Prefill URL for details on the supported variables.

Carousel Container Types

Type: object

Container types wrap around other primitive types. These types are used in carousels.

Same definition as Carousel Container Types

Entries Limit

Type: integer

The limit on the number of entries that can be displayed in the message (default to 5). Any extra entry will not be shown.

Text Message [deprecated]

Type: object

Properties related to the text message formatting of this chat application.

No Additional Properties

Text

Type: string

Template for the text message.

Must be at least 1 characters long

Button Text

Type: string

Text of the button below the text body.

Must be at least 1 characters long

Button URL

Type: string

URL to open when the button is clicked. If not set, there will be no button.

Must be at least 1 characters long

Button kwargs

Type: object

Keyword arguments that will be attached to the button when sent to the frontend.

Limit Entries

Type: integer

The maximum number of entries displayed in the text message.

Quick Reply [deprecated]

Type: object

Used to customize how the quick replies looks in the chat application.

Type: string

Must be at least 1 characters long

Additional Properties of any type are allowed.

Type: object