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": "USDC",
        },
        "destination": {
            "currency": "AED",
            "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-260824095007070234576584534",
            "feeData": {
                "depositAmount": 2.750917,
                "withdrawAmount": 10,
                "exchangeRate": 0.27234079637895675,
                "totalFee": 0.1
            },
            "quoteHistory": {
                "refreshCount": 0,
                "orderCreationQuote": {
                    "isRefreshed": false,
                    "usedQuotes": {
                        "sourceCurrency": "USDC",
                        "sourceAmount": 2.750917,
                        "sourceCurrencyType": "crypto",
                        "destinationCurrency": "AED",
                        "destinationAmount": 10,
                        "destinationAmountInUsd": 2.72,
                        "destinationCurrencyType": "fiat",
                        "conversionRate": 0.27234079637895675,
                        "processingFee": 0.1,
                        "processingFeeRate": 0.01,
                        "customerFee": 0,
                        "customerFeeRate": 0,
                        "discount": 0,
                        "discountRate": 0,
                        "additionalFee": 0,
                        "fixedFee": {
                            "totalFixedFees": 0,
                            "totalFixedTfFees": 0,
                            "totalFixedCxFees": 0,
                            "fixedFeesCurrency": "",
                            "fixedFeeDetails": {
                                "baseFeeFixedRate": 0,
                                "tfFeeFixedRate": 0,
                                "cxFeeFixedRate": 0,
                                "currency": ""
                            }
                        },
                        "totalFee": 0.1,
                        "feeMode": "percentage",
                        "rateType": "live",
                        "quoteId": "QUOTE-e8c904b2-dc81-449e-ac18-a08007b695e2",
                        "networkFee": 0
                    }
                }
            }
        },
        "traceId": "c325fbb8-3998-41d1-864d-06bd2472590e"
    }

  • 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": "USDC",
        },
        "destination": {
            "currency": "AED",
            "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-260824095007070234576584534",
            "feeData": {
                "depositAmount": 2.750917,
                "withdrawAmount": 10,
                "exchangeRate": 0.27234079637895675,
                "totalFee": 0.1
            },
            "quoteHistory": {
                "refreshCount": 0,
                "orderCreationQuote": {
                    "isRefreshed": false,
                    "usedQuotes": {
                        "sourceCurrency": "USDC",
                        "sourceAmount": 2.750917,
                        "sourceCurrencyType": "crypto",
                        "destinationCurrency": "AED",
                        "destinationAmount": 10,
                        "destinationAmountInUsd": 2.72,
                        "destinationCurrencyType": "fiat",
                        "conversionRate": 0.27234079637895675,
                        "processingFee": 0.1,
                        "processingFeeRate": 0.01,
                        "customerFee": 0,
                        "customerFeeRate": 0,
                        "discount": 0,
                        "discountRate": 0,
                        "additionalFee": 0,
                        "fixedFee": {
                            "totalFixedFees": 0,
                            "totalFixedTfFees": 0,
                            "totalFixedCxFees": 0,
                            "fixedFeesCurrency": "",
                            "fixedFeeDetails": {
                                "baseFeeFixedRate": 0,
                                "tfFeeFixedRate": 0,
                                "cxFeeFixedRate": 0,
                                "currency": ""
                            }
                        },
                        "totalFee": 0.1,
                        "feeMode": "percentage",
                        "rateType": "live",
                        "quoteId": "QUOTE-e8c904b2-dc81-449e-ac18-a08007b695e2",
                        "networkFee": 0
                    }
                }
            }
        },
        "traceId": "c325fbb8-3998-41d1-864d-06bd2472590e"
    }

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": "12",
            "additionalPaymentDetails": {
                "walletOwner": "exchange"
             }        
        }
    }'
    {
        "status": "success",
        "data": {
            "flow": "CRYPTO_PAYOUT",
            "orderId": "OR-260824095145276457990398540",
            "feeData": {
                "depositAmount": 12.128293,
                "withdrawAmount": 12,
                "exchangeRate": 1,
                "totalFee": 0.128293
            },
            "quoteHistory": {
                "refreshCount": 0,
                "orderCreationQuote": {
                    "isRefreshed": false,
                    "usedQuotes": {
                        "sourceCurrency": "USDT",
                        "sourceAmount": 12.128293,
                        "sourceAmountInUsd": 12.13,
                        "sourceCurrencyType": "crypto",
                        "destinationCurrency": "USDTPOLYGON",
                        "destinationAmountInUsd": 12,
                        "destinationCurrencyType": "crypto",
                        "conversionRate": 1,
                        "processingFee": 0.121283,
                        "processingFeeRate": 0.01,
                        "customerFee": 0,
                        "customerFeeRate": 0,
                        "discount": 0,
                        "discountRate": 0,
                        "additionalFee": 0,
                        "additionalFeeRate": 0,
                        "fixedFee": {},
                        "totalFee": 0.128293,
                        "feeMode": "percentage",
                        "rateType": "live",
                        "quoteId": "QUOTE-6ba0d893-8e8c-4950-b5dd-ff9603142792",
                        "networkFee": 0.00701
                    }
                }
            }
        },
        "traceId": "fa090e51-99ff-4794-942f-2ef80979c339"
    }

  • 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": "12",
            "additionalPaymentDetails": {
                "walletOwner": "exchange",
                "exchangeName": "binance"
             }        
        }
    }'
    {
        "status": "success",
        "data": {
            "flow": "CRYPTO_PAYOUT",
            "orderId": "OR-260824095145276457990398540",
            "feeData": {
                "depositAmount": 12.128293,
                "withdrawAmount": 12,
                "exchangeRate": 1,
                "totalFee": 0.128293
            },
            "quoteHistory": {
                "refreshCount": 0,
                "orderCreationQuote": {
                    "isRefreshed": false,
                    "usedQuotes": {
                        "sourceCurrency": "USDT",
                        "sourceAmount": 12.128293,
                        "sourceAmountInUsd": 12.13,
                        "sourceCurrencyType": "crypto",
                        "destinationCurrency": "USDTPOLYGON",
                        "destinationAmountInUsd": 12,
                        "destinationCurrencyType": "crypto",
                        "conversionRate": 1,
                        "processingFee": 0.121283,
                        "processingFeeRate": 0.01,
                        "customerFee": 0,
                        "customerFeeRate": 0,
                        "discount": 0,
                        "discountRate": 0,
                        "additionalFee": 0,
                        "additionalFeeRate": 0,
                        "fixedFee": {},
                        "totalFee": 0.128293,
                        "feeMode": "percentage",
                        "rateType": "live",
                        "quoteId": "QUOTE-6ba0d893-8e8c-4950-b5dd-ff9603142792",
                        "networkFee": 0.00701
                    }
                }
            }
        },
        "traceId": "fa090e51-99ff-4794-942f-2ef80979c339"
    }

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).

Did this page help you?