#sunny_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/1291839608094720001
📝 Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi, what is your specific question here?
I have 5 questions that would unblock us from migrating our integration
Sending them now
- We made changes in our code so that our invoices would be created with the “customer balance” payment setting. We DO NOT want to collect bank details from customers. We use VBAN. Is that the correct way to create the invoice?
- The “source.chargeable” webhook is going away with PaymentIntents. Do we need to handle a replacement event webhook or can we get rid of that part of our code?
- As part of point 2, we manually reconcile in our code and try to pay an invoice. We pass in a source ID in the “invoice.pay” call. Since sources are going away, can we pay invoices without sources? Do we even need to do this since the event webhook is going away?
- We update source owners in certain cases to keep the customer email up to date. Since sources are going away, how do we achieve this so that Stripe contacts our customers using the right email?
- We use event webhooks related to invoices and the “charge.dispute.created” event webhook. Can we keep using them? Do we need to replace them or add any additional webhooks?
We made changes in our code so that our invoices would be created with the “customer balance” payment setting. We DO NOT want to collect bank details from customers. We use VBAN. Is that the correct way to create the invoice?
I'm unsure what 'we use VBAN mean', but the context of the question makes it sound like you're referring to Bank Transfers. If so, we support Bank Transfers in a limited number of countries: https://docs.stripe.com/payments/bank-transfers. This payment method provides customers with a virtual bank account number that they can push money to from their own online bank interface or in-person bank branch.
The “source.chargeable” webhook is going away with PaymentIntents. Do we need to handle a replacement event webhook or can we get rid of that part of our code?
No, there is not an equivalent here: https://docs.stripe.com/api/events/types#event_types-source.chargeable. Can you share more what this code looks like?
As part of point 2, we manually reconcile in our code and try to pay an invoice. We pass in a source ID in the “invoice.pay” call. Since sources are going away, can we pay invoices without sources? Do we even need to do this since the event webhook is going away?
You can make the pay invoice call using the payment method collected, https://docs.stripe.com/api/invoices/pay#pay_invoice-payment_method. It would work the same way.
We update source owners in certain cases to keep the customer email up to date. Since sources are going away, how do we achieve this so that Stripe contacts our customers using the right email?
You can update the customer object, https://docs.stripe.com/api/customers/update and update the email address.
We use event webhooks related to invoices and the “charge.dispute.created” event webhook. Can we keep using them? Do we need to replace them or add any additional webhooks?
Yes, you can: https://docs.stripe.com/disputes/responding.
- Yes we want to switch to bank transfers
- Can I share screenshot of our code for the webhook here?
- We are not creating a payment method. A support rep told us we don’t need to. We are using “customer balance”. Is your suggestion to still create a payment method with “customer balance” as the type for the customer and use that?
- Thank you for this
- Thank you for this
Customer balance is for Bank Transfer payment methods. I highly recommend that you review this, https://docs.stripe.com/payments/bank-transfers/accept-a-payment.
Yes that is what we want to do
Can you copy and paste the code instead?
Yes give me a moment
Let me copy paste it
Give me a second
This webhook is going away. So can we get rid of this function and logic or do we still need to handle this some other way?
I think that code is handling reconciliation. Correct me if I'm wrong. In this case, Bank Transfers has automatic reconciliation: https://docs.stripe.com/payments/bank-transfers#customer-balance. We send customer_cash_balance_transaction.created event with type: "funded" first. This lets you know that this transaction happened because the customer added funds. Then, we send another customer_cash_balance_transaction.created event letting you know that the funds were used. This is indicated with type: "applied_to_payment" on the event. You can learn more about it here: https://docs.stripe.com/api/events/types#event_types-customer_cash_balance_transaction.created and https://docs.stripe.com/payments/customer-balance.
If the customer has funds, https://docs.stripe.com/payments/customer-balance#view-balance that you want to use to a payment, you can: https://docs.stripe.com/payments/customer-balance#make-cash-payment. If funds are held in the customer balance for more than 75 days, Stripe automatically attempts to return the funds to the customer’s bank account.
Correct me if I'm wrong.
Yes that is what we are trying to do here.
If bank transfers have the automatic reconciliation, do we need to still handle it using the customer_cash_balance_transaction.created event?
You do not need to handle anything. What you do with these events is up to your integration and what you want to do with the data.
Okay sounds good.
Thank you
This should resolve all of the questions and doubts we had but if any additional questions come up can I use this thread to ask more questions?
We will be here for the next 30-40 minutes, yes. This channel will be closed for the weekend but we will here on Monday.
Okay sounds good.
Thank you so much!