Creating Payout Transfer

Creating a Fiat-Payout Transfer (API link):

When creating a FIAT Payout, you need to already know the bank account details where the payout will be sent out which includes the bank code and the bank account number of the business within that bank. If an invalid bank code and/ or bank account number are provided, the payout will be rejected.

  • Minimal payload:
    curl --location 'https://sandbox-api.transfi.com/v3/orders' \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Basic ==' \
    --header 'mid: SAH1N3_NA_NA' \
    --data '{
        "userId": "UX-2123123123123",
        "orderType": "payout",
        "purposeCode": "company_expenses",
        "source": {
            "currency": "USDT",
        },
        "destination": {
            "currency": "EUR",
            "amount":"10",
            "paymentType": "bank_transfer",
            "paymentCode": "sepa_bank",
            "additionalPaymentDetails": {
                "iban": "BE61231231234",
                "bic": "DE123123123XX",
                "street": "abcd",
                "city": "abcd",
                "postalCode": "123123"
            }
        }
    }'
    {
        "status": "success",
        "data": {
            "flow": "FIAT_PAYOUT",
            "orderId": "OR-2509301734555691983"
        }
    }

  • Full payload
    curl --location 'https://sandbox-api.transfi.com/v3/orders' \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Basic ==' \
    --header 'mid: SAH1N3_NA_NA' \
    --data '{
        "userId": "UX-2123123123123",
        "orderType": "payout",
        "purposeCode": "company_expenses",
        "purposeCodeReason": "Personal payment",
        "invoiceId": "IN-2509301349208479789",
        "sourceUrl": "https://yourapp.com/source"
        "partnerId": "1234567890",
        "customerMetaData": {
            "customerId": "1234567890",
            "customerName": "John Doe",
            "customerEmail": "[email protected]"
        },
        "deviceDetails": {
            "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64)",
            "ipInfo": {
                "ip": "123.123.123.123",
                "countryCode3": "IND"
            }
        },
        "source": {
            "currency": "USDT",
        },
        "destination": {
            "currency": "EUR",
            "amount":"10",
            "paymentType": "bank_transfer",
            "paymentCode": "sepa_bank",
            "additionalPaymentDetails": {
                "iban": "BE61231231234",
                "bic": "DE123123123XX",
                "street": "abcd",
                "city": "abcd",
                "postalCode": "123123"
            }
        }
    }'
    {
        "status": "success",
        "data": {
            "flow": "FIAT_PAYOUT",
            "orderId": "OR-2509301734555691983"
        }
    }

Creating a Crypto-Payout Transfer (API link):

When creating a Crypto Payout, you need to already know the wallet address where the payout will be sent out. If an invalid wallet address is passed, the payout will be rejected. Also, the wallet is checked for any exposure before any payouts are made to the wallet.

  • Minimal payload:
    curl --location 'https://sandbox-api.transfi.com/v3/orders' \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Basic ==' \
    --header 'mid: SAH1N3_NA_NA' \
    --data '{
        "userId": "UX-2123123123123",
        "orderType": "payout",
        "purposeCode": "company_expenses", 
        "source": {
            "currency": "USDT"
        },
        "destination": {
            "currency": "USDTPOLYGON",
            "walletAddress": "0xDEADBEEF1234567890ABCDEF1234567890ABCDEF",
            "amount": "100"
        }
    }'
    {
        "status": "success",
        "data": {
            "flow": "CRYPTO_PAYOUT",
            "orderId": "OR-2509301207018202709"
        }
    }

  • Full payload
    curl --location 'https://sandbox-api.transfi.com/v3/orders' \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Basic ==' \
    --header 'mid: SAH1N3_NA_NA' \
    --data '{
        "userId": "UX-2123123123123",
        "orderType": "payout",
        "purposeCode": "company_expenses",
        "purposeCodeReason": "Personal payment",
        "invoiceId": "IN-2509301349208479789",
        "sourceUrl": "https://yourapp.com/source"
        "partnerId": "1234567890",
        "customerMetaData": {
            "customerId": "1234567890",
            "customerName": "John Doe",
            "customerEmail": "[email protected]"
        },
        "deviceDetails": {
            "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64)",
            "ipInfo": {
                "ip": "123.123.123.123",
                "countryCode3": "IND"
            }
        },  
        "source": {
            "currency": "USDT"
        },
        "destination": {
            "currency": "USDTPOLYGON",
            "walletAddress": "0xDEADBEEF1234567890ABCDEF1234567890ABCDEF",
            "amount": "100"
        }
    }'
    {
        "status": "success",
        "data": {
            "flow": "CRYPTO_PAYOUT",
            "orderId": "OR-2509301207018202709"
        }
    }

Note: Amount to be transferred can be passed in either source or destination.

Examples:

{
    "source": {
        "currency": "EUR"
    },
    "destination": {
        "currency": "USDC",
        "amount": "100"
    }
}
{
    "source": {
        "currency": "EUR",
        "amount": "100"
    },
    "destination": {
        "currency": "USDC"
    }
}
  1. Amount is sent in destination object: In this case, 100 USDC will be sent to the user and amount of EUR that will be deducted from balances will be calculated (~94.5 EUR). (This is usually preferred)
  2. Amount is sent in source object: In this case, 100 EUR will be deducted from balances. Amount of USDC that user will receive, will be calculated (~105 USDC).