---
agentTools:
  projectIndex: https://copperx.readme.io/llms.txt
---

# List of all invoices

Returns the list of all invoices

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "paths": {
    "/api/v1/invoices": {
      "get": {
        "operationId": "InvoiceController_getAll",
        "summary": "List of all invoices",
        "description": "Returns the list of all invoices",
        "parameters": [
          {
            "name": "page",
            "required": false,
            "in": "query",
            "example": 1,
            "description": "Page number. Starts from 1",
            "schema": {
              "type": "number"
            }
          },
          {
            "name": "limit",
            "required": false,
            "in": "query",
            "example": 10,
            "description": "Number of items per page",
            "schema": {
              "type": "number"
            }
          },
          {
            "name": "createdAt",
            "required": false,
            "in": "query",
            "description": "Filter by created date",
            "example": {
              "gt": "2020-01-01"
            },
            "style": "deepObject",
            "explode": true,
            "schema": {
              "$ref": "#/components/schemas/DateFilterDto"
            }
          },
          {
            "name": "ids",
            "required": false,
            "in": "query",
            "example": [
              "c3611c05-df51-4b47-b601-f2eac02f4ef0",
              "c3611c05-df51-4b47-b601-f2eac02f4ef2"
            ],
            "description": "Filter by id. Returns items with given ids",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "customerId",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "subscriptionId",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "dueDate",
            "required": false,
            "in": "query",
            "style": "deepObject",
            "explode": true,
            "schema": {
              "$ref": "#/components/schemas/DateFilterDto"
            }
          },
          {
            "name": "includes",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/PageDto"
                    },
                    {
                      "properties": {
                        "data": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/InvoiceDto"
                          }
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "500": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorDto"
                }
              }
            }
          }
        },
        "tags": [
          "Invoices"
        ],
        "security": [
          {
            "bearer": []
          }
        ]
      }
    }
  },
  "info": {
    "title": "Copperx API",
    "description": "Copperx APIs allows you to access to manage payments, transactions and more in a simple way. Our APIs are easy to use and provide an intuitive APIs for developers to create powerful applications.",
    "version": "v0.0.0",
    "contact": {
      "name": "Copperx",
      "url": "https://t.me/+bVxXaalfhF8wMDFl",
      "email": "support@copperx.io"
    }
  },
  "servers": [
    {
      "url": "https://api.copperx.dev",
      "description": "Test"
    },
    {
      "url": "https://api.copperx.io",
      "description": "Production"
    }
  ],
  "components": {
    "securitySchemes": {
      "bearer": {
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "type": "http"
      }
    },
    "schemas": {
      "ErrorDto": {
        "type": "object",
        "properties": {
          "message": {
            "type": "object"
          },
          "statusCode": {
            "type": "number"
          },
          "error": {
            "type": "string"
          }
        },
        "required": [
          "message",
          "statusCode",
          "error"
        ]
      },
      "PaymentMethodType": {
        "type": "string",
        "enum": [
          "superfluid",
          "wallet",
          "allowance_based_recurring",
          "stripe",
          "binance_pay"
        ]
      },
      "CryptoCurrency": {
        "type": "string",
        "enum": [
          "usdc",
          "usdt",
          "pyusd",
          "eurc",
          "brett",
          "dai",
          "btc",
          "eth",
          "matic",
          "bnb",
          "sol",
          "busd",
          "trx",
          "food",
          "bonk",
          "wif",
          "goat",
          "spx",
          "truf",
          "pengu"
        ]
      },
      "CheckoutSessionSplitWithdrawalAddressDto": {
        "type": "object",
        "properties": {
          "splitPercentage": {
            "type": "number",
            "minimum": 0,
            "maximum": 100,
            "example": 1
          },
          "address": {
            "type": "string",
            "description": "The withdrawal address for the split percentage"
          }
        },
        "required": [
          "splitPercentage",
          "address"
        ]
      },
      "PaymentSettingChainDto": {
        "type": "object",
        "properties": {
          "chainId": {
            "type": "number",
            "example": 1
          },
          "blacklistCurrencies": {
            "type": "array",
            "description": "The list of currencies to disable for the payment. Note: This field is only used for checkout session API atm.",
            "example": [
              "usdc"
            ],
            "items": {
              "$ref": "#/components/schemas/CryptoCurrency"
            }
          },
          "withdrawalAddress": {
            "type": "string",
            "description": "This is optional, default withdrawal address configured in dashboard under settings > payment methods is used. The custom withdrawal address to use for this chain instead of stored default withdrawal address."
          },
          "withdrawalAddresses": {
            "description": "The list of withdrawal addresses to split the payment. If provided, the sum of all split percentages should be 100.",
            "minItems": 2,
            "maxItems": 4,
            "example": [
              {
                "splitPercentage": 20,
                "address": "0x898bf05dfec6a2cfbfda2877ff759d62beed7fe7"
              },
              {
                "splitPercentage": 80,
                "address": "0xa7d770a5c4276a4d85caba7bea9a1fcbd3672db7"
              }
            ],
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CheckoutSessionSplitWithdrawalAddressDto"
            }
          }
        },
        "required": [
          "chainId"
        ]
      },
      "PaymentSettingDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "paymentMethodTypes": {
            "type": "array",
            "description": "A list of the types of payment methods",
            "example": "wallet",
            "minItems": 1,
            "maxItems": 1,
            "items": {
              "$ref": "#/components/schemas/PaymentMethodType"
            }
          },
          "allowedChains": {
            "description": "The list of chains allowed for the payment. If not provided, all chains supported by the organization are enabled.",
            "example": [
              {
                "chainId": 137
              }
            ],
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PaymentSettingChainDto"
            }
          },
          "allowedCurrencies": {
            "type": "array",
            "description": "The list of currencies allowed for the payment.",
            "example": [
              "usdc",
              "usdt"
            ],
            "items": {
              "$ref": "#/components/schemas/CryptoCurrency"
            }
          },
          "preferredChainId": {
            "type": "number",
            "example": 1,
            "description": "The preferred chain's id"
          },
          "preferredCurrency": {
            "description": "The preferred currency for payment",
            "$ref": "#/components/schemas/CryptoCurrency"
          },
          "allowSwap": {
            "type": "boolean",
            "description": "Whether the user can swap the payment currency",
            "default": false
          },
          "applyFee": {
            "type": "boolean",
            "description": "Whether add a application fee to the user payment",
            "default": false
          },
          "feePercentage": {
            "type": "number",
            "minimum": 0,
            "maximum": 100,
            "example": 1,
            "description": "Percent that will be added to subtotal as a fee"
          },
          "applyGasFee": {
            "type": "boolean",
            "description": "Whether add a transaction fee to the user payment",
            "default": false
          },
          "allowSplitPayments": {
            "type": "boolean",
            "description": "Whether the user can split the payment"
          },
          "slippagePercentage": {
            "type": "number",
            "minimum": 0,
            "maximum": 100,
            "example": 1,
            "description": "The slippage percentage allowed for swaps and withdrawals",
            "default": 10
          }
        },
        "required": [
          "id",
          "feePercentage"
        ]
      },
      "AddressDetailDto": {
        "type": "object",
        "properties": {
          "line1": {
            "type": "string"
          },
          "line2": {
            "type": "string"
          },
          "city": {
            "type": "string"
          },
          "state": {
            "type": "string"
          },
          "postalCode": {
            "type": "string"
          },
          "country": {
            "type": "string"
          }
        }
      },
      "Interval": {
        "type": "string",
        "enum": [
          "day",
          "week",
          "month",
          "year"
        ]
      },
      "EntityVisibility": {
        "type": "string",
        "enum": [
          10,
          20
        ]
      },
      "PriceType": {
        "type": "string",
        "enum": [
          "one_time",
          "recurring",
          "streaming"
        ]
      },
      "Currency": {
        "type": "string",
        "enum": [
          "usdc",
          "usdt",
          "pyusd",
          "eurc",
          "brett",
          "dai",
          "btc",
          "eth",
          "matic",
          "bnb",
          "sol",
          "busd",
          "trx",
          "food",
          "bonk",
          "wif",
          "goat",
          "spx",
          "truf",
          "pengu",
          "usd",
          "inr"
        ]
      },
      "FullAddressDetailDto": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The name"
          },
          "email": {
            "type": "string",
            "description": "The email"
          },
          "phone": {
            "type": "string",
            "description": "The phone"
          },
          "organizationName": {
            "type": "string",
            "description": "The organization name"
          },
          "address": {
            "description": "The address",
            "allOf": [
              {
                "$ref": "#/components/schemas/AddressDetailDto"
              }
            ]
          }
        }
      },
      "TaxIdDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "value": {
            "type": "string"
          },
          "country": {
            "type": "string"
          },
          "customerId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          }
        },
        "required": [
          "id",
          "customerId"
        ]
      },
      "TaxIdsDto": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TaxIdDto"
            }
          }
        }
      },
      "CustomerDto": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The name"
          },
          "email": {
            "type": "string",
            "description": "The email"
          },
          "phone": {
            "type": "string",
            "description": "The phone"
          },
          "organizationName": {
            "type": "string",
            "description": "The organization name"
          },
          "address": {
            "description": "The address",
            "allOf": [
              {
                "$ref": "#/components/schemas/AddressDetailDto"
              }
            ]
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0",
            "description": "Customer's id"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string",
            "description": "Customer's created at"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string",
            "description": "Customer's updated at"
          },
          "customerReferenceId": {
            "type": "string",
            "description": "Customer's reference id"
          },
          "shipping": {
            "description": "Customer's shipping address",
            "allOf": [
              {
                "$ref": "#/components/schemas/FullAddressDetailDto"
              }
            ]
          },
          "taxIds": {
            "$ref": "#/components/schemas/TaxIdsDto"
          },
          "visibility": {
            "description": "Customer's visibility. If Dashboard then displayed on dashboard UI. If API then only returned in API response only.",
            "$ref": "#/components/schemas/EntityVisibility"
          },
          "metadata": {
            "type": "object",
            "description": "Customer's metadata"
          },
          "customerNumber": {
            "type": "string",
            "description": "Customer number assigned by the system"
          }
        },
        "required": [
          "id",
          "customerNumber"
        ]
      },
      "BillingScheme": {
        "type": "string",
        "enum": [
          "per_unit"
        ]
      },
      "RecurringUsageType": {
        "type": "string",
        "enum": [
          "licensed"
        ]
      },
      "PublicProductDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "name": {
            "type": "string",
            "description": "The name of the product. Displayed on the checkout page"
          },
          "description": {
            "type": "string",
            "description": "The description of the product. Displayed on the checkout page"
          },
          "isActive": {
            "type": "boolean",
            "description": "Whether the product is currently active"
          },
          "images": {
            "maxItems": 8,
            "description": "The url of product images. Displayed on the checkout page",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "publicImages": {
            "description": "Product images with absolute public url",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "unitLabel": {
            "type": "string",
            "description": "The label of the unit of the product. Displayed on the checkout page"
          },
          "url": {
            "type": "string",
            "description": "The url of the product"
          },
          "defaultPriceId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0",
            "description": "Product's default price id"
          },
          "metadata": {
            "type": "object",
            "description": "The metadata of the product"
          },
          "visibility": {
            "description": "The visibility of the product",
            "$ref": "#/components/schemas/EntityVisibility"
          }
        },
        "required": [
          "id",
          "name"
        ]
      },
      "PublicPriceDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "billingScheme": {
            "description": "The billing scheme to use for this price",
            "$ref": "#/components/schemas/BillingScheme"
          },
          "currency": {
            "description": "The currency symbol",
            "$ref": "#/components/schemas/CryptoCurrency"
          },
          "productId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0",
            "description": "Product's id"
          },
          "interval": {
            "description": "The interval at which to bill for this price. Only required for subscriptions",
            "$ref": "#/components/schemas/Interval"
          },
          "intervalCount": {
            "type": "number",
            "example": 1,
            "description": "It is used to determine the frequency at which the subscription is billed. Only required for subscriptions"
          },
          "isActive": {
            "type": "boolean",
            "description": "Whether the price is currently active"
          },
          "usageType": {
            "description": "The usage type of the price.",
            "$ref": "#/components/schemas/RecurringUsageType"
          },
          "type": {
            "description": "The type of the price",
            "$ref": "#/components/schemas/PriceType"
          },
          "unitAmount": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807",
            "description": "The unit amount in 8 decimals, represented as a whole integer. If not provided, the unit amount will be calculated from unit_amount_decimal."
          },
          "unitAmountDecimal": {
            "type": "string"
          },
          "customUnitMax": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807",
            "description": "The maximum amount that can be billed per unit for this price. Only if unit amount is not provided"
          },
          "customUnitMin": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807",
            "description": "The minimum amount that can be billed per unit for this price. Only if unit amount is not provided"
          },
          "customPreset": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807",
            "description": "The default amount to fill in the amount field for this price on checkout. Only if unit amount is not provided"
          },
          "customUnitAmountSuggestions": {
            "description": "Amount suggestions for this price. Only if unit amount is not provided",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "product": {
            "description": "The product this price belongs to",
            "allOf": [
              {
                "$ref": "#/components/schemas/PublicProductDto"
              }
            ]
          },
          "metadata": {
            "type": "object",
            "description": "A set of key-value pairs that you can attach to an object. It can be useful for storing additional information about the object in a structured format."
          },
          "visibility": {
            "description": "The visibility of the price. If dashboard, the price is visible in the dashboard",
            "$ref": "#/components/schemas/EntityVisibility"
          }
        },
        "required": [
          "id",
          "currency",
          "productId",
          "type",
          "product"
        ]
      },
      "TaxRateType": {
        "type": "string",
        "enum": [
          "exclusive",
          "inclusive"
        ]
      },
      "LineTaxRateDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string",
            "description": "The name of the tax rate."
          },
          "description": {
            "type": "string",
            "description": "The description of the tax rate."
          },
          "country": {
            "type": "string",
            "description": "The country of the tax rate."
          },
          "percentage": {
            "type": "number",
            "minimum": 0,
            "maximum": 100,
            "example": 1,
            "description": "Percent that will be added to subtotal as a tax."
          },
          "type": {
            "description": "The type of the tax rate.",
            "$ref": "#/components/schemas/TaxRateType"
          },
          "isDefault": {
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "percentage",
          "type",
          "isDefault"
        ]
      },
      "SuperTokenDto": {
        "type": "object",
        "properties": {
          "address": {
            "type": "string",
            "description": "SuperToken's address"
          },
          "decimals": {
            "type": "number",
            "example": 1
          },
          "symbol": {
            "type": "string",
            "description": "SuperToken's symbol"
          }
        },
        "required": [
          "address",
          "decimals",
          "symbol"
        ]
      },
      "ChainType": {
        "type": "string",
        "enum": [
          "evm",
          "solana",
          "tron",
          "stripe",
          "binance_pay"
        ]
      },
      "ChainSlimDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "number",
            "example": 1,
            "description": "Chain id"
          },
          "name": {
            "type": "string",
            "description": "Chain name"
          },
          "icon": {
            "type": "string",
            "description": "Chain icon"
          },
          "currency": {
            "description": "Chain currency symbol",
            "$ref": "#/components/schemas/Currency"
          },
          "blockExplorerTransactionUrl": {
            "type": "string",
            "description": "Chain block explorer transaction url"
          },
          "blockExplorerName": {
            "type": "string",
            "description": "Chain block explorer name"
          },
          "type": {
            "description": "Chain type",
            "$ref": "#/components/schemas/ChainType"
          },
          "isBeta": {
            "type": "boolean",
            "description": "Is beta asset"
          }
        },
        "required": [
          "id",
          "name",
          "icon",
          "currency",
          "blockExplorerTransactionUrl",
          "blockExplorerName",
          "type",
          "isBeta"
        ]
      },
      "CheckoutSessionAssetDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "address": {
            "type": "string"
          },
          "chainId": {
            "type": "number",
            "example": 1
          },
          "currency": {
            "$ref": "#/components/schemas/Currency"
          },
          "symbol": {
            "type": "string"
          },
          "decimals": {
            "type": "number",
            "example": 1
          },
          "coingeckoId": {
            "type": "string"
          },
          "isPublic": {
            "type": "boolean"
          },
          "superToken": {
            "$ref": "#/components/schemas/SuperTokenDto"
          },
          "chain": {
            "$ref": "#/components/schemas/ChainSlimDto"
          }
        },
        "required": [
          "id",
          "name",
          "address",
          "chainId",
          "currency",
          "symbol",
          "decimals",
          "isPublic",
          "chain"
        ]
      },
      "PaymentIntentStatus": {
        "type": "string",
        "enum": [
          "requires_payment_method",
          "requires_confirmation",
          "requires_action",
          "processing",
          "requires_capture",
          "canceled",
          "succeeded"
        ]
      },
      "AssetDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Asset id"
          },
          "name": {
            "type": "string",
            "description": "Asset name"
          },
          "chainId": {
            "type": "number",
            "example": 1,
            "description": "Asset chain id"
          },
          "address": {
            "type": "string",
            "description": "Asset address on chain"
          },
          "currency": {
            "description": "Asset currency symbol",
            "$ref": "#/components/schemas/Currency"
          },
          "symbol": {
            "type": "string",
            "description": "Asset symbol"
          },
          "decimals": {
            "type": "number",
            "example": 1,
            "description": "Asset decimals in which it is represented on chain"
          },
          "coingeckoId": {
            "type": "string",
            "description": "Asset coingecko id"
          },
          "superToken": {
            "description": "SuperToken data",
            "allOf": [
              {
                "$ref": "#/components/schemas/SuperTokenDto"
              }
            ]
          },
          "isEIP5827Supported": {
            "type": "boolean",
            "description": "Is EIP5827 supported"
          }
        },
        "required": [
          "id",
          "name",
          "chainId",
          "address",
          "currency",
          "symbol",
          "decimals",
          "isEIP5827Supported"
        ]
      },
      "PaymentMethodDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "assetId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "asset": {
            "$ref": "#/components/schemas/AssetDto"
          },
          "type": {
            "$ref": "#/components/schemas/PaymentMethodType"
          },
          "accountAddress": {
            "type": "string"
          },
          "billingDetails": {
            "$ref": "#/components/schemas/FullAddressDetailDto"
          },
          "customerId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "options": {
            "type": "object"
          }
        },
        "required": [
          "id",
          "assetId",
          "asset",
          "type"
        ]
      },
      "TransactionType": {
        "type": "string",
        "enum": [
          "incoming",
          "outgoing",
          "event",
          "transfer"
        ]
      },
      "TransactionDto": {
        "type": "object",
        "properties": {
          "type": {
            "description": "Transaction type",
            "$ref": "#/components/schemas/TransactionType"
          },
          "transactionRelayId": {
            "type": "string",
            "description": "Transaction relay id"
          },
          "transactionHash": {
            "type": "string",
            "description": "Transaction hash"
          },
          "nonce": {
            "type": "number",
            "example": 1,
            "description": "Transaction nonce"
          },
          "gasLimit": {
            "type": "number",
            "example": 1,
            "description": "Transaction gas limit used in payment"
          },
          "validUntil": {
            "type": "string",
            "description": "Transaction valid until"
          },
          "fromAddress": {
            "type": "string",
            "description": "Transaction from address"
          },
          "toAddress": {
            "type": "string",
            "description": "Transaction to address"
          },
          "currency": {
            "description": "Transaction currency",
            "$ref": "#/components/schemas/Currency"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string",
            "description": "Transaction created at"
          },
          "amount": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807",
            "description": "Transaction amount in 8 decimals"
          },
          "amountRaw": {
            "type": "string",
            "description": "Transaction amount raw received from alchemy"
          },
          "assetId": {
            "type": "string",
            "description": "Transaction asset id"
          },
          "asset": {
            "$ref": "#/components/schemas/CheckoutSessionAssetDto"
          },
          "transactionUrl": {
            "type": "string",
            "description": "Transaction url"
          }
        },
        "required": [
          "type",
          "fromAddress",
          "toAddress",
          "currency",
          "amountRaw",
          "assetId",
          "asset"
        ]
      },
      "PaymentReceiptDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "organizationId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "paymentIntentId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "name": {
            "type": "string"
          },
          "receiptNumber": {
            "type": "string"
          },
          "uri": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "organizationId",
          "paymentIntentId",
          "receiptNumber"
        ]
      },
      "StripeDataDto": {
        "type": "object",
        "properties": {
          "paymentIntentId": {
            "type": "string"
          },
          "receiptUrl": {
            "type": "string"
          },
          "cardLast4": {
            "type": "string"
          },
          "displayName": {
            "type": "string"
          }
        }
      },
      "PaymentIntentDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "organizationId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "amount": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "amountReceived": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "currency": {
            "$ref": "#/components/schemas/Currency"
          },
          "status": {
            "$ref": "#/components/schemas/PaymentIntentStatus"
          },
          "paymentMethodId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "description": {
            "type": "string"
          },
          "paymentMethod": {
            "$ref": "#/components/schemas/PaymentMethodDto"
          },
          "paymentMethodTypes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PaymentMethodType"
            }
          },
          "transferAccountAddress": {
            "type": "string"
          },
          "transactions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TransactionDto"
            }
          },
          "paymentReceipt": {
            "$ref": "#/components/schemas/PaymentReceiptDto"
          },
          "canceledAt": {
            "format": "date-time",
            "type": "string"
          },
          "cancellationReason": {
            "type": "string"
          },
          "stripe": {
            "$ref": "#/components/schemas/StripeDataDto"
          },
          "isMarkRefunded": {
            "type": "boolean",
            "nullable": true
          },
          "markRefundedAt": {
            "format": "date-time",
            "type": "string",
            "nullable": true
          },
          "markRefundedComment": {
            "type": "string",
            "nullable": true
          }
        },
        "required": [
          "id",
          "organizationId",
          "status",
          "paymentMethodId",
          "transactions"
        ]
      },
      "DateFilterDto": {
        "type": "object",
        "properties": {
          "isnull": {
            "type": "boolean",
            "description": "Returns null values"
          },
          "notnull": {
            "type": "boolean",
            "description": "Returns not null values"
          },
          "gt": {
            "format": "date-time",
            "type": "string",
            "description": "Returns values greater than the given date"
          },
          "gte": {
            "format": "date-time",
            "type": "string",
            "description": "Returns values greater than or equal to the given date"
          },
          "lt": {
            "format": "date-time",
            "type": "string",
            "description": "Returns values less than the given date"
          },
          "lte": {
            "format": "date-time",
            "type": "string",
            "description": "Returns values less than or equal to the given date"
          }
        }
      },
      "PaginationFilterDto": {
        "type": "object",
        "properties": {
          "page": {
            "type": "number",
            "minimum": 1,
            "example": 1,
            "default": 1,
            "description": "Page number. Starts from 1"
          },
          "limit": {
            "type": "number",
            "minimum": 1,
            "maximum": 200,
            "example": 10,
            "default": 200,
            "description": "Number of items per page"
          },
          "createdAt": {
            "description": "Filter by created date",
            "example": {
              "gt": "2020-01-01"
            },
            "allOf": [
              {
                "$ref": "#/components/schemas/DateFilterDto"
              }
            ]
          }
        }
      },
      "PageDto": {
        "type": "object",
        "properties": {
          "page": {
            "type": "number",
            "example": 1,
            "default": 1,
            "description": "Page number. Starts from 1"
          },
          "limit": {
            "type": "number",
            "example": 10,
            "default": 200,
            "description": "Number of items per page"
          },
          "count": {
            "type": "number",
            "example": 1
          },
          "hasMore": {
            "type": "boolean"
          },
          "query": {
            "$ref": "#/components/schemas/PaginationFilterDto"
          },
          "data": {
            "type": "array",
            "items": {
              "type": "object"
            }
          }
        },
        "required": [
          "page",
          "limit",
          "count",
          "hasMore",
          "data"
        ]
      },
      "InvoiceCustomFieldsDto": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "value"
        ]
      },
      "InvoiceCustomFieldDto": {
        "type": "object",
        "properties": {
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/InvoiceCustomFieldsDto"
            }
          }
        }
      },
      "InvoiceCollectionMethod": {
        "type": "string",
        "enum": [
          "charge_automatically",
          "send_invoice"
        ]
      },
      "InvoiceType": {
        "type": "string",
        "enum": [
          "one_time",
          "recurring"
        ]
      },
      "InvoiceStatus": {
        "type": "string",
        "enum": [
          "draft",
          "open",
          "paid",
          "void",
          "uncollectible"
        ]
      },
      "InvoicePriceItemDto": {
        "type": "object",
        "properties": {
          "description": {
            "type": "string"
          },
          "periodStart": {
            "format": "date-time",
            "type": "string"
          },
          "periodEnd": {
            "format": "date-time",
            "type": "string"
          },
          "quantity": {
            "type": "number",
            "example": 1
          },
          "price": {
            "$ref": "#/components/schemas/PublicPriceDto"
          },
          "taxRates": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LineTaxRateDto"
            }
          },
          "amountTotal": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "amountSubtotal": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "amountTax": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "currency": {
            "$ref": "#/components/schemas/Currency"
          }
        },
        "required": [
          "price"
        ]
      },
      "InvoicePriceItemsDto": {
        "type": "object",
        "properties": {
          "object": {
            "type": "string"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/InvoicePriceItemDto"
            }
          }
        }
      },
      "InvoiceBillingReason": {
        "type": "string",
        "enum": [
          "subscription_cycle",
          "subscription_create",
          "subscription_update",
          "subscription",
          "manual",
          "upcoming",
          "subscription_threshold"
        ]
      },
      "ErrorCode": {
        "type": "string",
        "enum": [
          "account_closed",
          "account_information_mismatch",
          "account_invalid",
          "account_number_invalid",
          "amount_too_large",
          "amount_too_small",
          "api_key_expired",
          "authentication_required",
          "balance_insufficient",
          "account_bad_routing_numbers",
          "account_declined",
          "account_exists",
          "account_restricted",
          "account_unusable",
          "account_unverified",
          "billing_invalid_mandate",
          "capture_charge_authorization_expired",
          "capture_unauthorized_payment",
          "charge_already_captured",
          "charge_already_refunded",
          "charge_disputed",
          "charge_exceeds_source_limit",
          "charge_expired_for_capture",
          "charge_invalid_parameter",
          "charge_not_refundable",
          "clearing_code_unsupported",
          "country_code_invalid",
          "country_unsupported",
          "coupon_expired",
          "customer_max_payment_methods",
          "customer_max_subscriptions",
          "debit_not_authorized",
          "email_invalid",
          "expired_card",
          "idempotency_key_in_use",
          "incorrect_address",
          "incorrect_number",
          "insufficient_funds",
          "intent_invalid_state",
          "intent_verification_method_missing",
          "invalid_characters",
          "invalid_charge_amount",
          "invalid_source_usage",
          "invoice_no_customer_line_items",
          "invoice_no_payment_method_types",
          "invoice_no_subscription_line_items",
          "invoice_not_editable",
          "invoice_on_behalf_of_not_editable",
          "invoice_payment_intent_requires_action",
          "invoice_upcoming_none",
          "livemode_mismatch",
          "lock_timeout",
          "missing",
          "no_account",
          "parameter_invalid_empty",
          "parameter_invalid_integer",
          "parameter_invalid_string_blank",
          "parameter_invalid_string_empty",
          "parameter_missing",
          "parameter_unknown",
          "parameters_exclusive",
          "payment_intent_action_required",
          "payment_intent_authentication_failure",
          "payment_intent_incompatible_payment_method",
          "payment_intent_invalid_parameter",
          "payment_intent_mandate_invalid",
          "payment_intent_payment_attempt_expired",
          "payment_intent_payment_attempt_failed",
          "payment_intent_unexpected_state",
          "payment_method_billing_details_address_missing",
          "payment_method_configuration_failures",
          "payment_method_currency_mismatch",
          "payment_method_customer_decline",
          "payment_method_invalid_parameter",
          "payment_method_invalid_parameter_testmode",
          "payment_method_not_available",
          "payment_method_provider_decline",
          "payment_method_provider_timeout",
          "payment_method_unactivated",
          "payment_method_unexpected_state",
          "payment_method_unsupported_type",
          "payout_reconciliation_not_ready",
          "payouts_limit_exceeded",
          "payouts_not_allowed",
          "postal_code_invalid",
          "processing_error",
          "product_inactive",
          "progressive_onboarding_limit_exceeded",
          "rate_limit",
          "refer_to_customer",
          "refund_disputed_payment",
          "resource_already_exists",
          "resource_missing",
          "return_intent_already_processed",
          "routing_number_invalid",
          "secret_key_required",
          "setup_attempt_failed",
          "setup_intent_authentication_failure",
          "setup_intent_invalid_parameter",
          "setup_intent_mandate_invalid",
          "setup_intent_setup_attempt_expired",
          "setup_intent_unexpected_state",
          "shipping_calculation_failed",
          "sku_inactive",
          "status_transition_invalid",
          "tax_id_invalid",
          "taxes_calculation_failed",
          "testmode_charges_only",
          "tls_version_unsupported",
          "token_already_used",
          "token_in_use",
          "transfer_source_balance_parameters_mismatch",
          "transfers_not_allowed",
          "url_invalid"
        ]
      },
      "PaymentIntentErrorType": {
        "type": "string",
        "enum": [
          "api_error",
          "card_error",
          "idempotency_error",
          "invalid_request_error",
          "chain_error",
          "unknown"
        ]
      },
      "PaymentIntentAttemptDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "errorCode": {
            "$ref": "#/components/schemas/ErrorCode"
          },
          "type": {
            "$ref": "#/components/schemas/PaymentIntentErrorType"
          },
          "declineCode": {
            "type": "string"
          },
          "paymentIntentId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "paymentMethodType": {
            "$ref": "#/components/schemas/PaymentMethodType"
          },
          "docUrl": {
            "type": "string"
          },
          "status": {
            "$ref": "#/components/schemas/PaymentIntentStatus"
          }
        },
        "required": [
          "id",
          "type",
          "status"
        ]
      },
      "InvoiceDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "organizationId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "description": {
            "type": "string"
          },
          "total": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "subTotal": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "currency": {
            "$ref": "#/components/schemas/CryptoCurrency"
          },
          "customerId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "customer": {
            "$ref": "#/components/schemas/CustomerDto"
          },
          "autoAdvance": {
            "type": "boolean"
          },
          "collectionMethod": {
            "$ref": "#/components/schemas/InvoiceCollectionMethod"
          },
          "invoiceType": {
            "$ref": "#/components/schemas/InvoiceType"
          },
          "customFields": {
            "$ref": "#/components/schemas/InvoiceCustomFieldDto"
          },
          "paymentSettingId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "paymentSetting": {
            "$ref": "#/components/schemas/PaymentSettingDto"
          },
          "status": {
            "$ref": "#/components/schemas/InvoiceStatus"
          },
          "attempted": {
            "type": "boolean"
          },
          "attemptCount": {
            "type": "number",
            "example": 1
          },
          "nextPaymentAttempt": {
            "format": "date-time",
            "type": "string"
          },
          "dueDate": {
            "format": "date-time",
            "type": "string"
          },
          "footer": {
            "type": "string"
          },
          "fromInvoiceId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "latestRevisionId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "invoicePdfUrl": {
            "type": "string"
          },
          "invoiceNumber": {
            "type": "string"
          },
          "paid": {
            "type": "boolean"
          },
          "paidOutOfBand": {
            "type": "boolean"
          },
          "metadata": {
            "type": "object"
          },
          "clientReferenceId": {
            "type": "string"
          },
          "lineItems": {
            "$ref": "#/components/schemas/InvoicePriceItemsDto"
          },
          "finalizedAt": {
            "format": "date-time",
            "type": "string"
          },
          "paidAt": {
            "format": "date-time",
            "type": "string"
          },
          "markedUncollectibleAt": {
            "format": "date-time",
            "type": "string"
          },
          "visibility": {
            "$ref": "#/components/schemas/EntityVisibility"
          },
          "paymentIntentId": {
            "type": "string",
            "format": "uuid",
            "example": "c3611c05-df51-4b47-b601-f2eac02f4ef0"
          },
          "url": {
            "type": "string",
            "description": "The URL to redirect the customer to pay invoice"
          },
          "subscriptionId": {
            "type": "string"
          },
          "periodStart": {
            "format": "date-time",
            "type": "string"
          },
          "periodEnd": {
            "format": "date-time",
            "type": "string"
          },
          "billingReason": {
            "$ref": "#/components/schemas/InvoiceBillingReason"
          },
          "allowPromotionCodes": {
            "type": "boolean",
            "description": "Enables user redeemable promotion codes."
          },
          "finalizeScheduleAt": {
            "format": "date-time",
            "type": "string",
            "description": "The date on which invoice will be finalize and send"
          },
          "totalTax": {
            "format": "int64",
            "type": "integer",
            "example": "9223372036854775807"
          },
          "paymentIntent": {
            "$ref": "#/components/schemas/PaymentIntentDto"
          },
          "paymentIntentAttempt": {
            "description": "The payment intent associated with the session. Payment intent is created when the session is created.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PaymentIntentAttemptDto"
            }
          },
          "taxRateIds": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "id",
          "organizationId",
          "customerId",
          "customer",
          "autoAdvance",
          "collectionMethod",
          "paymentSettingId",
          "paymentSetting",
          "status",
          "attempted",
          "paid",
          "lineItems",
          "url",
          "billingReason"
        ]
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "_id": {
    "buffer": {
      "0": 99,
      "1": 181,
      "2": 177,
      "3": 27,
      "4": 23,
      "5": 171,
      "6": 139,
      "7": 0,
      "8": 127,
      "9": 93,
      "10": 212,
      "11": 76
    }
  }
}
```