# AuthDataType

Location: [gRPC API](https://developer.m-files.com/APIs/gRPC-API/index.md) > [Reference](https://developer.m-files.com/APIs/gRPC-API/Reference/index.md) > [Enums](https://developer.m-files.com/APIs/gRPC-API/Reference/Enums/index.md)

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

Authentication methods for [LogIn](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCLogin/LogIn/index.md).

- **Full name:** `MFiles.AuthDataType`
- **Proto file:** [`mfiles/enums.proto`](https://developer.m-files.com/APIs/gRPC-API/downloads/proto/mfiles/enums.proto)

<a id="values"></a>

## Values

| Name | Number | Description |
|---|---|---|
| <a id="v-AUTH_DATA_TYPE_UNDEFINED"></a>`AUTH_DATA_TYPE_UNDEFINED` | 0 | Not a valid choice; `LogIn` fails with `E_INVALIDARG`. |
| <a id="v-AUTH_DATA_TYPE_MFILES_LEG1"></a>`AUTH_DATA_TYPE_MFILES_LEG1` | 1 | First step of the M-Files challenge login, used by M-Files clients. Applications use `AUTH_DATA_TYPE_CREDENTIALS` instead. |
| <a id="v-AUTH_DATA_TYPE_MFILES_LEG2"></a>`AUTH_DATA_TYPE_MFILES_LEG2` | 2 | Second step of the M-Files challenge login. |
| <a id="v-AUTH_DATA_TYPE_WINDOWS"></a>`AUTH_DATA_TYPE_WINDOWS` | 3 | Windows authentication (SSPI tokens), possibly over several calls. |
| <a id="v-AUTH_DATA_TYPE_PLUGIN"></a>`AUTH_DATA_TYPE_PLUGIN` | 4 | An authentication plug-in, such as single sign-on through an identity provider. See [GetAuthenticationConfiguration](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCLogin/GetAuthenticationConfiguration/index.md). |
| <a id="v-AUTH_DATA_TYPE_CREDENTIALS"></a>`AUTH_DATA_TYPE_CREDENTIALS` | 5 | User name and password in one call. The simplest method for applications; use it over TLS. |
| <a id="v-AUTH_DATA_TYPE_ANONYMOUS"></a>`AUTH_DATA_TYPE_ANONYMOUS` | 6 | Anonymous access, only to vaults configured to allow it. |

<a id="used-in-fields"></a>

## Used in fields

- [`AuthDataClient.type`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.AuthDataClient/index.md#f-type): The authentication method. Must match the member set in `data`; unset fails with `E_INVALIDARG`. For user name and password use `AUTH_DATA_TYPE_CREDENTIALS`.
- [`AuthDataServer.type`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.AuthDataServer/index.md#f-type): The authentication method, as in the request.
