GenerateAuthToken - Obtain Authentication Token

Obtain an authentication Token for subsequent API calls using an application secret key (appSecretKey).

Interface Description

Before calling any business interface in Open Text2Insight, you must first use this interface to obtain a login Token. This Token serves as the identity credential for all subsequent requests.

Usage Notes

  • The appSecretKey is generated and distributed by the platform administrator in the backend.
  • The Token has an expiration time; you must obtain a new one after it expires.
  • Keep your appSecretKey secure to prevent leakage.

Request Method

GET /open/api/v1/appSecretKey/generateAuthToken

Request Parameters

ParameterLocationTypeRequiredDescription
appSecretKeyQueryStringYesApplication secret key, assigned by the administrator

Response Parameters

ParameterTypeDescription
successBooleanWhether the request was successful
data.tokenStringAuthentication Token, used for subsequent interface calls

Request Example

GET /open/api/v1/appSecretKey/generateAuthToken?appSecretKey=your_secret_key_here

Response Example

Successful response:

{ "success": true, "data": { "token": "eyJhbGciOiJIUzI1NiJ9..." } }

Error Codes

Error CodeDescription
success=falseappSecretKey is invalid or has expired