Schema for Scalpel TabularInferface Settings

From TabularInterfaceSettings.schema.yaml (scalpel/TabularInterfaceSettings.schema)

---
$id: https://skeleton.botmd.io/scalpel/TabularInterfaceSettings.schema
$schema: http://json-schema.org/draft-07/schema#

title: "TabularInferface Settings"
description: |
  These settings are used by providers that depend on `scalpel.externals.TabularInterface`s.

type: object
additionalProperties: false
required: []

properties:
  tabular:
    title: Tabular Interface
    description: Settings for using `scalpel.externals.TabularInterface`. When this key is used, `TabularInterface.from_url(...)` is used to load the source data.

    $ref: "#/definitions/TabularInterface"

  airtable:
    title: Airtable
    description: Settings for using `scalpel.externals.Airtable`.

    $ref: "#/definitions/TabularInterface"

  csv:
    title: CSV
    description: Settings for using `scalpel.externals.TabularCSV`.

    $ref: "#/definitions/TabularInterface"

  google:
    title: Google Sheets
    description: Settings for using `scalpel.externals.GoogleSheets`.

    $ref: "#/definitions/TabularInterface"

  gsheets:
    title: Google Sheets
    description: Settings for using `scalpel.externals.GoogleSheets`.

    $ref: "#/definitions/TabularInterface"

  excel:
    title: Excel
    description: Settings for using `scalpel.externals.ExcelXLSX`.

    $ref: "#/definitions/TabularInterface"
#end properties

definitions:
  TabularInterface:
    title: TabularInterface
    description: Settings for TabularInterfaces.

    type: object
    additionalProperties:
      description: Additional properties will be passed on to the `__init__` for the `TabularInterface` reader.
    #end additionalProperties

    anyOf:
      - required:
          - url
      - required:
          - urls
    properties:
      url:
        title: URL
        description: The URL containing tabular data.
        type: string
        minLength: 1
      #end url

      urls:
        title: URLs
        description: URLs containing tabular data (for use when data is split into multiple tables).
        type: array
        minItems: 1
        items:
          type: string
          minLength: 1
      #end urls

      sheet_name:
        title: Sheet Name
        description: Name of the sheet in a workbook
        type: string
        minLength: 1
      #end url

      status_column:
        title: Status Column
        description: |
          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.

        type: string
        minLength: 1

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

        type: array
        minItems: 1
        items:
          type: string
          minLength: 1

      skip_header_row:
        title: Skip Header Row
        description: |
          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.

        type: boolean
    #end properties
  #end TabularInterface
#end definitions

[Main Page] [Schema Documentation] [Examples]