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

# PFEntityGetEntityKey

> Obtiene la PFEntityKey de una entidad.

Obtiene la PFEntityKey de una entidad.

## Sintaxis

```cpp theme={null}
HRESULT PFEntityGetEntityKey(  
    PFEntityHandle entityHandle,  
    size_t bufferSize,  
    void* buffer,  
    const PFEntityKey** entityKey,  
    size_t* bufferUsed  
)  
```

### Parámetros

**`entityHandle`**   PFEntityHandle

PFEntityHandle devuelto por una llamada de autenticación.

**`bufferSize`**   size\_t

El tamaño del búfer para la PFEntityKey. El tamaño necesario puede obtenerse a partir de PFEntityGetEntityKeySize.

**`buffer`**   void\*<br />\**Out\_writes\_bytes\_to*(bufferSize,*bufferUsed)*

Búfer de bytes usado para la PFEntityKey y sus campos.

**`entityKey`**   [PFEntityKey\*\*](/services/playfab/api-references/c/pftypes/structs/pfentitykey-c)<br />*library-allocated output*

TBD

**`bufferUsed`**   size\_t\*<br />*optional output*

El número de bytes del búfer proporcionado que se usaron.

### Valor devuelto

Tipo: HRESULT

Código de resultado de esta operación de API.

## Comentarios

entityKey es un puntero dentro de buffer y no es necesario liberarlo por separado.

## Requisitos

**Encabezado:** PFEntity.h

## Consulte también

[Miembros de PFEntity](/services/playfab/api-references/c/pfentity/pfentity_members)


## Related topics

- [PFEntityIsTitlePlayer](/es/services/playfab/api-references/c/pfentity/functions/pfentityistitleplayer.md)
- [Inicio rápido del GDK](/es/services/playfab/sdks/c/quickstart-gdk.md)
- [Inicio rápido de iOS](/es/services/playfab/sdks/c/quickstart-ios.md)
- [Inicio rápido de Linux](/es/services/playfab/sdks/c/quickstart-linux.md)
- [Inicio rápido de macOS](/es/services/playfab/sdks/c/quickstart-macos.md)
