{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://heartcortex.ai/schemas/1.0/brain-offline-request.schema.json",
  "title": "brain offline request",
  "description": "Body of PUT /heart/v1/brain/offline (D36): turn auto mode on or off. Turning it on is destructive (the owner, with proof of presence). Turning it off only lowers risk.",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "enabled"
  ],
  "properties": {
    "enabled": {
      "type": "boolean"
    },
    "maxSec": {
      "type": "integer",
      "minimum": 0,
      "maximum": 2592000,
      "description": "At most card.brain.offline.maxSec. The lease's offline.maxSec may shorten it further."
    },
    "actionId": {
      "$ref": "common.schema.json#/$defs/actionId"
    },
    "presence": {
      "description": "Proof of presence for the digest of the Action named by actionId (API Standard 6.3, rule 3). Needs actionId.",
      "$ref": "common.schema.json#/$defs/presence"
    }
  },
  "dependentRequired": {
    "presence": [
      "actionId"
    ]
  }
}
