BDK Payment Help - Set Subscription Status To Canceled

Hi there, I am wrapping my app with The BDK. I’ve created it in Bubble as a single page app.

I am using BDK to trigger and process payments on ios + android.

Right now, my app has a setting under User called “Subscription Status”. There, you can pick from one of three settings: inactive, active and canceled.

Inactive is set for every User as a default when they are created.
When a BDK payment in ios or android is activated, the Subscription Status updates to “active”.
When an account is “active” various features are unlocked.

This is all working.
The last step has me stumped.

I followed along the BDK tutorial and @gaurav uses a backend workflow to set the subscriptions expiry date.

I’d like to check, and if the subscription is not paid after the expiry date, then it should be marked as canceled.

This is what I tried. Any suggestions?

Thanks for your help - Its just a bit difficult because there is no way to test this until it’s live and wrapped.