> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 그룹

> PlayFab 엔터티 그룹과 해당 역할, 구성원, 초대, 신청 및 차단을 관리합니다.

`playfab group` 명령 패밀리는 실험적 기능입니다. CLI 인터페이스는 피드백에 따라 변경되거나 제거될 수
있습니다.

PlayFab 엔터티 그룹과 해당 역할, 구성원, 초대, 신청 및 차단을 관리하고, 엔터티가 속한 그룹을 나열합니다.

대부분의 명령은 `--group-id`로 그룹을 대상으로 지정하며, `group get`은 대신 `--group-name`을 사용할 수
있습니다. `--entity-id`와 `--entity-type`은 `--entity-type title_player_account`처럼 함께 전달하세요.
플레이어의 경우 마스터 플레이어 계정 ID가 아니라 타이틀 플레이어 계정 ID를 전달하세요.
[`playfab player account get`](https://docs.xbox.com/ko/tools/xbox-cli/commands/playfab/player)은 이 ID를
`UserInfo.TitleInfo.TitlePlayerAccount.Id`로 반환합니다.

`group delete`와 `group role delete`는 터미널에서는 먼저 묻고, 그 밖의 환경에서는 `--confirm`이 필요합니다.
`group member remove`를 포함하여 그룹을 변경하는 다른 명령은 묻지 않고 실행됩니다.
[안전 및 파괴적 작업](https://docs.xbox.com/ko/tools/xbox-cli/safety.md)을 참조하세요.

## 그룹 수명 주기

| 명령 | PlayFab API 경로 | 옵션 |
| - | - | - |
| `playfab group create` | `/Group/CreateGroup` | `--group-name` 필수, 선택적 소유자 `--entity-id`, `--entity-type`. |
| `playfab group get` | `/Group/GetGroup` | `--group-id` 또는 `--group-name`. |
| `playfab group update` | `/Group/UpdateGroup` | `--group-id` 필수, 선택적 `--group-name`, `--admin-role-id`, `--member-role-id`, `--expected-profile-version`. |
| `playfab group delete` | `/Group/DeleteGroup` | `--group-id` 필수. |

## 그룹 구성원

| 명령 | PlayFab API 경로 | 옵션 |
| - | - | - |
| `playfab group member add` | `/Group/AddMembers` | `--group-id`, `--member-ids`, `--member-type` 필수, 선택적 `--role-id`. |
| `playfab group member remove` | `/Group/RemoveMembers` | `--group-id`, `--member-ids`, `--member-type` 필수, 선택적 `--role-id`. |
| `playfab group member change-role` | `/Group/ChangeMemberRole` | `--group-id`, `--member-ids`, `--member-type`, `--origin-role-id`, `--destination-role-id` 필수. |
| `playfab group member list` | `/Group/ListGroupMembers` | `--group-id` 필수. |
| `playfab group member is-member` | `/Group/IsMember` | `--group-id`, `--entity-id`, `--entity-type` 필수, 선택적 `--role-id`. 읽기만 합니다. |

## 그룹 역할

| 명령 | PlayFab API 경로 | 옵션 |
| - | - | - |
| `playfab group role create` | `/Group/CreateRole` | `--group-id`, `--role-id`, `--role-name` 필수. |
| `playfab group role update` | `/Group/UpdateRole` | `--group-id`, `--role-id`, `--role-name` 필수, 선택적 `--expected-profile-version`. |
| `playfab group role delete` | `/Group/DeleteRole` | `--group-id` 및 `--role-id` 필수. |

## 그룹 초대

| 명령 | PlayFab API 경로 | 옵션 |
| - | - | - |
| `playfab group invite send` | `/Group/InviteToGroup` | `--group-id`, `--entity-id`, `--entity-type` 필수, 선택적 `--role-id`, `--auto-accept`. |
| `playfab group invite accept` | `/Group/AcceptGroupInvitation` | `--group-id` 필수, 선택적으로 수락하는 엔터티의 `--entity-id`, `--entity-type`. |
| `playfab group invite remove` | `/Group/RemoveGroupInvitation` | `--group-id`, `--entity-id`, `--entity-type` 필수. |
| `playfab group invite list` | `/Group/ListGroupInvitations` | `--group-id` 필수. |

`invite send`에서 `--auto-accept`의 기본값은 `true`입니다. 엔터티가 이미 그룹에 신청한 경우 PlayFab은 초대를
보내는 대신 신청을 수락합니다.

## 그룹 신청

| 명령 | PlayFab API 경로 | 옵션 |
| - | - | - |
| `playfab group application apply` | `/Group/ApplyToGroup` | `--group-id` 필수, 선택적으로 신청자의 `--entity-id`, `--entity-type`, `--auto-accept`. |
| `playfab group application accept` | `/Group/AcceptGroupApplication` | `--group-id` 필수, 선택적으로 신청자의 `--entity-id`, `--entity-type`. |
| `playfab group application remove` | `/Group/RemoveGroupApplication` | `--group-id`, `--entity-id`, `--entity-type` 필수. |
| `playfab group application list` | `/Group/ListGroupApplications` | `--group-id` 필수. |

`application apply`에서 `--auto-accept`의 기본값은 `true`입니다. 그룹이 이미 엔터티를 초대한 경우
PlayFab은 신청을 생성하는 대신 초대를 수락합니다.

## 그룹 차단

| 명령 | PlayFab API 경로 | 옵션 |
| - | - | - |
| `playfab group block add` | `/Group/BlockEntity` | `--group-id`, `--entity-id`, `--entity-type` 필수. |
| `playfab group block remove` | `/Group/UnblockEntity` | `--group-id`, `--entity-id`, `--entity-type` 필수. |
| `playfab group block list` | `/Group/ListGroupBlocks` | `--group-id` 필수. |

## 엔터티 멤버 자격

| 명령 | PlayFab API 경로 | 옵션 |
| - | - | - |
| `playfab group membership list` | `/Group/ListMembership` | 선택적 `--entity-id`, `--entity-type`. 호출하는 엔터티를 대상으로 하려면 둘 다 생략하세요. |
| `playfab group membership opportunity list` | `/Group/ListMembershipOpportunities` | 선택적 `--entity-id`, `--entity-type`. 호출하는 엔터티를 대상으로 하려면 둘 다 생략하세요. |

## 테이블 출력

다음 명령은 `--output table`을 허용하며, 다른 명령은 허용하지 않습니다.
[테이블 출력](https://docs.xbox.com/ko/tools/xbox-cli/commands.md#table-output)을 참조하세요.

| 명령 | 열 |
| - | - |
| `playfab group member list` | `MEMBER ID`, `MEMBER TYPE`, `ROLE ID` |
| `playfab group invite list` | `INVITED ENTITY`, `ROLE ID`, `EXPIRES` |
| `playfab group application list` | `ENTITY`, `EXPIRES` |
| `playfab group block list` | `BLOCKED ENTITY`, `ENTITY TYPE` |
| `playfab group membership list` | `GROUP ID`, `GROUP NAME` |
| `playfab group membership opportunity list` | `TYPE`, `GROUP ID`, `ROLE ID`, `EXPIRES` |

`member list`는 각 역할의 각 구성원마다 행을 하나씩 표시하므로, 두 역할에 속한 구성원은 두 행으로 표시되고,
구성원이 없는 역할은 구성원이 `-`인 한 행으로 표시됩니다. `membership opportunity list`는 초대와 신청을 하나의
표에 표시합니다. `TYPE`은 `invitation` 또는 `application`이고, 신청의 경우 `ROLE ID`는 `-`입니다.

## 예제

그룹을 읽고, 구성원을 나열하고, 플레이어가 그룹에 속해 있는지 확인하고, 처리되지 않은 초대를 나열합니다.

```bash theme={null}
xbox --playfab-title-id ABC123 playfab group get --group-id GROUP123
xbox --playfab-title-id ABC123 playfab group member list --group-id GROUP123 --data-only --output json-compact
xbox --playfab-title-id ABC123 playfab group member is-member --group-id GROUP123 --entity-id TITLEPLAYER123 --entity-type title_player_account
xbox --playfab-title-id ABC123 playfab group invite list --group-id GROUP123 --output table
```

플레이어를 그룹에 초대합니다.

```bash theme={null}
xbox --playfab-title-id ABC123 playfab group invite send --group-id GROUP123 --entity-id TITLEPLAYER123 --entity-type title_player_account
```

그룹을 삭제합니다.

```bash theme={null}
xbox --playfab-title-id ABC123 playfab group delete --group-id GROUP123 --confirm
```


## Related topics

- [대상 그룹](https://docs.xbox.com/ko/tools/xbox-cli/commands/audience.md)
- [제품 그룹](https://docs.xbox.com/ko/publishing/game-publishing/concepts/product-groups.md)
- [그룹 삭제](https://docs.xbox.com/ko/services/playfab/api-references/rest/groups/groups/delete-group.md)
- [엔터티 그룹](https://docs.xbox.com/ko/services/playfab/community/associations/groups/quickstart.md)
- [그룹 순위표](https://docs.xbox.com/ko/services/playfab/community/leaderboards/group-leaderboards.md)
