Lago Payment_requests API

Everything about PaymentRequests

Operations 2

POST /payment_requests Lago Create a payment request #
GET /payment_requests Lago List all payment requests #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/lago-payment-requests-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

lago-payment-requests-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Lago API documentation Add_ons Payment Requests API
  description: Lago API allows your application to push customer information and metrics (events) from your application to the billing application.
  version: 1.15.0
  license:
    name: AGPLv3
    identifier: AGPLv3
  contact:
    email: tech@getlago.com
servers:
- url: https://api.getlago.com/api/v1
  description: US Lago cluster
- url: https://api.eu.getlago.com/api/v1
  description: EU Lagos cluster
security:
- bearerAuth: []
tags:
- name: Payment_requests
  description: Everything about PaymentRequests
  externalDocs:
    description: Find out more
    url: https://doc.getlago.com/docs/api/payment_requests/payment_request-object
paths:
  /payment_requests:
    post:
      tags:
      - Payment_requests
      summary: Lago Create a payment request
      description: This endpoint is used to create a payment request to collect payments of overdue invoices of a given customer
      operationId: createPaymentRequest
      requestBody:
        description: PaymentRequest payload
        content:
          application/json:
            schema:
              type: object
              required:
              - payment_request
              properties:
                payment_request:
                  type: object
                  required:
                  - email
                  - external_customer_id
                  - lago_invoice_ids
                  properties:
                    customer_external_id:
                      type: string
                      example: 5eb02857-a71e-4ea2-bcf9-57d3a41bc6ba
                      description: The customer external unique identifier (provided by your own application)
                    email:
                      type: string
                      format: email
                      example: dinesh@piedpiper.test
                      description: The customer's email address used for sending dunning notifications
                    lago_invoice_ids:
                      type: array
                      description: A list of Lago IDs for the customer's overdue invoices to start the dunning process
                      items:
                        type: string
                        example: 1a901a90-1a90-1a90-1a90-1a901a901a90
                        description: Unique identifier assigned to the invoice within the Lago application. This ID is exclusively created by Lago and serves as a unique identifier for the invoice's record within the Lago system.
        required: true
      responses:
        '200':
          description: PaymentRequest created
          content:
            application/json:
              schema:
                type: object
                required:
                - payment_request
                properties:
                  payment_request:
                    $ref: '#/components/schemas/PaymentRequestObject'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '422':
          $ref: '#/components/responses/UnprocessableEntity'
    get:
      tags:
      - Payment_requests
      summary: Lago List all payment requests
      description: This endpoint is used to list all existing payment requests.
      operationId: findAllPaymentRequests
      parameters:
      - $ref: '#/components/parameters/page'
      - $ref: '#/components/parameters/per_page'
      - $ref: '#/components/parameters/external_customer_id'
      responses:
        '200':
          description: PaymentRequests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaymentRequestsPaginated'
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  schemas:
    PaymentRequestsPaginated:
      type: object
      required:
      - payment_requests
      - meta
      properties:
        payment_requests:
          type: array
          items:
            $ref: '#/components/schemas/PaymentRequestObject'
        meta:
          $ref: '#/components/schemas/PaginationMeta'
    Timezone:
      type: string
      example: America/Los_Angeles
      enum:
      - UTC
      - Africa/Algiers
      - Africa/Cairo
      - Africa/Casablanca
      - Africa/Harare
      - Africa/Johannesburg
      - Africa/Monrovia
      - Africa/Nairobi
      - America/Argentina/Buenos_Aires
      - America/Bogota
      - America/Caracas
      - America/Chicago
      - America/Chihuahua
      - America/Denver
      - America/Godthab
      - America/Guatemala
      - America/Guyana
      - America/Halifax
      - America/Indiana/Indianapolis
      - America/Juneau
      - America/La_Paz
      - America/Lima
      - America/Los_Angeles
      - America/Mazatlan
      - America/Mexico_City
      - America/Monterrey
      - America/Montevideo
      - America/New_York
      - America/Phoenix
      - America/Puerto_Rico
      - America/Regina
      - America/Santiago
      - America/Sao_Paulo
      - America/St_Johns
      - America/Tijuana
      - Asia/Almaty
      - Asia/Baghdad
      - Asia/Baku
      - Asia/Bangkok
      - Asia/Chongqing
      - Asia/Colombo
      - Asia/Dhaka
      - Asia/Hong_Kong
      - Asia/Irkutsk
      - Asia/Jakarta
      - Asia/Jerusalem
      - Asia/Kabul
      - Asia/Kamchatka
      - Asia/Karachi
      - Asia/Kathmandu
      - Asia/Kolkata
      - Asia/Krasnoyarsk
      - Asia/Kuala_Lumpur
      - Asia/Kuwait
      - Asia/Magadan
      - Asia/Muscat
      - Asia/Novosibirsk
      - Asia/Rangoon
      - Asia/Riyadh
      - Asia/Seoul
      - Asia/Shanghai
      - Asia/Singapore
      - Asia/Srednekolymsk
      - Asia/Taipei
      - Asia/Tashkent
      - Asia/Tbilisi
      - Asia/Tehran
      - Asia/Tokyo
      - Asia/Ulaanbaatar
      - Asia/Urumqi
      - Asia/Vladivostok
      - Asia/Yakutsk
      - Asia/Yekaterinburg
      - Asia/Yerevan
      - Atlantic/Azores
      - Atlantic/Cape_Verde
      - Atlantic/South_Georgia
      - Australia/Adelaide
      - Australia/Brisbane
      - Australia/Darwin
      - Australia/Hobart
      - Australia/Melbourne
      - Australia/Perth
      - Australia/Sydney
      - Europe/Amsterdam
      - Europe/Athens
      - Europe/Belgrade
      - Europe/Berlin
      - Europe/Bratislava
      - Europe/Brussels
      - Europe/Bucharest
      - Europe/Budapest
      - Europe/Copenhagen
      - Europe/Dublin
      - Europe/Helsinki
      - Europe/Istanbul
      - Europe/Kaliningrad
      - Europe/Kiev
      - Europe/Lisbon
      - Europe/Ljubljana
      - Europe/London
      - Europe/Madrid
      - Europe/Minsk
      - Europe/Moscow
      - Europe/Paris
      - Europe/Prague
      - Europe/Riga
      - Europe/Rome
      - Europe/Samara
      - Europe/Sarajevo
      - Europe/Skopje
      - Europe/Sofia
      - Europe/Stockholm
      - Europe/Tallinn
      - Europe/Vienna
      - Europe/Vilnius
      - Europe/Volgograd
      - Europe/Warsaw
      - Europe/Zagreb
      - Europe/Zurich
      - GMT+12
      - Pacific/Apia
      - Pacific/Auckland
      - Pacific/Chatham
      - Pacific/Fakaofo
      - Pacific/Fiji
      - Pacific/Guadalcanal
      - Pacific/Guam
      - Pacific/Honolulu
      - Pacific/Majuro
      - Pacific/Midway
      - Pacific/Noumea
      - Pacific/Pago_Pago
      - Pacific/Port_Moresby
      - Pacific/Tongatapu
    PaymentRequestObject:
      type: object
      required:
      - lago_id
      - email
      - amount_cents
      - amount_currency
      - payment_status
      - created_at
      - customer
      - invoices
      properties:
        lago_id:
          type: string
          format: uuid
          description: Unique identifier of the payment request, created by Lago.
          example: 1a901a90-1a90-1a90-1a90-1a901a901a90
        email:
          type: string
          format: email
          example: dinesh@piedpiper.test
          description: The customer's email address used for sending dunning notifications
        amount_cents:
          type: integer
          description: The sum of the total amounts of all the invoices included in the payment request, expressed in cents.
          example: 100
        amount_currency:
          allOf:
          - $ref: '#/components/schemas/Currency'
          - description: The currency of the payment request.
            example: EUR
        payment_status:
          type: string
          enum:
          - pending
          - succeeded
          - failed
          description: 'The status of the payment associated with the payment request. It can have one of the following values:

            - `pending`: the payment is pending, waiting for payment processing in the payment provider or when the invoice is emitted but users have not updated the payment status through the endpoint.

            - `succeeded`: the payment of the payment request has been successfully processed.

            - `failed`: the payment of the payment request has failed or encountered an error during processing.'
          example: succeeded
        created_at:
          type: string
          format: date-time
          description: The date and time when the payment request was created. It is expressed in UTC format according to the ISO 8601 datetime standard. This field provides the timestamp for the exact moment when the payment request was initially created.
          example: '2022-04-29T08:59:51Z'
        customer:
          $ref: '#/components/schemas/CustomerObject/allOf/0'
          description: The customer on which the payment request applies. It refers to the customer account or entity associated with the payment request.
        invoices:
          type: array
          items:
            $ref: '#/components/schemas/InvoiceObject/allOf/0'
    ApiErrorBadRequest:
      type: object
      required:
      - status
      - error
      properties:
        status:
          type: integer
          format: int32
          example: 400
        error:
          type: string
          example: Bad request
    ApiErrorUnprocessableEntity:
      type: object
      required:
      - status
      - error
      - code
      - error_details
      properties:
        status:
          type: integer
          format: int32
          example: 422
        error:
          type: string
          example: Unprocessable entity
        code:
          type: string
          example: validation_errors
        error_details:
          type: object
    Address:
      type: object
      description: Configuration specific to the payment provider, utilized for billing the customer. This object contains settings and parameters necessary for processing payments and invoicing the customer.
      properties:
        address_line1:
          type: string
          example: 5230 Penfield Ave
          description: The first line of the billing address
          nullable: true
        address_line2:
          type: string
          example: null
          description: The second line of the billing address
          nullable: true
        city:
          type: string
          example: Woodland Hills
          description: The city of the customer's billing address
          nullable: true
        country:
          allOf:
          - $ref: '#/components/schemas/Country'
          - nullable: true
            description: Country code of the customer's billing address. Format must be ISO 3166 (alpha-2)
            example: US
        state:
          type: string
          example: CA
          description: The state of the customer's billing address
          nullable: true
        zipcode:
          type: string
          example: '91364'
          description: The zipcode of the customer's billing address
          nullable: true
    Country:
      type: string
      example: US
      enum:
      - AD
      - AE
      - AF
      - AG
      - AI
      - AL
      - AM
      - AO
      - AQ
      - AR
      - AS
      - AT
      - AU
      - AW
      - AX
      - AZ
      - BA
      - BB
      - BD
      - BE
      - BF
      - BG
      - BH
      - BI
      - BJ
      - BL
      - BM
      - BN
      - BO
      - BQ
      - BR
      - BS
      - BT
      - BV
      - BW
      - BY
      - BZ
      - CA
      - CC
      - CD
      - CF
      - CG
      - CH
      - CI
      - CK
      - CL
      - CM
      - CN
      - CO
      - CR
      - CU
      - CV
      - CW
      - CX
      - CY
      - CZ
      - DE
      - DJ
      - DK
      - DM
      - DO
      - DZ
      - EC
      - EE
      - EG
      - EH
      - ER
      - ES
      - ET
      - FI
      - FJ
      - FK
      - FM
      - FO
      - FR
      - GA
      - GB
      - GD
      - GE
      - GF
      - GG
      - GH
      - GI
      - GL
      - GM
      - GN
      - GP
      - GQ
      - GR
      - GS
      - GT
      - GU
      - GW
      - GY
      - HK
      - HM
      - HN
      - HR
      - HT
      - HU
      - ID
      - IE
      - IL
      - IM
      - IN
      - IO
      - IQ
      - IR
      - IS
      - IT
      - JE
      - JM
      - JO
      - JP
      - KE
      - KG
      - KH
      - KI
      - KM
      - KN
      - KP
      - KR
      - KW
      - KY
      - KZ
      - LA
      - LB
      - LC
      - LI
      - LK
      - LR
      - LS
      - LT
      - LU
      - LV
      - LY
      - MA
      - MC
      - MD
      - ME
      - MF
      - MG
      - MH
      - MK
      - ML
      - MM
      - MN
      - MO
      - MP
      - MQ
      - MR
      - MS
      - MT
      - MU
      - MV
      - MW
      - MX
      - MY
      - MZ
      - NA
      - NC
      - NE
      - NF
      - NG
      - NI
      - NL
      - 'NO'
      - NP
      - NR
      - NU
      - NZ
      - OM
      - PA
      - PE
      - PF
      - PG
      - PH
      - PK
      - PL
      - PM
      - PN
      - PR
      - PS
      - PT
      - PW
      - PY
      - QA
      - RE
      - RO
      - RS
      - RU
      - RW
      - SA
      - SB
      - SC
      - SD
      - SE
      - SG
      - SH
      - SI
      - SJ
      - SK
      - SL
      - SM
      - SN
      - SO
      - SR
      - SS
      - ST
      - SV
      - SX
      - SY
      - SZ
      - TC
      - TD
      - TF
      - TG
      - TH
      - TJ
      - TK
      - TL
      - TM
      - TN
      - TO
      - TR
      - TT
      - TV
      - TW
      - TZ
      - UA
      - UG
      - UM
      - US
      - UY
      - UZ
      - VA
      - VC
      - VE
      - VG
      - VI
      - VN
      - VU
      - WF
      - WS
      - YE
      - YT
      - ZA
      - ZM
      - ZW
    Currency:
      type: string
      example: USD
      enum:
      - AED
      - AFN
      - ALL
      - AMD
      - ANG
      - AOA
      - ARS
      - AUD
      - AWG
      - AZN
      - BAM
      - BBD
      - BDT
      - BGN
      - BIF
      - BMD
      - BND
      - BOB
      - BRL
      - BSD
      - BWP
      - BYN
      - BZD
      - CAD
      - CDF
      - CHF
      - CLF
      - CLP
      - CNY
      - COP
      - CRC
      - CVE
      - CZK
      - DJF
      - DKK
      - DOP
      - DZD
      - EGP
      - ETB
      - EUR
      - FJD
      - FKP
      - GBP
      - GEL
      - GIP
      - GMD
      - GNF
      - GTQ
      - GYD
      - HKD
      - HNL
      - HRK
      - HTG
      - HUF
      - IDR
      - ILS
      - INR
      - ISK
      - JMD
      - JPY
      - KES
      - KGS
      - KHR
      - KMF
      - KRW
      - KYD
      - KZT
      - LAK
      - LBP
      - LKR
      - LRD
      - LSL
      - MAD
      - MDL
      - MGA
      - MKD
      - MMK
      - MNT
      - MOP
      - MRO
      - MUR
      - MVR
      - MWK
      - MXN
      - MYR
      - MZN
      - NAD
      - NGN
      - NIO
      - NOK
      - NPR
      - NZD
      - PAB
      - PEN
      - PGK
      - PHP
      - PKR
      - PLN
      - PYG
      - QAR
      - RON
      - RSD
      - RUB
      - RWF
      - SAR
      - SBD
      - SCR
      - SEK
      - SGD
      - SHP
      - SLL
      - SOS
      - SRD
      - STD
      - SZL
      - THB
      - TJS
      - TOP
      - TRY
      - TTD
      - TWD
      - TZS
      - UAH
      - UGX
      - USD
      - UYU
      - UZS
      - VND
      - VUV
      - WST
      - XAF
      - XCD
      - XOF
      - XPF
      - YER
      - ZAR
      - ZMW
    InvoiceObject:
      allOf:
        '0':
          type: object
          required:
          - lago_id
          - number
          - issuing_date
          - invoice_type
          - status
          - payment_status
          - currency
          - fees_amount_cents
          - coupons_amount_cents
          - credit_notes_amount_cents
          - sub_total_excluding_taxes_amount_cents
          - taxes_amount_cents
          - sub_total_including_taxes_amount_cents
          - prepaid_credit_amount_cents
          - progressive_billing_credit_amount_cents
          - total_amount_cents
          - version_number
          properties:
            lago_id:
              type: string
              format: uuid
              description: Unique identifier assigned to the fee within the Lago application. This ID is exclusively created by Lago and serves as a unique identifier for the fee's record within the Lago system.
              example: 1a901a90-1a90-1a90-1a90-1a901a901a90
            sequential_id:
              type: integer
              description: This ID helps in uniquely identifying and organizing the invoices associated with a specific customer. It provides a sequential numbering system specific to the customer, allowing for easy tracking and management of invoices within the customer's context.
              example: 2
            number:
              type: string
              description: The unique number assigned to the invoice. This number serves as a distinct identifier for the invoice and helps in differentiating it from other invoices in the system.
              example: LAG-1234-001-002
            issuing_date:
              type: string
              format: date
              description: The date when the invoice was issued. It is provided in the ISO 8601 date format.
              example: '2022-04-30'
            payment_dispute_lost_at:
              type: string
              format: date-time
              description: The date when the payment dispute was lost. It is expressed in Coordinated Universal Time (UTC).
              example: '2022-09-14T16:35:31Z'
            payment_due_date:
              type: string
              format: date
              description: The payment due date for the invoice, specified in the ISO 8601 date format.
              example: '2022-04-30'
            payment_overdue:
              type: boolean
              description: Specifies if the payment is considered as overdue.
              example: true
            net_payment_term:
              type: integer
              example: 30
              description: The net payment term, expressed in days, specifies the duration within which a customer is expected to remit payment after the invoice is finalized.
            invoice_type:
              type: string
              enum:
              - subscription
              - add_on
              - credit
              - one_off
              - progressive_billing
              description: The type of invoice issued. Possible values are `subscription`, `one-off`, `credit` or `progressive_billing`.
              example: subscription
            status:
              type: string
              enum:
              - draft
              - finalized
              - voided
              - failed
              description: 'The status of the invoice. It indicates the current state of the invoice and can have two possible values:

                - `draft`: the invoice is in the draft state, waiting for the end of the grace period to be finalized. During this period, events can still be ingested and added to the invoice.

                - `finalized`: the invoice has been issued and finalized. In this state, events cannot be ingested or added to the invoice anymore.

                - `voided`: the invoice has been issued and subsequently voided. In this state, events cannot be ingested or added to the invoice anymore.

                - `failed`: during an attempt of finalization of the invoice, an error happened. This invoice will have an array of error_details, explaining, in which part of the system an error happened and how it''s possible to fix it. This invoice can''t be edited or updated, only retried. This action will discard current error_details and will create new ones if the finalization failed again.'
              example: finalized
            payment_status:
              type: string
              enum:
              - pending
              - succeeded
              - failed
              description: 'The status of the payment associated with the invoice. It can have one of the following values:

                - `pending`: the payment is pending, waiting for payment processing in Stripe or when the invoice is emitted but users have not updated the payment status through the endpoint.

                - `succeeded`: the payment of the invoice has been successfully processed.

                - `failed`: the payment of the invoice has failed or encountered an error during processing.'
              example: succeeded
            currency:
              allOf:
              - $ref: '#/components/schemas/Currency'
              - description: The currency of the invoice issued.
                example: EUR
            fees_amount_cents:
              type: integer
              description: The total sum of fees amount in cents. It calculates the cumulative amount of all the fees associated with the invoice, providing a consolidated value.
              example: 100
            coupons_amount_cents:
              type: integer
              description: The total sum of all coupons discounted on the invoice. It calculates the cumulative discount amount applied by coupons, expressed in cents.
              example: 10
            credit_notes_amount_cents:
              type: integer
              description: The total sum of all credit notes discounted on the invoice. It calculates the cumulative discount amount applied by credit notes, expressed in cents.
              example: 10
            sub_total_excluding_taxes_amount_cents:
              type: integer
              description: 'Subtotal amount, excluding taxes, expressed in cents.

                This field depends on the version number. Here are the definitions based on the version:

                - Version 1: is equal to the sum of `fees_amount_cents`, minus `coupons_amount_cents`, and minus `prepaid_credit_amount_cents`.

                - Version 2: is equal to the `fees_amount_cents`.

                - Version 3 & 4: is equal to the `fees_amount_cents`, minus `coupons_amount_cents`'
              example: 100
            taxes_amount_cents:
              type: integer
              description: The sum of tax amount associated with the invoice, expressed in cents.
              example: 20
            sub_total_including_taxes_amount_cents:
              type: integer
              description: 'Subtotal amount, including taxes, expressed in cents.

                This field depends on the version number. Here are the definitions based on the version:

                - Version 1: is equal to the `total_amount_cents`.

                - Version 2: is equal to the sum of `fees_amount_cents` and `taxes_amount_cents`.

                - Version 3 & 4: is equal to the sum `sub_total_excluding_taxes_amount_cents` and `taxes_amount_cents`'
              example: 120
            prepaid_credit_amount_cents:
              type: integer
              description: The total sum of all prepaid credits discounted on the invoice. It calculates the cumulative discount amount applied by prepaid credits, expressed in cents.
              example: 0
            progressive_billing_credit_amount_cents:
              type: integer
              description: The usage already billed in previous invoices. Only apply to `progressive_billing` and `subscription` invoices.
              example: 0
            total_amount_cents:
              type: integer
              description: The sum of the amount and taxes amount on the invoice, expressed in cents. It calculates the total financial value of the invoice, including both the original amount and any applicable taxes.
              example: 100
            version_number:
              type: integer
              example: 3
            file_url:
              type: string
              format: uri
              description: Contains the URL that provides direct access to the invoice PDF file. You can use this URL to download or view the PDF document of the invoice
              example: https://getlago.com/invoice/file
    CustomerMetadata:
      type: object
      description: Set of key-value pairs that you can attach to a customer. This can be useful for storing additional information about the customer in a structured format
      required:
      - lago_id
      - key
      - value
      - display_in_invoice
      - created_at
      properties:
        lago_id:
          type: string
          format: uuid
          example: 1a901a90-1a90-1a90-1a90-1a901a901a90
          description: A unique identifier for the customer metadata object in the Lago application. Can be used to update a key-value pair
        key:
          type: string
          example: Purchase Order
          description: The metadata object key
        value:
          type: string
          example: '123456789'
          description: The metadata object value
        display_in_invoice:
          type: boolean
          example: true
          description: Determines whether the item or information should be displayed in the invoice. If set to true, the item or information will be included and visible in the generated invoice. If set to false, the item or information will be excluded and not displayed in the invoice.
        created_at:
          type: string
          format: date-time
          example: '2022-04-29T08:59:51Z'
          description: The date of the metadata object creation, represented in ISO 8601 datetime format and expressed in Coordinated Universal Time (UTC). The creation_date provides a standardized and internationally recognized timestamp for when the metadata object was created
    CustomerBillingConfiguration:
      type: object
      description: Configuration specific to the payment provider, utilized for billing the customer. This object contains settings and parameters necessary for processing payments and invoicing the customer.
      properties:
        invoice_grace_period:
          type: integer
          example: 3
          description: The grace period, expressed in days, for the invoice. This period refers to the additional time granted to the customer beyond the invoice due date to adjust usage and line items
        payment_provider:
          type: string
          example: stripe
          description: 'The payment provider utilized to initiate payments for invoices issued by Lago.

            Accepted values: `stripe`, `adyen`, `gocardless` or null. This field is required if you intend to assign a `provider_customer_id`.'
          enum:
          - stripe
          - adyen
          - gocardless
        payment_provider_code:
          type: string
          example: stripe-eu-1
          description: Unique code used to identify a payment provider connection.
        provider_customer_id:
          type: string
          example: cus_12345
          description: The customer ID within the payment provider's system. If this field is not provided, Lago has the option to create a new customer record within the payment provider's system on behalf of the customer
        sync:
          type: boolean
          example: true
          description: Set this field to `true` if you want to create the customer in the payment provider synchronously with the customer creation process in Lago. This option is applicable only when the `provider_customer_id` is `null` and the customer is automatically created in the payment provider through Lago. By default, the value is set to `false`
        sync_with_provider:
          type: boolean
          example: true
          description: Set this field to `true` if you want to create a customer record in the payment provider's system. This option is applicable only when the `provider_customer_id` is null and the `sync_with_provider` field is set to `true`. By default, the value is set to `false`
        document_locale:
          type: string
          example: fr
          description: The document locale, specified in the ISO 639-1 format. This field represents the language or locale used for the documents issued by Lago
        provider_payment_methods:
          type: array
          nullable: true
          items:
            type: string
          description: Specifies the available payment methods that can be used for this customer when `payment_provider` is set to `stripe`. The `provider_payment_methods` field is an array that allows multiple payment options to be defined. If this field is not explicitly set, the payment methods will be set to `card`. For now, possible values are `card`, `sepa_debit`, `us_bank_account`, `bacs_debit` and `link`. Note that when `link` is selected, `card` should also be provided in the array.
          example:
          - card
          - sepa_debit
    PaginationMeta:
      type: object
      required:
      - current_page
      - total_pages
      - total_count
      properties:
        current_page:
          type: integer
          description: Current page.
          example: 2
        next_page:
          type: integer
          description: Next page.
          example: 3
          nullable: true
        prev_page:
          type: integer
          description: Previous page.
          example: 1
          nullable: true
        total_pages:
          type: integer
          description: Total number of pages.
          example: 4
        total_count:
          type: integer
          description: Total number of records.
          example: 70
    ApiErrorUnauthorized:
      type: object
      required:
      - status
      - error
      properties:
        status:
          type: integer
          format: int32
          example: 401
        error:
          type: string
          example: Unauthorized
    CustomerObject:
      allOf:
        '0':
          type: object
          required:
          - lago_id
          - sequential_id
          - slug
          - external_id
          - applicable_timezone
          - created_at
          properties:
            lago_id:
              type: string
              format: uuid
              example: 1a901a90-1a90-1a90-1a90-1a901a901a90
              description: Unique identifier assigned to the customer within the Lago application. This ID is exclusively created by Lago and serves as a unique identifier for the customer's record within the Lago system
            sequential_id:
              type: integer
              example: 1
              description: The unique identifier assigned to the customer within the organization's scope. This identifier is used to track and reference the customer's order of creation within the organization's system. It ensures that each customer has a distinct `sequential_id`` associated with them, allowing for easy identification and sorting based on the order of creation
            slug:
              type: string
              example: LAG-1234-001
              description: A concise and unique identifier for the customer, formed by combining the Organization's `name`, `id`, and customer's `sequential_id`
            external_id:
              type: string
              example: 5eb02857-a71e-4ea2-bcf9-57d3a41bc6ba
              description: The customer external unique identifier (provided by your own application)
            address_line1:
              type: string
              example: 5230 Penfield Ave
              description: The first line of the billing address
              nullable: true
            address_line2:
              type: string
              example: null
              description: The second line of the billing address
              nullable: true
            applicable_timezone:
              allOf:
              - $ref: '#/components/schemas/Timezone'
              - description: The customer's applicable timezone, used for billing p

# --- truncated at 32 KB (38 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/lago/refs/heads/main/openapi/lago-payment-requests-api-openapi.yml