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

# PFAccountManagementServerSendCustomAccountRecoveryEmailAsync

> Forces an email to be sent to the registered contact email address for the user's account based on an account recovery email template

Forces an email to be sent to the registered contact email address for the user's account based on an account recovery email template

## Syntax

```cpp theme={null}
HRESULT PFAccountManagementServerSendCustomAccountRecoveryEmailAsync(  
    PFEntityHandle titleEntityHandle,  
    const PFAccountManagementSendCustomAccountRecoveryEmailRequest* request,  
    XAsyncBlock* async  
)  
```

### Parameters

**`titleEntityHandle`**   PFEntityHandle

PFEntityHandle for a title Entity obtained using PFAuthenticationGetEntityWithSecretKeyAsync.

**`request`**   [PFAccountManagementSendCustomAccountRecoveryEmailRequest\*](/services/playfab/api-references/c/pfaccountmanagementtypes/structs/pfaccountmanagementsendcustomaccountrecoveryemailrequest)

Populated request object.

**`async`**   XAsyncBlock\*<br />*Inout*

XAsyncBlock for the async operation.

### Return value

Type: HRESULT

Result code for this API operation.

## Remarks

This API is available on Win32, Linux, and macOS. PlayFab accounts which have valid email address or username will be able to receive a password reset email using this API.The email sent must be an account recovery email template. The username or email can be passed in to send the email. Call XAsyncGetStatus to get the status of the operation. If the service call is unsuccessful, the async result will be E\_PF\_EMAIL\_CLIENT\_CANCELED\_TASK, E\_PF\_EMAIL\_CLIENT\_TIMEOUT, E\_PF\_EMAIL\_MESSAGE\_TO\_ADDRESS\_IS\_MISSING, E\_PF\_EMAIL\_TEMPLATE\_MISSING, E\_PF\_NO\_CONTACT\_EMAIL\_ADDRESS\_FOUND, E\_PF\_SMTP\_ADDON\_NOT\_ENABLED or any of the global PlayFab Service errors. See doc page "Handling PlayFab Errors" for more details on error handling.

## Requirements

**Header:** PFAccountManagement.h

## See also

[PFAccountManagement members](/services/playfab/api-references/c/pfaccountmanagement/pfaccountmanagement_members)


## Related topics

- [Services C API overview - PFAccountManagement.h](/services/playfab/api-references/c/pfaccountmanagement/pfaccountmanagement_members.md)
- [PFAccountManagementClientSendAccountRecoveryEmailAsync](/services/playfab/api-references/c/pfaccountmanagement/functions/pfaccountmanagementclientsendaccountrecoveryemailasync.md)
- [PFAccountManagementSendCustomAccountRecoveryEmailRequest](/services/playfab/api-references/c/pfaccountmanagementtypes/structs/pfaccountmanagementsendcustomaccountrecoveryemailrequest.md)
- [PFAccountManagementSendAccountRecoveryEmailRequest](/services/playfab/api-references/c/pfaccountmanagementtypes/structs/pfaccountmanagementsendaccountrecoveryemailrequest.md)
- [PFAccountManagementServerSendEmailFromTemplateAsync](/services/playfab/api-references/c/pfaccountmanagement/functions/pfaccountmanagementserversendemailfromtemplateasync.md)
