{
  "name": "execution.throttle.create",
  "description": "Creates or replaces a named throttle enforced by [execution.throttle]; declaring an unchanged configuration keeps the existing throttle and its counters, while invoking the slot without arguments deletes the throttle instead",
  "signature": {
    "input": {
      "kind": "throttle-name",
      "description": "Name of the throttle to create, replace or delete",
      "required": true,
      "mode": "ValueOrExpression"
    },
    "children": {
      "limit": {
        "type": "int",
        "description": "Maximum number of invocations allowed per window; mandatory when creating a throttle, while invoking the slot without any arguments deletes the throttle instead",
        "required": false,
        "mode": "ValueOrExpression",
        "cardinality": "ZeroOrOne",
        "role": "Option",
        "projection": "Value"
      },
      "window": {
        "type": "int",
        "kind": "duration-seconds",
        "description": "Window length in seconds",
        "required": false,
        "mode": "ValueOrExpression",
        "cardinality": "ZeroOrOne",
        "default": "60",
        "role": "Option",
        "projection": "Value"
      },
      "per": {
        "type": "string",
        "description": "How to partition the limit; 'user' partitions per authenticated username, 'ip' per client IP address, and 'global' shares one limit between all callers",
        "required": false,
        "mode": "ValueOrExpression",
        "cardinality": "ZeroOrOne",
        "default": "user when authenticated, otherwise ip",
        "role": "Option",
        "projection": "Value"
      }
    }
  }
}
