LoginSignup
0
1

More than 1 year has passed since last update.

PowerAutomate: Parent Message ID (スレッドの親 ID) が取得出来るようになった。⇒ For a selected message でスレッド内返信が可能に

Posted at

背景

Teams の Message Details (メッセージの詳細)を取得する際

  • 返信したいメッセージID

ではなく、

  • 返信したいメッセージIDの親のメッセージID(スレッドの最初の投稿メッセージID)

が必要です。

以前は 親のメッセージID (Parent Message ID) を取得することが出来なかったはずなんだけど、いつの間にか出来るようになってましたってお話

Get Message Details
【日本語版】⇒ メッセージ詳細を取得する

以下で指定する ID です
image.png

取れるもの

元々困っていた、For a selected message トリガーと、取得アクション自体での結果を例示

Parent Message ID という名前ではなく、Reply To ID で存在。

トリガー: For a selected message

For a selected message (V2)
【日本語版】⇒ 選択されたメッセージに対して (V2)

Parent Message ID の取得
@{triggerBody()?['teamsFlowRunContext']?['messagePayload']?['replyToId']}

2022-08-31_14h59_25.png

アクション: Get Message Details 自身からも取得出来ます

Get Message Details
【日本語版】⇒ メッセージ詳細を取得する

Parent Message ID の取得
@{outputs('Get_message_details')?['body/replyToId']}@{triggerBody()?['teamsFlowRunContext']?['messagePayload']?['subject']}

2022-08-31_15h49_29.png

ドキュメント

以下記載なので、不明

Returns
The outputs of this operation are dynamic.

2022-08-31_13h45_40.png

2022-08-31_13h46_10.png

あとがき

これで、For a selected message を使って、スレッド内返信が出来るようになりました

0
1
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
1