

# Microsoft Teams エンティティからの読み取り
<a name="microsoft-teams-reading-from-entities"></a>

 **前提条件** 
+  読み取り元の Microsoft Teams オブジェクト。team または channel-message などのオブジェクト名が必要です。次の表に、サポートされているエンティティを示します。

 **ソースに対応するエンティティ** 

 すべてのエンティティは API バージョン 1.0 でサポートされています。


| エンティティ | フィルタリング可能 | 制限をサポートする | Order By をサポートする | Select \* をサポートする | パーティショニングをサポートする | 
| --- | --- | --- | --- | --- | --- | 
| チーム | なし | なし | なし | あり | なし | 
| Team Members | はい | あり | なし | あり | あり | 
| グループ | はい | あり | あり | あり | あり | 
| Group Members | はい | あり | なし | あり | なし | 
| チャンネル | あり | なし | なし | あり | あり | 
| Channel Messages | なし | あり | なし | あり | なし | 
| Channel Message Replies | なし | あり | なし | あり | なし | 
| Channel Tabs | あり | なし | なし | あり | なし | 
| Chats | はい | あり | あり | あり | あり | 
| Calendar Events | はい | あり | あり | あり | あり | 

 **例** 

```
MicrosoftTeams_read = glueContext.create_dynamic_frame.from_options(
    connection_type="MicrosoftTeams",
    connection_options={
        "connectionName": "connectionName",
        "ENTITY_NAME": "company",
        "API_VERSION": "v1.0"
    }
```

## Microsoft Teams エンティティとフィールドの詳細
<a name="microsoft-teams-entity-and-field-details"></a>

 エンティティリスト: 
+  Team: [ https://docs.microsoft.com/en-us/graph/api/user-list-joinedteams?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/user-list-joinedteams?view=graph-rest-1.0) 
+  Team-Member: [ https://docs.microsoft.com/en-us/graph/api/team-list-members?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/team-list-members?view=graph-rest-1.0) 
+  Group: [ https://docs.microsoft.com/en-us/graph/api/group-list?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/group-list?view=graph-rest-1.0) 
+  Group-Member: [ https://docs.microsoft.com/en-us/graph/api/group-list-members?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/group-list-members?view=graph-rest-1.0) 
+  Channel: [ https://docs.microsoft.com/en-us/graph/api/channel-list?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/channel-list?view=graph-rest-1.0) 
+  Channel-Message: [ https://docs.microsoft.com/en-us/graph/api/channel-list-messages?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/channel-list-messages?view=graph-rest-1.0) 
+  Channel-Message-Reply: [ https://docs.microsoft.com/en-us/graph/api/chatmessage-list-replies?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/chatmessage-list-replies?view=graph-rest-1.0) 
+  Channel-Tab: [ https://docs.microsoft.com/en-us/graph/api/channel-list-tabs?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/channel-list-tabs?view=graph-rest-1.0) 
+  Chat: [ https://docs.microsoft.com/en-us/graph/api/chat-list?view=graph-rest-1.0 ]( https://docs.microsoft.com/en-us/graph/api/chat-list?view=graph-rest-1.0) 
+  Calendar-Event: [ https://docs.microsoft.com/en-us/graph/api/group-list-events?view=graph-rest-1.0 ](https://docs.microsoft.com/en-us/graph/api/group-list-events?view=graph-rest-1.0) 

 **パーティショニングクエリ** 

 Spark で同時実行を使用する場合は、追加の Spark オプション `PARTITION_FIELD`、`LOWER_BOUND`、`UPPER_BOUND`、および `NUM_PARTITIONS` を指定できます。これらのパラメータを使用すると、元のクエリは Spark タスクで同時に実行できるサブクエリの `NUM_PARTITIONS` の数に分割されます。
+  `PARTITION_FIELD`: クエリのパーティション化に使用するフィールドの名前。
+  `LOWER_BOUND`: 選択したパーティションフィールドの包括的な下限値。

   日付については、Spark SQL クエリで使用される Spark の日付形式を受け入れます。有効な値の例: `"2024-02-06"`。
+  `UPPER_BOUND`: 選択したパーティションフィールドの排他的上限値。
+  `NUM_PARTITIONS`: パーティション数。

 エンティティごとのパーティション分割フィールドのサポートの詳細は、以下の表にまとめられています。


| エンティティ名 | パーティション分割フィールド | データタイプ | 
| --- | --- | --- | 
| Team Members | visibleHistoryStartDateTime | DateTime | 
| グループ | createdDateTime | DateTime | 
| チャンネル | createdDateTime | DateTime | 
| Chats | createdDateTime、lastModifiedDateTime | DateTime | 
| Calendar Events | createdDateTime、lastModifiedDateTime、originalStart | DateTime | 

 **例** 

```
microsoftteams_read = glueContext.create_dynamic_frame.from_options(
    connection_type="MicrosoftTeams",
    connection_options={
        "connectionName": "connectionName",
        "ENTITY_NAME": "group",
        "API_VERSION": "v1.0",
        "PARTITION_FIELD": "createdDateTime"
        "LOWER_BOUND": "2022-07-13T07:55:27.065Z"
        "UPPER_BOUND": "2022-08-12T07:55:27.065Z"
        "NUM_PARTITIONS": "2"
    }
```