# Refresh spending wallet

Reads the wallet's on-chain balance and marks it funded or empty. Console session or API key with payment:read.

`POST /v1/spending-wallets/{id}/refresh`

Reads the wallet's on-chain balance and marks it funded or empty. Console session or API key with payment:read.

Requires permission `payment:read`.

## Parameters

| Name | In | Required | Description |
| --- | --- | --- | --- |
| `id` | path | yes | Spending wallet id (swl_...). |

## Responses

- **200**: Success.
- **401**: No valid session, API key or agent credential (UNAUTHENTICATED, AGENT_CREDENTIAL_INVALID).
- **403**: Authenticated but not allowed: missing permission, passkey step-up required, or denied by policy.
- **404**: The resource does not exist or belongs to another organization.
- **503**: The payment rail is temporarily unavailable.

Example 200 response:

```json
{
  "wallet": {
    "id": "id_01jd2x3k4m5n6p7q8r9s0t1v2w",
    "agent_id": "agt_01jd2x3k4m5n6p7q8r9s0t1v2w",
    "agent_name": "string",
    "network": "eip155:84532",
    "network_name": "string",
    "rail": "x402",
    "asset": "USDC",
    "address": "string",
    "status": "active",
    "balance_base_units": "50000",
    "cap_base_units": "50000",
    "balance_checked_at": "2026-11-16T12:00:00Z",
    "created_at": "2026-11-16T12:00:00Z",
    "fee_note": "string"
  },
  "funding": {
    "address": "string",
    "network": "eip155:84532",
    "network_name": "string",
    "asset": "USDC",
    "amount_base_units": "50000",
    "qr": "string",
    "fee_note": "string",
    "instructions": "string"
  }
}
```
