API Connector
info
- The API Connector only supports RESTful APIs, and the API response must be in JSON format (a JSON object or JSON array).
- The API Connector is suited to low-volume RESTful APIs; we recommend that a single JSON response not exceed 10MB.
Step 1: Create a data source
There are two ways to create a data source: click the "+" button next to Data Source in the sidebar, or click the Create a Data Source button on the Overview page.
Step 2: Configure the connection
In the dialog form, fill in the connection information and click Submit. The connection fields are described below.
Basic
- Name: The display name of the data source in Canner Enterprise. You can change it later.
- Data Source Type: The data source type. Select
API.
Data Source Properties
- Base URL: The base path of the API you want to connect to, e.g.
https://a.b.c/path/. - Headers: The API request headers.
info
Up to 10 headers can be added.
- Ignore Invalid SSL certificate (off by default): Turn this on to skip SSL certificate validation when connecting.
- Explore Timeout: The timeout for connecting to and parsing the data source. If this takes longer than the timeout, the system stops and shows a connection error. The default timeout is
5000 ms. If the source has many tables, consider increasing this timeout. - Request Timeout: The timeout for waiting for the API to respond. If the API takes longer than this to respond, the system stops and shows a connection error. The default timeout is
30000 ms. If the API you are connecting to responds slowly, consider increasing this timeout.
API Endpoints
You can add multiple API endpoints under the same Base URL. Each API endpoint creates one table on the Tables tab of the Data Source page.
info
Up to 10 API endpoints can be added.
- URL Path: The path of the API endpoint to connect to
GET / POST: The API request method;GETandPOSTare supported.
warning
The URL Path must contain only valid HTTP characters. Any invalid characters must be escaped.
- Table Name: The display name of this table in Canner Enterprise. You can change it later.
- Column Schema: Define the column structure of the data returned by this API endpoint.
Column Name: The column name.Type: The column's data type;double,varchar,boolean, andbigintare supported.
Step 3: Finish
After you submit, you are returned to the list page shortly, and the API you just configured appears in the data source list.
