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

# PFPlatformSpecificClientRegisterForIOSPushNotificationAsync

> 注册 iOS 设备以接收推送通知

注册 iOS 设备以接收推送通知

## 语法

```cpp theme={null}
HRESULT PFPlatformSpecificClientRegisterForIOSPushNotificationAsync(  
    PFEntityHandle entityHandle,  
    const PFPlatformSpecificRegisterForIOSPushNotificationRequest* request,  
    XAsyncBlock* async  
)  
```

### 参数

**`entityHandle`**   PFEntityHandle

用于身份验证的 PFEntityHandle。

**`request`**   [PFPlatformSpecificRegisterForIOSPushNotificationRequest\*](https://docs.xbox.com/zh-CN/services/playfab/api-references/c/pfplatformspecifictypes/structs/pfplatformspecificregisterforiospushnotificationrequest.md)

已填充的请求对象。

**`async`**   XAsyncBlock\*\
*Inout*

用于异步操作的 XAsyncBlock。

### 返回值

类型：HRESULT

此 API 操作的结果代码。

## 备注

此 API 可在 iOS 上使用。有关配置和发送推送通知的步骤，请参阅[推送通知快速入门](https://docs.xbox.com/zh-CN/services/playfab/live-service-management/game-configuration/title-communications/push-notifications/quickstart.md)。调用 XAsyncGetStatus 以获取操作状态。如果服务调用不成功，异步结果将为 E\_PF\_NO\_PUSH\_NOTIFICATION\_ARN\_FOR\_TITLE、E\_PF\_PUSH\_SERVICE\_ERROR 或任何全局 PlayFab 服务错误。有关错误处理的更多详细信息，请参阅文档页“Handling PlayFab Errors”。

## 要求

**头文件：** PFPlatformSpecific.h

## 另请参阅

[PFPlatformSpecific 成员](https://docs.xbox.com/zh-CN/services/playfab/api-references/c/pfplatformspecific/pfplatformspecific_members.md)


## Related topics

- [Services C API 概览 - PFPlatformSpecific.h](https://docs.xbox.com/zh-CN/services/playfab/api-references/c/pfplatformspecific/pfplatformspecific_members.md)
- [PFPlatformSpecificRegisterForIOSPushNotificationRequest](https://docs.xbox.com/zh-CN/services/playfab/api-references/c/pfplatformspecifictypes/structs/pfplatformspecificregisterforiospushnotificationrequest.md)
- [PFPlatformSpecificClientAndroidDevicePushNotificationRegistrationAsync](https://docs.xbox.com/zh-CN/services/playfab/api-references/c/pfplatformspecific/functions/pfplatformspecificclientandroiddevicepushnotificationregistrationasync.md)
- [Register For IOS Push Notification](https://docs.xbox.com/api-reference/platform-specific-methods/register-for-ios-push-notification.md)
- [Android Device Push Notification Registration](https://docs.xbox.com/api-reference/platform-specific-methods/android-device-push-notification-registration.md)
