#harrier-sus-bois_best-practices
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/1480522835393908796
π 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.
- harrier-sus-bois_best-practices, 1 hour ago, 7 messages
π happy to help
we don't recommend using SetupIntents when creating a subscription
Hey @long lantern π please also refer to the previous thread (3rd latest) for my original question. Got locked because of my lunch break I presume
instead you can use the latest_invoice.confirmation_secret
I've had to go via the Payment Intents API route due to the design requirements in our project and had to go this route because they also wanted crypto payments to work.
is it available in the current clover SDK ?
no need to do that
yes this is described here https://docs.stripe.com/billing/subscriptions/build-subscriptions?api-integration=paymentintents#create-subscription:~:text=If youβre using,the default currency.
I also highlighted how multi-currency prices could be used in this case
and will this also work when offering a trial? I think I tried using this approach but it always fell flat when I tried adding a trial period so that it was not paid immediately
yes
when I specify the currency parameter in the stripe.subscriptions.create function it merely rejects it because the price already has a currency set.
Subscription creation error: Error: The price specified only supports usd. This doesn't match the expected currency: eur.
at ignore-listed frames {
type: 'StripeInvalidRequestError',
raw: [Object],
rawType: 'invalid_request_error',
code: undefined,
doc_url: undefined,
param: 'items[0][price]',
detail: undefined,
headers: [Object],
requestId: 'req_gGj5hdoqiq7WeY',
statusCode: 400,
userMessage: undefined,
charge: undefined,
decline_code: undefined,
payment_intent: undefined,
payment_method: undefined,
payment_method_type: undefined,
setup_intent: undefined,
source: undefined
}
Error: The price specified only supports usd. This doesn't match the expected currency: eur.
(test env)
Ok so I manually need to create multiple price variants for the same product that differ by the currency.
yes
adaptive pricing is only available for our hosted surfaces
because the test environment doesnt have that option
Oh I see, it only appears on creation not on editation ?
when Im trying to create a new priceId it has the option to add multiple currency options
I think because it has already been assigned to a subscription
Okay that makes sense. So technically I can try either to manipulate using API if it will allow me, or I will need to create an new priceId and migrate existing subscriptions to it ?
sorry, it's the same restrictions both on the dashboard and the API
so its the second option then
my bad, I didn't realize you were updating in the screenshot you shared
yes this one is editing (test env)
this one is creating (prod env)
So to sumarize this, To make multicurrency work in my intents API I would need to create a new priceId for the product, add multiple currency options to it and migrate existing subscriptions from the already existing prices to it. And then specifying a currency in the subscriptions.create will permit payment methods such as SEPA to be viable canditates to pay invoices on that subscription ?
correct
Okay, thank you very much for your help π
@long lantern One question the also regarding the euro payments. Will I need a bank account connected in each of the currencies?
it depends in which currency you want the settlement
SEPA payouts says that an EUR account will need to be connected for payouts in EUR
So its possible then to settle the eur funds to the USD account ?
yes but an FX fee would be applied