/auth/listApplications


+Examples:+
Method:/auth/listApplications
Parameters: 
\{
"return":\["id","name"\]
\}
Response: 
\{
 "error":0,
"result":
\{
total:1,
rows:
\[
 \{
 "id":"aid1",
 "name":"aaa application"
\}
\]
\}
\\
\}
\\
\\


/auth/listDomains


+Examples:+
Method:/auth/listDomains
Parameters: 
\{
 "application":
\{
"id":appid
\},
 "return":\["id","name"\]
\}
Response: 
\{
 "error":0,
 "result":
\{
total:1,
rows:
\[
 \{
 "id":"did1",
 "name":"aaa domain"
\}
\]
\}
\}
\\


/auth/ listAuthenticators


\\
+Examples:+
Method:/auth/ listAuthenticators
Parameters: 
\{
 "step": 1// step is 1-based
 "application":
\{
"id":appid
\},
"user":
\{
"domain.id":domainid,
"loginName":"login name"
\}
\\
\}
Response: 
\{
 "error":0,
 "result":\[total:2, rows:\[\{name:"OTP"\},\{name:"PASSWORD"\}\]
\}


/auth/getLogonSteps


+Examples:+
Method:/auth/getLogonSteps
Parameters: 
\{
 "application":
\{
"id":appid
\},
"return":\["challengResponse", "checkStaticPass","name"\]
\}
Response: 
\{
 "error":0,
 "result":\[total:3, rows:\[...\]\]
\}
\\
\\
\\


/auth/logon

Examples:
Method:/auth/logon
Parameters:
{
"application":
{
"id":appid
},
"user":
{
"id":userid
},
"token":
{
"serial":"10000000"
},
"credential":
{
"otp":"123456",
//"cc":"121212" // if verifyResponse is required
}
}
Response:
{
"error":0
}

/auth/logout

Examples:
Method:/auth/logout
Parameters:
{
}
Response:
{
"error":0
}

/auth/verify

Examples:
Method:/auth/verify
Parameters:
{
"user":
{
"id":userid
},
"token":
{
"serial":"10000000"
},
"credential":
{
"otp":"123456",
//"cc":"121212" // if verifyResponse is required
}
}
Response:
{
"error":0
}

/auth/verifyResponse

Examples:
Method:/auth/verifyResponse
Parameters:
{
"user":
{
"id":userid
},
"token":
{
"serial":"10000000"
},
"credential":
{
"otp":"123456",
"cc":"13113131"
}
}
Response:
{
"error":0
}

/auth/sendOTP

Examples:
Method:/auth/sendOTP
Parameters:

{
	"user":
	{
		"loginName": "user login name"
	},
	"token": // optional
	{
		"serial":"10000000"
	},
	"options": // optional
	{
		"format":"TEXT|HTML",
		"channel":"SMS",
		"expire":"2011-01-01T00:00:00"
	}
}

Send OTP to user "acme\john.smith" via "SMS"

{
	"user":
	{
		"loginName": "acme\\john.smith"
	},
	"options":
	{
		"channel":"SMS"
	}
}


Response:

{
	"error":0
}

/auth/sendActivationCode

Examples:
Method:/auth/sendActivationCode
Parameters:

{
	"user":
	{
		"id":"userid"
	},
	"token":
	{
		"serial":"10000000"
	},
	"options":
	{
		"format":"TEXT|HTML",
		"channel":"SMS",
		"expire":"2021-01-01T00:00:00"
	}
}


{
	"tokenAssignment":
	{
		"id":"token assignment id"
	},
	"options":
	{
		"format":"TEXT|HTML",
		"channel":"SMS",
		"expire":"2021-01-01T00:00:00"
	}
}



Response:
{
"error":0
}

/auth/syncToken

Examples:
Method:/auth/syncToken
Parameters:
{
"user":
{
"id":userid
},
"token":
{
"serial":"10000000"
},
"credential":"otp1,otp2"
}
Response:
{
"error":0
}

/auth/downloadToken

Examples:
Method:/auth/downloadToken
Parameters:
{
"user":
{
"id":userid
},
"token":
{
"serial":"10000000"
},
"acHash":SHA1 hash of activation code in base64 encoded
}
Response:
{
"error":0
}

/auth/activateTokenAssignment

Examples:
Method:/auth/activateTokenAssignment
Parameters:
{
// "tokenAssignment":{"id":assid}
"user":
{
"id":userid
},
"token":
{
"serial":"10000000"
},
"acHash":SHA1 hash of activation code in base64 encoded
}
Response:
{
"error":0
}

/auth/getPolicy


+Examples:+
Method:/auth/getPolicy
Parameters: 
\{
"application":
\{
 "name":"appname"
\},
"user":
\{
"loginName":"login name",
"domain.id":domainid
\},
"category":
\{
 "name":"logon"
\},
 "return":\["name", "id","options"\]
\}
Response: 
\{
 "error":0,
"result":
\{
  "id":"1",
  "name":"System logon policy",
"options":
\{
 "key":"value",
...
\}
\}
\}


/auth/listUsers


+Examples:+
Method:/auth/listUsers
Parameters: 
\{
"user":
\{
"loginName":"login name",
"domain.id":domainid
\}
 return:\["*"\]
\}
Response:
\{
 "error":0,
"result":\{"id":1,…\}
\}


/auth/listSiteStamps


+Examples:+
Method:/auth/listSiteStamps
Parameters: 
\{
"user":
\{
"id":userid
\}
 return:\["*"\]
\}
Response:
\{
 "error":0,
"result":\{"id":1, …\}
\}
\\
\\


/auth/getChallengeCode


+Examples:+
Method:/auth/getChallengeCode
Parameters: 
\{
"user":
\{
"loginName":"login name",
"domain.id":domainid
\},
"token":
\{
id:tid1
\},
 return:\["id", "code", "starts", "expires"\]
\}
Response:
\{
 "error":0,
"result":\{"id":1, "code":"xxx", starts:"xxx", expires:"xxx"\}
\}
\\
+Examples:+
The GridGo challenge code is the matrix in JSON string
\\
Parameters: 
\{
 "user":
\{
"loginName":"login name",
"domain.id":domainid
\},
"token":
\{
"product.method":"GridGo"
\},
\\
"return":\["id", "code", "reference"\]
\}
Response: 
\{
 "error":0,
 "result":
\{
 "id":"#i#_ChallengeCode_22",
"code":
'\{"grid":\["53c1s3npxgws4pw6jp5kx3",
"scmmu698wp9t1sag5spxzz",
"gmmzdj97x3jn4bpe9cvu1r",
"ps0hs5g2nh5xer6r93fj7x",
"mn8zbs5nnnm8rxt2r5ekd0",
"0jr935hx618a3vcvzdehn0",
"9xtr71jff7jaz255n5rtc4",
"dr96rxn7pgs3anmfzpeu7y",
"uf06ttmc3kfvhrun2remk9",
"z7c3ytf9u2xtfmc60p06ax"\],
"rows":10,
"cols":22,
"indiecs":"ABCDEFGHJKMNPRSTUVWXY"
\}',
"reference":"10948e64-b829-47be-be2a-414217bee16f"
\}
\}


/auth/listTokens


+Examples:+
Method:/auth/listTokens
Parameters: 
\{
 "user":
\{
"loginName":"login name",
"domain.id":domainid
\},
"token":
\{
"product.method":"GridCard"
\},
\\
"return":\["id", "serial"\]
\}
Response: 
\{
 "error":0,
 "result":
\{
 "total":2,
 "rows":
\[
 \{"id":1, "serial":"77003456"\},
\{"id":2, "serial":"77003457"\}
\]
\}
\}
\\


/auth/changePassword

Examples:
Method:/auth/changePassword
Parameters:
{
"user":
{
"loginName":"login name",
"domain.id":domainid
},
"oldPassword":"old",
"newPassword":"new"
}
Response:
{
"error":0
}

/auth/verifyPin

Examples:
Method:/auth/verifyPin

  1. verify password

Parameters:
{
"user":
{
"loginName":"login name",
"domain.id":domainid
},
"pin":"password"
}
Response:
{
"error":0
}

  1. verify pin

Parameters:
{
"user":
{
"loginName":"login name",
"domain.id":domainid
},
"token":
{
"serial":"1213131"
}
"pin":"pin"
}
Response:
{
"error":0
}

  1. verify pin

Parameters:
{
"user":
{
"loginName":"login name",
"domain.id":domainid
},
"tokenAssignment":
{
"id":"assignment id"
}
"pin":"pin"
}
Response:
{
"error":0
}