Skip to main content
GET
/
:projectId
/
api
/
v7
/
users
/
by-username
Fetch User by Username
curl --request GET \
  --url https://api.replyke.com/api/v6/:projectId/api/v7/users/by-username
{
  "id": "<string>",
  "foreignId": {},
  "projectId": "<string>",
  "name": {},
  "username": {},
  "avatar": {},
  "bio": {},
  "metadata": {},
  "reputation": 123,
  "avatarFile": {},
  "bannerFile": {},
  "createdAt": "<string>"
}
Finds a user within the project by their username. Optionally includes file associations for avatar and banner images.

Query Parameters

username
string
required
The username to look up. Lookup is exact-match and case-sensitive to the stored value (usernames are lowercased on write).
include
string
Comma-separated list of associations to include. Pass "files" to include the processed avatarFile and bannerFile objects.

Response

On success, returns HTTP 200 with the user object:
id
string
Unique user ID (UUID).
foreignId
string | null
External identifier from your system.
projectId
string
Project this user belongs to.
name
string | null
Display name.
username
string | null
The user’s username.
avatar
string | null
Avatar image URL.
bio
string | null
Short bio text.
metadata
object | null
Public custom key-value data.
reputation
number
Reputation score.
avatarFile
object | null
Processed avatar image with variants. Only present when include=files is requested.
bannerFile
object | null
Processed banner image with variants. Only present when include=files is requested.
createdAt
string
ISO timestamp of account creation.

Error Responses

{
  "error": "User not found",
  "code": "user/not-found"
}
{
  "error": "...",
  "code": "user/invalid-query"
}

See Also