Complete the following steps to import a data file from an API and create a new table in
Connect.
- From the Home screen, select the
Add button under Tables.
- On the Dataset tab, enter a Name that identifies the table
and select a Folder to save the table.
- Under API, select Rest API.
- Under Connection, select the Rest API
connection that you previously set up. If you have not previously set up a
connection, select New Connection.
- Under Update Frequency, specify how often you want
Connect to update the table. You can import the data one time or have
Connect continuously import the data at a set time interval. Connect
automatically creates a flow for your import. If you select
Once, you can use the flow at a later time to
automatically run the import again.
- Under URL, enter the base request URL. You'll add parameters later.
- From Request Type, select either a HTTP GET request or a HTTP POST request.
- In Maximum Array Depth, select the maximum depth in which Connect
converts JSON data nodes into table columns. The JSON string data becomes
the cell value result when Connect reaches the maximum depth.
- Select Next.
- In Request Header Parameters and Request Body Parameters
, enter the request parameters that you want to send.
- No fields are available initially. Select Add Parameter to add key
pairs to the request URL parameters.
- In Array Key for Records (Root Path), enter the comma
separated path to the node.
- Select Save
. If you go to the
Prep Tool and select Run
, Minitab Connect
displays the imported data.
Note
If no data appears
after you select Run, select Reset Config
.
When you save the import, Connect creates a flow with the settings that you selected. For more
information on how to schedule a flow and add more data processes to clean data, go
to Overview of the Flow Tool
.
JSON Flattening Logic
Connect flattens the JSON results to properly represent them as a table. Flattening means to
put the JSON into a single hierarchy structure so that there are no child or
parent objects. Columns can then be represented since everything is a key-value
pair. Nested objects are displayed by a dot operator in the column name.