- リリース ノート
- 概要
- 基本情報
- Marketplace ベンダー
- Marketplace のお客様
- パブリッシング ガイドライン
- すぐに使えるオートメーションのパブリッシング ガイドライン
- ソリューション アクセラレータの公開ガイドライン
- Integration Service コネクタの公開ガイドライン
- Process Mining アプリ テンプレートのパブリッシュ ガイドライン
- セキュリティと IP 保護
- その他の UiPath コンポーネント
- Node-RED
- セットアップ
- クイックスタート - チーム、チャンネル、メッセージを取得する
- クイックスタート - チャットを取得してメッセージを送信する
- Teams
- Microsoft Teams Scope
- Create Team
- Create Team from Group
- Get Team
- Get Teams
- Channels
- チャンネルを作成
- Delete Channel
- Get Channel
- Get Channels
- Update Channel
- Chats
- Get Chat
- Get Chats
- Get Chat Members
- Messages
- メッセージを取得
- メッセージを取得
- Get Message Replies
- メッセージに返信
- メッセージを送信
- イベント
- イベント/予定を作成
- イベント/予定を削除
- Get Event
- Get Events
- ユーザー
- Get User Presence
- 動作のしくみ
- テクニカル リファレンス
- はじめに
- 概要
- セットアップ
- テクニカル リファレンス
- Azure Form Recognizer Scope
- Activities (アクティビティ)
- Analyze Form
- Analyze Form Async
- Get Analyze Form Result
- Analyze Receipt
- Analyze Receipt Async
- Get Analyze Receipt Result
- Analyze Layout
- Analyze Layout Async
- Get Analyze Layout Result
- Train Model
- Get Models
- モデル キーを取得する
- Get Model Info
- モデルを削除
- コネクタ
- How to Create Activities
- 連携の独自開発

Marketplace ユーザー ガイド
Quickstart - get chats and send message
概要
The purpose of this guide is to help you create a working sample that uses different Microsoft Teams activities, including the Get Chats, Get Chat Members, Send Message and Get Message activities.
This working sample enables you to quickly verify the connection to your registered Microsoft Teams application and get familiar with the activity's input/output datatypes.
このページの手順を完了すると、以下のアクションを実行するオートメーション シーケンスが使用できるようになります。
-
Establishes a connection to your registered Microsoft Teams application (Microsoft Teams Scope).
-
Retrieves all of your chats (Get Chats).
-
Retrieves the members of each of your chats (For Each and Get Chat Members).
-
Locates the chat that includes a specific chat member and sends a message (If, Assign, and Send Message.
-
Verifies the message was sent successfully by retrieving and outputting the message Id and message content Get Message and Write Line).

前提条件
はじめる前に
- Complete the Microsoft Teams Setup steps.
- 既存のチャットを作成するか使用し、少なくとも1つのチャットメッセージを送信します。
手順
プロジェクトをビルドする
- Add the Microsoft Teams Scope activity to your project.
- Enter the ApplicationId for your registered application.
- For more information, see the Register your application section in Setup guide.
- From the AuthenticationType drop-down list, select the applicable authentication flow (for example, InteractiveToken).
- For more information, see the Unattended vs. Attended Automation in the Microsoft Teams Scope activity page.
- Add the Get Chats activity after the Microsoft Teams Scope activity.
- Create and enter a
Chat[]variable for your Chats value (e.g., myChats).- When creating your variable, select *Microsoft.Graph.Chat
- as the variable type.
- Add a For Each activity after the Get Chats activity.
- In the TypeArgument property, select Microsoft.Graph.Chat.
- In the Values property, enter the
Chat[]variable you created for the Get Chats activity (e.g., myChats).
- Create and enter a
- In the For Each activity, add an Assign.
- Create and enter a
Stringvariable for the To property (e.g., chatId) - In Value property, enter item.Id.
- Creating and assigning the *item.id
- value to this variable enables it to be used in a later For Each activity that has a different argument type.
- Add the Get Chat Members activity after the Assign activity.
- In the ChatId property, enter Item.Id to get the members for each chat.
- Create and enter a
ConversationMember[]variable for your ChatMembers value (e.g., myChatMembers).- When creating your variable, select *Microsoft.Graph.ConversationMember
- as the variable type.
- Add another For Each activity after the Get Chat Members activity.
- In the TypeArgument property, select Microsoft.Graph.ConversationMember.
- In the Values property, enter the
ConversationMember[]variable you created for the Get Chat Members activity (e.g., myChatMembers).
- Create and enter a
- In the For Each activity, add an If activity.
- In the Condition property, enter a value to identify a specific chat by member (e.g., item.DisplayName="Sarah Connor")
- In the Then sequence block, add the Send Message activity.
-
In the ChatId property, enter the
Stringvariable you created for the Assign activity (e.g., chatId). -
Enter your Body content that you want to send (e.g., "Just saying hi")
-
In the BodyType property, enter BodyType.Text.
-
Create and enter a new
Stringvariable for your MessageId value (e.g., newMessageId)
-
プロジェクトをテストする
-
To test that your activities retrieved your Chats, the Chat Members, and sent a Message, add a Write Line activity after the Send Message activity.
- In the Text property, enter the
Stringvariable you created for the Send Message activity (e.g., newMessageId)
- In the Text property, enter the
-
Add the Get Message activity after the Write Line activity.
-
In the ChatId property, enter the
Stringvariable you created for the Assign activity (e.g., chatId). -
In the MessageId property, enter the
Stringvariable you created for the Send Message activity (e.g., newMessageId).3 . Create and enter a
ChatMessagevariable for your Message value (e.g., newMessage).- When creating your variable, select Microsoft.Graph.ChatMessage as the variable type.
-
Add another Write Line activity after the Get Message activity.
-
In the Text property, enter the
ChatMessagevariable you created for the Get Message activity and append .Body.Content to the end of it (e.g. newMessage.Body.Content)
-
-
Click Run and verify the Output window includes your sent message Id and content.

完了です!
When you're ready, try the other Quickstart guides to get more familiar with the different Microsoft Teams activities.
Microsoft Teams アクティビティの詳細 (プロパティの入力/出力の例を含む) については、以下のアクティビティのページをご覧ください。すべてのアクティビティが記載されたリストと、アクティビティの詳細な説明ページへのリンクが記載されています。