{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.myhacks.org/resources/personal-os-schema.json",
  "$comment": "Licensed under the MIT License: https://opensource.org/license/mit",
  "title": "myhacks Personal OS",
  "description": "An open, vendor-neutral model for connecting goals, projects, habits and tasks. MIT License.",
  "type": "object",
  "required": ["version", "items"],
  "properties": {
    "version": { "const": "1.0" },
    "reviewedAt": { "type": ["string", "null"], "format": "date" },
    "items": {
      "type": "array",
      "items": {
        "type": "object",
        "required": ["id", "type", "title", "status"],
        "properties": {
          "id": { "type": "string", "minLength": 1 },
          "type": { "enum": ["goal", "project", "habit", "task"] },
          "title": { "type": "string", "minLength": 1 },
          "parentId": { "type": ["string", "null"] },
          "status": { "enum": ["idea", "active", "next", "paused", "complete", "dropped"] },
          "nextAction": { "type": ["string", "null"] },
          "context": { "type": ["string", "null"] },
          "reviewDate": { "type": ["string", "null"], "format": "date" },
          "notes": { "type": ["string", "null"] }
        },
        "additionalProperties": false
      }
    }
  },
  "additionalProperties": false
}
