Interface IUGCPlayerApi
Represents a collection of functions to interact with the API endpoints
Namespace: Unity.Services.Apis.UGC
Assembly: solution.dll
Syntax
public interface IUGCPlayerApi : IApiAccessor
Methods
BanPlayer(string, string, BanPlayerRequest, CancellationToken)
Ban a player from doing any actions
Declaration
ApiOperation<BannedPlayerDTO> BanPlayer(string projectId, string environmentId, BanPlayerRequest banPlayerRequest = null, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | projectId | The project for this player |
string | environmentId | The environment for this player |
BanPlayerRequest | banPlayerRequest | Reason for the ban (optional) |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
ApiOperation<BannedPlayerDTO> | The operation |
GetPlayerStatistics(string, string, CancellationToken)
Get Current Player Statistics
Declaration
ApiOperation<PlayerStatisticsDTO> GetPlayerStatistics(string projectId, string environmentId, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | projectId | |
string | environmentId | |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
ApiOperation<PlayerStatisticsDTO> | The operation |
UnbanPlayer(string, string, UnbanPlayerRequest, CancellationToken)
Unban a previously banned player
Declaration
ApiOperation UnbanPlayer(string projectId, string environmentId, UnbanPlayerRequest unbanPlayerRequest = null, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | projectId | The project for this player |
string | environmentId | The environment for this player |
UnbanPlayerRequest | unbanPlayerRequest | The playerId of the player (optional) |
CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
Type | Description |
---|---|
ApiOperation | The operation |