Skip to content

The Component Schema Field Object

Retrieve an object of the component fields schema.

Every field type added to a component can include a set of properties, but some are only available in specific types, such as Blocks or Date/Time.

The example includes only a few of the available properties.

  • type string

    The type of the field

  • required boolean

    Default: false. Define the field as mandatory.

  • description string

    The description shown in the editor

  • tooltip boolean

    Default: false. Set to true to show the description as a tooltip.

  • pos number

    Position of the field in the component

  • translatable boolean

    true if translation is enabled

  • default_value string

    Default value of the field. Can be an escaped JSON object

  • display_name string

    Name displayed in the content editor

  • maximum number

    (for Blocks field) Maximum number of components allowed inside

  • minimum number

    (for Blocks field) Minimum number of components allowed inside

  • restrict_type string

    (for Blocks field) Restrict the type of components allowed inside by tags, groups (folders), or component names.

  • restrict_components boolean

    (for Blocks and Richtext fields) Default: false. Restrict the nestable component option.

  • component_whitelist string[]

    (for Blocks, Link, and Richtext fields) An array of content type block names. For example: \["post", "page", "product"\]. Only these components are allowed.

  • component_tag_whitelist number[]

    (for Blocks and Richtext fields) An array of tag IDs. Only components with these tags are allowed.

  • component_group_whitelist string[]

    (for Blocks and Richtext fields) An array of group UUIDs. Only components that belong to these groups are allowed.

  • no_translate boolean

    (for Text and number fields) Exclude from translation export

  • rtl boolean

    (for Markdown, Text, and Textarea fields) Enable global RTL for the field

  • regex string

    (for Text field) Client Regex validation for the the field

  • max_length number

    (for Markdown, Text, and Textarea fields) Set the maximum length of the input string

  • style_options object[]

    (for Richtext field) Objects containing data about custom CSS set inside the field.

    Show child properties
    • _uid string

      UUID of the style

    • name string

      Name of the style (displayed in the UI)

    • value string

      Value of the style

  • customize_toolbar boolean

    (for Markdown and Richtext fields) true if customization of toolbar is enabled

  • toolbar string[]

    (for Markdown and Richtext fields) Array containing the value of enabled items while customizing the toolbar

  • allow_target_blank boolean

    (for Link and Richtext fields) Allow links to open in a new tab

  • allow_custom_attributes boolean

    (for Link and Richtext fields) Enable custom attributes in links

  • rich_markdown boolean

    (for Markdown field) Enable rich markdown view

  • allow_multiline boolean

    (for Markdown field) Enable empty paragraphs

  • min_value number

    (for Number field) Minimum value allowed

  • max_value number

    (for Number field) Maximum value allowed

  • decimals number

    (for Number field) The number of decimal places that appear after the point

  • steps number

    (for Number field) The interval between numbers

  • disable_time boolean

    (for Date/Time field) Default: false. Disable time selection in the date picker.

  • inline_label boolean

    (for Boolean field) Display the field’s label next to the toggle

  • exclude_empty_option boolean

    (for Single-Option and Multi-Options fields) Hide empty options in the UI

  • source enum

    (for Single-Option and Multi-Options fields)

    Possible valuesDescription
    undefinedSelf
    internal_storiesStories
    internalDatasource
    externalAPI endpoint in a datasource entries array
    internal_languagesThe languages enabled in the space
  • options object[]

    (for Single-Option, Multi-Options, and Plugin fields) Array of datasource entries. Relevant only when source is undefined (reference above).

    Show child properties
    • _uid string

      UUID of the option

    • name string

      Name of the option

    • value string

      Value of the option

  • use_uuid boolean

    (for Single-Option and Multi-Options fields) Default: true. Relevant only when source is internal_stories (reference above).

  • datasource_slug string

    (for Single-Option, Multi-Options, and Plugin fields) Define selectable datasources. Relevant only when source is internal (reference above).

  • external_datasource string

    (for Single-Option and Multi-Options fields) Define external datasource JSON URL. Relevant only when source is external (reference above).

  • folder_slug string

    (for Single-Option, Multi-Options, and References fields) Filter the selectable stories path. Relevant only when source is internal_stories (reference above). With a multilingual folder structure, add the {0} placeholder to adapt the path dynamically. For example, {0}/categories/.

  • max_options string

    (for Single-Option, Multi-Options, and References fields) Maximum selectable options

  • min_options string

    (for Single-Option, Multi-Options, and References fields) Minimum selectable options

  • filter_content_type string[]

    (for Single-Option and Multi-Options fields) An array of selectable content types. Relevant only when source is internal_stories (reference above).

  • entry_appearance string

    (for Single-Option, Multi-Options, and References fields) Select if an option appears as link (default) or card. Relevant only when source is internal_stories (reference above).

  • allow_advanced_search boolean

    (for Single-Option, Multi-Options, and References fields) Allow editors to perform advanced search in a modal window

  • is_reference_type boolean

    (for References field) true if the Multi-Options field is a References field

  • filetypes string[]

    (for Asset and Multi-Assets fields) Array of file type names. For example: \["images", "videos", "audios", "texts"\].

  • asset_folder_id number

    (for Asset and Multi-Assets fields) Numeric ID of the selected asset folder

  • allow_external_url boolean

    (for Asset and Multi-Assets fields) allow external URLs

  • email_link_type boolean

    (for Link field) Default: false. Allow emails.

  • asset_link_type boolean

    (for Link field) Default: false. Allow assets.

  • show_anchor boolean

    (for Link field) Default: false. Enable anchor field for internal links.

  • restrict_content_types boolean

    (for Link field) Restrict the content type

  • force_link_scope boolean

    (for Link field) Default: false. Restrict access to folders.

  • link_scope string

    (for Link field) Default: false. Filter the selectable folders when force_link_fields is true.

  • keys string[]

    (for Group field) An array of field keys

  • field_type string

    (for Plugin field) Name of the custom field type plugin

  • required_fields string

    (for Plugin field) Comma-separated required fields

  • image_crop boolean

    (for deprecated Image field) Activate force crop for images

  • keep_image_size boolean

    (for deprecated Image field) Keep the original image size

  • image_width string

    (for deprecated Image field) Define image width in pixels or width ratio if keep_image_size is true

  • image_height string

    (for deprecated Image field) Define image height in pixels or height ratio if keep_image_size is true

  • add_https boolean

    (for deprecated Image and File fields) Prepends https: to disallow the relative protocol

  • can_sync boolean

    Default: false. Advanced usage to sync with the field in preview.

  • exclude_from_merge boolean

    (requires the Dimensions App) Exclude merging

  • exclude_from_overwrite boolean

    (requires the Dimensions App) Exclude overwriting

  • force_merge boolean

    (requires the Dimensions App) Overwrite when merging

  • conditional_settings object[]

    Array containing an object with information about conditions set on the field

Example Object
"title": {
"type": "text",
"pos": 0,
"translatable": true,
"required": true,
"regex": "",
"description": "Description for the field",
"display_name": "",
"default_value": "",
"can_sync": false,
"rtl": false,
"no_translate": false
}