{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "insights/v1/events/system/report.system.memory.json",
  "title": "System: report.system.memory",
  "description": "Virtual memory metrics from the Honeybadger CLI agent. Recorded once per reporting interval.",
  "x-hb": {
    "notifiers": [
      "honeybadger-cli"
    ],
    "category": "system"
  },
  "type": "object",
  "properties": {
    "event_type": {
      "type": "string",
      "const": "report.system.memory"
    },
    "host": {
      "type": "string",
      "description": "Hostname of the machine running the agent.",
      "examples": [
        "web-1.example.com"
      ]
    },
    "ts": {
      "type": "string",
      "description": "ISO 8601 timestamp set by the CLI agent at collection time.",
      "examples": [
        "2026-06-12T14:30:00Z"
      ]
    },
    "total_bytes": {
      "type": "integer",
      "description": "Total virtual memory in bytes.",
      "examples": [
        17179869184
      ]
    },
    "used_bytes": {
      "type": "integer",
      "description": "Used memory in bytes.",
      "examples": [
        11811160064
      ]
    },
    "free_bytes": {
      "type": "integer",
      "description": "Free memory in bytes.",
      "examples": [
        1610612736
      ]
    },
    "available_bytes": {
      "type": "integer",
      "description": "Available memory in bytes (free + reclaimable).",
      "examples": [
        5368709120
      ]
    },
    "used_percent": {
      "type": "number",
      "description": "Memory usage as a percentage (0.0–100.0), rounded to 2 decimal places.",
      "examples": [
        68.75
      ]
    }
  },
  "required": [
    "event_type",
    "host",
    "total_bytes",
    "used_bytes"
  ]
}
