POST /api_sign_in
Authenticate and return auth_token

Returns authentication token on verifying credentials. This auth_token should be added to header of every other api request.

Supported Formats

JSON

Params

Param name Description
email
required

Email address of user


Value: Must be a String
password
required

Password of user


Value: Must be a String
organisation_key
optional

Organisation Key of a child organisation of an OEM account. This allows an OEM admin to login as admin of that account


Value: Must be a String

Examples

Request:
 curl -X POST -H "Content-Type:application/json" -d '{"email":"bob@acme.com","password":"foobar"}' 'https://api.datonis.io/api_sign_in' 
Response:
 {
  "success": true,
  "auth_token": "wOzV_s3ZIheqrkCcKHTPxQ",
  "email": "bob@acme.com",
  "role": "admin",
  "time_zone": "Mumbai",
  "organisation": {
    "name": null,
    "organisation_key": "f58155467d2ba784516a59ade6t6715fde567131",
    "license": {
      "license_key": "61572fd9137fd5c95d33454tf98e662762116812"
    }
  }
}

DELETE /api_sign_out
Signout the User.

Delete the AuthToken and User will Signout

Supported Formats

JSON

Examples

Request:
 curl -X DELETE -H "Content-Type:application/json" 'https://api.datonis.io/api_sign_out' 
Response:
 {
  "success": true,
  "message": "User signout Sucessfully."
}

POST /azure_api_sign_in
Authenticate using OAuth and return auth_token

Returns authentication token on verifying credentials. This auth_token should be added to header of every other api request.

Supported Formats

JSON

Params

Param name Description
client_id
required

c


Value: Must be a String
code
required

Password of user


Value: Must be a String

Examples

Request:
 curl -X POST -H "Content-Type:application/json" -d '{"code":"1234-5678-91011212-131415","client_id":"foobar","mode":"AzureAD"}' 'https://api.datonis.io/azure_api_sign_in' 
Response:
 {
  "success": true,
  "auth_token": "wOzV_s3ZIheqrkCcKHTPxQ",
  "email": "bob@acme.com",
  "role": "admin",
  "time_zone": "Mumbai",
  "organisation": {
    "name": null,
    "organisation_key": "f58155467d2ba784516a59ade6t6715fde567131",
    "license": {
      "license_key": "61572fd9137fd5c95d33454tf98e662762116812"
    }
  }
}