Schema for Jarvisv2 Einstein Directory Syncer Settings

From EinsteinDirectorySyncerSettings.schema.yaml (jarvisv2/EinsteinDirectorySyncerSettings.schema)

---
$defs:
  ChernobylFieldMapping:
    description: |-
      This object describes how Chernobyl entry variables (i.e., fields) are mapped to Jarvis answer/source fields.
      Answer fields are indexed in the KB while source fields are stored but not indexed.
      Source fields are used during the answer generation step to provide information back to the user.

      For a list of answer and source fields supported for each answer type, see https://gitlab.com/fivehealth/hippocrates/-/blob/staging/hippocrates/jarvis/types/answers.py
    properties:
      answer_field:
        anyOf:
        - minLength: 1
          type: string
        - type: 'null'
        default: null
        description: The field name in the Jarvis answer.
        title: Answer Field
      chernobyl_field:
        description: The field name of the Chernobyl entry.
        minLength: 1
        title: Chernobyl Field
        type: string
      source_field:
        anyOf:
        - minLength: 1
          type: string
        - type: 'null'
        default: null
        description: The field name in the source object.
        title: Source Field
    required: [chernobyl_field]
    title: Chernobyl Field Mapping
    type: object
  DefaultValue:
    description: Defines default value to use for an answer or source field.
    properties:
      answer_field:
        anyOf:
        - minLength: 1
          type: string
        - type: 'null'
        default: null
        description: The field name in the Jarvis answer.
        title: Answer Field
      source_field:
        anyOf:
        - minLength: 1
          type: string
        - type: 'null'
        default: null
        description: The field name in the source object.
        title: Source Field
      value:
        description: The default value to use.
        minLength: 1
        title: Value
        type: string
    required: [value]
    title: Default Value
    type: object
$id: https://skeleton.botmd.io/jarvisv2/EinsteinDirectorySyncerSettings.schema
$schema: http://json-schema.org/draft-07/schema#
description: This contains settings for syncing Einstein directorys.
properties:
  chernobyl_field_mappings:
    description: Describe how fields in a Chernobyl entry are mapped to Jarvis answers.
    items:
      $ref: '#/$defs/ChernobylFieldMapping'
    title: Chernobyl Field Mappings
    type: array
  data_source:
    description: The data source key in Einstein.
    minLength: 1
    title: Data Source
    type: string
  default_values:
    description: Default values for fields in the Jarvis answer.
    items:
      $ref: '#/$defs/DefaultValue'
    title: Default Values
    type: array
  syncer_id:
    description: Unique name identifying this syncer.
    title: Syncer ID
    type: string
  tenants:
    anyOf:
    - anyOf:
      - description: The `cleo` app tenant applicable to this object.
        pattern: ^cleo\:[a-zA-Z0-9][\w\-\_]*$
        title: Cleo Tenant
        type: string
      - description: The `hospital` app tenant applicable to this object.
        pattern: ^hospital\:[a-zA-Z0-9][\w\-\_]*$
        title: Hospital Tenant
        type: string
      description: The tenant applicable to this object. This must be one specific
        tenant and not any of the `__all__ alternatives.
      title: Tenant
    - const: __all__
      description: A literal to represent all tenants.
      title: All Tenants
      type: string
    - const: cleo:__all__
      description: A literal to represent all cleo app tenants.
      title: Cleo All Tenant
      type: string
    - const: hospital:__all__
      description: A literal to represent all hospital app tenants.
      title: Hospital All Tenant
      type: string
    - description: A list of tenants.
      items:
        anyOf:
        - anyOf:
          - description: The `cleo` app tenant applicable to this object.
            pattern: ^cleo\:[a-zA-Z0-9][\w\-\_]*$
            title: Cleo Tenant
            type: string
          - description: The `hospital` app tenant applicable to this object.
            pattern: ^hospital\:[a-zA-Z0-9][\w\-\_]*$
            title: Hospital Tenant
            type: string
          description: The tenant applicable to this object. This must be one specific
            tenant and not any of the `__all__ alternatives.
          title: Tenant
        - const: __all__
          description: A literal to represent all tenants.
          title: All Tenants
          type: string
        - const: cleo:__all__
          description: A literal to represent all cleo app tenants.
          title: Cleo All Tenant
          type: string
        - const: hospital:__all__
          description: A literal to represent all hospital app tenants.
          title: Hospital All Tenant
          type: string
      minItems: 1
      title: Tenant List
      type: array
    default: [__all__]
    description: The tenant that this object is applicable for. Defaults to all tenants.
    title: Tenants
  type:
    const: einstein-directory
    default: einstein-directory
    title: Type
    type: string
required: [syncer_id, data_source]
title: Einstein Directory Syncer Settings
type: object

[Main Page] [Schema Documentation] [Examples]