#khris22963
1 messages ยท Page 1 of 1 (latest)
Hi there
You want to specify a trial period in this case
Otherwise you will still be creating an initial Invoice here
Which will involve a PaymentIntent
Not a SetupIntent
Ok, I seem to be getting a lot of conflicting advice today ๐
Ah well I'm sorry to hear that.
If you lay out your use-case I'd be happy to help ensure you are on the right track
thank you ๐
Ok, my client is a not-for-profit organisation. I host a website for my client who wants to collect online donations.
So a donor wants to set up a recurring gift... monthly, for example, so visits the page having logged in, specifies the monthly payment amount, and the future date on which the first payment is to be collected.
I want to present the donor with the Payments Element, collect payment details either card or BACS direct debit, and then record all the details server side for later reporting
Got it
Then yep you want to do as I noted. Since you want to trigger future payment you want to use a trial period.
You don't need to explicitly set a billing_cycle_anchor at all, you just let the trial handle that.
Ok.
So when I got this working for one-off payments, I created a Payment Intent, and used its client secret in the Options when I created the Payments element using stripe.js
Yep
is there still a client secret in the recurring case?
Yep when you set a trial the pending_setup_intent will no longer be null
ahhhhhhhhh
so you expand: pending_setup_intent
got it
Then grab its client_secret and pass it to the frontend
the secret piece of crucial information!!!!!!!!
๐
so how do I avoid any initial payment being taken?
Since it is on trial there will be no initial payment
Ah ok
That is the point of the trial
I think my IQ is decreasing in proportion to the number of hours I spend in the documentation
lol
which at this point is considerable ( the number of hours that is, no longer my IQ ๐
Ok, many thanks, I'll give that a go
Well dang that is not how it is supposed to work!
If you do have feedback don't hesitate to let us know
We are always trying to improve our docs
They are amazing
But yeah there is a lot in there so I can totally understand how it can be overwhelming
But huge, and there always seems to be a crucial detail not spelled out for noobs like me
It definitely is a hard balance to figure out what the right amount of info is
Anywho if you ever do get stuck don't hesitate to pop in this channel
We are here 24/5
thank you so much for your time, I do appreciate it. I guess you have a real job to do as well, so that's double the appreciation
gosh, how do you stay sane with all the numpties like me?
eek ๐
Ok, I'll try again. It is gradually starting to make sense
thank you again
Good luck!