#akdj16 - subscription updates

1 messages ยท Page 1 of 1 (latest)

civic tapirBOT
half jetty
#

Hi ๐Ÿ‘‹

silk musk
#

Hi!

half jetty
#

The Subscription object does not contain an updated timestamp

#

Stripe saves snapshots of each change that is made though.

silk musk
#

ok, is there a way to get when it is updated?

half jetty
#

Well the easiest way would be to listen for the customer.subscription.updated event and log it yourself.

silk musk
#

ok, I am using it already for saving data in my DB, but to avoid timing issue (very rare) I need to use a cron to get all subscription from strip and update the DB data. And I would like to compare data to only update subscriptions that's not synchronized

half jetty
#

Ah I see

#

I can understand that

silk musk
#

nevermind, I will try to find out other way ๐Ÿ™‚ thanks!

#

if you have some idea, don't hesitate to tell me ๐Ÿ™‚

half jetty
#

I can raise this as a feature request but I think the reason we don't expose this is that some users would expect the updated timestamp to only be changed when they make changes to the Subscription but others would expect it to update whenever there are any changes to the Subscription.

#

Return all the customer.subscription.updated events and inspect the created timestamp on the Event object as the time the update occurred.

silk musk
#

ok, thank you a lot ๐Ÿ™‚

half jetty
#

Happy to help ๐Ÿ™‚

pastel solar
#

akdj16 - subscription updates