Account API
Endpoint Index
Action | Endpoint |
---|---|
Authenticate a standard account | POST /account/authenticate |
Authenticate an admin account | POST /account/authenticateAdmin |
Renew an authentication token | POST /account/renewAuthentication |
Unlock an account that has been locked out due to failed login attempts | POST /account/unlock |
Update a password | PATCH /account/v1/accounts/password |
Create an account | POST /account/v1/account |
Authentication
POST /account/authenticate
Name | Position | Type | Required |
---|---|---|---|
body | body | AuthenticateRequest | optional |
hostName | query | string | optional |
tenantName | query | string | optional |
AuthenticateResponse
Note
Use /authenticate
for authenticating as a regular user (in which case you must specify a tenantName
or hostName
), or for an administration account for deploying configurations (in which case you should not specify a tenantName
or hostName
.)
POST /account/authenticateAdmin
Name | Position | Type | Required |
---|---|---|---|
body | body | AuthenticateRequest | optional |
hostName | query | string | optional |
tenantLocator | query | string | optional |
tenantName | query | string | optional |
AuthenticateResponse
Note
Use /authenticateAdmin
for authenticating as a “tenant administrator.” It’s the equivalent of logging in as an administrator in the Socotra Administration UI to modify users, maintain external integrations, and query plugin logs. You must specify one of the tenantLocator, hostName, or tenantName. This type of account token cannot be used to deploy configurations.
Note
Values for hostName
and tenantName
can be included in either the query string or the AuthenticateRequest
POST /account/renewAuthentication
AuthenticateResponse
requiredpassword stringusername stringoptionalhostName stringtenantName string
requiredexpiresTimestamp timestampauthorizationToken string
Account Lockout Reset
POST /account/unlock
Name | Position | Type | Required |
---|---|---|---|
request | body | AccountUnlockRequest | required |
void
Note
To unlock any account you must be authenticated as an admin user.
requiredusername stringoptionalhostName stringtenantName string
Note
To unlock a tenant user account you must specify both the username and hostname in the request. To unlock another admin user you must specify only the username.
Password Change
A user can change their password with the following endpoint:
PATCH /account/v1/accounts/password
Name | Position | Type | Required |
---|---|---|---|
passwordRequest | body | PasswordChangeRequest | required |
void
requiredoldPassword stringpassword string
Note
Note that the path for the above endpoint is /accounts
and not /account
.
Account Management
POST /account/v1/account
Name | Position | Type | Required |
---|---|---|---|
accountRequest | body | AccountAddRequest | required |
AccountResponse
requiredname stringemail stringpassword stringtype stringusername string
requiredid stringname stringcreatedTimestamp timestampaccountType string account.internal | account.tenant.admin | account.tenant.employee | account.tenant.read.only.user | account.tenant.claims.only.user | account.unauthenticated | account.test.tenant.admindeleted booleanemail stringlocked booleantenant stringusername string