Returning.AIDevelopers
v1

API reference / Community / Community Users

.md

Get community users

Get one page of your community's traders, with their names, email, online status and last sign-in.

Last updated 26 Sep 2026API v1

Method
GET
Path
https://api.returning.ai/v1/communities/{communityId}/users
Permission
None
Retries
Read-only; exact retries are safe

When to use this

  • You show a simple member list in your own admin tools, with who is online first.
  • You want to see which of your traders are online right now.
  • You need the platform user IDs of recently active traders.

Authentication#

Header
Authorization: Bearer <API_KEY>
Permission
NoneAny Community API key for this community works

Send a Community API key as Authorization: Bearer <API_KEY>, and keep it on your server. This endpoint needs no specific permission, but communityId must be the community that owns your key.

Behaviour#

Traders are sorted online first, then by most recent sign-in, so the order shifts as traders come and go; don't rely on paging to visit every trader exactly once. Results are cached, so a trader who just joined, or a profile that just changed, may not show straight away. To check one trader, use Get User Data.

By default every trader includes all ten fields. Send one or more field flags, such as email=true&id=true, to get only those fields.

Request#

Path parameters#

communityId#stringREQUIRED
Your community's ID. Use the community that owns your API key.

Rule24 hex characters

Eg"66f000000000000000000010"

Query parameters#

page#integerOPTIONAL
Page number.

RuleMin 1; default 1

Eg1

limit#integerOPTIONAL
Traders per page.

RuleDefault 20; max 100

Eg20

_id#booleanOPTIONAL
Send true to include _id. Sending any field flag returns only the flagged fields.

Egtrue

id#booleanOPTIONAL
Send true to include id, the platform user ID.

Egtrue

avatar#booleanOPTIONAL
Send true to include avatar.

Egtrue

displayName#booleanOPTIONAL
Send true to include displayName.

Egtrue

username#booleanOPTIONAL
Send true to include username.

Egtrue

firstName#booleanOPTIONAL
Send true to include firstName.

Egtrue

lastName#booleanOPTIONAL
Send true to include lastName.

Egtrue

email#booleanOPTIONAL
Send true to include email.

Egtrue

isOnline#booleanOPTIONAL
Send true to include isOnline.

Egtrue

lastLogin#booleanOPTIONAL
Send true to include lastLogin.

Egtrue

Headers#

Authorization#stringREQUIRED
Community API key. No specific permission is needed.

RuleBearer <API_KEY>

curl --request GET \
  --url 'https://api.returning.ai/v1/communities/66f000000000000000000010/users?page=1&limit=20' \
  --header 'Authorization: Bearer <API_KEY>'

Response#

A 200 returns up to limit traders in data, with the page details in meta. A trader whose profile is missing a required value, such as an email, is left out of data and listed in meta.validationErrors instead.

meta#objectALWAYS

Eg{ ... }

status#stringALWAYS

Eg"success"

statusCode#integerALWAYS

Eg200

total#integerALWAYS
Number of community memberships. It can be higher than the traders you can page through.

Eg1

page#integerALWAYS
The page returned.

Eg1

limit#integerALWAYS
The page size used.

Eg20

validationErrors#object[]
Traders left out of this page because their profile is missing a required value, such as an email, with the reason.
message#stringALWAYS
Human-readable summary. Do not branch on it.

Eg"Get community users success."

data#object[]ALWAYS
Up to limit traders, online traders first, then by most recent sign-in.

Eg[ ... ]

_id#stringBY DEFAULT
The trader's internal record ID.

Eg"<userObjectId>"

id#numberBY DEFAULT
The trader's platform user ID, as a number here. Store it as a string.

Eg3247779

avatar#stringBY DEFAULT
Avatar image URL, or null.

RuleNullable

Egnull

displayName#stringBY DEFAULT
Public display name.

Eg"Sample Trader"

username#stringBY DEFAULT
Username.

Eg"sample_trader"

firstName#stringBY DEFAULT
First name, or ******** when the trader's privacy settings hide it.

Eg"Sample"

lastName#stringBY DEFAULT
Last name, or ******** when hidden.

Eg"Trader"

email#stringBY DEFAULT
Email, or ******** when hidden.

Eg"trader@example.com"

isOnline#booleanBY DEFAULT
true while the trader is online.

Egfalse

lastLogin#stringBY DEFAULT
When the trader last signed in.

RuleDate-time

Eg"2026-09-26T08:30:00.000Z"

{
  "meta": {
    "status": "success",
    "statusCode": 200,
    "total": 1,
    "page": 1,
    "limit": 20
  },
  "message": "Get community users success.",
  "data": [
    {
      "_id": "<userObjectId>",
      "id": 3247779,
      "avatar": null,
      "displayName": "Sample Trader",
      "username": "sample_trader",
      "firstName": "Sample",
      "lastName": "Trader",
      "email": "trader@example.com",
      "isOnline": false,
      "lastLogin": "2026-09-26T08:30:00.000Z"
    }
  ]
}

Errors#

Errors on this endpoint have no machine-readable code; branch on the HTTP status. Without an Authorization header the 401 body is not JSON. An unexpected failure returns 500; retry it with backoff.

Fix the request02

400Fix the request
page is below 1, limit is outside 1-100, either isn't a number, or communityId isn't a valid ID. detail names the parameter.
401Fix the request
The key is missing, invalid or expired, or it can't access this community. Send Authorization: Bearer <API_KEY> with a current key for your own community.
{
  "meta": {
    "status": "error",
    "statusCode": 400
  },
  "message": "Get community users error.",
  "detail": {
    "limit": "Limit cannot exceed 100"
  },
  "solution": "Read error detail and try again."
}

Next step#

Get User DataPOST/v1/users/infoRead one trader in full, including roles, coins, XP and custom fields, with their id.