Authentication

You'll need your client id, secret to get an access token which you can use to access all of our other API endpoints. Your organisation should have received these information by email or slack during initial setup, if not please get in touch via mailto:[email protected].

post

IDaaS authentication support under client_credentials and authorization_code, about where to find your client credentials, you'd better contact Hanchu for more details.

Required scopes
This endpoint requires the following scopes:
  • : all privileges
  • : all privileges
Authorizations
OAuth2clientCredentialsRequired
Token URL:

OAuth2authorizationCodeRequired
Authorization URL: Token URL:
Body
client_idstringRequired

Application id

Example: x6A****480
client_secretstringRequired

Application secret

Example: 746b14f042104******52ec801e561a9
grant_typestringRequired

Grant type

Example: client_credentials
refresh_tokenstringOptional

Refresh token when expired (Needed when refresh)

Example: VvnUrJoqeWQFg******wH-OBpDbb3hXr6p7W
Responses
200

Authentication was successful

application/json
post
/oauth/token
POST /portal/oauth/token HTTP/1.1
Host: idaas-sandbox.hanchuess.com
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/x-www-form-urlencoded
Accept: */*
Content-Length: 166

"client_id='x6A****480'&client_secret='746b14f042104******52ec801e561a9'&grant_type='client_credentials'&refresh_token='VvnUrJoqeWQFg******wH-OBpDbb3hXr6p7W'"
{
  "access_token": "eyJhbGciOiJIUz******InR5cCI6IkpXVCJ9",
  "token_type": "bearer",
  "expires_in": 3599,
  "refresh_token": "text"
}

Last updated