Creating Actions from App Intents iOS16

I’m new to the Automators. And most of the podcasts go over my head but I enjoy them nonetheless.
I’m playing around with programming “App Intents” which are new in iOS 16.
I am able to do Siri intents and programmatically create shortcuts. But I would like to extract values from my app and use them for actions in automations.
Has anyone done this?
Here is a simplistic example video. I would like to use a value from Counter to perform an action.
Thank you,

I am no content superstar.
App Intents Demo

Doable with App Storage and AppGroup Capability

Add AppGroups to your app target AND to your shortcut (intent) target.

The use e.g.

@AppStorage("Counter", store: UserDefaults(suiteName: "group.com.company.AppGroupName")) var Counter: Double = 0.0

Transfer your Counter variable via Intent to Shortcut (I am always using text in kind of json format to hand over multiple variables to Shortcuts app) … In Shortcuts App, just use Dictionary to read out your specific variable .