{
  "$id": "https://firefox-ci-tc.services.mozilla.com/schemas/hooks/v1/hook-definition.json#",
  "$schema": "https://firefox-ci-tc.services.mozilla.com/schemas/common/metaschema.json#",
  "additionalProperties": false,
  "description": "Definition of a hook that will create tasks when defined events occur.\n",
  "properties": {
    "bindings": {
      "$ref": "bindings.json#"
    },
    "hookGroupId": {
      "maxLength": 1000,
      "minLength": 1,
      "pattern": "^([a-zA-Z0-9-_]*)$",
      "type": "string"
    },
    "hookId": {
      "maxLength": 1000,
      "minLength": 1,
      "pattern": "^([a-zA-Z0-9-_/]*)$",
      "type": "string"
    },
    "metadata": {
      "$ref": "hook-metadata.json#"
    },
    "schedule": {
      "$ref": "schedule.json#"
    },
    "task": {
      "description": "Template for the task definition.  This is rendered using [JSON-e](https://json-e.js.org/)\nas described in [firing hooks](/docs/reference/core/hooks/firing-hooks) to produce\na task definition that is submitted to the Queue service.\n",
      "title": "Task Template",
      "type": "object"
    },
    "triggerSchema": {
      "type": "object"
    }
  },
  "required": [
    "hookGroupId",
    "hookId",
    "metadata",
    "task",
    "schedule",
    "triggerSchema"
  ],
  "title": "Hook definition",
  "type": "object"
}