LoginSignup
0
0

アダプティブカードのAction.SubmitボタンのDataをPowerAutomateで抽出

Last updated at Posted at 2024-02-03

背景

TeamsチャットへPowerAutomateでアダプティブカードを送信してワンクリックで勤務状況報告できるようにしようとしてプチハマり。

アダプティブカードイメージ図
イメージ図

クリックされた各ボタンのDataをPowerAutomateで抽出する方法について。

アダプティブカード側の設定

Designerにて、まずは各ボタンのDataプロパティ値をセットするが、{"Key":"Value"}の形式で記載必要。
image.png
image.png
Keyは同じにしておいてValueをそれぞれのボタンで変更し、押されたボタンのValueでその後の処理を条件分岐させる作戦。

PowerAutomate側の設定

image.png
下記の数式でトリガーからデータの抽出。
triggerBody()?['entity']?['cardOutputs']?['Key']
Keyはアダプティブカード作成時に設定したもの。
PerseJSONでの抽出も試みたが何故かできなかった。。。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0