How to call Google Authenticator for two-factor authentication

Hey @jm.zhang

image

If you haven’t used one of your social accounts at Google, Facebook, Twitter, or LinkedIn to login to the portal.

To obtain a Two-factor authentication token using POST api/2.0/authentication/{code}, you only need:

  1. code from Google Authenticator (code)
  2. User name or email (userName)
  3. Password (password)

To obtain it using curl, use the following command:

curl --request POST --header “Content-Type: application/json” --data “{"username":"your@mail.com","password":"yourPassword"}” “portalNameOrIP/api/2.0/authentication/code.json”

“provider”, “accessToken”, and “codeOAuth” are used for authorization through social accounts.

Passing authentication

Authenticate a user

Authenticate a user by code

If that’s not what you meant, please let me know.