#tirth-jain_api
1 messages · Page 1 of 1 (latest)
👋 Welcome to your new thread!
⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1433374274902560838
📝 Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- tirth-jain_docs, 40 minutes ago, 31 messages
- tirth-jain_docs, 1 day ago, 46 messages
- tirth-jain_docs, 1 day ago, 25 messages
- tirth-jain_api, 2 days ago, 8 messages
My Platform only have the USD Balance, What my goal is to pass currency other than USD (Consider this is the case) .
Example:
The receiver’s local currency is EUR, and I need to transfer 8 EUR. Stripe should convert the amount from EUR to USD, debit from my account in USD, and the receiver should receive 8 EUR.
Working Example :white_check_mark:
const transfer = await stripe.transfers.create({
amount: 8 * 100, // Amount in cents from frontend
currency: 'usd', // because i have balance in usd
destination: account.id,
description: `Transfer to ${account.email || account.id}`,
});
Not Working Example :x:
Error: Insufficient Balance
const transfer = await stripe.transfers.create({
amount: 8 * 100, // Amount in cents from frontend
currency: 'eur', // or any other currency expect usd
destination: account.id,
description: `Transfer to ${account.email || account.id}`,
});
@wind elm Tell me to do this below but how would i convert the amount in usd ? althou i want stripe to do on it's own ...
{
to_currency: 'eur', // connected account currency
from_currencies : ['usd'], // platform currency
lock_duration: 'day',
lock_duration : 'five_minutes',
usage : {
type : 'transfer',
transfer : {
destination : 'acct_xxx' #account you want to transfer to
}
}
}
Create a transfer, specifying the fx_quote field, example payload below
{
currency: "usd", // this must be the platform currency
destination: "acct_xxx",
fx_quote: 'fexq_xxx',
amount : //amount to be transfered ,
}
Are you based in US ?
My platform is based in US Region, because as per docs for enabling the cross border functionally (Platform region must be in US)
Nice, yeah that's what I wanted to confirm with you
That you can use Cross Border Payouts:
https://docs.stripe.com/connect/cross-border-payouts
Now what is the issue you are facing ?
For the currency conversion, I think you simply need to create the transfer and Stripe will do the conversion
I actually want to transfer the balance from my platform payment balance to connect account stripe balance, Payout we dont have to do, connected user will do that thingss manually
So in your use case, did you try to create a Transfer ?
Yes!
And what error/issue you get ?
I have give the example here
Can you share the failure request Id ?
Yes give me a minute
https://dashboard.stripe.com/test/logs/req_lo7a2pb2M3lIO4?t=1761814968
This is my requset url
req_lo7a2pb2M3lIO4
Hey!
looks like the attempted transfer exceeded your platform's available balance
if you need to increase your platform's available balance directly, you can use these test cards to create a payment: https://docs.stripe.com/testing#available-balance
I have $ 100,506.09 available balance, and i am transfering the 10 EUR
the currency of the transfer should match your platform's balance (i.e USD)
this is why the subsequent attempts in USD succeeded
Yes! but is it possible that stripe auto convert in **usd ** ? If I transfer in EUR stripe convert to USD and receiver will get EUR in there local currency
@wind elm give me some example of fx_quotebut I didn't completely understand what exactly it is and how it will help me achieve this.. could you please help me our with that ? or you have any other better solution
All I want is stripe auto convert any currencies to usd... while using the Transfer API
hmmm, so you want the funds to be converted twice?
USD > EUR > Receiver local currency?
Yes
I'm not sure we support this (it's generally something people want to avoid because of the FX fees when converting funds)
can you tell me why you don't want to just do one conversion? (i.e. USD > Receiver local currency)
Let's say I Have to transfer 10 EUR, there might be possible of variation of few amount
is there any API that take amount, from_currency, **to_currency **and give me the converted amount based on the latest conversion rate ?
yes! this is what the FX Quotes API can be used for
could you please give me working example of if i want to transfer eur then how to do ?
How do i convert EUR to USD and how to use it in transfer API
there are full examples for the different Connect use cases in this doc: https://docs.stripe.com/connect/currencies/fx-quotes-api
https://docs.stripe.com/connect/currencies/fx-quotes-api#separate-charges-transfers-without-on-behalf-of
What the differnce
https://docs.stripe.com/connect/currencies/fx-quotes-api#fx-quote-for-the-transfer
I can see botha re same
All this document is for like give me the conversation rate, is there any way it provide me the amount directly in usd which i have to transfer ?
👋 Hi there. Taking over for my colleague
There isn't a way for it to provide you with the amount — you would have to calculate this based on the exchange rate it returns
Error Log = https://dashboard.stripe.com/test/logs/req_ELERhzyUr5f2l0?t=1761819062
I have USD balance = $100,506.09
Account ID Tranfering = acct_1SNrgb18IRRTobsK
Curl Call For fx_quote
curl --location 'https://api.stripe.com/v1/fx_quotes' \
--header 'Stripe-Version: 2025-07-30.preview' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--header 'Authorization: ••••••' \
--data-urlencode 'to_currency=eur' \
--data-urlencode 'from_currencies%5B%5D=usd' \
--data-urlencode 'lock_duration=five_minutes' \
--data-urlencode 'usage%5Btype%5D=transfer' \
--data-urlencode 'usage%5Btransfer%5D%5Bdestination%5D=acct_1SNrgb18IRRTobsK'
fx_quote = fxq_1SNsoC01P2qVxTjG89aoNtLo
Creating the transfer
return await this.stripe.transfers.create({
amount: 10 * 100,
currency: 'eur',
destination: accountId,
description,
metadata,
fx_quote: 'fxq_1SNsoC01P2qVxTjG89aoNtLo',
});
Can you please check
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
The error message says that you did not include eur in the from_currencies when creating the FX quote, in this request: req_lnWWiSKDoairi3
{
"error": {
"message": "The FX Quote's to_currency: "usd" must match the merchant's default currency: "eur".",
"param": "to_currency",
"request_log_url": "https://dashboard.stripe.com/test/logs/req_Jv7k4aI4HV2DlJ?t=1761819614",
"type": "invalid_request_error"
}
}
curl --location 'https://api.stripe.com/v1/fx_quotes' \
--header 'Stripe-Version: 2025-07-30.preview' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--header 'Authorization: Basic c2tfdGVzdF81MVJraXp5MDFQMnFWeFRqR0o0dHFUQW9RSXI5MW9pSzB4RzFMVlVSd01rSWVLa3d5N0wzZ2pWTjdOdGRJSVJCWUZiWGVubHJveTJqRHo3OVdwaHdLU1BDdTAwUDNmcDNCYWs6' \
--data-urlencode 'to_currency=usd' \
--data-urlencode 'from_currencies%5B%5D=eur' \
--data-urlencode 'from_currencies%5B%5D=eur' \
--data-urlencode 'lock_duration=five_minutes' \
--data-urlencode 'usage%5Btype%5D=transfer' \
--data-urlencode 'usage%5Btransfer%5D%5Bdestination%5D=acct_1SNrgb18IRRTobsK'
This it give me this error, please check
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
to_currency was fine, but not from_currencies
But if you want to pay someone in USD, your Transfer has to have currency: usd — you used currency: eur in req_ELERhzyUr5f2l0
I want to pay someone in EUR From USD
If you want to send 1000 EUR using your USD balance, you need to calculate the USD amount to send them (e.g. using FX quotes), and use currency: usd in the transfer
I pass the EUR amoutn and the currency=usd, but receiver not received the 10 EUR
It received the dollar instead of EUR
It should recived the EUR directly, I belive
You need to pass the USD amount that's equal to 10 EUR, which would be around 11.74 USD according to the exchange rate shown there
No, you need to decide how much to send
"rates": {
"usd": {
"exchange_rate": 0.851624,
"rate_details": {
"base_rate": 0.860835,
"duration_premium": 0.00070,
"fx_fee_rate": 0.01,
"reference_rate": 0.859402,
"reference_rate_provider": "ecb"
}
}
},
fx_fee_rate is the fee who is going to bear, like platform or receiver
The platform
Where can i see this in platform ?
Once the transfer is created, you should see it in its view
I Have transfer to acct_1SNrgb18IRRTobsK, i am unabel to see any fee
can you please look into this
Can you share a transfer that there were a currency conversion please ?
You see here for example tr_1SNu1w01P2qVxTjG7DiPW7Cc if there were Stripe fees related, then you could see it here:
In general if you want to see the related Stripe fees you can check the balance transactions
One more thing when i use fx_quote it gives me exchange rate, but if you see there is still a 0.02 EUR is move extra.
Not sure honestly about how the FX calculation are done, as this channel is for technical integration questions only, you should reach out to Stripe Support in order to understand how the FX quotes are calculated
Make sure to provide that concrete example in the email too.
okay
Happy to help!