Skip to main content
Version: 🚧 Next

Upload a report to a file server

Business goal​

This action allows a generated report to be saved on a file server. The generated report will be saved in CSV format.

UploadReportToFileServerV2​

Configuration​

  • Add the action UploadReportToFileServerV2.
  • Link this action to an appropriate event, typically REPORT_GENERATED.

Settings​

The filename setting names the uploaded file. Because it is required, the report's own csvFilename is not used unless you ask for it through ${documentName}. It supports the following contextual placeholders:

  • ${financialSpName} for the name of the financial service provider of the report.
  • ${identifier} for the identifier of the report.
  • ${timestamp} for the time of upload (UTC in format yyyyMMddHHmmss), or ${timestamp:<pattern>} for that same moment in any DateTimeFormatter pattern. An invalid pattern is rejected when the configuration is saved.
  • ${documentName} for the stored document's name, without its extension. The template still needs to carry the extension. Use ${documentName}.csv to upload the report under the name it was generated with.

A rendered placeholder is reduced to letters, digits, underscores and hyphens, so it can never move the upload out of the configured directory. A report execution without a stored document, or a template that renders to nothing, fails the action instead of uploading a nameless file.

Upload only some reports​

REPORT_GENERATED fires for every report generated in the FSP, scheduled or generated from the UI. Without reportIdentifiers, the action uploads all of them. Set reportIdentifiers to the reports that belong on this file server, and every other report is skipped. A skipped report is not a failure. An identifier that does not match an existing report is rejected when the configuration is saved.

Settings Configuration

Examples

Example​

{
"type": "EVENT",
"value": "REPORT_GENERATED",
"className": "eu.myharmoney.app.bll.executors.dossierstatustransition.UploadReportToFileServerV2",
"synchronous": false,
"enabled": true,
"settings": {
"providerIdentifier": "FILE_TRANSFER - Generated Reports",
"filename": "$vault{PROVIDER_FILE_TRANSFER_GENERATED_REPORTS_settings_FILENAME}"
}
}

Example: upload only two reports​

{
"type": "EVENT",
"value": "REPORT_GENERATED",
"className": "eu.myharmoney.app.bll.executors.dossierstatustransition.UploadReportToFileServerV2",
"synchronous": false,
"enabled": true,
"settings": {
"providerIdentifier": "FILE_TRANSFER - Retention Reports",
"filename": "${identifier}_${timestamp:yyyyMMdd}.csv",
"reportIdentifiers": ["Party Retention", "Dossier Retention"]
}
}