# IRPCServerAdmin.GetServerUsers

Location: [gRPC API](https://developer.m-files.com/APIs/gRPC-API/index.md) > [Administration API](https://developer.m-files.com/APIs/gRPC-API/admin/index.md) > [Server administration](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCServerAdmin/index.md)

HTML version: https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCServerAdmin/GetServerUsers/

Badges: `Administration API / specialized` `admin` `session` `idempotent`

Gets the server users: account names with server roles that are stored separately from login
accounts.

- **Service:** [Server administration](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCServerAdmin/index.md) `MFiles.IRPCServerAdmin`
- **gRPC method:** `/MFiles.IRPCServerAdmin/GetServerUsers`
- **HTTP (mf-http-grpc):** `POST /grpc/v1/get-server-users`
- **Request:** [`GetServerUsersRequest`](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCServerAdmin/GetServerUsers/index.md#request)
- **Response:** [`GetServerUsersResponse`](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCServerAdmin/GetServerUsers/index.md#response)
- **Book and level:** Administration API, specialized
- **Kind:** admin
- **Session:** Required: the session ID from LogIn in the mfiles-session-id-bin metadata.
- **Idempotent:** yes
- **Returns metadata structure version:** no
- **Streaming:** none (unary)

<a id="remarks"></a>

## Remarks

- Any session can call it. Without the server right `manage_logins` the list is empty; the call
  does not fail.
- M-Files Admin shows these under "Server Users" on on-premises servers whose login accounts come
  from M-Files Manage.

<a id="request"></a>

## Request: GetServerUsersRequest

No fields.

<a id="response"></a>

## Response: GetServerUsersResponse

> Nested message fields are expanded to depth 3; follow a type link for deeper levels and for the type's own page.

| Field | Type | Description |
|---|---|---|
| `serverusers[]` | repeated [`ServerUser`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ServerUser/index.md) | The server users, each an account name and its server roles. See [ServerUser](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ServerUser/index.md). |
| `serverusers[].login_name` | `string` | The login name that is associated with this server user (e.g. 'DOMAIN\user'). |
| `serverusers[].server_roles` | [`SRVROLES`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.SRVROLES/index.md) | Bitmask of the server roles of the login. |
| `serverusers[].server_roles.all` | `bool` | Specifies all flags set; Including any future flags. |
| `serverusers[].server_roles.system_administrator` | `bool` | System administrator (can perform any operation on the server). [ name( "vaultCreator" ) ] const SRVROLES SRVROLE_VAULT_CREATOR		= ( 1 << 1 );  //!< Can create, modify and delete vaults. Can also restore vaults. [ name( "backupOperator" ) ] const SRVROLES SRVROLE_BACKUP_OPERATOR		= ( 1 << 2 );  //!< Can back up vaults. |
| `serverusers[].server_roles.can_log_in` | `bool` | Can log in. A login that does not have this role is disabled and cannot log in even if the login has the sysadmin role. |
| `serverusers[].server_roles.invalid_password` | `bool` | This special role indicates that the M-Files login does not yet have a valid password. MFAdmin uses this flag to force the user to define the password. |
