Skip to main content
POST
/
transfer
/
fees
/
crypto-withdrawal
Create Crypto Withdrawal Fee
curl --request POST \
  --url https://api.paxos.com/v2/transfer/fees/crypto-withdrawal \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "asset": "ETH",
  "amount": "0.00005",
  "destination_address": "0xF0Aa84466e353E5390be37FE2934301c07c19a55",
  "crypto_network": "ETHEREUM"
}
'
import requests

url = "https://api.paxos.com/v2/transfer/fees/crypto-withdrawal"

payload = {
    "asset": "ETH",
    "amount": "0.00005",
    "destination_address": "0xF0Aa84466e353E5390be37FE2934301c07c19a55",
    "crypto_network": "ETHEREUM"
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: JSON.stringify({
    asset: 'ETH',
    amount: '0.00005',
    destination_address: '0xF0Aa84466e353E5390be37FE2934301c07c19a55',
    crypto_network: 'ETHEREUM'
  })
};

fetch('https://api.paxos.com/v2/transfer/fees/crypto-withdrawal', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => "https://api.paxos.com/v2/transfer/fees/crypto-withdrawal",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'asset' => 'ETH',
    'amount' => '0.00005',
    'destination_address' => '0xF0Aa84466e353E5390be37FE2934301c07c19a55',
    'crypto_network' => 'ETHEREUM'
  ]),
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer <token>",
    "Content-Type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.paxos.com/v2/transfer/fees/crypto-withdrawal"

	payload := strings.NewReader("{\n  \"asset\": \"ETH\",\n  \"amount\": \"0.00005\",\n  \"destination_address\": \"0xF0Aa84466e353E5390be37FE2934301c07c19a55\",\n  \"crypto_network\": \"ETHEREUM\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.paxos.com/v2/transfer/fees/crypto-withdrawal")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"asset\": \"ETH\",\n  \"amount\": \"0.00005\",\n  \"destination_address\": \"0xF0Aa84466e353E5390be37FE2934301c07c19a55\",\n  \"crypto_network\": \"ETHEREUM\"\n}")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.paxos.com/v2/transfer/fees/crypto-withdrawal")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"asset\": \"ETH\",\n  \"amount\": \"0.00005\",\n  \"destination_address\": \"0xF0Aa84466e353E5390be37FE2934301c07c19a55\",\n  \"crypto_network\": \"ETHEREUM\"\n}"

response = http.request(request)
puts response.read_body
{
  "id": "34bd61ed-cf0a-4012-8be4-d347667b6154",
  "fee": "0.00005",
  "asset": "ETH",
  "amount": "0.001",
  "expires_at": "2021-02-10T23:00:00Z",
  "destination_address": "0xF0Aa84466e353E5390be37FE2934301c07c19a55",
  "crypto_network": "ETHEREUM"
}
OAuth Scope
fee:write_crypto_withdrawal_fee

Authorizations

Authorization
string
header
required

Paxos APIs use OAuth 2 with the client credentials grant flow.

Token URLs:

Learn more in the API credentials guide →

Body

application/json
asset
string
required

The currency to withdraw.

destination_address
string
required

The destination address.

crypto_network
enum<string>
required

A CryptoNetwork is a blockchain transmitting cryptocurrencies.

Available options:
BITCOIN,
ETHEREUM,
BITCOIN_CASH,
LITECOIN,
SOLANA,
POLYGON_POS,
BASE,
ARBITRUM_ONE,
STELLAR,
INK,
XLAYER
amount
string

The amount to withdraw. Must be greater than 0. Specify exactly one of amount or total, otherwise an error is returned.

Pattern: ^[0-9]*\.?[0-9]+$
total
string

Total amount to withdraw, including fees. Must be greater than 0. Specify exactly one of total or amount, otherwise an error is returned.

Pattern: ^[0-9]*\.?[0-9]+$

Response

200 - application/json

A successful response.

id
string
required

The id of the guaranteed fee.

fee
string
required

The guaranteed fee value, in the same currency.

Pattern: ^[0-9]*\.?[0-9]+$
asset
string
required

The currency to withdraw.

expires_at
string<date-time>
required

The expiration timestamp of the created fee.

destination_address
string
required

The destination address.

crypto_network
enum<string>
required

A CryptoNetwork is a blockchain transmitting cryptocurrencies.

Available options:
BITCOIN,
ETHEREUM,
BITCOIN_CASH,
LITECOIN,
SOLANA,
POLYGON_POS,
BASE,
ARBITRUM_ONE,
STELLAR,
INK,
XLAYER
amount
string

The quoted amount to withdraw for which the fee is valid. Specify exactly one of amount or total, otherwise an error is returned.

Pattern: ^[0-9]*\.?[0-9]+$
total
string

Total amount to withdraw, including fees. Specify exactly one of amount or total, otherwise an error is returned.

Pattern: ^[0-9]*\.?[0-9]+$