On-Premise EDS Inflow REST API
Starting with 2022 March release of MC2 a new Inflow REST API is exposed to ingest/load data using EDS Service.
The Inflow REST API definition can be accessed at https://webserver/mc2/swagger-ui.html, then selecting the Inflow from the dropdown:
Currently the Inflow REST API supports only one POST operation at:
https://webserver/eagle/v2/inflow
This POST operation allows loading data files as a multipart/form-data attachment with a set of control parameters.
To test the API in Swagger UI you can use the POST Operation:
The following HTTP headers are supported for executing the requests:
x-eagle-correlation-id - this header can be specified to define the correlation id this request will be tracked by. If not specified a unique correlation id will be generated.
x-eagle-business-task-id - this header can be used to specify the business task id. If not specified the generated correlation id will be used.
x-eagle-return-ticket - if this header is set to Y MC2 will return an acknowledgement and will process the request asynchronously in background
The instructions has to contain a JSON object defining how the file should be processed. The type, header and taskIdentifier are optional.
Most of the parameters are optional, except ResourceName. The parameters will be mapped to Run Task Request parameters passed to EDS (pyruleservice). The parameters, including ResourceName can be specified at the top level.
A simple request can be:
{
"ResourceName": "codevalue"
}
or
{
"parameters": {
"ResourceName": "codevalue"
}
}
The above instructions are equivalent.
The file defines a file attachment to be loaded in EDS. You can press Choose File in Swagger UI to select a file to be loaded. Currently EagleML, CSV and EagleJSON are supported out of the box. Additional resource definitions can be used to load other data formats.