{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/converly-io/json-schema/converly-io-paginated-invoices-schema.json",
  "title": "PaginatedInvoices",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/converly-io-invoices-api-openapi.yml#/components/schemas/PaginatedInvoices",
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Invoice"
      }
    },
    "has_more": {
      "type": "boolean"
    },
    "next_cursor": {
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "data",
    "has_more",
    "next_cursor"
  ],
  "$defs": {
    "Invoice": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "number": {
          "type": [
            "string",
            "null"
          ]
        },
        "date": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "amount": {
          "type": "number",
          "description": "Cents"
        },
        "currency": {
          "type": "string"
        },
        "status": {
          "type": "string",
          "enum": [
            "paid",
            "open",
            "past_due",
            "uncollectible",
            "void",
            "draft"
          ]
        },
        "pdf_url": {
          "type": [
            "string",
            "null"
          ]
        },
        "hosted_url": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "required": [
        "id",
        "number",
        "date",
        "amount",
        "currency",
        "status",
        "pdf_url",
        "hosted_url"
      ]
    }
  }
}