# Process Withdraw

## Withdrawal Endpoint

<mark style="color:green;">`POST`</mark> `https://sandbox.pgecom.com/api/v1/withdraw`

#### Headers

| Name                                            | Type   | Description    |
| ----------------------------------------------- | ------ | -------------- |
| authorization<mark style="color:red;">\*</mark> | String | Bearer `token` |

#### Request Body

<table><thead><tr><th width="197">Property</th><th width="225">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>receiverEmail</code></td><td>string - required</td><td>Recipient's email address</td></tr><tr><td><code>amount</code></td><td>string - required</td><td>The amount to send to recipient. If you're sending <strong>htg</strong> as the currency, this is the amount of gourdes </td></tr><tr><td><code>type</code></td><td>string - default pgecom</td><td>Where you want to send the funds (PGecom, MonCash, NatCash, Sogebank, etc)</td></tr><tr><td><code>delivery</code></td><td>string - default instant</td><td>When do you want the funds to be available (standard, regular, express, urgent, instant)</td></tr><tr><td><code>currency</code></td><td>string - default usd</td><td>The currency that you'd like to send the funds to</td></tr><tr><td><code>message</code></td><td>string</td><td>A custom message for the recipient to receive </td></tr><tr><td><code>firstName</code></td><td>string</td><td>The first name of the recipient</td></tr><tr><td><code>lastName</code></td><td>string</td><td>The last name of the recipient</td></tr><tr><td><code>accountNumber</code></td><td>string</td><td>The bank account number</td></tr><tr><td><code>accountName</code></td><td>string</td><td>The account name</td></tr><tr><td><code>routingNumber</code></td><td>string</td><td>The routing account if any</td></tr><tr><td><code>accountType</code></td><td>string</td><td>The bank account type if any</td></tr><tr><td><code>address</code></td><td>string</td><td>The recipient address if any</td></tr><tr><td><code>webhookUrl</code></td><td>string</td><td>The url that you'd like to receive a withdraw is successful</td></tr><tr><td><code>metadata</code></td><td>object</td><td>You can pass additional values if you need to receive it once the order is complete</td></tr><tr><td></td><td></td><td></td></tr></tbody></table>

{% tabs %}
{% tab title="200: OK " %}

```json
{
    "newBalance": 638.64,
    "sender": "info@pgecom.com",
    "receiver": "info@pgecom.com",
    "orderId": "a1d52cce-2f80-448f-bfe8-b9c95ed1f2db",
    "amount": 5,
    "gourdes": 660,
    "userFee": 0.15,
    "userID": "5f56dfa3-a415-4818-8275-44fc63ece3fd",
    "deliveryMethod": "standard",
    "transactionType": "moncash_withdraw",
    "currency": "usd",
    "status": "processing",
    "metadata": {
        "currency": "usd"
    },
    "id": "028ed5e0-30ae-43de-8e94-6254c55e8ccb",
    "platform": "pgrewards",
    "createdAt": "2024-06-03T22:47:35.538Z",
    "updatedAt": "2024-06-03T22:47:35.538Z",
    "delivery": "standard"
}
```

{% endtab %}
{% endtabs %}
