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

# XGameActivationType

> XGameActivationType

# XGameActivationType

Specifies the type of activation that occurred.

## Syntax

```cpp theme={null}
enum class XGameActivationType : uint32_t  
{  
    Protocol = 0,  
    File = 1,  
    PendingGameInvite = 2,  
    AcceptedGameInvite = 3  
}  
```

## Constants

| Constant           | Description                                                                                                                                                                                                                                                                                                                                                                                                                     |
| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Protocol           | The game was activated via a custom protocol URI. The `protocolUri` field of [XGameActivationInfo](/reference/system/xgameactivation/structs/xgameactivationinfo) contains the activation URI. For more information, see [Protocol activation](https://learn.microsoft.com/gaming/gdk/docs/gdk-dev/overviews/protocolactivation).                                                                                               |
| File               | The game was activated via a file association. The `file` field of [XGameActivationInfo](/reference/system/xgameactivation/structs/xgameactivationinfo) contains the file path. For more information, see [File type activation](https://learn.microsoft.com/gaming/gdk/docs/gdk-dev/overviews/filetypeactivation).                                                                                                             |
| PendingGameInvite  | The game received a game invite that hasn't yet been accepted. The `inviteUri` field of [XGameActivationInfo](/reference/system/xgameactivation/structs/xgameactivationinfo) contains the invite URI. The game should present UI to the user to accept or reject the invite, and call [XGameActivationAcceptPendingInvite](/reference/system/xgameactivation/functions/xgameactivationacceptpendinginvite) if the user accepts. |
| AcceptedGameInvite | The game was activated because the user accepted a game invite. The `inviteUri` field of [XGameActivationInfo](/reference/system/xgameactivation/structs/xgameactivationinfo) contains the invite URI.                                                                                                                                                                                                                          |

## Remarks

**XGameActivationType** is used by the [XGameActivationInfo](/reference/system/xgameactivation/structs/xgameactivationinfo) structure to indicate what kind of activation triggered the [XGameActivationCallback](/reference/system/xgameactivation/functions/xgameactivationcallback). The activation type determines which field of the `XGameActivationInfo` union contains valid data.

This enum is designed to be extensible. Future GDK releases may add additional activation types. Games should handle unknown values gracefully by ignoring them.

## Requirements

**Header:** XGameActivation.h

**Supported platforms:** Windows, XBOX One family consoles and XBOX Series consoles

## See also

[XGameActivation](/reference/system/xgameactivation/xgameactivation_members)\
[XGameActivationInfo](/reference/system/xgameactivation/structs/xgameactivationinfo)\
[XGameActivationCallback](/reference/system/xgameactivation/functions/xgameactivationcallback)


## Related topics

- [XGameActivationInfo](/reference/system/xgameactivation/structs/xgameactivationinfo.md)
- [XGameActivation](/reference/system/xgameactivation/xgameactivation_members.md)
- [XGameActivationCallback](/reference/system/xgameactivation/functions/xgameactivationcallback.md)
- [XGameActivationAcceptPendingInvite](/reference/system/xgameactivation/functions/xgameactivationacceptpendinginvite.md)
- [XGameActivationRegisterForEvent](/reference/system/xgameactivation/functions/xgameactivationregisterforevent.md)
