{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/drupal-permissions/latest.json",
  "title": "JSON schema for Drupal permissions file",
  "x-lintel": {
    "source": "https://www.schemastore.org/drupal-permissions.json",
    "sourceSha256": "c22bd72071acb59776cd102926cad36fbc7a304a0404671500d01a17ac744d82",
    "fileMatch": [
      "*.permissions.yml"
    ],
    "parsers": [
      "yaml"
    ]
  },
  "type": "object",
  "properties": {
    "permission_callbacks": {
      "title": "List of permission callbacks",
      "type": "array",
      "items": {
        "title": "A callback that return array of permissions",
        "type": "string"
      },
      "uniqueItems": true
    }
  },
  "additionalProperties": {
    "title": "Permission definition",
    "type": "object",
    "required": [
      "title"
    ],
    "properties": {
      "title": {
        "title": "The human-readable name of the permission",
        "type": "string"
      },
      "description": {
        "title": "A description of what the permission does",
        "type": "string"
      },
      "restrict access": {
        "title": "Restrict access to this permission to trusted users",
        "description": "This should be used for permissions that have inherent security risks across a variety of potential use cases (for example, the \"administer filters\" and \"bypass node access\" permissions provided by Drupal core).",
        "type": "boolean"
      }
    },
    "additionalProperties": false
  }
}
