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

# Fiat deposits and withdrawals

> Fund end-client accounts with USD deposits and process withdrawals.

## How it works

<Steps>
  <Step title="Generate a wire memo">
    Generate a unique USD wire memo per account so incoming wires are attributed automatically.
  </Step>

  <Step title="Client wires funds">
    The client wires USD from an account held in their own name, including the memo.
  </Step>

  <Step title="Funds settle">
    Once settled, funds are available to trade or withdraw.
  </Step>

  <Step title="Client requests a withdrawal">
    You initiate the withdrawal via API. Anchorage Digital sends a DocuSign to the client for approval, then wires the funds back to the originating account.
  </Step>
</Steps>

***

## Fund accounts with USD

Generate a USD wire memo per account via API and share it with the end client. Include the memo in the wire to Anchorage Digital to ensure proper attribution.

### USD funding considerations

* **Wires without memos are returned** — Any wire without a memo field is subject to return. Anchorage Digital will use best efforts to determine the recipient but requires written confirmation from the wealth manager before attributing.
* **Multiple accounts** — If the end client has multiple accounts, they can fund one and rebalance USD across accounts using the account transactions API.
* **Third-party wires not supported** — The originating bank account must be held in the end client's name. Payments from accounts not in the end client's name will be returned.

### Step 1: Generate a wire memo

**`GET /v2/subaccounts/accounts/{subaccountId}/bank-info`**

<CodeGroup>
  ```bash Request theme={null}
  curl --request GET \
       --url https://api.anchorage-staging.com/v2/subaccounts/accounts/cb80459c-a930-444e-8f17-69ba9d0e122f/bank-info \
       --header 'Api-Access-Key: [API Key]' \
       --header 'accept: application/json'
  ```

  ```json Response theme={null}
  {
    "data": {
      "bank": "Customers Bank",
      "bankAccountNr": "1234567",
      "bankAddress": "123 Test",
      "bankRoutingNr": "123456789",
      "bankSwiftCode": "CUESUS33",
      "beneficiaryAddress": "123 Test",
      "beneficiaryName": "Anchorage Digital Bank NA",
      "memo": "515624204"
    }
  }
  ```
</CodeGroup>

<Note>
  Instruct clients to use the **Message to Beneficiary (OBI)** or **Message to Recipient (OBI)** field for the memo. If unavailable, use the **Memo** field. For international wires, share the `bankSwiftCode`.
</Note>

### Step 2: View account balances

**`GET /v2/subaccounts/customers/{customerId}/accounts`**

<CodeGroup>
  ```bash Request theme={null}
  curl --request GET \
       --url https://api.anchorage-staging.com/v2/subaccounts/customers/{customerId}/accounts \
       --header 'Api-Access-Key: [API Key]' \
       --header 'accept: application/json'
  ```

  ```json Response theme={null}
  {
    "data": [
      {
        "subaccountId": "cb80459c-a930-444e-8f17-69ba9d0e122f",
        "name": "A1234_John Doe_Strat1",
        "customerId": "cf326d89b501d7ff2d1c7b7ffea4bd305a6561b54c9c6158160e17b5aca5cec2",
        "fees": [
          { "type": "MANAGEMENT", "rate": 0.01, "startDate": "2025-02-18", "isBillable": true },
          { "type": "CUSTODY", "rate": 0.01, "startDate": "2025-02-18", "isBillable": true }
        ],
        "balances": [
          { "assetType": "BTC", "totalBalance": "100", "availableForWithdrawal": "100", "availableForTrading": "100" },
          { "assetType": "USD", "totalBalance": "100000", "availableForWithdrawal": "100000", "availableForTrading": "100000" }
        ]
      }
    ]
  }
  ```
</CodeGroup>

### Step 3: Move funds between same-client accounts

**`POST /v2/subaccounts/transactions`**

Only settled funds can be moved. Use `availableForWithdrawal` for the settled balance. Cannot move funds between different end clients.

<CodeGroup>
  ```bash Request theme={null}
  curl --request POST \
       --url https://api.anchorage-staging.com/v2/subaccounts/transactions \
       --header 'Api-Access-Key: [API Key]' \
       --header 'accept: application/json' \
       --header 'content-type: application/json' \
       --data '{
    "transactions": [
      {
        "sourceSubaccountId": "cb80459c-a930-444e-8f17-69ba9d0e122f",
        "destinationSubaccountId": "3eeaf765-0df2-49c9-9e1f-db9cf3e796dd",
        "assetType": "USD",
        "amount": "1000.00",
        "transactionMemo": "USD re-balance",
        "idempotentId": "12838927347"
      }
    ]
  }'
  ```

  ```json Response theme={null}
  {
    "data": {
      "transactionIds": [
        { "transactionId": "c4c4652f-0c07-472c-a7f8-955fbe07775d", "idempotentId": "12838927347" }
      ]
    }
  }
  ```
</CodeGroup>

<Tip>
  Use `idempotentId` on bulk account transactions to prevent duplicate submissions.
</Tip>

***

## Withdraw USD

Key considerations before initiating a USD withdrawal:

* External wire fees are covered by Anchorage Digital (subject to change).
* Funds may only be transferred to the account from which they were initially deposited. To send to a different account, that account must be in the end client's name.

### Withdrawal process

Once submitted, a withdrawal moves through this process:

1. **Wealth manager initiates a USD withdrawal via API.**
2. **Anchorage Digital sends a DocuSign to the end client, copying the wealth manager.**
3. **End client reviews and approves the DocuSign.**
4. **Anchorage Digital initiates the wire to the end client's account.**
5. **Withdrawal transaction completes on the ledger.**

### Banks with master/subaccount structures

The following institutions typically use master + subaccount structures (common for investment accounts):

JPMorgan, Morgan Stanley, TD Bank, Vanguard, Merrill Lynch

For these institutions, format the API payload as follows:

* `bankAccountNr`: `"##-##-#####"`
* `bankRoutingNr`: `"#####"`
* `memo`: `"FCC [Client Name], FCC [recipient bank brokerage sub-account number########]"`

### Step 1: Submit a USD withdrawal

**`POST /v2/subaccounts/{subaccountId}/fiat/withdrawals`**

```bash Request theme={null}
curl --request POST \
     --url https://api.anchorage-staging.com/v2/subaccounts/{subaccountId}/fiat/withdrawals \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '{
  "asset": {
    "amount": "1000.00",
    "assetType": "USD"
  },
  "customerDetails": {
    "beneficiary": {
      "accountNumber": "1234567890",
      "address": {
        "address": "123 Main St",
        "address2": "Apt 4B",
        "city": "Anytown",
        "country": "USA",
        "state": "CA",
        "zipcode": "90210"
      },
      "name": "Jane Doe"
    },
    "financialInstitution": {
      "address": {
        "address": "123 Main St",
        "address2": "Apt 4B",
        "city": "Anytown",
        "country": "USA",
        "state": "CA",
        "zipcode": "90210"
      },
      "code": "ABA",
      "id": "routing_id_123",
      "name": "Bank of America"
    },
    "intermediateFinancialInstitution": {
      "address": {
        "address": "123 Main St",
        "address2": "Apt 4B",
        "city": "Anytown",
        "country": "USA",
        "state": "CA",
        "zipcode": "90210"
      },
      "code": "ABA",
      "id": "123",
      "name": "Bank of America"
    },
    "memo": "For services rendered"
  }
}'
```

<Tip>
  Before submitting, confirm the account has sufficient funds and will continue to have sufficient funds while the request is processing. If the available balance falls below what's needed to complete the withdrawal, Anchorage Digital will need to contact the wealth manager before proceeding.
</Tip>
