Server Data Models
Enums
EPgosServerBackfillStrategy
The player filling strategy when backfilling.
enum class EPgosServerBackfillStrategy : uint8
| member | value | description |
|---|
| Dummy | 0 | |
| Custom | 1 | In this mode, the target player count of each team needs to be specified. However, the number of players per team must comply with the ruleset constraint. |
| MaxPossible | 2 | Backfill matchmaking will target max players as defined in ruleset and ignore expansions on player count. |
EPgosServerBackfillStatus
Backfill matchmaking request status.
enum class EPgosServerBackfillStatus : uint8
| member | value | description |
|---|
| Dummy | 0 | No ongoing or ended backfill request. |
| Searching | 1 | Searching player to backfill with. |
| Paused | 2 | Means that the backfill is suspended, normally because the battle is full. If any player leaves the battle session after the backfill is paused, the backfill status will turn to searching again. |
| Canceled | 3 | The backfill request is canceled. |
| Completed | 4 | Means that the backfill reaches target and stopped, which only happens when using Custom strategy. |
| Error | 5 | Means that the backfill is terminated due to mathcmaking engine failure, submit bug to us when this happened. |
EPgosServerCreationPolicy
The player battle session creation policy.
enum class EPgosServerCreationPolicy : uint8
| member | value | description |
|---|
| ALLOW_ALL | 0 | |
| DENY_ALL | 1 | |
EPgosServerEctStatus
The status of ECT.
enum class EPgosServerEctStatus : uint8
| member | value | description |
|---|
| Uncompleted | 0 | The ECT is in an 'Uncompleted' state, indicating that it has not yet reached the 'Done', 'Canceled', or 'Expired' state. This status implies that the ECT is still in progress or has not been completed. |
| Done | 1 | The status of all the actions were updated to 'SUCCESS'; consequently, the ECT's status will become 'Done' |
| Canceled | 2 | The ECT is canceled. |
| Expired | 3 | The ECT is Expired. |
EPgosServerEctActionStatus
The status of ECT action.
enum class EPgosServerEctActionStatus : uint8
| member | value | description |
|---|
| Init | 0 | The default action status when an ECT is created. |
| Success | 1 | The action is succeeded. |
| Failed | 2 | The action is failed. |
EPgosServerPartyJoinStrategy
The strategy controls the rules who could join the party
enum class EPgosServerPartyJoinStrategy : uint8
| member | value | description |
|---|
| Public | 0 | Open to anyone, it's the default strategy |
| OnlyFriendsOfLeader | 1 | Only friends of the leader could join the party |
| OnlyFriendsOfMembers | 2 | Only friends of any member could join the party |
| OnlyInvited | 3 | Only invited players could join the party |
| NotAllowed | 4 | No one can join |
EPgosServerPartyInviteStrategy
The strategy controls the rules who could invite others to the party
enum class EPgosServerPartyInviteStrategy : uint8
| member | value | description |
|---|
| AllMembersCanInvite | 0 | All members of the party can invite others, it's the default strategy |
| OnlyLeaderCanInvite | 1 | Only the party leader can invite others |
Structs
FPgosServerWorldTeamInfo
Information of a team in a world battle session.
struct FPgosServerWorldTeamInfo
| field | type | description |
|---|
| team_name | FString | The world team name |
| player_ids | TArray<FString> | Players of the world team |
| team_capacity | int32 | Max number of players in the world team |
FPgosServerBalance
The currency in the player's wallet.
struct FPgosServerBalance
| field | type | description |
|---|
| currency_code | FString | The code of the currency. |
| currency_name | FString | The name of the currency. |
| currency_icon | FString | The uri of the currency. |
| currency_type | EPgosCurrencyType | Currency type. |
| amount | int64 | The balance of the currency. |
| max_deposit | int64 | The maximum balance that a player can hold for this currency. A value of 0 represents no limitation. |
FPgosServerBatchGetPlayerInfoSvrRsp
Response that server batch getting playerInfo.
struct FPgosServerBatchGetPlayerInfoSvrRsp
| field | type | description |
|---|
| data | TMap<FString, FPgosPlayerDetail> | Player infos, key: player_id, value: player detail. |
| fail_players | TMap<FString, FString> | Players who totally failed, key: player_id, value: failed reason. |
FPgosServerBatchIncrOneOfPlayerKVDataRsp
The response that Performs atomic increment operation on a specific kvdata item for multiple players.
struct FPgosServerBatchIncrOneOfPlayerKVDataRsp
| field | type | description |
|---|
| data | TMap<FString, FPgosOnePlayerKVData> | data after the increment, key: player_id, value: the player's new kvdata value after the updated. |
| failed_players | TMap<FString, FPgosResult> | Players who totally failed, key: player_id, value: failed reason. |
FPgosServerKVDataGroupWithResult
A set of kvdata items.
struct FPgosServerKVDataGroupWithResult
| field | type | description |
|---|
| result | FPgosResult | The result corresponding to the data in the structure: If the result.err_code is 0 (success), then the operation for the player is successful and the kvdata is the latest data. If the result.err_code is 11108 (kBackendKVDataVersionMismatched (11108)), then the operation for the player is failed and the kvdata is the latest data, you may try again with the latest version. For other values of the result.err_code, the kvdata is invalid, you can check the result.msg for detail. |
| version | int32 | The player-wide version of the versioned kvdata |
| kvdata | TMap<FString, FPgosKVDataValue> | KVData items, key: item key, value: item value. |
FPgosServerBatchSetPlayerVersionedKVDataRsp
Response that updates versioned kvdata for multiple players.
struct FPgosServerBatchSetPlayerVersionedKVDataRsp
FPgosServerBatchOpenIDToPlayerIDRsp
Response of transform playerIDs of PGOS to account openIDs of external platform.
struct FPgosServerBatchOpenIDToPlayerIDRsp
| field | type | description |
|---|
| data | TMap<FString, FString> | Result of successful conversion, key: account openID, value: player id. |
| fails | TMap<FString, FString> | Account openIDs who failed, key: account openID, value: failed reason. |
FPgosServerBattleSession
A battle session corresponds a accessible battle
struct FPgosServerBattleSession
| field | type | description |
|---|
| battle_session_id | FString | The battle session id to query |
| fleet_id | FString | The DS fleet that battle sessions located in |
| battle_source_data | FPgosBattleSourceData | Creation source data of a battle session, contains information about the source type of the battle and player information filled in by the battle creator. |
| battle_properties | TArray<FPgosBattleProperty> | Custom K-V pairs of a battle session. Preset in matchmaking or world configuration of filled with lobby data |
| battle_session_data | FString | Custom string data of a battle session. Preset in matchmaking or world configuration |
| port | int32 | The port of the DS holding the battle session. |
| ip_address | FString | The IP address of the DS holding the battle session. |
| backfill_status | EPgosServerBackfillStatus | Backfill request status. |
| bucket_path | TMap<FString, FString> | Mapping from bucket filter attribute name to attribute value. [for WORLD battle session only] |
| source_type | EPgosBattleSourceType | What service that the battle session generated from |
| configuration_name | FString | Configuration name of matchmaking, lobby or world service |
| max_players | int32 | Maximum number of players in the battle session If the source of the battle session is Matchmaking, the max_players is calculated from the teams section of ruleset script If the source of the game is Lobby, the max_players is calculated from the teams section of lobby config |
| max_teams | int32 | Maximum number of teams in the battle session Only filled when the battle session source type is BattleSourceType::World |
| total_players | int32 | Total number of players in the battle session. Only players with a player battle session status of COMPLETED will be excluded |
| ruleset_name | FString | Ruleset name hit. Filled when battle session source type is BattleSourceType::Matchmaking |
| locked | bool | True if the battle session is locked by game server A battle session generated from world service could be locked/unlocked by calling Lock/UnlockWorldBattleSession. |
| zone | FString | Zone where the battle session placed. |
| teams | TMap<FString, FPgosServerWorldTeamInfo> | Teams info in a world battle session. Only filled when the battle session source type is BattleSourceType::World |
FPgosServerPlayerBattleSession
A player-battle-session is a session between a player and a activated battle-session
struct FPgosServerPlayerBattleSession
| field | type | description |
|---|
| player_battle_session_id | FString | The id of player session in the battle, !!! NOT BATTLE SESSION ID !!! |
| player_id | FString | The player id |
| battle_session_id | FString | The battle session id |
| status | FString | PENDING The player battle session requires DS to call the ReservePlayerBattleSession interface for approval. RESERVED Reserved players can be validated through the AcceptPlayerBattleSession interface. ACTIVE Player battle session status turn to ACTIVE after AcceptPlayerBattleSession is called successfully. COMPLETED This is the terminal status of player battle session. The status will turn to COMPLETED after RemovePlayerBattleSession is called or player actively leave the battle session. |
| payload | FString | Payload data set be game client when calling interface JoinWorldBattleSession. |
| created_time | int64 | The Unix timestamp(in seconds) when the battle session was created. |
| team_name | FString | Team name in a world battle session. |
FPgosServerPlayerBattleSessionParams
struct FPgosServerPlayerBattleSessionParams
| field | type | description |
|---|
| battle_session_id | FString | The battle session in which the player is participating. |
| player_battle_session_id | FString | The session ID of the player within the battle session. Please note that this parameter is different from the battle session ID. PGOS assigns different player battle session IDs to players who join the same battle session multiple times. |
| player_id | FString | Player ID. |
FPgosServerDescribePlayerBattleSessionsParams
Request info to describe player battle sessions
struct FPgosServerDescribePlayerBattleSessionsParams
| field | type | description |
|---|
| battle_session_id | FString | The battle session id to query |
| player_battle_session_id | FString | The id of player session in the battle, !!! NOT BATTLE SESSION ID !!! |
| offset | int32 | The next token |
| count | int32 | The limit of the player battle sessions request |
FPgosServerDescribePlayerBattleSessionsResult
Information about the players in the battle session.
struct FPgosServerDescribePlayerBattleSessionsResult
| field | type | description |
|---|
| next_offset | int32 | The next offset. |
| has_more | bool | If has more players. |
| total_num | int32 | None-completed players count in the battle session. |
| player_battle_sessions | TArray<FPgosServerPlayerBattleSession> | A list of player battle sessions. Empty if there's no more sessions. |
FPgosServerGrantItem
struct FPgosServerGrantItem
| field | type | description |
|---|
| item_id | FString | The id of the item will be granted. |
| amount | int32 | The number of the item will be granted. |
| mutable_custom_data | TMap<FString, FPgosKVDataValue> | The mutable kv data of the instance. The key must be prefixed with "int", "flt", or "str_", which respectively indicate that the value type is integer, float, or string. Max 32 keys, each key limited to 128 bytes and each value limited to 4096 bytes(in a narrow-character string). |
FPgosServerBatchRevokeInstancesParams
Request struct for revoke instances.
struct FPgosServerBatchRevokeInstancesParams : public FPgosBaseBackendEventParams
parent: FPgosBaseBackendEventParams
| field | type | description |
|---|
| player_id | FString | The player whose item instance will be revoked from inventory. |
| instance_ids | TArray<FString> | The item instance ids. Maximum array size: 99. |
FPgosServerBatchRevokeInstancesResult
Request struct for batch revoke instances.
struct FPgosServerBatchRevokeInstancesResult
| field | type | description |
|---|
| left_amounts | TMap<FString, int32> | The number of instance remaining after this operation. key: item instance id, value: left amount. |
| fails | TMap<FString, FPgosResult> | Item instances that failed to revoke. key: item instance id, value: failed reason. |
FPgosServerGrantCurrency
struct FPgosServerGrantCurrency
| field | type | description |
|---|
| currency_code | FString | The code of the currency will be granted. |
| amount | int32 | The amount of the currency will be granted. |
FPgosServerGrantItemToPlayerParams
Request struct for grant item to player.
struct FPgosServerGrantItemToPlayerParams : public FPgosBaseBackendEventParams
parent: FPgosBaseBackendEventParams
| field | type | description |
|---|
| player_id | FString | The player id who will be granted items to. |
| items | TArray<FPgosServerGrantItem> | The items will be granted. |
| idempotency_token | FString | [Optional] Used to ensure the idempotence of the function. Idempotence means that regardless of how many times the function is called, the result remains the same. By passing a unique idempotency_token, it ensures that the function does not produce duplicate side effects or results when called repeatedly. Note: To avoid generating the same idempotency_token as other players, it is recommended to concatenate it with the player_id. |
| pay_platform_data | FPgosPayPlatformData | The necessary information required by the payment platform, which must be filled out when granting items contents premium currency. |
FPgosServerGrantItemResult
struct FPgosServerGrantItemResult
| field | type | description |
|---|
| player_id | FString | The player id who has been successfully granted. |
| item_insts | FPgosItemInstPack | The item instances that have been granted. |
| currencies | TArray<FPgosCurrency> | The currencies that have been granted. (such as granting bundle that contains currencies) |
| conflict_unique_items | TArray<FPgosConflictUniqueItem> | Unique items that already in inventory cause failed to be granted. |
| failed_currencies | TMap<FString, FString> | Currencies that failed to grant. Mapping from currency code to failure reason. |
| replayed | bool | Whether the request is replayed. When it is True, it indicates that the result of the function is obtained by replaying with the same idempotency_token. This means that the result of the function has been generated in a previous call and is being reused in the current call. |
FPgosServerGrantCurrencyToPlayerParams
Request struct for grant currency to player.
struct FPgosServerGrantCurrencyToPlayerParams : public FPgosBaseBackendEventParams
parent: FPgosBaseBackendEventParams
| field | type | description |
|---|
| player_id | FString | The player id who will be granted currencies to. |
| currencies | FPgosServerGrantCurrency | The currencies will be granted. |
| idempotency_token | FString | [Optional] Used to ensure the idempotence of the function. Idempotence means that regardless of how many times the function is called, the result remains the same. By passing a unique idempotency_token, it ensures that the function does not produce duplicate side effects or results when called repeatedly. Note: To avoid generating the same idempotency_token as other players, it is recommended to concatenate it with the player_id. |
| pay_platform_data | FPgosPayPlatformData | The necessary information required by the payment platform, which must be filled out when granting premium currency. |
FPgosServerGrantCurrencyResult
struct FPgosServerGrantCurrencyResult
| field | type | description |
|---|
| player_id | FString | The player id who have been successfully granted. |
| replayed | bool | Whether the request is replayed. When it is True, it indicates that the result of the function is obtained by replaying with the same idempotency_token. This means that the result of the function has been generated in a previous call and is being reused in the current call. |
FPgosServerGetPlayerInventoryResult
struct FPgosServerGetPlayerInventoryResult
| field | type | description |
|---|
| player_id | FString | The player id whose inventory will be queried. |
| item_insts | FPgosItemInstPack | The item instances of the query instance ids. |
| fails | TMap<FString, FString> | The instance ids which was failed to query. |
FPgosServerGetPlayerInventoryWithFilterResult
struct FPgosServerGetPlayerInventoryWithFilterResult
| field | type | description |
|---|
| player_id | FString | The player id whose inventory will be queried. |
| item_insts | FPgosItemInstPack | The item instances of the query instance ids. |
FPgosServerSetInstanceCustomDataParams
struct FPgosServerSetInstanceCustomDataParams
| field | type | description |
|---|
| player_id | FString | The player whose item instance mutable_custom_data will be updated. |
| instance_id | FString | The item instance id. |
| update_data | TMap<FString, FPgosKVDataValue> | Update the data of the specified keys in the mutable_custom_data. If the key does not exist, it indicates inserting new data. |
| delete_keys | TArray<FString> | Delete the data of specified keys in the mutable_custom_data. The key from update_data cannot be included. |
FPgosServerSetInstanceCustomDataResult
struct FPgosServerSetInstanceCustomDataResult
| field | type | description |
|---|
| mutable_custom_data | TMap<FString, FPgosKVDataValue> | Latest mutable_custom_data of item instance. |
| version | int32 | Latest mutable_custom_data_version of item instance. |
FPgosServerUpdatedInstanceCustomData
struct FPgosServerUpdatedInstanceCustomData
| field | type | description |
|---|
| update_data | TMap<FString, FPgosKVDataValue> | Update the data of the specified keys in the mutable_custom_data. If the key does not exist, it indicates inserting new data. |
| delete_keys | TArray<FString> | Delete the data of specified keys in the mutable_custom_data. The key from update_data cannot be included. |
FPgosServerBatchSetInstanceCustomDataParams
struct FPgosServerBatchSetInstanceCustomDataParams
| field | type | description |
|---|
| player_id | FString | The player whose item instance mutable_custom_data will be updated. |
| data | TMap<FString, FPgosServerUpdatedInstanceCustomData> | The item instances to be updated. key: item instance id, value: custom data to be updated. Maximum map entries: 99. |
FPgosServerInstanceCustomData
struct FPgosServerInstanceCustomData
| field | type | description |
|---|
| mutable_custom_data | TMap<FString, FPgosKVDataValue> | Latest mutable_custom_data of item instance. |
| version | int32 | Latest mutable_custom_data_version of item instance. |
FPgosServerBatchSetInstanceCustomDataResult
struct FPgosServerBatchSetInstanceCustomDataResult
| field | type | description |
|---|
| data | TMap<FString, FPgosServerInstanceCustomData> | Latest mutable_custom_data of item instance. key: item instance id, value: latest custom data |
| fails | TMap<FString, FPgosResult> | Item instances that failed to update. key: item instance id, value: failed reason. |
FPgosServerSetInstanceCustomDataWithVersionParams
struct FPgosServerSetInstanceCustomDataWithVersionParams : public FPgosServerSetInstanceCustomDataParams
parent: FPgosServerSetInstanceCustomDataParams
| field | type | description |
|---|
| version | int32 | The latest mutable_custom_data_version. |
FPgosServerIncrInstanceCustomDataParams
struct FPgosServerIncrInstanceCustomDataParams
| field | type | description |
|---|
| player_id | FString | The player id whose item instance mutable_custom_data will be updated. |
| instance_id | FString | The item instance id. |
| increments | TMap<FString, FPgosKVDataValue> | Increments to update, key: kvdata key, value: increment of the value. |
| idempotency_token | FString | [Optional] Used to ensure the idempotence of the function. By passing a unique idempotency_token, it ensures that the function does not produce duplicate side effects or results when called repeatedly. |
FPgosServerIncrInstanceCustomDataResult
struct FPgosServerIncrInstanceCustomDataResult
| field | type | description |
|---|
| mutable_custom_data | TMap<FString, FPgosKVDataValue> | Latest mutable_custom_data of item instance. |
| version | int32 | Latest mutable_custom_data_version of item instance. |
| replayed | bool | Whether the request is replayed. When it is true, it indicates that the previously used idempotency_token was used, and the increment operation did not take effect. The result returns the latest mutable_custom_data and mutable_custom_data_version of the instance. |
struct FPgosServerSetInstanceTagsParams
| field | type | description |
|---|
| player_id | FString | The player id whose item instance tags will be updated. |
| instance_id | FString | The item instance id. |
| update_data | TMap<FString, FString> | Update the data of the specified keys in the tags. If the key does not exist, it indicates inserting new data. |
| delete_keys | TArray<FString> | Delete the data of specified keys in the tags. The key from update_data cannot be included. |
struct FPgosServerSetInstanceTagsResult
| field | type | description |
|---|
| tags | TMap<FString, FString> | Latest tags of item instance. |
struct FPgosServerUpdatedInstanceTags
| field | type | description |
|---|
| update_data | TMap<FString, FString> | Update the data of the specified keys in the tags. If the key does not exist, it indicates inserting new data. |
| delete_keys | TArray<FString> | Delete the data of specified keys in the tags. The key from update_data cannot be included. |
struct FPgosServerBatchSetInstanceTagsParams
| field | type | description |
|---|
| player_id | FString | The player id whose item instance tags will be updated. |
| data | TMap<FString, FPgosServerUpdatedInstanceTags> | The item instances to be updated. key: item instance id, value: tags to be updated. Maximum map entries: 99. |
struct FPgosServerInstanceTags
| field | type | description |
|---|
| tags | TMap<FString, FString> | Latest tags of item instance. |
struct FPgosServerBatchSetInstanceTagsResult
| field | type | description |
|---|
| data | TMap<FString, FPgosServerInstanceTags> | Latest tags of item instance. |
| fails | TMap<FString, FPgosResult> | Item instances that failed to update. key: item instance id, value: failed reason. |
FPgosServerDelBattleDataRsp
Response that delete battle data.
struct FPgosServerDelBattleDataRsp
| field | type | description |
|---|
| fails | TMap<FString, FString> | Keys failed to delete, key: battle data keys, value: failed reason. |
FPgosServerStartBackfillParams
struct FPgosServerStartBackfillParams
| field | type | description |
|---|
| battle_session_id | FString | Battle session to be backfilled. |
| backfill_strategy | EPgosServerBackfillStrategy | The player filling strategy when backfilling. |
| custom_team_map | TMap<FString, int32> | The target player count of each team. |
FPgosServerCancelBackfillResult
Cancel a backfill matchmaking request
struct FPgosServerCancelBackfillResult
| field | type | description |
|---|
| canceled | bool | Whether the player has canceled the backfill matchmaking request |
FPgosServerBattlePlayerOfflineEvt
The event will be triggered when the player in the battle-session is offline.
struct FPgosServerBattlePlayerOfflineEvt
| field | type | description |
|---|
| player_id | FString | The player id of the player who is offline. |
| battle_session_id | FString | The battle-session the player is in |
| offline_type | EPgosPlayerSessionEvt | The reason why the player is offline. |
| offline_msg | FString | The detail message for the event. |
FPgosServerBattlePlayerBannedEvt
The event will be triggered when the player in the battle-session is banned.
struct FPgosServerBattlePlayerBannedEvt
| field | type | description |
|---|
| player_id | FString | The player id of the player who is baned. |
| battle_session_id | FString | The battle-session the player is in |
| ban_reason | FString | Reason for ban. The reason string comes from the reason string passed in when creating the ban. |
| ban_created_time | int64 | Ban creation time. |
| ban_duration | int64 | Ban duration |
| ban_expired_time | int64 | Ban expiration time, 0 means forever |
FPgosServerBattleSessionUpdatedEvt
The event will be triggered when new players are added to the battle session or when the backfill status changes.
struct FPgosServerBattleSessionUpdatedEvt
| field | type | description |
|---|
| update_reason | FString | This is a string data enumeration: @BACKFILL_STATUS_CHANGED: backfill status changes @BACKFILL_ADDED_PLAYERS: new players backfilled to the battle session @WORLD_ADDED_PLAYERS: New players are added to the session by World service. |
| battle_session_id | FString | Battle session id. |
| backfill_status | EPgosServerBackfillStatus | Status for the backfilling process to the battle session. |
| total_players | int32 | Total number of players in the battle session. Note: players with a player battle session status of COMPLETED will be excluded. |
| max_players | int32 | Max number of players in the battle session. |
| backedfilled_players | TArray<FPgosPlayerDesc> | New players add by backfill matchmaking. |
| new_player_battle_sessions | TArray<FPgosServerPlayerBattleSession> | New players added to the battle session. For example, by the World service. |
| locked | bool | Locked state of the battle session. |
FPgosServerUpdateStatItemParams
struct FPgosServerUpdateStatItemParams
| field | type | description |
|---|
| item | FPgosStatItem | The stat item to update. |
| ignore_custom_data | bool | Whether update custom data. It won't overwrite the old one when updated if this is true. |
| ignore_tags | bool | Whether update tags. It won't overwrite the old one when updated if this is true. |
FPgosServerBatchUpdateStatItemParams
struct FPgosServerBatchUpdateStatItemParams
| field | type | description |
|---|
| items | TArray<FPgosStatItem> | The stat items to update. |
| ignore_custom_data | bool | Whether update custom data. It won't overwrite the old one when updated if this is true. |
| ignore_tags | bool | Whether update tags. It won't overwrite the old one when updated if this is true. |
FPgosServerUpdateStatItemFailInfo
Update stat item fail info.
struct FPgosServerUpdateStatItemFailInfo
| field | type | description |
|---|
| stat_name | FString | Stat to update. |
| key | FString | The key of the stat item to update. |
| err_code | int32 | update fail error code, view pgos_error.h or PgosErrorCode.h for details. |
| msg | FString | Update fail error message, view pgos_error.h or PgosErrorCode.h for details. |
FPgosServerStatItemAfterUpdate
Update stat item success info.
struct FPgosServerStatItemAfterUpdate
| field | type | description |
|---|
| latest_item | FPgosStatItem | Latest stat item. |
| is_inserted | bool | If the stat item is newly created (which means previously the key doesn't exist). |
| is_modified | bool | If the stat item is updated (which depends on aggregation type and min/max value range). |
FPgosServerBatchUpdateStatItemResult
Response for batch update stat items.
struct FPgosServerBatchUpdateStatItemResult
FPgosServerSetBattlePropertiesParams
struct FPgosServerSetBattlePropertiesParams
| field | type | description |
|---|
| battle_session_id | FString | Battle session id. |
| battle_properties | TArray<FPgosBattleProperty> | The new battle properties. |
FPgosServerLockWorldBattleSessionParams
struct FPgosServerLockWorldBattleSessionParams
| field | type | description |
|---|
| battle_session_id | FString | Battle session id. |
FPgosServerUnlockWorldBattleSessionParams
struct FPgosServerUnlockWorldBattleSessionParams
| field | type | description |
|---|
| battle_session_id | FString | Battle session id. |
FPgosServerPlayerFriendsLimit
struct FPgosServerPlayerFriendsLimit
| field | type | description |
|---|
| player_id | FString | Player id. |
| friends_limit | int32 | The maximum limit of friends player can have. (max 500 friends) |
FPgosServerBatchSetPlayerFriendsLimitParams
struct FPgosServerBatchSetPlayerFriendsLimitParams
FPgosServerBatchGetPlayerFriendsLimitParams
struct FPgosServerBatchGetPlayerFriendsLimitParams
| field | type | description |
|---|
| player_ids | TArray<FString> | Player ids. |
FPgosServerBatchGetPlayerFriendsLimitResult
struct FPgosServerBatchGetPlayerFriendsLimitResult
struct FPgosServerSetBattleTagsParams
| field | type | description |
|---|
| battle_session_id | FString | The id of battle session. |
| tags | TArray<FString> | The tags of battle. |
FPgosServerKVDataItemsWithReplayed
struct FPgosServerKVDataItemsWithReplayed
| field | type | description |
|---|
| kvdata | TMap<FString, FPgosKVDataValue> | KVData items, key: item key, value: value of the key. |
| replayed | bool | Whether the request is replayed. When it is True, it indicates that the result of the function is obtained by replaying with the same idepotency_token. This means that the result of the function has been generated in a previous call and is being reused in the current call. |
FPgosServerKVDataIncrementsIdempotent
A set of kvdata items with a idempotency token.
struct FPgosServerKVDataIncrementsIdempotent : public FPgosPlayerKVDataGroup
parent: FPgosPlayerKVDataGroup
| field | type | description |
|---|
| idempotency_token | FString | [Optional] Used to ensure the idempotence of the function. An idempotent operation produces the same outcome regardless of how many times it's executed, without causing any side effects or altering the system's state. The scope of the idempotent token is for each player. |
FPgosServerBatchIncrPlayerKVDataIdempotentParams
struct FPgosServerBatchIncrPlayerKVDataIdempotentParams
FPgosServerBatchIncrPlayerKVDataIdempotentResult
struct FPgosServerBatchIncrPlayerKVDataIdempotentResult
| field | type | description |
|---|
| data | TMap<FString, FPgosServerKVDataItemsWithReplayed> | players kvdata result values map: key is player id, value is result for increment operations. |
| failed_players | TMap<FString, FPgosResult> | Failed players map: key is player id, value is error code and message. |
FPgosServerMachineInfo
struct FPgosServerMachineInfo
| field | type | description |
|---|
| machine_id | FString | unique id of the machine |
| machine_model | FString | instance type of the machine |
FPgosServerBuildInfo
struct FPgosServerBuildInfo
| field | type | description |
|---|
| build_id | FString | unique id of the build |
| build_name | FString | name of the build |
FPgosServerDeploymentInfo
struct FPgosServerDeploymentInfo
| field | type | description |
|---|
| public_ip | FString | public ip of the game server |
| fleet_id | FString | unique id of the fleet |
| data_center | FString | name of the data center. the possible values can be viewed in the 'DataCenterName' definition. |
| machine_info | FPgosServerMachineInfo | detail information of the machine |
| build_info | FPgosServerBuildInfo | detail information of the build |
| title_id | FString | |
| title_region_id | FString | |
FPgosServerEctActionInfo
Structure to hold information about an ECT action.
struct FPgosServerEctActionInfo
| field | type | description |
|---|
| id | FString | The ID of ECT action. |
| name | FString | The name of ECT action. |
| idempotency_token | FString | Token for idempotency operation. |
| payload | FString | The userdata of operation set by game, such as parameters in JSON. |
| result | FString | The result of operation set by game. |
| status | EPgosServerEctActionStatus | The status of ECT action. |
| updated_time | int64 | The last updated time of ECT action. |
FPgosServerEctExpirationAndRetryPolicy
struct FPgosServerEctExpirationAndRetryPolicy
| field | type | description |
|---|
| expiration_duration | int32 | The expiration duration for an ECT is the time period in seconds from its creation until it expires. The ECT will be marked as expired if the duration has elapsed and the ECT is uncompleted. Minimum: 60 seconds; maximum: 604800 seconds (7 days). |
| trigger_auto_retry_event | bool | Whether the retry event of ECT is triggered to VS by PGOS if the ECT is uncompleted. |
| max_auto_retry_count | int32 | Maximum number of retry attempts. This is only meaningful when the 'trigger_auto_retry_event' is set to true. |
| auto_retry_interval | int32 | The time interval in seconds between each retry attempt. The timing of the first try starts counting from the creation of the ECT. This is only meaningful when the 'trigger_auto_retry_event' is set to true. Minimum: 60 seconds; maximum: 86400 seconds (24 hours). |
FPgosServerEctInfo
Structure to hold information about an ECT (Eventual Consistent Transaction).
struct FPgosServerEctInfo
| field | type | description |
|---|
| id | FString | The ID of ECT. |
| name | FString | The name of ECT. |
| payload | FString | The userdata of ECT set by game. |
| player_ids | TArray<FString> | All players associated with the operation in this ECT. |
| status | EPgosServerEctStatus | The status of ECT. |
| expiration_and_retry_policy | FPgosServerEctExpirationAndRetryPolicy | Whether the retry event of ECT is triggered to VS by PGOS if the ECT is not done. |
| created_time | int64 | The created time of ECT. |
| updated_time | int64 | The last updated time of ECT. |
| actions | TArray<FPgosServerEctActionInfo> | The actions of ECT. |
FPgosServerEctActionCreateParams
struct FPgosServerEctActionCreateParams
| field | type | description |
|---|
| name | FString | The name of ECT action. |
| payload | FString | The userdata of operation set by game, such as parameters in JSON. |
| idempotency_token | FString | Token for idempotency operation. |
FPgosServerCreateEctParams
struct FPgosServerCreateEctParams
| field | type | description |
|---|
| id | FString | The ID of ECT. |
| name | FString | The name of ECT. |
| payload | FString | The userdata of ECT set by game. |
| player_ids | TArray<FString> | All players associated with the operation in this ECT. |
| expiration_and_retry_policy | FPgosServerEctExpirationAndRetryPolicy | Whether the retry event of ECT will be triggered to VS by PGOS if the ECT is uncompleted. |
| actions | TArray<FPgosServerEctActionCreateParams> | The actions of ECT. |
FPgosServerEctActionUpdateParam
struct FPgosServerEctActionUpdateParam
| field | type | description |
|---|
| payload | FString | Update action's payload. |
| result | FString | Update action's result. |
| status | EPgosServerEctActionStatus | Update action's status. |
FPgosServerUpdateEctParams
struct FPgosServerUpdateEctParams
| field | type | description |
|---|
| id | FString | ECT ID. |
| payload | FString | Update action's payload. |
| action_updates | TMap<FString, FPgosServerEctActionUpdateParam> | Update the results and status of actions. key: action ID. |
FPgosServerUpdateEctActionsParams
struct FPgosServerUpdateEctActionsParams
FPgosServerCancelEctParams
struct FPgosServerCancelEctParams
| field | type | description |
|---|
| id | FString | ECT ID. |
| reason | FString | Reason for cancellation. |
FPgosServerGetEctInfoParams
struct FPgosServerGetEctInfoParams
| field | type | description |
|---|
| id | FString | ECT ID. |
FPgosServerGetPlayerUncompletedEctsParams
struct FPgosServerGetPlayerUncompletedEctsParams
| field | type | description |
|---|
| player_id | FString | The ID of the specified player. |
| offset | int32 | The start position. |
| count | int32 | The limit of the ECTs request. |
FPgosServerGetPlayerUncompletedEctsResult
struct FPgosServerGetPlayerUncompletedEctsResult
| field | type | description |
|---|
| ect_list | TArray<FPgosServerEctInfo> | List of ECTs. |
| has_more | bool | Has more. |
| next_offset | int32 | The next starting position of the list. |
| total_num | int32 | The total number of uncompleted ECTs that this player has. |
FPgosServerPushMsgToGameBackendParams
struct FPgosServerPushMsgToGameBackendParams
| field | type | description |
|---|
| msg_bus_tag | FString | Optional, the tag of the message bus instance to which the message is sent. If this value is not set, the messge will be sent to a random message bus instance. |
| msg | TArray<uint8> | The message data to be sent. |
| extra | TArray<uint8> | Optional, extra data to be delivered. For example: it can be used as a header for routing. |
FPgosServerRPCRequestToGameBackendParams
struct FPgosServerRPCRequestToGameBackendParams
| field | type | description |
|---|
| msg_bus_tag | FString | Optional, the tag of the message bus instance to which the message is sent. If this value is not set, the messge will be sent to a random message bus instance. |
| msg | TArray<uint8> | The message data to be sent. |
| extra | TArray<uint8> | Optional, extra data to be delivered. For example: it can be used as a header for routing. |
| timeout_ms | int32 | Timeout period, in milliseconds. If this value is set to 0, the maximum value 60000 (60 seconds) will be used. |
FPgosServerRPCResponse
struct FPgosServerRPCResponse
| field | type | description |
|---|
| response | TArray<uint8> | The response of an RPC request. |
FPgosServerGameBackendMsgEvt
Event info when received msg from the game backend.
struct FPgosServerGameBackendMsgEvt
| field | type | description |
|---|
| msg_bus_tag | FString | The tag of the message bus instance from which the message is received. |
| msg | TArray<uint8> | Message data sent by the game via PgosMsgBusSDK. |
FPgosServerHTTPAPIMsgEvt
Event info when received msg the PGOS backend HTTP API.
struct FPgosServerHTTPAPIMsgEvt
| field | type | description |
|---|
| msg | TArray<uint8> | Message data sent by the game via backend HTTP API. |
| extra | TArray<uint8> | Extra data sent by the game via backend HTTP API. |
FPgosServerSubtractCurrency
struct FPgosServerSubtractCurrency
| field | type | description |
|---|
| currency_code | FString | The code of the currency will be subtracted. |
| amount | int32 | The amount of the currency will be subtracted. |
FPgosServerSubtractPlayerCurrencyParams
struct FPgosServerSubtractPlayerCurrencyParams : public FPgosBaseBackendEventParams
parent: FPgosBaseBackendEventParams
| field | type | description |
|---|
| player_id | FString | Players whose balance will be subtracted. |
| subtract_currency | FPgosServerSubtractCurrency | Information about the subtracted currency. |
| idempotency_token | FString | [Optional] Used to ensure the idempotence of the function. Idempotence means that regardless of how many times the function is called, the result remains the same. By passing a unique idempotency_token, it ensures that the function does not produce duplicate side effects or results when called repeatedly. Note: To avoid generating the same idempotency_token as other players, it is recommended to concatenate it with the player_id. |
| pay_platform_data | FPgosPayPlatformData | The necessary information required by the payment platform, which must be filled out when deducting premium currency. |
FPgosServerSubtractPlayerCurrencyResult
struct FPgosServerSubtractPlayerCurrencyResult
| field | type | description |
|---|
| player_id | FString | The player id who have been successfully granted. |
| replayed | bool | Whether the request is replayed. When it is True, it indicates that the result of the function is obtained by replaying with the same idempotency_token. This means that the result of the function has been generated in a previous call and is being reused in the current call. |
FPgosServerGetPlayerBalanceParams
struct FPgosServerGetPlayerBalanceParams
| field | type | description |
|---|
| player_id | FString | |
| pay_platform_data | FPgosPayPlatformData | The necessary information required by the payment platform, which must be filled out when deducting premium currency. |
FPgosServerGetPlayerBalanceResult
struct FPgosServerGetPlayerBalanceResult
| field | type | description |
|---|
| currencies | TArray<FPgosServerBalance> | All virtual currency balance of the player. |
FPgosServerBatchGrantVirtualCurrenciesToPlayerParams
Request struct for batch grant currency to player.
struct FPgosServerBatchGrantVirtualCurrenciesToPlayerParams : public FPgosBaseBackendEventParams
parent: FPgosBaseBackendEventParams
| field | type | description |
|---|
| player_id | FString | The player id who will be granted currencies to. |
| granted_currencies | TArray<FPgosServerGrantCurrency> | The virtual currencies will be granted. |
| idempotency_token | FString | [Optional] Used to ensure the idempotence of the function. Idempotence means that regardless of how many times the function is called, the result remains the same. By passing a unique idempotency_token, it ensures that the function does not produce duplicate side effects or results when called repeatedly. Note: To avoid generating the same idempotency_token as other players, it is recommended to concatenate it with the player_id. |
FPgosServerBatchGrantVirtualCurrenciesToPlayerResult
struct FPgosServerBatchGrantVirtualCurrenciesToPlayerResult
| field | type | description |
|---|
| player_id | FString | The player id who have been successfully granted. |
| replayed | bool | Whether the request is replayed. When it is True, it indicates that the result of the function is obtained by replaying with the same idempotency_token. This means that the result of the function has been generated in a previous call and is being reused in the current call. |
FPgosServerBatchSubtractPlayerVirtualCurrenciesParams
struct FPgosServerBatchSubtractPlayerVirtualCurrenciesParams : public FPgosBaseBackendEventParams
parent: FPgosBaseBackendEventParams
| field | type | description |
|---|
| player_id | FString | Players whose balance will be subtracted. |
| subtract_currencies | TArray<FPgosServerSubtractCurrency> | The virtual currencies to be granted. |
| idempotency_token | FString | [Optional] Used to ensure the idempotence of the function. Idempotence means that regardless of how many times the function is called, the result remains the same. By passing a unique idempotency_token, it ensures that the function does not produce duplicate side effects or results when called repeatedly. Note: To avoid generating the same idempotency_token as other players, it is recommended to concatenate it with the player_id. |
FPgosServerBatchSubtractPlayerVirtualCurrenciesResult
struct FPgosServerBatchSubtractPlayerVirtualCurrenciesResult
| field | type | description |
|---|
| player_id | FString | The player id who have been successfully granted. |
| replayed | bool | Whether the request is replayed. When it is True, it indicates that the result of the function is obtained by replaying with the same idempotency_token. This means that the result of the function has been generated in a previous call and is being reused in the current call. |
FPgosServerPartyCustomData
Custom data for party.
struct FPgosServerPartyCustomData
| field | type | description |
|---|
| version | int32 | Custom data version, always incremental over the lifetime of the party. |
| global_custom_data | FString | Global custom data. Only Leader has permission to modify it. |
| player_custom_data | TMap<FString, FString> | Player custom data. The map key is party member's player ID, the map value is the party member's custom data. Each party member could modify it's player custom data. |
FPgosServerPartyInfo
Detailed information of a party
struct FPgosServerPartyInfo
| field | type | description |
|---|
| party_id | FString | The party id |
| name | FString | Name of the party |
| leader | FPgosPlayerInfo | Player who is the leader of the party A leader can: Kick out members: a leader can kick out any member at any time. Dismiss the party. Transfer leadership to another member. |
| members | TArray<FPgosPlayerInfo> | Players of the party |
| created_time | int64 | The Unix timestamp(in seconds) when the party was created. |
| max_player | int32 | Max number of players in the party, unlimited if it is 0. |
| custom_data | FPgosServerPartyCustomData | Custom data of the party(including global and player). |
| join_strategy | EPgosServerPartyJoinStrategy | The strategy controls the rules who could join the party. |
| invite_strategy | EPgosServerPartyInviteStrategy | The strategy controls the rules who could invite others to the party. |
FPgosServerBatchGetPlayerCurrentPartyIdsParams
struct FPgosServerBatchGetPlayerCurrentPartyIdsParams
| field | type | description |
|---|
| player_ids | TArray<FString> | The player ids. |
FPgosServerBatchGetPlayerCurrentPartyIdsResult
struct FPgosServerBatchGetPlayerCurrentPartyIdsResult
| field | type | description |
|---|
| player_party_ids | TMap<FString, FString> | The map of player -> party ids, the empty value implies the player is not in any party. |
FPgosServerGetPartyInfoParams
struct FPgosServerGetPartyInfoParams
| field | type | description |
|---|
| party_id | FString | The player id. |
FPgosServerGetPartyInfoResult
struct FPgosServerGetPartyInfoResult
FPgosServerGetPlayerInventoryWithFilterParams
Get inventory with filter params.
struct FPgosServerGetPlayerInventoryWithFilterParams