2bttns
  • Getting Started
    • What is 2bttns?
    • Quick Start
    • 🆕You Asked We Listened
  • HOW TO
    • Set up your Console
    • Use the API
    • Build a game
    • Manage game data
    • Integrate game via API
    • Retrieve scores via API
  • References
    • APIs
      • Authentication
      • Generate Game URL
      • Games
      • Game Objects
      • Tags
      • Players
      • Admin
      • Export/Import
    • Command Line Interface (CLI)
      • Install
      • Usage
      • Configuration
  • TUTORIALS
    • ✨Personalize profiles with 2bttns and Next.js
Powered by GitBook
On this page

Was this helpful?

  1. References
  2. APIs

Admin

PreviousPlayersNextExport/Import

Was this helpful?

Get All Admins

get

Get all administrators

Authorizations
Query parameters
takeany ofOptionalDefault: 10
notOptional
or
numberOptional
skipany ofOptionalDefault: 0
notOptional
or
numberOptional
idFilterany ofOptional

Comma-separated ids to filter by

notOptional
or
string[]Optional
allowFuzzyIdFilterbooleanOptional

Set to true to enable fuzzy id filtering. If false, only returns exact matches.

Default: false
sortFieldstring · enumOptional

Field to sort by

Possible values:
sortOrderstring · enumOptional

Sort order for the selected field

Possible values:
Responses
200
Successful response
application/json
default
Error response
application/json
get
GET /api/administrators HTTP/1.1
Host: 
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "administrators": [
    {
      "id": "text",
      "displayName": "text",
      "createdAt": "text",
      "updatedAt": "text",
      "lastSeen": "text"
    }
  ]
}

Get Admin Count

get

Get the total number of administrators. Useful for pagination.

Authorizations
Query parameters
idFilterany ofOptional

Comma-separated ids to filter by

notOptional
or
string[]Optional
allowFuzzyIdFilterbooleanOptional

Set to true to enable fuzzy id filtering. If false, only returns exact matches.

Default: false
Responses
200
Successful response
application/json
default
Error response
application/json
get
GET /api/administrators/count HTTP/1.1
Host: 
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "count": 1
}
  • GETGet All Admins
  • GETGet Admin Count