Skip to content

Returns the three leaderboards — last 7 days, last 30 days and all time — each with its top ten members and their profiles attached.

No parameters are read; the ranking size and windows are fixed. Results are cached for five minutes, so a member who has only now earned points may not move immediately.

Endpoint

  • Method: GET

  • Path: /leaderboard

  • Edition: PRO

  • Controller: LeaderBoardController@getLeaders

  • Route source: fluent-community-pro/app/Modules/LeaderBoard/Http/leaderboard_api.php:8

  • Requires FluentCommunity Pro; visibility is governed by the leaderboard_members_visibility privacy setting, which can open it to everyone, restrict it to signed-in members, or limit it to moderators.

  • This read endpoint writes: where a stored profile point total is behind the calculated one it is corrected and fluent_community/user_points_updated fires, which can trigger a level upgrade and any automation listening on it.

  • The routes are registered even when the leader_board_module feature is switched off, though the scoring that feeds them is not.

Live sample

The request and response below were recorded against a running FluentCommunity install and then anonymised — member names, emails, avatars and post content are fictional, and long collections are trimmed to a few entries.

GET List Leaderboard

GET
/leaderboard

Returns the three leaderboards — last 7 days, last 30 days and all time — each with its top ten members and their profiles attached.

Controller: LeaderBoardController@getLeaders
Route source: fluent-community-pro/app/Modules/LeaderBoard/Http/leaderboard_api.php:8

Authorizations

ApplicationPasswords

WordPress Application Passwords — use Basic auth with username:application_password.

Type
API Key (header: Authorization)

Responses

Successful response

application/json
JSON
{
  
"current_user_follows": {
  
  
"10": "string",
  
  
"148": "string",
  
  
"166": "string",
  
  
"242": "string",
  
  
"1707": "string",
  
  
"2813": "string",
  
  
"3327": "string",
  
  
"3952": "string",
  
  
"6531": "string",
  
  
"9933": "string"
  
},
  
"leaderboard": [
  
  
{
  
  
  
"items": [
  
  
  
  
{
  
  
  
  
  
"total_points": "string",
  
  
  
  
  
"user_id": "string",
  
  
  
  
  
"xprofile": {
  
  
  
  
  
  
"avatar": "string",
  
  
  
  
  
  
"badge": "string",
  
  
  
  
  
  
"created_at": "string",
  
  
  
  
  
  
"display_name": "string",
  
  
  
  
  
  
"is_verified": 0,
  
  
  
  
  
  
"last_activity": "string",
  
  
  
  
  
  
"meta": {
  
  
  
  
  
  
  
"badge_slug": "string",
  
  
  
  
  
  
  
"cover_photo": "string",
  
  
  
  
  
  
  
"social_links": {
  
  
  
  
  
  
  
  
"fb": "string",
  
  
  
  
  
  
  
  
"instagram": "string",
  
  
  
  
  
  
  
  
"linkedin": "string",
  
  
  
  
  
  
  
  
"twitter": "string",
  
  
  
  
  
  
  
  
"youtube": "string"
  
  
  
  
  
  
  
},
  
  
  
  
  
  
  
"website": "string"
  
  
  
  
  
  
},
  
  
  
  
  
  
"permalink": "string",
  
  
  
  
  
  
"short_description": "string",
  
  
  
  
  
  
"status": "string",
  
  
  
  
  
  
"total_points": 0,
  
  
  
  
  
  
"user_id": 0,
  
  
  
  
  
  
"username": "string"
  
  
  
  
  
}
  
  
  
  
}
  
  
  
],
  
  
  
"key": "string",
  
  
  
"title": "string"
  
  
}
  
]
}

Playground

Authorization

Samples

Powered by VitePress OpenAPI

FluentCommunity developer documentation