Type: AuthenticationRequest


An authentication request made to the HiveMP servers to log a user in.


emailAddress Description The user's email address, which is used both as their primary account identifier and the mechanism that allows users to login to the game on new platforms they haven't previously played on before.
Type string
marketingPreferenceOptIn Description The user's marketing preference when they authenticate with your game for the first time.
Type boolean
metered Description Whether the created session should be a metered session. Metered sessions are charged by the session minute rather than by a fixed cost per API call. Please note that some API calls still incur charges even when accessed with a metered session; refer to HiveMP's pricing page for more information. If you do not provide a value here, the default is unmetered for "builtin:admin" roles and metered for all other roles.
Type boolean
passwordHash Description The user's password, salted with a "HiveMPv1" prefix and hashed with SHA256.
Type string
projectId Description When signing into a project with an administrative role, you need to
Type string
promptForProject Description

By default HiveMP will sign the user into the project as determined by the API key being used. However for most administrative session logins, the project you want to administer will be different from the project that is performing the sign-in (for example, through the Account Portal).

If this is true, then HiveMP will require a project ID to be present in the projectId field in order to complete authentication. The authentication response prior to this will include a list of projects the user can administer if the other authentication credentials are correct.

If this is false and projectId is null, HiveMP will only attempt to authenticate against the project specified by the API key.

Type boolean
requestedRole Description The requested role for the new session. This be one of the built-in roles ("builtin:user" or "builtin:admin"), or a custom role defined in the target project.
Type string
tokens Description A list of token-based authentication credentials to use when authenticating with HiveMP. Token-based authentication enables implicit login, where existing users of your application can be immediately signed into the app without a login prompt.
Type AuthenticationRequestTokens
twoFactor Description The two factor authentication information used to authenticate the user.
Type AuthenticationRequestTwoFactor