Documentation

GetUserBans

Gets all bans for a user.

Request Details

Get all bans for a user, including inactive and expired bans.

GetUserBansRequest
Request Properties
PlayFabId (required) String

Unique PlayFab assigned ID of the user on whom the operation will be performed.

POST https://{{TitleID}}.playfabapi.com/Admin/GetUserBans
    Content-Type: application/json
    X-SecretKey: <developer_secret_key>
{
  "PlayFabId": "1679AF5CD04BD838"
}
        

Response Details

GetUserBansResult
Result Properties
BanData List<BanInfo>

Information about the bans

Sample Response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
  "code": 200,
  "status": "OK",
  "data": {
    "BanData": [
      {
        "PlayFabId": "1679AF5CD04BD838",
        "BanId": "E0B5FF89542D413C",
        "IPAddress": "192.111.11.1",
        "Created": "2016-08-13T05:04:03Z",
        "Reason": "You cheated!",
        "Active": false
      },
      {
        "PlayFabId": "1679AF5CD04BD838",
        "BanId": "EF43FF89542G1546",
        "Created": "2016-05-13T05:04:03Z",
        "Expires": "2016-09-13T05:04:03Z",
        "Reason": "You used speed hack!",
        "Active": true
      }
    ]
  }
}

Authentication

SecretKey

Possible Error Codes

Name Code
UserisNotValid 1030