Registering OpenAPI Data Source¶
To integrate data through OpenAPI, you need to first configure the data source information and establish a connection to the target API service.
Prerequisites¶
Before you begin, ensure the following:
Your account has been granted the required asset permissions, operation permissions, and menu group access. If not assigned, contact OU administrator.
You have obtained the detailed connection configuration of the data source, including the server IP address, port number, database name, access credentials, password, etc.
Procedure¶
Log in to the EnOS Application Portal, and select Data > Data Source Registration from the left navigation bar.
Click Add Data Source.
On the Add Data Source page, complete the following configurations:
Basic Information:
Data Source Type (Required): Select OPENAPI.
Data Source Name (Required): Enter a name for the data source. The maximum length is 50 characters, and the name can consist of:
Letters
numbers
_
(underscore)-
(hyphen)
Data Source Description: Enter a description for the data source. The maximum length is 100 characters and supports internationalization (default, Chinese, English).
Under Configuration Information > API Request, configure API request parameters:
Service Host (Required): Enter the API service address, e.g.,
https://{apigw-address}
Method (Required): Select request method (GET or POST)
Request Path (Required): Enter API endpoint path, e.g.,
/model-service/v2.1/thing-models?action=get
Request Parameters: Click Add Parameter to configure API request parameters
Under Configuration Information > API Response, configure API response parameters:
Content Type (Required): Currently supports
application/json;charset=utf-8
Success Code (Required): Enter the response code for successful request
Dataset Type (Required): Select the dataset type (object or object array)
Dataset (Required): Enter the dataset
Select API authentication type (None or Basic Token Authentication). For Basic Token Authentication, configure the token service, token parameter and token refresh interval accordingly.
Under Configuration Information > Pagination:
Type: Select pagination method (None, Offset/Limit, or PageSize/PageNo)
Under Configuration Information > Getting Data:
Delta Time Parameter: Select a delta time parameter for getting data.
Outcome¶
Once the data source is successfully registered, it will appear in the Data Source Registration list. Users can view basic information about all data sources within the OU, but only the creator can modify or delete their registered data sources. For more details, see Managing Data Source.