Home Schema Example JSON Schema

Profile Settings

Type: object

Profile.settings are used to store settings related to the users. This is often used as a NoSQL store by frontend. This is WIP.

No Additional Properties

Legacy Account User Config.

Type: object

Config in JSON to store modules config such as reminder times.

Additional Properties of any type are allowed.

Type: object

Notifications

Type: object

Notifications related profile settings.

No Additional Properties

Deactivated Notifications.

Type: array

A unique list of notification keys that the user opted out from.

All items must be unique

No Additional Items

Each item of this array must be:


Notification Types

Type: object

These types are unique throughout the Bot MD ecosystem. These keys are used in the user's Profile.settings.notifications.deactivated[] to identify the notifications that they have deactivated.

Bot

Type: const

Messages from Bot. This is the default is no delivery_by is specified.

Specific value: "bot"

Alert

Type: const

Alerts

Specific value: "alert"

Email Notification

Type: const

Email Notification to Admin / User (eg. User License limit, activation, expiry, etc.)

Specific value: "email_notification"

Broadcast

Type: const

Broadcast to hospital

Specific value: "broadcast"

Profile Reminder

Type: const

Profile related reminder (eg. profile creation, activation, expiry, etc).

Specific value: "profile_reminder"

Temperature Reminder

Type: const

Temperature reminder for Singapore hospitals.

Specific value: "temperature_reminder"

ART Reminder

Type: const

ART reminder for Singapore hospitals.

Specific value: "art_reminder"

ED

Type: const

ED Roster Updates used by TTSH Emergency Department.

Specific value: "ed_roster"

Mental Health

Type: const

Mental Health bot for TTSH.

Specific value: "emobot"

Mood Log Reminder

Type: const

Mood Log Reminder for TTSH Mental Health Module (2024)

Specific value: "moodlog_reminder"

ECG

Type: const

ECG Updates used by TTSH Emergency Department.

Specific value: "ecg"

Arise

Type: const

Arise/PSP used by Roche.

Specific value: "arise_psp"

Emobot

Type: object

Emobot related profile settings.

No Additional Properties

Preferred Name

Type: string

How would you like EmoBot to address you?

Must be at least 1 characters long

Reminder Frequency

Type: enum (of string)

Frequency of reminder. E.g. "Weekly", "Twice Weekly" etc.

Must be one of:

  • "none"
  • "daily"
  • "weekly"
  • "twice_weekly"

Reminder Time

Type: string

Time the reminder will be sent, e.g., "09:00", "18:00" etc.

Must match regular expression: ^[0-2]\d\:[0-5]\d$

Last Reminded On

Type: number

Used internally to determine when the user was last sent a reminder. This is a Posix timestamp.

Value must be greater or equal to 0

Sources of Strengths

Type: array of object

Where does the user derive their emotional sources of strengths.

No Additional Items

Each item of this array must be:

Type: object
No Additional Properties

Label

Type: string

Pretty human readable label for this source of strength

Value

Type: boolean

Whether this source is selected.

Chat State

Type: object

Used internally to keep track of the state of a user's chat with emobot. Backend use only.

Current State ID

Type: string

The current chat state ID.

Emotion

Type: string

User's emotion based on what they say.

Vent Counter

Type: integer

No. of venting messages we've received.

Thinking Trap

Type: string

Current "Thinking trap" as part of the CBT flow.

Feelings

Type: array of string

Array of feelings of user when going through the CBT flow.

No Additional Items

Each item of this array must be:

Updated On

Type: stringFormat: date-time

ISO formatted datetime of when the state was last updated.

Additional Properties of any type are allowed.

Type: object

CGH Related Metadata

Type: object

Metadata related to CGH 2FA

No Additional Properties

2FA Approved

Type: boolean

The user has verified his/her 2FA code.

Phone Number

Type: string

Encrypted phone number of user.

Notified Expiry

Type: boolean

The user received the notification for expiry