#amit_api

1 messages ยท Page 1 of 1 (latest)

young mothBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! We typically respond in a few minutes, but in some cases we might need a bit more time (e.g., server's busy, you've got a complex question, etc.).

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can 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/1246106700981997588

๐Ÿ“ Have more to share? Add details, code, screenshots, videos, etc. below.

rough radishBOT
rain spade
#

It returns but works fine If customer have card payment added but shows error when customer have sepa_debit added.

violet moon
#

Hi ๐Ÿ‘‹ can you share the ID of the request that returned the message you described:

Nothing to invoice for customer

rain spade
#

req_EiGE5BjvIpb0wi?t=1717160710

violet moon
#

Hm, I do see you're creating an Invoice Item for the Customer. Can you try setting pending_invoice_items_behavior to include when you make the request to create the Invoice?
https://docs.stripe.com/api/invoices/create#create_invoice-pending_invoice_items_behavior

I would need to double check, but I think the API version you're using may not default to include there.

rain spade
#

Sure, let me try

#

I added and try it created invoice but charged 0 amount even in invoice item I added 15

#

In pending invoice item it shows 15$

#

but in invoices it was with 0$

violet moon
#

IDs please, requests and Invoice

rain spade
#

Invoice item req ID req_LI03TzMLv3MPPG

#

Invoice create req ID req_LsNueN9wno06rq

#

Invoice ID in_1PMWYKAMqFsdQ4zZO9YS3o60

violet moon
#

You're seeing this because you're working with a multi-currency Customer. Their default currency is usd, but hte Invoice Item you craeted is in eur. When you create the Invoice, you need to specify the currency of the Invoice Items you want to pull in if you aren't using the Customer's default. Can you try one more time, but set currency to eur when creating the Invoice?
https://docs.stripe.com/api/invoices/create#create_invoice-currency

https://docs.stripe.com/invoicing/multi-currency-customers#create-invoice-code

rain spade
#

I'm passing currency: 'eur', in stripe.invoiceItems.create

#

we have old currency USD for a card, but as I checked for sepa_debit need to use EUR.

#

so while stripe.invoiceItems.create I'm passing currency: EUR

violet moon
#

I know, that's why you need to pass it when creating the Invoice too.

#

If you don't, the Invoice is created in the Customer's default currency (usd) and isn't expected to pull in your eur Invoice Items.

rain spade
#

Yes is it possible to use multi currency ?

#

otherwise for sepa_debit we need to pass the currency conditionally.

violet moon
#

No, you can't mix currencies on a single Invoice. You can process Invoices for different currencies for a Customer though, as explained in the guide that I linked to above.

rain spade
#

Okay, Thanks Man for the help, you save me.

#

About others like ACH for US bank transfer does it work with EU country bank accounts?

violet moon
rain spade
#

Us bank transfer works with checkout session and future payment?

#

Becuase we want payment method for bank transfer that support checkout-session and can save payment method for auto future payment

violet moon
#

You can reference this page to figure that out for various Payment Method types:
https://docs.stripe.com/payments/payment-methods/integration-options

It shows that Bank Transfers can be used with Checkout Sessions, but only in payment mode:
https://docs.stripe.com/payments/payment-methods/integration-options#support-bank-transfers
because they don't support setup_future_usage:
https://docs.stripe.com/payments/payment-methods/integration-options#additional-api-bank-transfers

Learn about the different ways to integrate payment methods.

rain spade
#

okay thanks.

#

Due you have doc for Google pay integration?

#

and does it support setup mode?

violet moon
#

Google Pay can be found on that page in the Wallets categories. A guide for enabling it for which type of integration, the instructions vary a bit depending on whether you're using Payment Element, Checkout Sessions, mobile integrations, etc.

rain spade
#

We're using checkout session in web

violet moon
rain spade
#

okay, sure thanks.

violet moon
#

Any time!