Access the Generated Reports

Using the access token, get a generated report in PDF format via the Reporting API.

1. Creating the Request

Create a new request in Postman as follows:

  1. Set the HTTP verb to GET.
  2. Click on the Authorization tab and set the access token as the Bearer Token.
  3. Specify the URL to the report/{jobId}/reports/{guid} API endpoint, where the jobId and guid are passed in the URL of the request. For example, https://fslpresales.fslcgix-uat.co.uk/FSLPresales_WebAPI/api/report/12780/reports/4ff73e73-8cd1-4ace-96f5-70e44127ff2e, where jobId = "12780" and guid = "4ff73e73-8cd1-4ace-96f5-70e44127ff2e".
  4. Click on the Body tab and then the none option.

2. Sending the Request

Click the Send button to send the prepared request.

3. The Response Body

The response streams the generated report in PDF file format.

Response received in Postman

Response received in Postman

📘

File Location

The generated reports are stored in the folder specified by the TempReportFolder setting in the CGiX Web API configuration file (appsettings.json).

"HangfireSettings": {
    "QueueName": "cgix",
    "CalcQueueName": "calc",
    "TempReportFolder": "C:\\CGiX\\TempReportFolder",
    "CalcFolder": "C:\\CGiX\\WhatifCalculationTests"
},

The file naming convention for generated report files is Report_{GUID}.pdf. For example, "Report_4ff73e73-8cd1-4ace-96f5-70e44127ff2e.pdf".