> ## 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.

# 세그먼트의 플레이어 내보내기 자습서

> GetPlayersInSegment를 대체하는 최신 API인 ExportPlayersInSegment 및 GetSegmentExport API를 사용하여 세그먼트에서 PlayFab 플레이어 프로필을 내보냅니다.

# 세그먼트의 플레이어 내보내기

이 자습서는 ExportPlayersInSegment API와 GetSegmentExport API를 사용하여 세그먼트의 플레이어 프로필을 내보내는 데 필요한 단계를 안내합니다. 이 API는 GetPlayersInSegment API의 더 새롭고 개선된 버전입니다.

### 1단계

페이로드로 세그먼트 ID를 사용하여 ExportPlayersInSegment API에 POST 요청을 보냅니다. 응답의 ‘ExportId‘는 내보내기 작업의 고유 식별자입니다.

![세그먼트에서 플레이어 내보내기](https://mintcdn.com/microsoft-4404708b/IwSYTY5BEqd_x-HK/images/playfab/data-analytics/acting-data/ExportPlayersInSegment.png?fit=max\&auto=format\&n=IwSYTY5BEqd_x-HK\&q=85\&s=0f535cbc01662f81a695bf25de88b330)

> [!NOTE]
>
> 이 API에는 값이 타이틀 비밀 키인 ‘X-SecretKey’ 헤더가 필요합니다. ‘Content-Type’ 헤더는 ‘application/json’으로 설정되어야 합니다.

### 2단계

위 API 호출에서 받은 ExportId를 페이로드로 사용하여 GetSegmentExport API에 POST 요청을 보냅니다. 응답에는 내보내기 작업의 ‘State’가 있습니다. 내보내기 상태가 ‘Complete’인 경우, 응답에는 인덱스 파일을 다운로드할 수 있는 ‘IndexUrl’이 포함됩니다.

![세그먼트 내보내기 가져오기](https://mintcdn.com/microsoft-4404708b/IwSYTY5BEqd_x-HK/images/playfab/data-analytics/acting-data/GetSegmentExport.png?fit=max\&auto=format\&n=IwSYTY5BEqd_x-HK\&q=85\&s=4aa11d28756553e3af3c78c76124adb0)

> [!NOTE]
>
> 이 API에는 값이 타이틀 비밀 키인 ‘X-SecretKey’ 헤더가 필요합니다. ‘Content-Type’ 헤더는 ‘application/json’으로 설정되어야 합니다.

### 3단계

IndexUrl에서 인덱스 파일을 다운로드합니다. 인덱스 파일은 각 줄이 세그먼트의 플레이어 프로필 조각을 다운로드할 수 있는 URL인 파일입니다. 다음은 인덱스 파일의 예입니다. 인덱스 파일에는 2개의 URL(내보내기 조각)이 있습니다.

![Index File.png](https://mintcdn.com/microsoft-4404708b/IwSYTY5BEqd_x-HK/images/playfab/data-analytics/acting-data/IndexFile.png?fit=max\&auto=format\&n=IwSYTY5BEqd_x-HK\&q=85\&s=0de6e8a4519b5ded129f982e779f44d3)

### 4단계:

인덱스 파일의 각 줄을 반복하여 각 URL에서 플레이어 프로필을 다운로드합니다. 플레이어 프로필 파일은 tsv 형식을 사용합니다. 예를 들어, 위 인덱스 파일의 첫 번째 URL에서 다운로드한 플레이어 프로필은 다음과 같습니다:

![인덱스 파일 URL에서 검색된 플레이어 프로필](https://mintcdn.com/microsoft-4404708b/IwSYTY5BEqd_x-HK/images/playfab/data-analytics/acting-data/PlayerProfilesRetrievedFromTheIndexFileURL.png?fit=max\&auto=format\&n=IwSYTY5BEqd_x-HK\&q=85\&s=ddd0cccdadb1aa046e579e594ec6eafb)


## Related topics

- [세그먼트의 플레이어 수 계산 자습서](https://docs.xbox.com/ko/services/playfab/live-service-management/game-configuration/segmentation/segmentation-player-count.md)
- [세그먼트의 플레이어 내보내기](https://docs.xbox.com/ko/services/playfab/api-references/rest/admin/play-stream/export-players-in-segment.md)
- [플레이어 사용자 지정 속성을 활용한 고급 세그멘테이션](https://docs.xbox.com/ko/services/playfab/live-service-management/game-configuration/segmentation/advanced-segmentation.md)
- [Economy V2 타깃 오퍼](https://docs.xbox.com/ko/services/playfab/economy-monetization/economy-v2/player-segmented-monetization/targeted-offers.md)
- [전체 플레이어 세그먼트에 대한 일괄 작업](https://docs.xbox.com/ko/services/playfab/data-analytics/acting-data/action-rules-bulk-actions-for-an-entire-player-segment.md)
