View data sources

Now that you have imported the schema file, let's take a look at the data sources that are now available for your project, as shown in the example below.

Available data sources

Viewing data source settings

The settings for every data source can be viewed and edited. In fact, in most cases you need to set parameter values, enable authentication or any number of other settings. However, for this tutorial we don't need to make any changes but let's see how it's done anyway, as shown in the example below.

Step

Description

1

From the Home menu, click Data Sources. This displays the list of data sources you imported in the previous step.

2

Select a data source from the list of available data sources, for example findEnginebyId. This opens the Edit Data Source pane displaying the current settings for the selected data source.

3

We won't make any changes so let's now preview the data source.

Normally, the HTTP method or address should not be changed. The name can be changed as required. Path parameters require data sample values. (See Data source settings).

Preview data source

Next to the Edit Data Source pane is the Preview pane. This pane provides a preview of a response of a request to the data source.

So, go ahead and click Preview Data Source. Xapix sends a GET request to the provided address. The response is shown in the Preview area.

Preview data source

The following shows the output from a call to this data source based on the default settings of the findEngineById.

Some values were redacted for privacy and security reasons.

{
"status": 200,
"body": {
"power_hp": 180,
"fuel_type": "Diesel",
"manufacturer": "Remedy Engines",
"price": 4800
},
"cookies": {},
"header": {
"server": "server",
"content-type": "application/json",
"content-length": "103",
"connection": "close",
"accept-ranges": "bytes",
"e-tag": "\"tag\"",
"x-amz-request-id": "236F8561DDB31AC6",
"date": "Fri, 22 Nov 2019 15:12:12 GMT",
"last-modified": "Mon, 11 Feb 2019 14:54:45 GMT",
"x-amz-id-2": "key"
}
}

With the data sources onboarded (imported), we are now ready to create an endpoint.

Next step
Next step

Continue with Create an endpoint.