Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Expand
titleGet information from current user GET /rest/securelogin−admin/1.0/api/user

Get information from Secure Login related to the current user.

Request - Query Parameters

The username is taken from the current HTTP session, so no parameter to submit.

Responses

Status
colourGreen
titleStatus 200
- application/json
The request was completed successfully.

Status
colourRed
titleStatus 406410
- application/json
The request was aborted, because the plugin is not active.

Response fields

field

type

description

state

string

can take one of these values:

enter - the user has to enter the PIN
bypass - no action is needed
onboarding - the user has not completed the onboarding process yet. The onboarding process must be completed in a desktop browser.
blocked - currently, the user cannot proceed because the account is blocked.

blocked

structure

This is only available if status == blocked and contains details.

Structure fields:
reason - Indicates why the account is blocked. Its only value is brute_force – too many PIN failures.
until - Indicates until when the account is blocked. The timestamp format is in ISO- 8601 format and at time zone GMT.

Examples

Code Block
{
    "state": "enter"
}
Code Block
{
    "state": "blocked",
    "blocked": {
        "reason": "brute_force",
        "until": "2022−09−25T14:08:48Z"
    }
}

...

Expand
titleAuthenticate the current user POST /rest/securelogin−admin/1.0/api/auth

Submit the PIN to authenticate the current HTTP session for the current user.

Request - Query Parameters

The username is taken from the current HTTP session. The PIN is posted with a Content-Type of text/plain as a sequence of numbers without any prefix or suffix and without any spacing. Just the string like 910817.

Responses

Status
colourGreen
titleStatus 200
- no response body
The request was completed successfully and the session is authenticated.

Status
colourRed
titleStatus 401
- no response body
The authentication failed.

Status
colourRed
titleStatus 406
- no response body
The request was aborted because the app is not activeuser still has onboarding status and cannot be authenticated yet.

Status
colourRed
titleStatus 410
- no response body
The user still has onboarding status and cannot be authenticated yetrequest was aborted because the app is not active.

Response fields

None

Examples

None

...