#clement-pinchedez_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/1432725642843127971
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
To complete the above quesiton, I do not see the currency parameter in the customer update endpoint: https://docs.stripe.com/api/customers/update
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Hey there
Hello
How do you normally charge customers?
For one-off payments and invoices, you should be able to charge a customer in any presentment currency you like at any time
For subscriptions, you cannot have simultaneous active subscriptions in different currencies for a single customer
Hello, we usually create and send invoice with charge_automatically property
One off invoices?
yes
Ok then you can just use a price with a different currency and that should be respected. Are you encountering an error when you try to do this?
Customers used to be locked to a single invoice/subscription currency based on the first payment, and it was not mutable, but that's been loosened since.
yes, here is the issue we had:
- the customer has the USD default currency
- we create invoice line items in EUR
- we create an invoice in EUR currency
The invoice line items are not added to the invoice when we finalize it
let me check
I have this customer id for example https://dashboard.stripe.com/acct_1FiitgAMgvgeiO2u/customers/cus_SWO6i1yUStmaqX
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
and this invoice in_1Ro0FEAMgvgeiO2ubwOUKcgX
I am sorry - for this invoice, we had this issue:
-the customer is in EUR default currency (because he got invoices in EUR)
-we created USD invoice lines
- we created an invoice - but this created a 0 EUR invoice without the USD invoice lines
Right, because USD invoice items cannot be included on a EUR invoice
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Try specifying currency=usd when you create the invoice
Indeed, we do not specify it
Which, for context, is setting the currency of the invoice rather than the customer
and then the pending invoice items will be included to the invoice if they have the same currencies ?
Yes, I expect that is what you'll observe
ok, thanks!
Give it a try for that customer and i can take a look
eg, run another request like this but adding the usd currency: https://dashboard.stripe.com/acct_1FiitgAMgvgeiO2u/logs/req_F4e9e8b8BQK7r1
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
this is a production environment I will rather try on the test environment
Googd news, I did the test for this invoice in_1SNDjpAMgvgeiO2uCFHdd8mN in a test environement and that works
Great!
so I will use this. Thanks for your help.
NP! Glad that got you what you needed ๐