# This file was auto-generated by Fern from our API Definition.

import typing_extensions
import typing_extensions
import typing
from .error import ErrorParams
from .payment_refund import PaymentRefundParams


class ListPaymentRefundsResponseParams(typing_extensions.TypedDict):
    """
    Defines the response returned by [ListPaymentRefunds](api-endpoint:Refunds-ListPaymentRefunds).

    Either `errors` or `refunds` is present in a given response (never both).
    """

    errors: typing_extensions.NotRequired[typing.Sequence[ErrorParams]]
    """
    Information about errors encountered during the request.
    """

    refunds: typing_extensions.NotRequired[typing.Sequence[PaymentRefundParams]]
    """
    The list of requested refunds.
    """

    cursor: typing_extensions.NotRequired[str]
    """
    The pagination cursor to be used in a subsequent request. If empty,
    this is the final response.
    
    For more information, see [Pagination](https://developer.squareup.com/docs/build-basics/common-api-patterns/pagination).
    """
