Loader Connection Datasources¶
/api/repositories/{repository}/loaderconnections/{loaderconnection}/datasources
| Parameter | Type | Purpose |
|---|---|---|
| repository | string | the name of the Repository |
| loaderconnection | string | the ID of the loader connection |
Get¶
-
GET/api/repositories/(string: repository)/loaderconnections/(int: loaderconnection)/datasources¶ Lists the datasources of the Loader Connection
GET /api/repositories/jupiter/loaderconnections/1/datasources HTTP/1.1
Accept: application/json
| Response Code | Reason |
|---|---|
| 200 | No error |
| 500 | Server error |
The response will be a Standard Response, with a list of loader connections in the corresponding Repository.
The columns array will contain the list of columns for each data row.
| Human Name | Column Name | Description |
|---|---|---|
| Filename | Filename | Name of the datasource |
| Size | Size | Size of the datasource |
The size column is applicable only to flat-file loader connections.
The rows array will contain the list of datasources of the corresponding Loader Connection:
"rows": [
{
"dataRow": [
"sample.dat",
"12500"
]
}
If there are no datasources in the Loader Connection, rows will be an empty string.
Post¶
-
POST/api/repositories/(string: repository)/loaderconnections/(int: loaderconnection)/datasources¶ Get the list of datasources in a Loader Connection which matches the criteria passed in the post body
POST /api/repositories/jupiter/loaderconnections/1/datasources HTTP/1.1
Content-Type: application/json
{
"command": "get",
"data": {
"filter": "d*",
"username": "uname",
"password": "passwd"
}
}
| Response Code | Reason |
|---|---|
| 204 | No error |
| 400 | Invalid data passed with request |
| 500 | Server error |
The request packet must contain the command and data elements. The options element is not required.
The response will be as described for all datasources.
Show Data Schemas¶
-
GET/api/repositories/(string: repository)/loaderconnections/(int: loaderconnection)/dataschemas¶ Lists the datasources of the Loader Connection where username and password is not required
GET /api/repositories/jupiter/loaderconnections/1/dataschemas HTTP/1.1
Accept: application/json
| Response Code | Reason |
|---|---|
| 200 | No error |
| 500 | Server error |
-
POST/api/repositories/(string: repository)/loaderconnections/(int: loaderconnection)/dataschemas¶ Get the list of dataschemas in a Loader Connection which requires username and password
POST /api/repositories/jupiter/loaderconnections/1/dataschemas HTTP/1.1
Content-Type: application/json
{
"command": "get",
"data": {
"username": "uname",
"password": "passwd"
}
}
| Response Code | Reason |
|---|---|
| 204 | No error |
| 400 | Invalid data passed with request |
| 500 | Server error |
The request packet must contain the command and data elements. The options element is not required.
The response for get and post will be a Standard Response, with a list of dataschemas in the corresponding Loader Connection.
The columns array will contain the list of columns for each data row.
| Human Name | Column Name | Description |
|---|---|---|
| Filename | Filename | Name of the datasource |
| Size | Size | Size of the datasource |
The size column is applicable only to flat-file loader connections.
The rows array will contain the list of dataschemas of the corresponding Loader Connection:
"rows": [
{
"dataRow": [
"e3.ddx",
"12738"
]
}
If there are no dataschemas in the Loader Connection, rows will be an empty string.
Show Schema Preview¶
-
POST/api/repositories/(string: repository)/loaderconnections/(int: loaderconnection)/dataschemas¶ Get the preview of dataschemafile
POST /api/repositories/jupiter/loaderconnections/1/dataschemas HTTP/1.1
Content-Type: application/json
{
"command": "preview",
"data": {
"username": "uname",
"password": "passwd",
"filename":"filename"
}
}
filename is the mandatory parameter
| Response Code | Reason |
|---|---|
| 204 | No error |
| 400 | Invalid data passed with request |
| 500 | Server error |
The request packet must contain the command and data elements. The options element is not required.
The response will be the preview of the schema file