We are currently processing charges via a stripe JS / elements form on our site. This works great for one-time charges, but we have a need as well to create customers and subscribe them to process subscriptions for auto-renewals.
Currently we have:
onFormLoad action that configures/draws the stripe element form
a window.stripe.createToken action tied to the pay button
a promise .then() action that sends the token data to FileMaker
a utility script in FileMaker that uses the token data to store the order data and charge/use the token.
This might not even be possible with elements, and we already have the ability to create stripe customer records from the filemaker side. It appears that creating a “source” instead of a “token” may be a way to go.
I believe in Stripe, “tokens” are one-time use only, and can’t be attached at all. I believe “sources” can be attached, but I’m not sure that stripe elements can create sources.
This is for an annual subscription and there is a checkbox to opt-in for recurring yearly payment of member dues.