{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/aisle-wedding/json-schema/aisle-wedding-registry-contribution-list-schema.json",
  "title": "RegistryContributionList",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/aisle-wedding-registry-api-openapi.yml#/components/schemas/RegistryContributionList",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "data",
    "has_more",
    "next_cursor"
  ],
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/PublicRegistryContribution"
      }
    },
    "has_more": {
      "type": "boolean"
    },
    "next_cursor": {
      "oneOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    }
  },
  "$defs": {
    "PublicRegistryContribution": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "id",
        "registry_item_id",
        "guest_id",
        "amount",
        "currency",
        "message",
        "anonymous",
        "contributor_name",
        "created_at"
      ],
      "properties": {
        "id": {
          "type": "string",
          "pattern": "^pay_.+$"
        },
        "registry_item_id": {
          "oneOf": [
            {
              "type": "string",
              "pattern": "^reg_.+$"
            },
            {
              "type": "null"
            }
          ]
        },
        "guest_id": {
          "oneOf": [
            {
              "type": "string",
              "pattern": "^gst_.+$"
            },
            {
              "type": "null"
            }
          ]
        },
        "amount": {
          "type": "string",
          "pattern": "^\\d+(?:\\.\\d{1,2})?$",
          "description": "A decimal currency amount. It is serialized as a string."
        },
        "currency": {
          "type": "string"
        },
        "message": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "anonymous": {
          "type": "boolean"
        },
        "contributor_name": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "created_at": {
          "$ref": "#/$defs/Timestamp"
        }
      }
    },
    "Timestamp": {
      "type": "string",
      "format": "date-time",
      "description": "An RFC 3339 UTC timestamp with milliseconds."
    }
  }
}