#mochihealth

1 messages · Page 1 of 1 (latest)

ocean lintelBOT
raven crown
#

I don't think there is an automatic setting for that (will double check) but you can definitely cancel and refund through the API.

regal dagger
#

yea that would be great i see that there is a proration option but is there a way to refund the entire amount through the api

raven crown
#

What is the call that you are currently making that is doing this proration? Can you send me the code?

regal dagger
#

I'm not doing any calls right now im just looking at the api

#

and it doesnt seem like a way from what i can tell to do a full refund

#

but im also not super familiar wit h the api so maybe you would know

#

i see that there is a refund api

#

but is that fully compatible with the subscriptions api

raven crown
#

Gotcha. You are looking at it correctly there, as best as I can tell, the cancel call itself doesn't have an option for a full refund. I think the simplest way to achieve what you want to here would be a cancel call without proration and then a call to create a refund for the full amount

#

Yes, it is compatible, you can just pass it the charge or payment intent ID from their first payment

#

The subscription has a latest_invoice, if you get its details it will have a payment_intent that you can use to create this refund

regal dagger
#

is there a way to cancel a subscription fully and just change thecancel_at_period_end

#

change

#

sorry i hit enter to soon

#

this doesnt make sense lol

#

can i cancel the subscription right away without waiting for the subscription period to end

raven crown
#

Gotcha, I'll wait for the full one

regal dagger
#

because right now i can just set the cancel_at_period_end field to true but that waits until the billing cycle to end

#

and if i refund someone i dont want them to have an active subscription

raven crown
#

Making that cancel call directly would be the best way to do that. It would cancel the subscription now and change its status accordingly

regal dagger
#

gotcha

#

thanks this helps

#

can you point me to the refund api

raven crown
regal dagger
#

thank you