Autocomplete Room Name for Private and Public Rooms
- Print
- DarkLight
- PDF
Autocomplete Room Name for Private and Public Rooms
- Print
- DarkLight
- PDF
Article summary
Did you find this summary helpful?
Thank you for your feedback
Get
/api/v1/rooms.autocomplete.channelAndPrivate
List the public and private rooms whose names match a given string, excluding discussions, DMs, and omnichannel rooms. The endpoint is valuable when performing search operations. It returns only rooms that the user belongs to.
Header parameters
X-Auth-Token
stringRequired
The authToken
of the authenticated user.
ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
X-User-Id
stringRequired
The userId
of the authenticated user.
ExamplerbAXPnMktTFbNpwtJ
Query parameters
selector
stringRequired
The term to be completed. It only applies to room name.
Example{"name":"ran"}
Responses
200
OK
Success
{
"items": [
{
"_id": "664f0d525df46832f75b1860",
"fname": "rancher",
"name": "rancher",
"t": "p"
},
{
"_id": "6630e94ad2226209149c67e2",
"fname": "random",
"name": "random",
"t": "c"
},
{
"_id": "664f148f5df46832f75b18b2",
"fname": "ranmowe",
"name": "ranmowe",
"t": "p"
}
],
"success": true
}
object
items
Array of object
object
_id
string
fname
string
name
string
t
string
success
boolean
400
Bad Request
Selector Param Required
{
"success": false,
"error": "The 'selector' param is required"
}
object
success
boolean
error
string
401
Unauthorized
Authorization Error
{
"status": "error",
"message": "You must be logged in to do this."
}
object
status
string
message
string
Was this article helpful?