{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "common.schema.json",
  "description": "Shared definitions for CSV template schemas",
  "$defs": {
    "address": {
      "type": "string",
      "pattern": "^0x[a-fA-F0-9]{40}$",
      "description": "Recipient Ethereum address"
    },
    "amount": {
      "type": "string",
      "pattern": "^[0-9]+(\\.[0-9]+)?$",
      "description": "Token amount to stream"
    },
    "timestamp": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}$",
      "description": "Timestamp (YYYY-MM-DD HH:mm)"
    },
    "duration": {
      "type": "string",
      "minLength": 1,
      "description": "Relative duration (e.g., '2 years 20 days')"
    },
    "positiveInteger": {
      "type": "string",
      "pattern": "^[1-9][0-9]*$",
      "description": "Positive integer"
    },
    "unlockPercentages": {
      "type": "string",
      "pattern": "^[0-9]+(;[0-9]+)*$",
      "description": "Semicolon-separated unlock percentages (e.g., '10;20;30;40')"
    },
    "granularity": {
      "type": "string",
      "enum": ["daily", "weekly", "yearly"],
      "description": "Step granularity for linear stepper vesting"
    }
  }
}
