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

# PFCloudScriptExecuteFunctionRequest

> PFCloudScriptExecuteFunctionRequest data model. Executes an Azure Function with the profile of the entity that is defined in the request.

PFCloudScriptExecuteFunctionRequest data model. Executes an Azure Function with the profile of the entity that is defined in the request.

## Syntax

```cpp theme={null}
typedef struct PFCloudScriptExecuteFunctionRequest {  
    PFStringDictionaryEntry const* customTags;  
    uint32_t customTagsCount;  
    PFEntityKey const* entity;  
    const char* functionName;  
    PFJsonObject functionParameter;  
    bool const* generatePlayStreamEvent;  
} PFCloudScriptExecuteFunctionRequest;  
```

### Members

**`customTags`**   [PFStringDictionaryEntry](/services/playfab/api-references/c/pftypes/structs/pfstringdictionaryentry) const\*<br />*may be nullptr*

(Optional) The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.).

**`customTagsCount`**   uint32\_t

Count of customTags

**`entity`**   [PFEntityKey](/services/playfab/api-references/c/pftypes/structs/pfentitykey-c) const\*<br />*may be nullptr*

(Optional) The optional entity to perform this action on. Defaults to the currently logged in entity.

**`functionName`**   const char\*<br />*is null-terminated*

The name of the CloudScript function to execute.

**`functionParameter`**   [PFJsonObject](/services/playfab/api-references/c/pftypes/structs/pfjsonobject)

(Optional) Object that is passed in to the function as the FunctionArgument field of the FunctionExecutionContext data structure.

**`generatePlayStreamEvent`**   bool const\*<br />*may be nullptr*

(Optional) Generate a 'entity\_executed\_cloudscript\_function' PlayStream event containing the results of the function execution and other contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager.

## Requirements

**Header:** PFCloudScriptTypes.h

## See also

[PFCloudScriptTypes members](/services/playfab/api-references/c/pfcloudscripttypes/pfcloudscripttypes_members)
