#leslie_api

1 messages ¡ Page 1 of 1 (latest)

idle solarBOT
#

👋 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/1257432948286689351

📝 Have more to share? Add details, code, screenshots, videos, etc. below.

marble halo
#

Thanks for the code, looking in to the proper syntax here

fresh pier
#

To add some more examples:

Stripe::SubscriptionSchedule.cancel('sub_sched_xxxxxx', { stripe_account:  'acct_xxxxx', idempotency: 'xxxxxxx'}) - Error
Stripe::SubscriptionSchedule.cancel('sub_sched_xxxxxx', { stripe_account:  'acct_xxxxx'}) - Error
Stripe::SubscriptionSchedule.cancel('sub_sched_xxxxxx', stripe_account:  'acct_xxxxx') - Error
Stripe::SubscriptionSchedule.cancel('sub_sched_xxxxxx') - Cannot find schedule for Connect Account
marble halo
#

Can you try an extra empty set of curly braces?
Stripe::SubscriptionSchedule.cancel('sub_sched_xxxxxx', {}, { stripe_account: 'acct_xxxxx', idempotency: 'xxxxxxx'})

#

I am still looking, I know one of our client libraries has a syntax like this but I forget if it is stripe-ruby

fresh pier
#

I will try that syntax and yes I am using Stripe Ruby

#

That works Thanks!

#

As a side note, is there a complete endpoint?

#

It isnt in the docs, so I set my system up to use the cancel endpoint

#

The complete endpoint is what I would have actually wanted, but I also understand if it doesnt make sense to have that

marble halo
#

Glad that worked! Unfortunately, we don't have a Complete endpoint. It looks like we only have Cancel and Release at the moment. So you may need to retrieve or record the behavior that you have at the end of the schedule and make the proper call from there

idle solarBOT
fresh pier
#

Ok, thanks again for the help!