API Portal

πŸ“œ User Transactions Endpoint

The User Transactions API retrieves the complete transaction history for a specific player. It includes all Credits IN and Credits OUT records performed by cashiers, including timestamps, amounts, IPs, and descriptions.

ℹ️ Description
  • Lists all transactions for the selected player (credits added or removed).
  • Supports filtering by transaction type:
    • ?type=in β†’ only deposits / credits in
    • ?type=out β†’ only withdrawals / credits out
  • Results are paginated β€” default 20 records per page.
  • You can customize pagination using ?page= and ?per_page= parameters.
  • Each transaction shows the cashier who performed the action and the originating IP address.
Endpoint
GET https://proapi.gapi.lol/api/cashier/user/{id}/transactions

Replace {id} with the player’s unique ID. Optional query: ?type=in or ?type=out

Authentication

This endpoint requires a valid cashier Bearer token:

Authorization: Bearer <your_token>
Accept: application/json
πŸ“„ Pagination

This endpoint supports standard pagination. By default, it returns 20 transactions per page. You can control this using query parameters:

?page=2&per_page=50
  • page β€” the page number to retrieve.
  • per_page β€” number of results per page (default = 20).

Example:

GET https://proapi.gapi.lol/api/cashier/user/3154/transactions?page=2&per_page=50

The response includes pagination metadata so you can know how many total pages exist:

"pagination": {
  "current_page": 2,
  "last_page": 5,
  "total": 100
}
Successful Response

Returns a paginated list of transactions with amount, type, and cashier info:

{
  "success": true,
  "user_id": 3154,
  "transactions": [
    {
      "id": 12025,
      "username": "demo",
      "cashier": "[email protected]",
      "in": "100.00",
      "out": "0.00",
      "date": "2025-10-31T12:21:40+02:00",
      "description": "Normal deposit",
      "ip": "192.168.1.5"
    },
    {
      "id": 12024,
      "username": "demo",
      "cashier": "[email protected]",
      "in": "0.00",
      "out": "50.00",
      "date": "2025-10-31T10:03:12+02:00",
      "description": "Cashier out",
      "ip": "192.168.1.5"
    }
  ],
  "pagination": {
    "current_page": 1,
    "last_page": 5,
    "total": 100
  }
}
Error Responses

401 Unauthorized β€” Missing or invalid Bearer token:

{
  "success": false,
  "message": "Please login via API token"
}

404 Not Found β€” Player not found or not part of this shop:

{
  "success": false,
  "message": "User not found"
}
Example Request (cURL)
curl -X GET "https://proapi.gapi.lol/api/cashier/user/3154/transactions?type=in&page=2&per_page=50" \
  -H "Authorization: Bearer <your_token>" \
  -H "Accept: application/json"