Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Replace /admin/v1/users_paginate endpoint with /admin/v2/users #5925

Merged
merged 12 commits into from
Dec 5, 2019
7 changes: 4 additions & 3 deletions docs/admin_api/user_admin_api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ The api is::
including an ``access_token`` of a server admin.
The parameters ``from`` and ``limit`` are required only for pagination.
By default, a ``limit`` of 100 is used.
The parameter ``user_id`` can be used to filter by user id using an SQL regexp.
The parameter ``user_id`` can be used to select only users with user ids that
contain this value.
richvdh marked this conversation as resolved.
Show resolved Hide resolved
The parameter ``guests=false`` can be used to exclude guest users,
default is to include guest users.
The parameter ``deactivated=true`` can be used to include deactivated users,
Expand All @@ -23,14 +24,14 @@ It returns a JSON body like the following:
{
"users": [
{
"user_id": "<user_id1>",
"name": "<user_id1>",
"password_hash": "<password_hash1>",
"is_guest": 0,
"admin": 0,
"user_type": null,
"deactivated": 0
}, {
"user_id": "<user_id2>",
"name": "<user_id2>",
"password_hash": "<password_hash2>",
"is_guest": 0,
"admin": 1,
Expand Down
4 changes: 2 additions & 2 deletions synapse/storage/_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1594,8 +1594,8 @@ def _simple_select_list_paginate_txn(
Executes a SELECT query on the named table with start and limit,
of row numbers, which may return zero or number of rows from start to limit,
returning the result as a list of dicts.
Use filters to search attributes using SQL regular expressions and/or keyvalues
to select attributes with exact matches. All constraints are joined together
Use `filters` to search attributes using SQL wildcards and/or `keyvalues` to
select attributes with exact matches. All constraints are joined together
using 'AND'.

Args:
Expand Down