{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/drupal-recipe/latest.json",
  "title": "New recipe",
  "x-lintel": {
    "source": "https://www.schemastore.org/drupal-recipe.json",
    "sourceSha256": "42082479fa00191591ba80085e254018cd85f3645a7612a488f3ba0ac8a63d25",
    "fileMatch": [
      "drupal-recipe.yml",
      "drupal-recipe.yaml"
    ],
    "parsers": [
      "yaml"
    ]
  },
  "type": "object",
  "properties": {
    "name": {
      "title": "User interface name for the recipe",
      "type": "string",
      "default": "''"
    },
    "description": {
      "type": "string",
      "default": "''"
    },
    "type": {
      "$ref": "#/$defs/recipeTypes",
      "title": "The type of the recipe. Used for administrative purposes.",
      "type": "string"
    },
    "recipes": {
      "type": "array",
      "title": "List of recipes that this recipe depends on. Recipes must be installed relative to the Drupal root directory.",
      "items": {
        "type": "string"
      },
      "examples": [
        "core/recipes/remote_video_media_type",
        "starshot_admin_theme"
      ]
    },
    "install": {
      "title": "List of modules to be installed.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "config": {
      "type": "object",
      "properties": {
        "import": {
          "title": "A list of configurations to be installed.",
          "description": "The key is the configuration provider and the value is the list of configuration names.",
          "type": "object",
          "additionalProperties": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            ]
          }
        },
        "actions": {
          "title": "Key/Value",
          "description": "The key is the configuration object targeted and the value is the action to be performed. For each action additional properties can be provided.",
          "type": "object",
          "additionalProperties": {
            "type": "object",
            "properties": {
              "set": {
                "$ref": "#/$defs/generic/set",
                "type": "object"
              },
              "setMultiple": {
                "$ref": "#/$defs/generic/setMultiple",
                "type": "array"
              },
              "cloneAs": {
                "$ref": "#/$defs/generic/cloneAs",
                "type": "string"
              },
              "create": {
                "$ref": "#/$defs/generic/create",
                "type": "object"
              },
              "createIfNotExists": {
                "$ref": "#/$defs/generic/createIfNotExists",
                "type": "object"
              },
              "createForEach": {
                "$ref": "#/$defs/generic/createForEach",
                "type": "object"
              },
              "createForEachIfNotExists": {
                "$ref": "#/$defs/generic/createForEachIfNotExists",
                "type": "object"
              },
              "setThirdPartySetting": {
                "$ref": "#/$defs/generic/setThirdPartySetting",
                "type": "object"
              },
              "setThirdPartySettings": {
                "$ref": "#/$defs/generic/setThirdPartySettings",
                "type": "array"
              },
              "simpleConfigUpdate": {
                "$ref": "#/$defs/generic/simpleConfigUpdate",
                "type": "object"
              }
            }
          },
          "patternProperties": {
            "block.block.*": {
              "$ref": "#/$defs/specific/block.block.*"
            },
            "core.entity_form_display.*.*.*": {
              "$ref": "#/$defs/specific/core.entity_form_display.*.*.*"
            },
            "core.entity_view_display.*.*.*": {
              "$ref": "#/$defs/specific/core.entity_view_display.*.*.*"
            },
            "contact.form.*": {
              "$ref": "#/$defs/specific/contact.form.*"
            },
            "editor.editor.*": {
              "$ref": "#/$defs/specific/editor.editor.*"
            },
            "field.field.*.*.*": {
              "$ref": "#/$defs/specific/field.field.*.*.*"
            },
            "field.storage.*.*": {
              "$ref": "#/$defs/specific/field.storage.*.*"
            },
            "workflows.workflow.*": {
              "$ref": "#/$defs/specific/workflows.workflow.*"
            },
            "user.role.*": {
              "$ref": "#/$defs/specific/user.role.*"
            }
          }
        }
      }
    },
    "content": {
      "title": "List of content to be created.",
      "description": "The contents are stored in a directory relative to the recipe file.",
      "type": "array",
      "prefixItems": [
        {
          "type": "string"
        }
      ]
    }
  },
  "required": [
    "name",
    "description",
    "type"
  ],
  "additionalProperties": true,
  "$defs": {
    "theme": {
      "defaultRegions": {
        "enum": [
          "sidebar_first",
          "sidebar_second",
          "content",
          "header",
          "primary_menu",
          "secondary_menu",
          "footer",
          "highlighted",
          "help",
          "page_top",
          "page_bottom",
          "breadcrumb"
        ]
      }
    },
    "recipeTypes": {
      "type": "string",
      "enum": [
        "Administration",
        "Block type",
        "Comment type",
        "Contact form",
        "Content field",
        "Content type",
        "Editor",
        "Maintenance",
        "Media type",
        "Performance",
        "Responsive image",
        "Search",
        "Site",
        "Taxonomy",
        "Text format",
        "Text format editor",
        "Theme",
        "User role",
        "User type",
        "Users",
        "Workflow"
      ]
    },
    "generic": {
      "cloneAs": {
        "description": "Creates a clone of any config entity with a new ID.",
        "type": "string"
      },
      "create": {
        "description": "Creates a config entity.",
        "type": "object"
      },
      "createIfNotExists": {
        "description": "Creates a config entity if it does not exist. Existence is determined by it having the same ID.",
        "type": "object"
      },
      "createForEach": {
        "description": "Loop over bundle config entities to create other config entities that are coupled to those bundles.",
        "type": "object"
      },
      "createForEachIfNotExists": {
        "description": "Extends createForEach, to create only when it doesn't exist.",
        "type": "object"
      },
      "set": {
        "description": "Changes a property of a config entity. This is a pretty low-level method and should generally only be used if no dedicated method exists. Works on all config entities.",
        "type": "object",
        "properties": {
          "property_name": {
            "description": "The property name i.e. label",
            "type": "string"
          },
          "value": {
            "description": "The property value i.e. Logged-in user",
            "type": [
              "string",
              "number",
              "boolean",
              "array"
            ]
          }
        },
        "required": [
          "property_name",
          "value"
        ]
      },
      "setMultiple": {
        "type": "array",
        "description": "The same as set, but accepts multiple property/value pairs.",
        "items": [
          {
            "$ref": "#/$defs/generic/set"
          }
        ]
      },
      "setThirdPartySetting": {
        "description": "Set third-party settings values for any config entity that can carry third-party settings.",
        "type": "object",
        "properties": {
          "module": {
            "description": "The module name",
            "type": "string"
          },
          "key": {
            "description": "The key i.e. enabled",
            "type": "string"
          },
          "value": {
            "description": "The property value i.e. true",
            "type": [
              "string",
              "number",
              "boolean",
              "array"
            ]
          }
        },
        "required": [
          "module",
          "key",
          "value"
        ]
      },
      "setThirdPartySettings": {
        "type": "array",
        "description": "The same as setThirdPartySetting, but accepts multiple property/value pairs.",
        "items": [
          {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          }
        ]
      },
      "simpleConfigUpdate": {
        "description": "Used to make updates to any configuration value.",
        "type": "object"
      }
    },
    "specific": {
      "block.block.*": {
        "type": "object",
        "properties": {
          "setRegion": {
            "$ref": "#/$defs/theme/defaultRegions",
            "description": "Sets the region in which a block should be. Which regions are available depends on which theme the block is in. Only works on blocks.",
            "type": "string",
            "default": "content"
          },
          "setStatus": {
            "description": "Sets status",
            "type": "boolean"
          },
          "setWeight": {
            "description": "Sets the weight (position relative to other blocks in the same region of the same theme) of a block. Accepts any number. Works on Blocks.",
            "type": "number"
          },
          "placeBlockInDefaultTheme": {
            "type": "object",
            "properties": {
              "id": {
                "description": "The block id",
                "type": "string"
              },
              "region": {
                "description": "The region accepts an array keyed by theme name.",
                "type": "object",
                "default": {
                  "bootstrap": "footer",
                  "olivero": "footer_top"
                }
              },
              "default_region": {
                "description": "A fallback used if no match found in the region array.",
                "type": "string",
                "default": "content"
              },
              "position": {
                "description": "Place the block before/after any blocks already in the region.",
                "type": "string",
                "enum": [
                  "first",
                  "last"
                ],
                "default": "first"
              },
              "plugin": {
                "description": "The plugin id",
                "type": "string",
                "default": "system_powered_by_block"
              }
            },
            "required": [
              "id",
              "region",
              "default_region",
              "position",
              "plugin"
            ]
          },
          "placeBlockInAdminTheme": {
            "$ref": "#/$defs/specific/block.block.*/properties/placeBlockInDefaultTheme"
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      },
      "core.entity_form_display.*.*.*": {
        "$comment": "",
        "type": "object",
        "title": "Form/View display",
        "description": "",
        "properties": {
          "hideComponent": {
            "type": "string",
            "title": "Hides a component from an entity view display or entity form display.",
            "description": "Value: The component id",
            "default": "uid"
          },
          "hideComponents": {
            "type": "array",
            "description": "Value: The list of component ids",
            "items": [
              {
                "type": "string"
              }
            ]
          },
          "setComponent": {
            "type": "object",
            "description": "Allows adding a field to an entity's view or form displays.",
            "properties": {
              "name": {
                "description": "The field id. i.e. field_tags",
                "type": "string"
              },
              "options": {
                "type": "object",
                "properties": {
                  "type": {
                    "description": "The field type. i.e. entity_reference_label",
                    "type": "string"
                  },
                  "label": {
                    "description": "Label position. i.e. above",
                    "type": "string",
                    "enum": [
                      "above",
                      "below",
                      "hidden",
                      "inline"
                    ]
                  },
                  "settings": {
                    "type": "object",
                    "properties": {
                      "link": {
                        "type": "boolean"
                      }
                    }
                  },
                  "third_party_settings": {
                    "type": "object"
                  },
                  "weight": {
                    "type": "number"
                  },
                  "region": {
                    "$ref": "#/$defs/theme/defaultRegions",
                    "type": "string"
                  }
                }
              }
            },
            "additionalProperties": false
          },
          "setComponents": {
            "type": "array",
            "description": "Allows adding adding the configuration for multiple fields.",
            "items": [
              {
                "$ref": "#/$defs/specific/core.entity_form_display.*.*.*/properties/setComponent"
              }
            ]
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      },
      "core.entity_view_display.*.*.*": {
        "$ref": "#/$defs/specific/core.entity_form_display.*.*.*"
      },
      "contact.form.*": {
        "type": "object",
        "properties": {
          "setMessage": {
            "description": "Sets the message that a contact form should display to users when they submit the form. Only works on contact forms.",
            "type": "string",
            "default": "'Hello world'"
          },
          "setRecipients": {
            "description": "Sets the email addresses that should be notified when a user submits a contact form. Accepts an array of email addresses. Only works on contact forms.",
            "type": "array",
            "items": [
              {
                "type": "string",
                "format": "email",
                "default": "me@example.com"
              }
            ]
          },
          "setRedirectPath": {
            "description": "Sets the path (URL) where users should be redirected when they submit a contact form. Must start with a slash. Only works on contact forms.",
            "type": "string",
            "default": "'/thank-you'"
          },
          "setReply": {
            "description": "Sets a message to be emailed to the person who submitted a contact form. Only works on contact forms.",
            "type": "string",
            "default": "'Thanks for your message.'"
          },
          "setWeight": {
            "description": "Sets the weight (position relative to other blocks in the same region of the same theme) of a block. Accepts any number. Works on Blocks.",
            "type": "number"
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      },
      "editor.editor.*": {
        "properties": {
          "addItemToToolbar": {
            "description": "Add a new toolbar item.",
            "type": "object",
            "properties": {
              "item_name": {
                "description": "The toolbar item name",
                "type": "string"
              },
              "position": {
                "description": "Specific the position, optionally replacing the item that's already in that position.",
                "type": "number",
                "minimum": 0
              },
              "replace": {
                "description": "If there's already something at that position, replace it.",
                "type": "boolean"
              }
            },
            "required": [
              "item_name"
            ]
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      },
      "field.field.*.*.*": {
        "properties": {
          "setDefaultValue": {
            "description": "Sets the default value of a field, which can be changed by users when editing content. Exactly what the default value should look like, varies by field type. Works on fields and base field overrides.",
            "type": "string",
            "default": "''"
          },
          "setDescription": {
            "description": "Changes the user-facing description of a field. Works on fields and base field overrides.",
            "type": "string",
            "default": "''"
          },
          "setLabel": {
            "description": "Changes the human-readable label of a field. Works on fields and base field overrides.",
            "type": "string",
            "default": "''"
          },
          "setRequired": {
            "description": "Sets whether users must enter a value for a field. Works on fields and base field overrides.",
            "type": "boolean",
            "default": true
          },
          "setTranslatable": {
            "description": "Sets whether a field should be translatable in the UI, or not. Works on fields and base field overrides. (Note that most fields are translatable by default.)",
            "type": "boolean",
            "default": true
          },
          "setSettings": {
            "description": "Changes field settings. Exactly which settings are available, and what they mean, varies by the field type. Any preexisting settings are added automatically, with the incoming settings taking precedence. Works on fields and base field overrides.",
            "type": "object",
            "properties": {
              "display_summary": {
                "type": "boolean",
                "default": true
              },
              "required_summary": {
                "type": "boolean",
                "default": true
              }
            }
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      },
      "field.storage.*.*": {
        "properties": {
          "addToAllBundles": {
            "description": "If you have a field that you want to add to every content type, but you don't know how many content types there are, or what they're called, there's an addToAllBundles config action that will automatically add a field to every content type.",
            "type": "object",
            "properties": {
              "label": {
                "type": "string",
                "default": "''"
              },
              "description": {
                "type": "string",
                "default": "''"
              },
              "fail_if_exists": {
                "description": "If field_meta_tags already exists on any content type, you'll get an error.",
                "type": "boolean",
                "default": false
              }
            }
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      },
      "workflows.workflow.*": {
        "type": "object",
        "properties": {
          "addNodeTypes": {
            "description": "If you have an entity type or entity bundle that you want to add to a content moderation workflow, you can use config actions.",
            "type": "array",
            "items": [
              {
                "description": "Opt only certain content types into moderation.",
                "type": "string"
              }
            ]
          },
          "addTaxonomyVocabularies": {
            "description": "Opt every taxonomy vocabulary into moderation.",
            "type": "string",
            "default": "'*'"
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      },
      "user.role.*": {
        "type": "object",
        "properties": {
          "grantPermission": {
            "description": "Used to add permissions to user roles.",
            "type": "string",
            "default": "''"
          },
          "grantPermissions": {
            "description": "Add multiple roles.",
            "type": "array",
            "items": [
              {
                "$ref": "#/$defs/specific/user.role.*/properties/grantPermission"
              }
            ]
          },
          "grantPermissionsForEachNodeType": {
            "description": "Grants permissions for every bundle of an entity type.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "grantPermissionsForEachTaxonomyVocabulary": {
            "description": "Grants permissions for every taxonomy vocabulary.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "grantPermissionsForEachMediaType": {
            "description": "Grants permissions for every media type.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "cloneAs": {
            "$ref": "#/$defs/generic/cloneAs"
          },
          "create": {
            "$ref": "#/$defs/generic/create"
          },
          "createIfNotExists": {
            "$ref": "#/$defs/generic/createIfNotExists"
          },
          "createForEach": {
            "$ref": "#/$defs/generic/createForEach"
          },
          "createForEachIfNotExists": {
            "$ref": "#/$defs/generic/createForEachIfNotExists"
          },
          "set": {
            "$ref": "#/$defs/generic/set"
          },
          "setMultiple": {
            "$ref": "#/$defs/generic/setMultiple"
          },
          "setThirdPartySetting": {
            "$ref": "#/$defs/generic/setThirdPartySetting"
          },
          "setThirdPartySettings": {
            "$ref": "#/$defs/generic/setThirdPartySettings"
          },
          "simpleConfigUpdate": {
            "$ref": "#/$defs/generic/simpleConfigUpdate"
          }
        },
        "additionalProperties": false
      }
    }
  }
}
