Authenticate. For internal use

Prev Next
Post
/authentication

API Scripts are recommended to use the Login call instead of separate Authentication & Authorization calls.

First step for logging in is sending the credentials and retrieving partial AuthToken. If the response has the "needTwoFactorAuth:true", then either API user must be extempt from Admin MFA or two-step MFA process must be completed before Authorization.

Security
HTTP
Type bearer
Body parameters

Login Credentials.

Expand All
object
providerName
string Required

Display name of the Identity Provider name.

Exampleldap
username
string

Username. Required if a credentials based Identity Provider is used.

Exampleuser
password
string

Password. Required if a credentials based Identity Provider is used.

ExampletSW3!QBv(rj{UuLY
deviceId
string (uuid) Required

UUID to distinguish the Client device making the request. It is supposed to be same for every login request from the same server.

Example4c07bc67-57ea-42dd-b702-c2d6c45419fc
samlResponse
string

SAMLResponse received from SAML provider. Required if a SAML based Identity Provider is used.

idToken
string

ID Token received from OIDC provider. Required if an OIDC based Identity Provider is used and the provider does not have a client secret (public client flow).

accessToken
string

Access Token received from OIDC provider. Optional for OIDC authentication.

oidcCodeExchange
object

OIDC authorization code exchange parameters. Required if an OIDC based Identity Provider is used and the provider has a client secret configured (backend token exchange flow).

authCode
string Required

Authorization code received from OIDC provider after user authentication.

redirectUri
string Required

Redirect URI used in authorization request. Must match exactly for OAuth security.

codeVerifier
string Required

PKCE code verifier generated by client.

Responses
200

Login Response.

Expand All
object
user
object

Information about logged in user, such as username and email address, if exists.

name
string

Username.

Exampleadmin
needTwoFactorAuth
boolean

If true, it is not possible to complete login process without providing MFA.

Examplefalse
canAccessAuditLogs
boolean

Whether there is a LogServer deployed and the user has privileges to access to it.

token
string

The AuthToken required for subsequent API calls.

expires
string (date-time)

Token expiration time.

rotatedReplicationAccessToken
string

Rotated replication access token. For internal use.

nextReplicationAccessToken
string

Next replication access token. For internal use.

400

JSON error. Check the JSON format.

object

Generic HTTP error.

id
string

Machine readable error code.

message
string

Human readable error details.

401

Login Failed.

object
id
string

Machine readable error code.

message
string

Human readable error details.

reason
string

The authentication failure reason.

ExampleInvalid username or password.
406

Invalid 'Accept' header.

object

Generic HTTP error.

id
string

Machine readable error code.

message
string

Human readable error details.

422

Request validation error. Check "errors" array for details.

Expand All
object

Http 422 error for object validation.

id
string

Machine readable error code.

message
string

Human readable error details.

errors
Array of object

List of fields with validation errors.

object
field
string

Name of the field that failed validation.

Examplename
message
string

Failure reason.

Examplemay not be null
displayField
string

Name of the field that should be displayed in the UI. It's an internal field to be used by the local replication service.

ExampleName
replicationMessage
string

Message to be displayed in the replication UI. It's an internal field to be used by the local replication service.

ExampleName is required.
500

Unexpected server side error.

object

Generic HTTP error.

id
string

Machine readable error code.

message
string

Human readable error details.