Search users according filter conditions
const url = 'https://gitea.com/api/v1/admin/users';const options = {method: 'GET', headers: {Authorization: 'Basic <credentials>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://gitea.com/api/v1/admin/users \ --header 'Authorization: Basic <credentials>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”ID of the user’s login source to search for
Identifier of the user, provided by the external authenticator
Page number of results to return (1-based)
Page size of results
Sort users by attribute. Supported values are “name”, “created”, “updated” and “id”. Default is “name”
Sort order, either “asc” (ascending) or “desc” (descending). Default is “asc”, ignored if “sort” is not specified.
Search term (username, full name, email)
Visibility filter. Supported values are “public”, “limited” and “private”.
Filter active users
Filter admin users
Filter restricted users
Filter 2FA enabled users
Filter login prohibited users
Responses
Section titled “Responses”UserList
User represents a user
object
Is user active
URL to the user’s avatar
The user’s description
User counts
The user’s full name
URL to the user’s gitea page
The user’s id
Is the user an administrator
User locale
The user’s location
Login of the user, same as username
Identifier of the user, provided by the external authenticator (if configured)
Is user login prohibited
Is user restricted
The ID of the user’s Authentication Source
User visibility level option: public, limited, private
The user’s website
Example
[ { "login_name": "empty", "visibility": "public" }]APIForbiddenError is a forbidden error response
Headers
Section titled “Headers”APIValidationError is error format response related to input validation