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

# GET /api/approvals/pending — List Pending Approvals

> GET /api/approvals/pending — returns all transactions awaiting your manual approval, including amount, recipient, AI session, and 2-minute expiry time.

Retrieve every transaction currently waiting for your manual approval. When an AI session attempts a transfer that exceeds the `manualApprovalThreshold` set in the session's spending policy, Pay3 holds the transaction and creates an approval request instead of executing it immediately. You must review and approve (or simply let it expire) within 2 minutes. This endpoint gives you the full list of open approval requests so you can process them promptly.

## Endpoint

```
GET /api/approvals/pending
```

## Authentication

All requests must include a valid bearer token in the `Authorization` header, or a `pay3_session` cookie obtained during wallet authentication.

```
Authorization: Bearer <token>
```

> [!WARNING]
>
> Each approval request expires **2 minutes** after it is created. If you do not approve the transaction before `expiresAt`, the request is automatically cancelled and the underlying transaction moves to `EXPIRED` status. The AI session will need to retry the operation if the action is still desired.

## Response

Returns an array of open approval request objects, ordered by `createdAt` descending (most recently created first). Only requests with a future `expiresAt` are included — already-expired requests do not appear.

### Response fields

**id** `string` *required*

UUID of the approval request itself.

**status** `string` *required*

Always `PENDING` for entries returned by this endpoint.

**transactionId** `string` *required*

UUID of the transaction awaiting approval. Pass this to [POST /api/approvals/:txId/approve](https://pay3.mintlify.site/api-reference/approvals/approve.md) to execute it.

**aiSessionId** `string` *required*

UUID of the AI session that submitted the transaction request.

**expiresAt** `string` *required*

ISO 8601 timestamp 2 minutes after `createdAt`. The approval request is cancelled automatically if you have not approved it by this time.

**createdAt** `string` *required*

ISO 8601 timestamp when the approval request was created (i.e. when the AI submitted the transaction).

**transaction** `object` *required*

The full transaction record for the payment being held for review.

**transaction fields**

**id** `string` *required*

UUID of the transaction.

**action** `string` *required*

Always `TRANSFER` for transactions that require approval.

**asset** `string` *required*

Asset code to be transferred (e.g. `"USDC"`).

**amount** `string` *required*

Requested transfer amount as a decimal string.

**recipientAddress** `string` *required*

Resolved Stellar G-address that will receive the funds if you approve.

**recipientInput** `string` *required*

The raw recipient value the AI originally specified.

**status** `string` *required*

Transaction status — `PENDING_APPROVAL` for all entries in this context.

**policyDecision** `string` *required*

Always `PENDING_APPROVAL` here.

**createdAt** `string` *required*

ISO 8601 timestamp when the transaction record was created.

**aiSession** `object` *required*

Summary of the AI session that triggered this approval request.

**aiSession fields**

**id** `string` *required*

UUID of the AI session.

**clientType** `string` *required*

AI client that initiated the transaction (e.g. `"CURSOR"`, `"CLAUDE"`).

## Example request

```bash theme={null}
curl https://api.pay3.dev/api/approvals/pending \
  -H "Authorization: Bearer <token>"
```

## Example response

```json theme={null}
[
  {
    "id": "apr1a2b3c4-0001-4abc-8def-000000000050",
    "status": "PENDING",
    "transactionId": "c3b2a1f0-9876-5432-fedc-ba0987654321",
    "aiSessionId": "e3b0c442-98fc-1c14-9afb-f4c8996fb924",
    "expiresAt": "2025-07-08T14:32:00.000Z",
    "createdAt": "2025-07-08T14:30:00.000Z",
    "transaction": {
      "id": "c3b2a1f0-9876-5432-fedc-ba0987654321",
      "action": "TRANSFER",
      "asset": "USDC",
      "amount": "75.0000000",
      "recipientAddress": "GBXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
      "recipientInput": "GBXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
      "status": "PENDING_APPROVAL",
      "policyDecision": "PENDING_APPROVAL",
      "createdAt": "2025-07-08T14:30:00.000Z"
    },
    "aiSession": {
      "id": "e3b0c442-98fc-1c14-9afb-f4c8996fb924",
      "clientType": "CURSOR"
    }
  },
  {
    "id": "apr1a2b3c4-0002-4abc-8def-000000000051",
    "status": "PENDING",
    "transactionId": "a0b1c2d3-1111-2222-3333-444455556666",
    "aiSessionId": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
    "expiresAt": "2025-07-08T14:32:45.000Z",
    "createdAt": "2025-07-08T14:30:45.000Z",
    "transaction": {
      "id": "a0b1c2d3-1111-2222-3333-444455556666",
      "action": "TRANSFER",
      "asset": "XLM",
      "amount": "60.0000000",
      "recipientAddress": "GCYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY",
      "recipientInput": "bob",
      "status": "PENDING_APPROVAL",
      "policyDecision": "PENDING_APPROVAL",
      "createdAt": "2025-07-08T14:30:45.000Z"
    },
    "aiSession": {
      "id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
      "clientType": "CLAUDE"
    }
  }
]
```

> [!NOTE]
>
> An empty array `[]` means there are no transactions currently awaiting your approval. Poll this endpoint regularly or build a notification workflow on top of it to catch time-sensitive approval requests before they expire.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.