---
updatedAt: 2026-10-30T21:37:52.000Z
agentTools:
  projectIndex: https://developer.veem.com/llms.txt
---

# Withdraw Money

Withdraw funds from a wallet or Virtual Bank Account.

This endpoint is used to create a withdrawal to another funding method owned by the same account (self-payments). The endpoint is as follows:

```http
POST /veem/v1.2/payments/withdraw
```

> 📘 **Headers**
>
> Three headers are required to use this endpoint.
>
> | Name            | Type   | Required | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
> | --------------- | ------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
> | `Authorization` | string | Yes      | Bearer token (OAuth 2.0) This header holds the bearer token required to use Veem's public API, and **belongs to the owner account**. Failure to use a valid bearer token will result in a 404 (Not Found) status code in the response. An example of a valid header value is as follows: `Bearer c047594b-082c-4da1-be89-08fe3770f4b3`. <br />See [Get Access Token section](https://developer.veem.com/docs/oauth#1---get-access-token) to generate your Bearer token. |
> | `X-Request-Id`  | string | Yes      | This is a unique string that identifies the current API request, and should follow the UUID format. Reusing this header without changing the value will result in a 409 (Conflict) status code in the response. An example X-request-id is as follows: `48855846-628d-4177-b071-80332a116f0a`                                                                                                                                                                           |
> | `Content-Type`  | string | Yes      | The content type of the request. Must be `application/json`                                                                                                                                                                                                                                                                                                                                                                                                             |

<br />

### Request Payload

When sending a withdraw request using Veem's Withdraw Payment API to another funding method, follow the format as shown in the following examples:

```json Request: Withdraw to Wallet
{
    "amount": {
        "currency": "USD",
        "number": 50
    },
    "fromFundingMethodType": "VirtualBank",
    "fromFundingMethodId": 1,
    "toFundingMethodType": "Wallet",
    "toFundingMethodId": 135323,
    "purposeOfPayment": "<POP value>",
    "purposeOfPaymentDescription": "<value>",
    "onBehalfAccountId": 12345 // see Partner Notes
}
```
```json Request: Withdraw to Partner Wallet
{
    "amount": {
        "currency": "USD",
        "number": 50
    },
    "fromFundingMethodType": "VirtualBank",
    "fromFundingMethodId": 1,
    "sweepToWalletId":11808
}
```

### Request Parameters

The following table contains detailed information on the payload's parameters, such as the parameter name, whether it is mandatory or not, formatting (if applicable), and size of the parameter. You can retrieve various fields such as `countryCode`, `bankName`, `bankCode`, `swiftCode`, and `purposeOfPayment` from the Country-Currency-Map endpoint. Please refer to the following link: [country-currency-map](https://sandbox-api.veem.com/veem/public/v1.2/country-currency-map?bankFields=True)

<Table align={["left","left","left","left"]}>
  <thead>
    <tr>
      <th>
        Parameter
      </th>

      <th style={{ width: "7.8%" }}>
        Mandatory?
      </th>

      <th style={{ width: "45.5%" }}>
        Format/Values
      </th>

      <th>
        Size (in chars)
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        amount.currency
      </td>

      <td>
        **Yes**
      </td>

      <td>
        Amount currency to withdraw<br />Currency Code (ISO 4217)
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        amount.number
      </td>

      <td>
        **Yes**
      </td>

      <td>
        Amount number to withdraw Number
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        fromFundingMethodType
      </td>

      <td>
        **Yes**
      </td>

      <td>
        "Wallet"<br />"VirtualBank"
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        fromFundingMethodId
      </td>

      <td>
        **Yes**
      </td>

      <td>
        Number<br />**Note**: Make sure the ID is the one associated with the requesting account
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        toFundingMethodType
      </td>

      <td>
        **Yes**<br />(if sweepToWalletId is not provided)
      </td>

      <td>
        For wallet withdrawal the supported funding methods:<br />"Bank"<br />"Card" (debit cards only)<br />"VirtualCard"<br />"VirtualBank"

        For Virtual Bank withdrawal the supported funding methods:<br />"Bank"<br />"Card" (debit cards only)<br />"VirtualCard"<br />"VirtualBank"<br />"Wallet"
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        toFundingMethodId
      </td>

      <td>
        **Yes**<br />(if sweepToWalletId is not provided)
      </td>

      <td>
        Number<br />**Note**: Make sure the ID is the one associated with the requesting account
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        purposeOfPayment
      </td>

      <td>
        No
      </td>

      <td>
        Purpose of payment which should be assigned to withdrawal payment. Allowed values depend on the country, you can retrieve more information using [country-currency-map](https://sandbox-api.veem.com/veem/public/v1.2/country-currency-map?bankFields=True) API endpoint.
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        purposeOfPaymentDescription
      </td>

      <td>
        No
      </td>

      <td>
        Purpose of payment description which should be assigned to withdrawal payment. Allowed values depend on the country, you can retrieve more information using [country-currency-map](https://sandbox-api.veem.com/veem/public/v1.2/country-currency-map?bankFields=True) API endpoint.
      </td>

      <td>

      </td>
    </tr>

    <tr>
      <td>
        sweepToWalletId
      </td>

      <td>
        Not supported for wallet withdrawals
        **Yes**<br />(if toFundingMethodType and toFundingMethodId are not provided)
      </td>

      <td>
        Number<br />**Note**: Make sure the ID is the one associated with the requesting account
      </td>

      <td>

      </td>
    </tr>
  </tbody>
</Table>

### Response Payload

Once a valid request has been sent, a response payload of this format should be expected:

```json Response
{
    "requestId": "18eb345d-2425-42f6-9b77-dbec8803cb75",
    "ccEmails": [],
    "status": "Sent",
    "goodFundsPayment": false,
    "realTimePayment": false,
    "extraInfo": {},
    "id": 468711,
    "exchangeRate": {},
    "feeInformation": {
        "payerInfo": {
            "originalAmount": 50.00,
            "feeAmount": 0.00,
            "totalAmount": 50.00,
            "currency": "USD"
        },
        "payeeInfo": {
            "originalAmount": 50.00,
            "feeAmount": 0.00,
            "totalAmount": 50.00,
            "currency": "USD"
        }
    },
    "fastTransfer": false,
    "cancelable": false,
    "payerFundingMethodType": "VirtualBank",
    "receiverFundingMethodType": "Wallet"
}
```

<Callout icon="👍" theme="okay">
  **Partner Notes:**

  * A partner account can be configured to make this API request on behalf of their customers. This requires internal configuration for the partner account by Veem. Once the internal configuration is enabled, the API request can be made using partner account bearer token.
  * `onBehalfAccountId` is an optional parameter, this needs to be included on the request body in case of partner making an API request on behalf of their customer. This is the customer Veem account ID.
</Callout>

### Possible Errors

If any mandatory field is missing, one will get a Status 400 (Bad Request) error in the following format:

```json Response
{
   "validationErrorMessage": [
       "From Funding Method Type is required.",
       "Sweep to Wallet is not supported for wallet withdrawals.",
       "Amount number <> is not acceptable",
       "To funding method type and id are required",
       "Funding method of type <> is not acceptable",
       "Partner <> is not allowed to sweep to wallet."
   ]
}
```

Here are some extra examples of specific errors that can pop up during the use of the Withdraw Money API:

**Unauthorized**

**Status Code: 401 (Unauthorized)**

**Example**:

```json Response
{
    "error": "unauthorized",
    "error_description": "Full authentication is required to access this resource"
}
```

**Incorrect Funding Method ID**

**Status Code: 404 (Not Found)**

**Example**:

```json Response
{
    "code": 10001004,
    "message": "Could not find funding method: VIRTUALBANK for payer accountId: 441628 and fundingMethodId: 163",
    "logTag": "6642a1b3-9b67-4bf5-a9ba-ca34138f1b4c",
    "timestamp": "2025-01-03T21:34:04.464",
    "fileName": "CreatePayment.java",
    "lineNumber": 406
}
```