Whenever you request a report, such as a
Papdis File we will examine the accept header to determine how to respond.
The accept headers that are supported can vary from report to report, but they're listed on the relevant page of the API documentation.
type property of the
ReportResponse will contain the accept header you provided. There are two other properties,
content. Which one contains your response depends on the accept header you provided.
contentproperty will provide a link to a PDF file.
modelproperty contains a JSON representation of the relevant model.
contentcontains a JSON encoded HTML string representing your HTML document. In some cases, such as Payslips there are multiple HTML documents to be returned. In these cases the
contentproperty will be blank and the
modelproperty will contain an array of JSON encoded HTML strings.