> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dodopayments.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List Payments

> Get a list of all payments associated with your account.



## OpenAPI

````yaml get /payments
openapi: 3.1.0
info:
  title: public
  description: ''
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0
  version: 1.102.0
servers:
  - url: https://test.dodopayments.com/
    description: Test Mode Server Host
  - url: https://live.dodopayments.com/
    description: Live Mode Server Host
security: []
tags:
  - name: Products
  - name: Payments
  - name: Subscriptions
  - name: Addons
  - name: Customers
  - name: Refunds
  - name: Disputes
  - name: Events
  - name: License Keys
  - name: Entitlements
  - name: Licenses
  - name: Discounts
  - name: Meters
  - name: Credit Entitlements
  - name: Credit Entitlement Balances
  - name: Outgoing Webhooks
  - name: Checkout
  - name: Webhook Events
paths:
  /payments:
    get:
      tags:
        - Payments
      operationId: list_payments_handler
      parameters:
        - name: created_at_gte
          in: query
          description: Get events after this created time
          required: false
          schema:
            type: string
            format: date-time
          style: form
        - name: created_at_lte
          in: query
          description: Get events created before this time
          required: false
          schema:
            type: string
            format: date-time
          style: form
        - name: page_size
          in: query
          description: Page size default is 10 max is 100
          required: false
          schema:
            type: integer
            format: int32
            minimum: 0
          style: form
        - name: page_number
          in: query
          description: Page number default is 0
          required: false
          schema:
            type: integer
            format: int32
            minimum: 0
          style: form
        - name: customer_id
          in: query
          description: Filter by customer id
          required: false
          schema:
            type: string
          style: form
        - name: subscription_id
          in: query
          description: Filter by subscription id
          required: false
          schema:
            type: string
          style: form
        - name: status
          in: query
          description: Filter by status
          required: false
          schema:
            type: string
            enum:
              - succeeded
              - failed
              - cancelled
              - processing
              - requires_customer_action
              - requires_merchant_action
              - requires_payment_method
              - requires_confirmation
              - requires_capture
              - partially_captured
              - partially_captured_and_capturable
          style: form
        - name: brand_id
          in: query
          description: filter by Brand id
          required: false
          schema:
            type: string
          style: form
        - name: product_id
          in: query
          description: Filter by product id
          required: false
          schema:
            type: string
          style: form
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetPaymentsListResponse'
        '500':
          description: Something went wrong :(
      security:
        - API_KEY: []
      x-codeSamples:
        - lang: JavaScript
          source: |-
            import DodoPayments from 'dodopayments';

            const client = new DodoPayments({
              bearerToken: process.env['DODO_PAYMENTS_API_KEY'], // This is the default and can be omitted
            });

            // Automatically fetches more pages as needed.
            for await (const paymentListResponse of client.payments.list()) {
              console.log(paymentListResponse.brand_id);
            }
        - lang: Python
          source: |-
            import os
            from dodopayments import DodoPayments

            client = DodoPayments(
                bearer_token=os.environ.get("DODO_PAYMENTS_API_KEY"),  # This is the default and can be omitted
            )
            page = client.payments.list()
            page = page.items[0]
            print(page.brand_id)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/dodopayments/dodopayments-go\"\n\t\"github.com/dodopayments/dodopayments-go/option\"\n)\n\nfunc main() {\n\tclient := dodopayments.NewClient(\n\t\toption.WithBearerToken(\"My Bearer Token\"),\n\t)\n\tpage, err := client.Payments.List(context.TODO(), dodopayments.PaymentListParams{})\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", page)\n}\n"
        - lang: Java
          source: |-
            package com.dodopayments.api.example;

            import com.dodopayments.api.client.DodoPaymentsClient;
            import com.dodopayments.api.client.okhttp.DodoPaymentsOkHttpClient;
            import com.dodopayments.api.models.payments.PaymentListPage;
            import com.dodopayments.api.models.payments.PaymentListParams;

            public final class Main {
                private Main() {}

                public static void main(String[] args) {
                    DodoPaymentsClient client = DodoPaymentsOkHttpClient.fromEnv();

                    PaymentListPage page = client.payments().list();
                }
            }
        - lang: Kotlin
          source: |-
            package com.dodopayments.api.example

            import com.dodopayments.api.client.DodoPaymentsClient
            import com.dodopayments.api.client.okhttp.DodoPaymentsOkHttpClient
            import com.dodopayments.api.models.payments.PaymentListPage
            import com.dodopayments.api.models.payments.PaymentListParams

            fun main() {
                val client: DodoPaymentsClient = DodoPaymentsOkHttpClient.fromEnv()

                val page: PaymentListPage = client.payments().list()
            }
        - lang: Ruby
          source: |-
            require "dodopayments"

            dodo_payments = Dodopayments::Client.new(
              bearer_token: "My Bearer Token",
              environment: "test_mode" # defaults to "live_mode"
            )

            page = dodo_payments.payments.list

            puts(page)
        - lang: PHP
          source: |-
            <?php

            require_once dirname(__DIR__) . '/vendor/autoload.php';

            use Dodopayments\Client;
            use Dodopayments\Core\Exceptions\APIException;

            $client = new Client(
              bearerToken: getenv('DODO_PAYMENTS_API_KEY') ?: 'My Bearer Token',
              environment: 'test_mode',
            );

            try {
              $page = $client->payments->list(
                brandID: 'brand_id',
                createdAtGte: new \DateTimeImmutable('2019-12-27T18:11:19.117Z'),
                createdAtLte: new \DateTimeImmutable('2019-12-27T18:11:19.117Z'),
                customerID: 'customer_id',
                pageNumber: 0,
                pageSize: 0,
                productID: 'product_id',
                status: 'succeeded',
                subscriptionID: 'subscription_id',
              );

              var_dump($page);
            } catch (APIException $e) {
              echo $e->getMessage();
            }
        - lang: C#
          source: |-
            using System;
            using DodoPayments.Client;
            using DodoPayments.Client.Models.Payments;

            DodoPaymentsClient client = new();

            PaymentListParams parameters = new();

            var page = await client.Payments.List(parameters);
            await foreach (var item in page.Paginate())
            {
                Console.WriteLine(item);
            }
components:
  schemas:
    GetPaymentsListResponse:
      type: object
      required:
        - items
      properties:
        items:
          type: array
          items:
            $ref: '#/components/schemas/GetPaymentsListResponseItem'
    GetPaymentsListResponseItem:
      type: object
      required:
        - payment_id
        - total_amount
        - currency
        - customer
        - created_at
        - brand_id
        - digital_products_delivered
        - has_license_key
        - metadata
        - payment_provider
      properties:
        brand_id:
          type: string
        card_last_four:
          type:
            - string
            - 'null'
          description: The last four digits of the card
        card_network:
          type:
            - string
            - 'null'
          description: Card network like VISA, MASTERCARD etc.
        created_at:
          type: string
          format: date-time
        currency:
          $ref: '#/components/schemas/Currency'
        customer:
          $ref: '#/components/schemas/CustomerLimitedDetailsResponse'
        digital_products_delivered:
          type: boolean
        dispute_status:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DisputeStatus'
              description: >-
                The most recent dispute status for this payment. None if no
                disputes exist.
        has_license_key:
          type: boolean
        invoice_id:
          type:
            - string
            - 'null'
          description: >-
            Invoice ID for this payment. Uses India-specific invoice ID if
            available.
        invoice_url:
          type:
            - string
            - 'null'
          description: URL to download the invoice PDF for this payment.
        metadata:
          $ref: '#/components/schemas/Metadata'
        payment_id:
          type: string
        payment_method:
          type:
            - string
            - 'null'
        payment_method_type:
          type:
            - string
            - 'null'
        payment_provider:
          $ref: '#/components/schemas/PaymentProvider'
          description: >-
            Which processor handled this payment. `stripe` / `adyen` for BYOP
            routes

            (the merchant's own Hyperswitch connector); `dodo` for everything
            Dodo

            processed itself.
        refund_status:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/PaymentRefundStatus'
              description: >-
                Summary of the refund status for this payment. None if no
                succeeded refunds exist.
        status:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/IntentStatus'
        subscription_id:
          type:
            - string
            - 'null'
        total_amount:
          type: integer
          format: int32
    Currency:
      type: string
      enum:
        - AED
        - ALL
        - AMD
        - ANG
        - AOA
        - ARS
        - AUD
        - AWG
        - AZN
        - BAM
        - BBD
        - BDT
        - BGN
        - BHD
        - BIF
        - BMD
        - BND
        - BOB
        - BRL
        - BSD
        - BWP
        - BYN
        - BZD
        - CAD
        - CHF
        - CLP
        - CNY
        - COP
        - CRC
        - CUP
        - CVE
        - CZK
        - DJF
        - DKK
        - DOP
        - DZD
        - EGP
        - ETB
        - EUR
        - FJD
        - FKP
        - GBP
        - GEL
        - GHS
        - GIP
        - GMD
        - GNF
        - GTQ
        - GYD
        - HKD
        - HNL
        - HRK
        - HTG
        - HUF
        - IDR
        - ILS
        - INR
        - IQD
        - JMD
        - JOD
        - JPY
        - KES
        - KGS
        - KHR
        - KMF
        - KRW
        - KWD
        - KYD
        - KZT
        - LAK
        - LBP
        - LKR
        - LRD
        - LSL
        - LYD
        - MAD
        - MDL
        - MGA
        - MKD
        - MMK
        - MNT
        - MOP
        - MRU
        - MUR
        - MVR
        - MWK
        - MXN
        - MYR
        - MZN
        - NAD
        - NGN
        - NIO
        - NOK
        - NPR
        - NZD
        - OMR
        - PAB
        - PEN
        - PGK
        - PHP
        - PKR
        - PLN
        - PYG
        - QAR
        - RON
        - RSD
        - RUB
        - RWF
        - SAR
        - SBD
        - SCR
        - SEK
        - SGD
        - SHP
        - SLE
        - SLL
        - SOS
        - SRD
        - SSP
        - STN
        - SVC
        - SZL
        - THB
        - TND
        - TOP
        - TRY
        - TTD
        - TWD
        - TZS
        - UAH
        - UGX
        - USD
        - UYU
        - UZS
        - VES
        - VND
        - VUV
        - WST
        - XAF
        - XCD
        - XOF
        - XPF
        - YER
        - ZAR
        - ZMW
    CustomerLimitedDetailsResponse:
      type: object
      required:
        - customer_id
        - name
        - email
      properties:
        customer_id:
          type: string
          description: Unique identifier for the customer
        email:
          type: string
          description: Email address of the customer
        metadata:
          $ref: '#/components/schemas/Metadata'
          description: Additional metadata associated with the customer
        name:
          type: string
          description: Full name of the customer
        phone_number:
          type:
            - string
            - 'null'
          description: Phone number of the customer
    DisputeStatus:
      type: string
      enum:
        - dispute_opened
        - dispute_expired
        - dispute_accepted
        - dispute_cancelled
        - dispute_challenged
        - dispute_won
        - dispute_lost
    Metadata:
      type: object
      additionalProperties:
        type: string
      propertyNames:
        type: string
    PaymentProvider:
      type: string
      description: >-
        The processor that ultimately handles a payment, surfaced to the
        dashboard

        so the UI can badge each payment / dispute as "powered by ...".


        `Stripe` and `Adyen` are returned for BYOP routes (the merchant's own

        Hyperswitch connector). `Dodo` covers every other route — both Dodo's
        own

        MoR processors (Stripe US/UK, Cashfree, Airwallex) and any payment that
        has

        no merchant connector attached.


        This type intentionally does NOT reuse the internal `Connector` enum:
        that

        one tracks Dodo's own processor pool and shouldn't leak its variants
        into

        dashboard responses.
      enum:
        - stripe
        - adyen
        - dodo
    PaymentRefundStatus:
      type: string
      enum:
        - partial
        - full
    IntentStatus:
      type: string
      enum:
        - succeeded
        - failed
        - cancelled
        - processing
        - requires_customer_action
        - requires_merchant_action
        - requires_payment_method
        - requires_confirmation
        - requires_capture
        - partially_captured
        - partially_captured_and_capturable
  securitySchemes:
    API_KEY:
      type: http
      scheme: bearer

````