> For the complete documentation index, see [llms.txt](https://docs.useshadowpay.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.useshadowpay.com/api-reference/transfers.md).

# Transfers

Initiate and inspect transfers programmatically. Every transfer created through this endpoint is confidential by default, same as one initiated from the app.

***

## Create a transfer

```
POST /v1/transfers
```

### Request body

```json
{
  "to": "string",
  "amount": "string",
  "asset": "USDC",
  "confidential": true,
  "memo": "string"
}
```

| Field          | Type      | Required | Description                                                                                               |
| -------------- | --------- | -------- | --------------------------------------------------------------------------------------------------------- |
| `to`           | `string`  | Yes      | Recipient `@handle` or raw Solana address                                                                 |
| `amount`       | `string`  | Yes      | Transfer amount, as a decimal string                                                                      |
| `asset`        | `string`  | No       | Defaults to `USDC`                                                                                        |
| `confidential` | `boolean` | No       | Defaults to `true`. Set `false` only when sending to a wallet that doesn't support Confidential Balances. |
| `memo`         | `string`  | No       | Encrypted memo, visible only to sender and receiver                                                       |

### Response

```json
{
  "transfer_id": "tr_7f3a1c2d",
  "status": "confirmed",
  "to": "@vendor",
  "confidential": true,
  "solana_signature": "5KJvsngH7zNw...",
  "created_at": "2026-07-02T14:23:09Z"
}
```

Note that the response never includes the amount in plaintext, even though you just sent the request that specified it. ShadowPay's API confirms the transfer settled; reading the amount back requires client-side decryption, same as any other confidential balance read.

***

## Get a transfer

```
GET /v1/transfers/{transfer_id}
```

### Response

```json
{
  "transfer_id": "tr_7f3a1c2d",
  "status": "confirmed",
  "from": "@yourname",
  "to": "@vendor",
  "confidential": true,
  "solana_signature": "5KJvsngH7zNw...",
  "created_at": "2026-07-02T14:23:09Z",
  "confirmed_at": "2026-07-02T14:23:09Z"
}
```

### Status values

| Status      | Description                             |
| ----------- | --------------------------------------- |
| `pending`   | Submitted, awaiting Solana confirmation |
| `confirmed` | Settled on-chain                        |
| `failed`    | Did not settle. No funds moved.         |

***

## List transfers

```
GET /v1/transfers
```

### Query parameters

| Parameter | Type      | Default | Description                                           |
| --------- | --------- | ------- | ----------------------------------------------------- |
| `limit`   | `integer` | `20`    | Results per page. Max `100`.                          |
| `offset`  | `integer` | `0`     | Pagination offset                                     |
| `status`  | `string`  | (none)  | Filter by status                                      |
| `from`    | `string`  | (none)  | ISO 8601 timestamp, filter transfers after this date  |
| `to`      | `string`  | (none)  | ISO 8601 timestamp, filter transfers before this date |

***

## Error responses

| Status | Code                               | Description                                                                                                                              |
| ------ | ---------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| `400`  | `invalid_request`                  | Malformed request body or missing required fields                                                                                        |
| `402`  | `insufficient_balance`             | Account does not hold enough of the requested asset                                                                                      |
| `404`  | `recipient_not_found`              | No account found for the given handle                                                                                                    |
| `422`  | `recipient_not_confidential_ready` | Recipient wallet doesn't support Confidential Balances; retry with `"confidential": false` if you want to proceed as a standard transfer |

***

## Example

```bash
curl -X POST https://api.shadowpay.xyz/v1/transfers \
  -H "Authorization: Bearer sp_live_xxxxxxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "to": "@vendor",
    "amount": "125.00",
    "asset": "USDC",
    "confidential": true,
    "memo": "Invoice #4471"
  }'
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.useshadowpay.com/api-reference/transfers.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
