Autocomplete User

Prev Next
Get
/api/v1/users.autocomplete

List the users whose names match a given pattern.

Header parameters
X-Auth-Token
stringRequired

The authenticated user token.

ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
X-User-Id
stringRequired

The authenticated user ID.

ExamplerbAXPnMktTFbNpwtJ
Query parameters
selector
objectRequired

Filter the response with the parameters.

Example{ "exceptions": [ "john.doe" ], "conditions": { "status": "offline" }, "term": "user", "$or": [ { "type": "user" }, { "roles": [ "bot" ] } ] }
Responses
200
Success Example
{
  "items": [
    {
      "_id": "6esQ6cpqSQYvoLTvC",
      "username": "Aaron.altamirano",
      "status": "offline",
      "name": "Aaron Altamirano ",
      "nickname": "[email protected]"
    },
    {
      "_id": "AySWYsyzToxy3239z",
      "username": "Balazs.Nemethi",
      "status": "offline",
      "name": "Balázs Némethi"
    },
    {
      "_id": "gxcJTYapi5mPxuAme",
      "username": "Bruno.Solis",
      "status": "offline",
      "name": "Bruno Solis",
      "avatarETag": "ZAHMxLQ6bW426Knwm"
    },
    {
      "_id": "kvqbntLso8y2dEx7C",
      "username": "Ivan.Belousov",
      "status": "offline",
      "name": "Ivan"
    },
    {
      "_id": "AkFjhgJFHAhNK3e6o",
      "status": "offline",
      "name": "Karina Monarkh",
      "username": "Karina"
    },
    {
      "_id": "M3ajjGeyg8SfKXopd",
      "username": "Rucks_guest2",
      "status": "offline",
      "name": "Rucks_guest2",
      "nickname": "anonymous3"
    }
  ],
  "success": true
}
Expand All
object
items
Array of object
object
_id
string
username
string
status
string
name
string
nickname
string
success
boolean
400

Bad Request

Example 1
{
  "success": false,
  "error": "must have required property 'selector' [invalid-params]",
  "errorType": "invalid-params"
}
object
success
boolean
error
string
errorType
string
401

Unauthorized

Authorization Error
{
  "status": "error",
  "message": "You must be logged in to do this."
}
object
status
string
message
string