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

# client.listTransactions()

> List the connected customer's transactions with optional filters and pagination.

Use this method to list the connected customer's transactions. You can filter by date range and page through results with a cursor.

For request and response details, see the [List transactions API](/api-reference/platform/endpoints/transactions/list).

```tsx List transactions focus={5-16} theme={null}
import { useMoonPay } from "@moonpay/platform-sdk-react-native";

export function TransactionsScreen() {
  const { client } = useMoonPay();

  const load = async () => {
    const result = await client.listTransactions({
      startDate: "2026-01-01",
      endDate: "2026-01-31",
      limit: 20,
    });

    if (!result.ok) {
      // Handle error
      console.error(result.error.code, result.error.message);
      return;
    }

    console.log(result.value.data); // Transaction[]
    console.log(result.value.pageInfo); // Pagination info
  };

  // ...
}
```

***

## Parameters

`client.listTransactions()` takes an optional `params` object. Call it with no arguments to fetch the most recent transactions without filters.

| Field       | Type     | Required | Description                                                                                                          |
| ----------- | -------- | -------- | -------------------------------------------------------------------------------------------------------------------- |
| `startDate` | `string` |          | An [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date. Only return transactions created on or after this date.  |
| `endDate`   | `string` |          | An [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date. Only return transactions created on or before this date. |
| `cursor`    | `string` |          | A pagination cursor returned from a previous call. Use it to fetch the next page.                                    |
| `limit`     | `number` |          | The maximum number of transactions to return in one page.                                                            |

This method does not require a separate auth token. The client uses stored credentials from an active connection.

## Result

`client.listTransactions()` returns a `Result<{ data: Transaction[]; pageInfo: PaginationInfo }, GetTransactionsError>`.

### Result envelope

`Result<{ data: Transaction[]; pageInfo: PaginationInfo }, GetTransactionsError>`

| Field   | Type                                                                                           | Required | Description                      |
| ------- | ---------------------------------------------------------------------------------------------- | -------- | -------------------------------- |
| `ok`    | `boolean`                                                                                      | ✅        | Whether the operation succeeded. |
| `value` | `{ data:` [`Transaction`](#transaction)`[]; pageInfo:` [`PaginationInfo`](#paginationinfo) `}` |          | Present when `ok` is `true`.     |
| `error` | [`GetTransactionsError`](#gettransactionserror)                                                |          | Present when `ok` is `false`.    |

### `Transaction`

Each entry in `data` is a full transaction. Key fields include `id`, `status`, `source.amount`, `destination.amount`, and `createdAt`. See the [Transaction object](/api-reference/platform/objects-and-types/transaction) for every field.

| Field         | Type                | Required | Description                                                                                                                                        |
| ------------- | ------------------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| `id`          | `string`            | ✅        | The MoonPay ID of the transaction.                                                                                                                 |
| `status`      | `TransactionStatus` | ✅        | The current transaction status. See the [Transaction object](/api-reference/platform/objects-and-types/transaction) for the full list of statuses. |
| `source`      | `object`            | ✅        | The source amount and asset (fiat currency).                                                                                                       |
| `destination` | `object`            | ✅        | The destination amount and asset (cryptocurrency).                                                                                                 |
| `createdAt`   | `string`            | ✅        | An [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp of when the transaction was created.                                               |

### `PaginationInfo`

Cursor-based pagination details returned alongside the data. See the [List transactions API](/api-reference/platform/endpoints/transactions/list) for the exact field names used in this response.

### `GetTransactionsError`

`GetTransactionsError` is the standard MoonPay Platform API error shape, `DevPlatformApiError`.

| Field     | Type                          | Required | Description                                                                                                                                                                           |
| --------- | ----------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `code`    | `DevPlatformApiErrorCode`     | ✅        | A machine-readable error code (for example, `"unauthorized"`, `"invalid_request"`). See the [error reference](/api-reference/platform/documentation/using-the-api) for the full list. |
| `message` | `string`                      | ✅        | A developer-friendly message.                                                                                                                                                         |
| `errors`  | `DevPlatformApiErrorDetail[]` |          | Optional list of field-level errors.                                                                                                                                                  |

## Example: page through transactions

Use the cursor returned in `pageInfo` to fetch additional pages. The exact cursor field name is documented in the [List transactions API](/api-reference/platform/endpoints/transactions/list) response.

```ts Page through transactions theme={null}
async function listAllTransactions() {
  const all = [];
  let cursor: string | undefined;

  do {
    const result = await client.listTransactions({ limit: 50, cursor });

    if (!result.ok) {
      throw new Error(result.error.message);
    }

    all.push(...result.value.data);

    // pageInfo carries the cursor for the next page; see the API reference
    // for the exact field name (for example, `pageInfo.endCursor`).
    cursor = result.value.pageInfo.endCursor;
  } while (cursor);

  return all;
}
```
