Documentation

GetPlayerTrades

Gets all trades the player has either opened or accepted, optionally filtered by trade status.

Request Details

GetPlayerTradesRequest
Request Properties
StatusFilter TradeStatus

Returns only trades with the given status. If null, returns all trades.

POST https://{{TitleID}}.playfabapi.com/Client/GetPlayerTrades
    Content-Type: application/json
    X-Authentication: <user_session_ticket_value>
{
  "StatusFilter": "Filled"
}
        

Response Details

GetPlayerTradesResponse
Result Properties
AcceptedTrades List<TradeInfo>

History of trades which this player has accepted.

OpenedTrades List<TradeInfo>

The trades for this player which are currently available to be accepted.

Sample Response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
  "code": 200,
  "status": "OK",
  "data": {
    "OpenedTrades": [
      {
        "Status": "Filled",
        "TradeId": "D819CEC225EA9948C351",
        "OfferingPlayerId": "CD803BF233CE76CC",
        "OfferedInventoryInstanceIds": [
          "1359447",
          "635691"
        ],
        "OfferedCatalogItemIds": [
          "gun_1",
          "skin_3"
        ],
        "RequestedCatalogItemIds": [
          "rare_hat_7"
        ],
        "AcceptedPlayerId": "461535E1EF4150A86889",
        "AcceptedInventoryInstanceIds": [
          "95C1797ADDAC24DC0383",
          "0F7793DF55CCEAF21B84"
        ],
        "OpenedAt": "2015-04-07T09:04:28Z",
        "FilledAt": "2015-04-07T09:20:53Z"
      }
    ],
    "AcceptedTrades": [
      {
        "Status": "Filled",
        "TradeId": "20BC5A5DCD966_D4935E795ABAE6",
        "OfferingPlayerId": "20BC5A5DCD966",
        "OfferedInventoryInstanceIds": [
          "23BDCB"
        ],
        "OfferedCatalogItemIds": [
          "boost_10"
        ],
        "RequestedCatalogItemIds": [
          "gem_5",
          "card_3"
        ],
        "AcceptedPlayerId": "CD803BF233CE76CC",
        "AcceptedInventoryInstanceIds": [
          "2DDD0187",
          "35D2A00"
        ],
        "OpenedAt": "2015-05-01T11:45:19Z",
        "FilledAt": "2015-05-01T15:07:34Z"
      }
    ]
  }
}

Authentication

SessionTicket

Possible Error Codes

Name Code