Get started with button trigger tokens
What are button trigger tokens?
Button trigger tokens are data points that are known and available to the device on which a button flow is running. These tokens change based on factors such as the current time or the geographic location of the device at a given moment.
For example, if you are running a button flow on a smart phone, it is likely that the phone knows the time at your current location as well as the date and your current address. In this context, the time, date and address where the phone is located are all determined at the time the button flow runs. They are automatically available for use in any button flows that are executed on the device. You can use these trigger tokens to build useful flows that will minimize repetitive tasks such as providing your location to someone or tracking how much time you spent on a particular job/service call.
List of button trigger tokens
Here's the list of the button trigger tokens that are available for you to use when creating your button flows.
|City||The city in which the device that's running the flow is located.|
|Country/Region||The country/region in which the device that's running the flow is located.|
|Full address||The full address where the device that's running the flow is located.|
|Latitude||The latitude in which the device that's running the flow is located.|
|Longitude||The longitude in which the device that's running the flow is located.|
|PostalCode||The postal code in which the device that's running the flow is located.|
|State||The state in which the device that's running the flow is located.|
|Street||The street on which the device that's running the flow is located.|
|Timestamp||The time in the area where the device that's running the flow is located.|
|Date||The date in the area where the device that's running the flow is located.|
|User name||The user name of the person signed into the device that's running the flow.|
|User email||The email address of the person signed into the device that's running the flow.|
Create a button flow that uses trigger tokens
When you create a button, you can use trigger tokens to add rich functionality to your button.
In this walk-through, we will create a button flow on an Android device. The button flow will use trigger tokens to send the date and your full address in a "Working from home" email to your boss.
In this walk-through, you will see screen-shots from an Android device, however, the experience is similar on iOS and Windows Phone devices as well.
- A work or school email address or a Microsoft Account with access to Microsoft Flow.
- The Microsoft Flow mobile app for Android, iOS, or Windows Phone.
Let's get started:
- Launch Flow and select Browse
- Select the Send a 'Working from home today' email to your manager service under the Button category
- Select USE THIS TEMPLATE
- Select Edit on the Send an email card
- Tap the Subject text box and enter: " today - " into the text box after the "WFH" text. Notice that when you tapped on the text box, a list of parameters/tokens also opened up. We'll use one of these tokens in the next step to add the date to the subject of the email.
- With the cursor still in the subject text box, scroll to the manual list of parameters and tap Date. Notice the date parameter is now in the Subject text box:
- Scroll to the Body text box and tap after the default message so that additional tokens can be included there.
- Tap the Full address parameter, then tap Create
- Tap Done. Your button flow is now created.
Run the button flow
NOTE: This button flow will send your current location via email.
- Tap the Buttons category at the bottom of the screen. You will see a list of the buttons that you have permissions to use. Tap the button that represents the button flow you just created:
- Tap ALLOW to indicate that it's OK for the button flow to access your device's location information:
- Within a few moments, notice that the email was sent to your boss:
Congratulations, you've just created a button flow that uses both the date and full address trigger tokens.
Send feedback about: