Login

This method logs in player to site, and returns a token to be used in all other methods. use gateway.[msdomain]

Request (POST)

/gateway/login/{version}/{brand_id}/player

{
  "user_name": "string",
  "email": "string",
  "password": "string",
  "language": "string",
  "brand_id": "string"
}

Parameters:

Name In Type Required Description
version path string true The API version to use.
brand_id path int true The ID of the casino. If a brand_id is not provided, all message formats will be fetched from default storage.
user_name body string false Player user name to login with, if not sent, email will be used.
email body string false Player personal email, if user_name is not sent, email will be used as the user name.
password body string true Player password to login with.
language body string true Player chosen language, this will be the language player receives mails in.
2fa-auth-token header string false Player 2FA Auth token that was given when the Player turned on the 2FA requirement in the account page

Response

Status 200

{
  "auth_token": "e74af034-a346-4d5c-be97-f7ed83f373a7",
  "result": "OK",
  "actions": [
    "responsible_gaming",
    "limits",
    "deposit_message",
    "self_exclusion",
    "timeout",
    " account_closure",
    "swap_limits",
    "start_game",
    "wallet",
    "login",
    "KYC"
  ],
  "documents_required": true,
  "identification_token": "214fecab65a7031b8530d4d000f3aa8b",
  "links": {
    "get_crm_token": "/gateway/crm/{version}/{brand_id}/token"
  }
}

Status 303

Error Code Description
INCOMPLETE_REGISTRATION The player did not complete his registration process, need to complete Registration Step Two.
TNC_APPROVAL_REQUIRED Player need to approve TnC.
PRIVACY_APPROVAL_REQUIRED Player need to approve Privacy Policy.
PASSWORD_CHANGE_REQUIRED Player has temp password and need to Change Password.
EMAIL_NOT_VERIFIED Player email is not verified and cannot continue any process till he verifies his mail.

Response notes:

  • documents_required indicates if the player must upload KYC documents now. when true, identification_token contains a UUID (otherwise empty string).
  • For INCOMPLETE_REGISTRATION and EMAIL_NOT_VERIFIED it’s always false because these occur before KYC is needed; a true value for them cannot occur logically.

Example 1 — INCOMPLETE_REGISTRATION (no documents required)

{
  "token": "e74af034-a346-4d5c-be97-f7ed83f373a7",
  "result": "INCOMPLETE_REGISTRATION",
  "actions": [
    "responsible_gaming",
    "limits",
    "deposit_message",
    "self_exclusion",
    "timeout",
    "account_closure",
    "swap_limits",
    "start_game",
    "wallet",
    "login"
  ],
  "documents_required": false,
  "identification_token": ""
}

Example 2 — TNC_APPROVAL_REQUIRED (documents required)

{
  "token": "e74af034-a346-4d5c-be97-f7ed83f373a7",
  "result": "TNC_APPROVAL_REQUIRED",
  "actions": [
    "responsible_gaming",
    "limits",
    "deposit_message",
    "self_exclusion",
    "timeout",
    "account_closure",
    "swap_limits",
    "start_game",
    "wallet",
    "KYC",
    "login"
  ],
  "documents_required": true,
  "identification_token": "214fecab65a7031b8530d4d000f3aa8b"
}

Status 400

{
  "errMsg": "invalid input - invalid brand id"
}

Status 401

Error Code Description
USER_PASSWORD_NOT_VALID Credentials entered do not match any player in system.
EXCEEDED_MAX_LOGIN_ATTEMPTS To many login attempts made in short period, need to wait few minutes till next try, till then, player will be considered as ‘Blocked’.
BANNED_COUNTRY Login country is forbidden.
PLAYER_BLOCKED Player cannot login, he is blocked.
IP_BLOCKED IP has been black listed in system.
{
  "result": "USER_PASSWORD_NOT_VALID"
}

Status 401 (Player need to verify his mobile number)

{
  "status": "mobile_verification_required",
  "data": {
    "mobile_number": "****1234",
    "2fa_auth_token": "60a6bbc8-95a3-4b4f-8305-cb334cc975b1"
  }
}

Status 401 (Player need to verify his mobile number)

{
  "status": "sms_verification_required",
  "data": {
    "mobile_number": "****1234",
    "2fa_auth_token": "60a6bbc8-95a3-4b4f-8305-cb334cc975b1"
  }
}

Status 401 (Need to wait before sending SMS code again)

{
  "status": "LOGIN_IN_PROCESS",
  "data": {
    "description": "Please wait before sending again in 52 seconds",
    "remaining_time": 52
  }
}

Status 401 (Player is blocked due to missing KYC documents)

{
  "result": "PLAYER_BLOCKED",
  "actions": [
    "responsible_gaming",
    "limits",
    "deposit_message",
    "self_exclusion",
    "timeout",
    "account_closure",
    "swap_limits",
    "start_game",
    "wallet",
    "KYC",
    "login"
  ],
  "documents_required": true,
  "identification_token": "214fecab65a7031b8530d4d000f3aa8b"
}

Status 500

{
  "result": "internal server error"
}

Response Parameters:

Name Description
token UUID which should be used as x-auth-token during player login time on each action he performs on site.
actions List containing all regulation requirements.