Rate This Document
Findability
Accuracy
Completeness
Readability

Request Format Description

client_id and client_secret are system identifiers. They are parameters to be configured by the integration party during the DevKit installation and stored in the DevKit configuration file. If an error occurs when the file is being read, run the sso_register.sh script in the tools directory in the DevKit installation directory for reconfiguration.

Request Mode

POST(HTTPS)

Resource URL

https://Domain_name_of_the_authentication_interface/sso/oauth2/getToken

Request Header

Content-Type: application/json

Request Parameter

1
2
3
4
5
6
7
{
  "client_id": "20221017000000001",
  "grant_type": "authorization_code",
  "client_secret": "****************************", 
  "authorization_code": "***************",
  "redirect_uri": "https://User_domain_name:Port_number/#/"
}
Table 1 Request parameters

Parameter

Name

Type

Description

client_id

Application ID

String

Registration ID of the client application (The input parameter is stored in the server configuration file during the DevKit installation.).

grant_type

Authentication type

String

Request type. Only authorization_code is supported.

client_secret

Application secret

String

Client application secret (The input parameter is stored in the server during the DevKit installation.).

authorization_code

Authorization code

String

Authorization code obtained by calling the authorize interface.

redirect_uri

Redirection address

String

The redirection address is the DevKit login address, which is the same as the redirection address described in the previous section.

Request Example

curl -X POST 
 https://Domain_name_of_the_authentication_interface/sso/oauth2/getToken
  -H 'Content-Type: application/json' 
  -d '{
  "client_id": "20221017000000001",
  "grant_type": "authorization_code",
  "client_secret": "****************************", 
  "authorization_code": "***************",
  "redirect_uri": "https://User_domain_name:Port_number/#/ "
}'