How to Export Wyn Reports by Using API

Background: 


This article explains how to export Wyn Reports by using export templates.

In Wyn Enterprise it is possible to export a report in different file formats. Depending on your needs, you can choose between format-preserving export formats such as PDF, Excel, Word, and Images, which are suitable as a backup or digital archive of report runs or for display or analysis in other applications. Alternatively, you can choose data-only export types such as CSV (compressed), CSV Raw (uncompressed), Excel Data (report data in an Excel workbook), JSON, Text, and XML, which export the report data without the formatting for further analysis or to be imported into other systems.

The API endpoint that allows for exporting the reports is /api/v2/reporting/reports/{reportId}/export/{exportSettingsTemplateId}

Request Details:

PropertyValue
Route{server}/api/v2/reporting/reports/{reportId}/export/{exportSettingsTemplateId}
MethodPOST

Request Parameters:

NameTypeLocated InDescription
reportIdRequiredstringpathReport id. For example: 3a44d8c0-9b3c-4ecf-a934-df08ba87b73e
exportSettingsTemplateIdRequiredstringpathExport template id. For example: eb6d614f-e595-4de6-8c51-c54c6b07c295
downloadBooleanqueryIndicates whether the result should be returned as a downloadable file.

To export a report, the Report ID and the Export Settings Template ID are required.
The endpoint to retrieve the Reporting Export Template IDs is /api/v2/reporting/export-templates

  curl --location 'http://localhost:51980/api/v2/reporting/export-templates' \
  --header 'Reference-Token: "YourToken"'

Request Body Schema:

FieldTypeNullableDefaultExampleExplanation
notificationSettingsObjectYesNotification settings model used to configure export result notifications.
notificationSettings.channelNotificationChannel (enum)YesAPISpecifies the notification delivery channel (for example API).
notificationSettings.onSuccessstring[]Yes[“contact1”]List of contact names that will receive a notification when the export operation completes successfully.
notificationSettings.onFailurestring[]Yes[“contact1”]List of contact names that will receive a notification when the export operation fails.
settingsDictionary<string,string>Yes{ “Title”: “Overridden title” }Rendering extension settings. Allows overriding specific export rendering options such as title or format-specific settings. Each key-value pair represents a rendering option.
overrideExportTemplateSettingsbooleanNofalsefalseIndicates whether to override the settings defined in the export template.
interactiveActionsstring[]Yes[“rpt1/TextBox10/4/toggle”]List of interactive actions (such as toggle operations) to apply before exporting the report. Typically used for expanding/collapsing sections or drill-down states.
skipEmptyReportbooleanNofalsefalseDetermines whether rendering should be skipped if the report contains no data. When true, empty reports will not be generated.
parametersDictionary<string, object[]>Yes{ “StringParameter”: [“StringValue”], “Integer”: [1] }Specifies report parameter values. Each key is a report parameter name, and its value is an array of values for that parameter.
cacheRefreshIsRequiredbooleanNofalsefalseDetermines whether the report cache should be refreshed before export. When set to true, the system refreshes the cached report prior to exporting.
timeZoneIdstringYesAsia/TokyoIANA time zone ID used during report export.

Here is a cURL example of exporting a report to PDF where a multi-value parameter has been applied

curl --location 'http://localhost:51980/api/v2/reporting/reports/14d08c5a-e5fb-45d3-adc6-4c1df0531b1d/export/b2f52743-2513-41e3-9cf9-6edf481a1a5d?download=true' \
--header 'Reference-Token: YourTokenHere' \
--header 'Content-Type: application/json' \
--data '{
  "settings": {
    "IsPaginated": false
  },
  "skipEmptyReport": false,
  "overrideExportTemplateSettings": true,
  "parameters": {
    "CarMake": [
      "Toyota",
      "Volvo",
    ]
  },
  "cacheRefreshIsRequired": false,
  "timeZoneId": "Asia/Tokyo"
}'

The CarMaker parameter has been applied to filter the table in the report; therefore, only the sales data for Toyota and Volvo is displayed.

In the request body, the "IsPaginated" setting is set to false.

  "settings": {
    "IsPaginated": false
  },  

As a result, the default IsPaginated setting from the export template is overridden, and the exported PDF file is not paginated.

Enea Gega

Enea Gega

Enea is a Technical Product Enablement Specialist for the Wyn Enterprise Platform. He acts as a vital bridge between customers, product teams, and engineering to ensure that every new feature delivers genuine value and drives user adoption.

Enea specializes in translating complex customer needs into actionable insights for product roadmaps and technical documentation. By partnering cross-functionally, he ensures seamless delivery readiness and alignment across all releases.