Groups - Update Role

Updates metadata about a role.

POST https://titleId.playfabapi.com/Group/UpdateRole

Request Header

Name Required Type Description
X-EntityToken True

string

This API requires an Entity Session Token, available from the Entity GetEntityToken method.

Request Body

Name Required Type Description
Group True

EntityKey

The identifier of the group

RoleName True

string

The new name of the role

CustomTags

object

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

ExpectedProfileVersion

number

Optional field used for concurrency control. By specifying the previously returned value of ProfileVersion from the GetGroup API, you can ensure that the group data update will only be performed if the group has not been updated by any other clients since the version you last loaded.

RoleId

string

ID of the role to update. Role IDs must be between 1 and 64 characters long.

Responses

Name Type Description
200 OK

UpdateGroupRoleResponse

400 Bad Request

ApiErrorWrapper

This is the outer wrapper for all responses with errors

Security

X-EntityToken

This API requires an Entity Session Token, available from the Entity GetEntityToken method.

Type: apiKey
In: header

Definitions

Name Description
ApiErrorWrapper

The basic wrapper around every failed API response

EntityKey

Combined entity type and ID structure which uniquely identifies a single entity.

OperationTypes
UpdateGroupRoleRequest

Updates the role name. Returns information about whether the update was successful.

UpdateGroupRoleResponse

ApiErrorWrapper

The basic wrapper around every failed API response

Name Type Description
code

integer

Numerical HTTP code

error

string

Playfab error code

errorCode

integer

Numerical PlayFab error code

errorDetails

object

Detailed description of individual issues with the request object

errorMessage

string

Description for the PlayFab errorCode

status

string

String HTTP code

EntityKey

Combined entity type and ID structure which uniquely identifies a single entity.

Name Type Description
Id

string

Unique ID of the entity.

Type

string

Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types

OperationTypes

Name Type Description
Created

string

Deleted

string

None

string

Updated

string

UpdateGroupRoleRequest

Updates the role name. Returns information about whether the update was successful.

Name Type Description
CustomTags

object

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

ExpectedProfileVersion

number

Optional field used for concurrency control. By specifying the previously returned value of ProfileVersion from the GetGroup API, you can ensure that the group data update will only be performed if the group has not been updated by any other clients since the version you last loaded.

Group

EntityKey

The identifier of the group

RoleId

string

ID of the role to update. Role IDs must be between 1 and 64 characters long.

RoleName

string

The new name of the role

UpdateGroupRoleResponse

Name Type Description
OperationReason

string

Optional reason to explain why the operation was the result that it was.

ProfileVersion

number

New version of the role data.

SetResult

OperationTypes

Indicates which operation was completed, either Created, Updated, Deleted or None.

Error Codes

Name Code
RoleDoesNotExist 1358