INTEGRATION

Getting Started

REPORTS

Report Scheduling

INTEGRATION

Report scheduling

The Report Scheduling API allows users to automate the generation of reports on the Silverflow platform. The API offers the following functionality:

  • Report name: The report name that the schedule is being created for. Currently we support report scheduling for the following reports:

    • schemeFeeDetails

  • Scheduling intervals: The endpoint allows users to schedule Daily or Hourly reports. If it’s a Daily schedule, one can choose the time of report creation through the hour parameter. Note that this is not the time when the report is completed.

  • Report formats: Depending on the report type, Silverflow may support different file formats through the mimeType parameter.

  • Reference: Allows users to specify an internal reference for the generated report.

Endpoints

  • Create a Report Schedule: create a new schedule using the reportName, trigger (timing and interval), and mimeType. One could optionally also include an internal reference.

  • List Report Schedules: List all report schedules currently active.

  • Get a Report Schedule: Get a specific report schedule using its report schedule key.

  • Delete a Report Schedule: Archive a specific report schedule using its report schedule key.

Usage

Create report schedule request

A user can create a new report schedule using the POST /v1/reportSchedules endpoint using the parameters mentioned above. For example, the following request will create a SchemeFeeDetails report on an hourly basis by setting the following parameters. Note that the report will be build in JSON format because of its mimeType. Please find the API reference for additional details.

Create report schedule response

After a new report schedule is created, new report entities will be created following the type and cadence interval. To confirm the successfull scheduling of the report, the user will receive a 200 response. In the response, you will find the status as active and the key which can be used to retrieve the report:

Retrieve report schedules

In order to retrieve the report schedule object(s), the user may call GET /v1/reportSchedules to list all report schedules or GET /v1/reportSchedules/{reportScheduleKey} using the key of the report schedule. Using the key in the previous response we can retrieve the report.

Archive report schedules

Lastly, to archive a report schedule, the user may call DELETE /v1/reportSchedules/{reportScheduleKey} which will change its status to archived.

Retrieve individual report files

Once a new report entity is created by the report schedule object, individual reports will be created as long as the status of the report schedule object is active. Going forward, the user can retrieve individual reports by calling the List Reports or Get Report endpoint. The following endpoints are available to retrieve report objects and content:

  • Get an individual report: GET v1/reports/{reportKey}

  • List all reports: GET v1/reports

To then retrieve the report file, or content, the user should call the following endpoint

  • GET v1/reports/{reportKey}/file

Note that it could happen that the report is not yet completed. In order to stay updated on when reports are completed to be retrieved, one should subscribe to the event subscription, described below.

Event subscriptions

After creating schedules for reports, the user can subscribe to the reports events POST /v1/eventSubscriptions, to be notified of the status changes on these reports. The event source for the reports events is https://silverflow.com/reports.