{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/modoboa/json-schema/modoboa-paginated-alias-list-schema.json",
  "title": "PaginatedAliasList",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/modoboa-aliases-api-openapi.yml#/components/schemas/PaginatedAliasList",
  "type": "object",
  "required": [
    "count",
    "results"
  ],
  "properties": {
    "count": {
      "type": "integer"
    },
    "next": {
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "previous": {
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "results": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Alias"
      }
    }
  },
  "$defs": {
    "Alias": {
      "type": "object",
      "description": "Alias serializer for v2 API.",
      "properties": {
        "pk": {
          "type": "integer",
          "readOnly": true,
          "title": "ID"
        },
        "address": {
          "type": "string",
          "format": "email"
        },
        "enabled": {
          "type": "boolean",
          "description": "Check to activate this alias"
        },
        "recipients": {
          "type": "array",
          "items": {
            "type": "string",
            "format": "email"
          },
          "description": "A list of recipient"
        },
        "expire_at": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "description": {
          "type": "string"
        },
        "creation": {
          "type": "string",
          "format": "date-time"
        },
        "last_modification": {
          "type": "string",
          "format": "date-time",
          "readOnly": true
        }
      },
      "required": [
        "address",
        "last_modification",
        "pk",
        "recipients"
      ]
    }
  }
}