v1

latestOpenAPI 3.0.0UNLICENSED2026-07-26178479713.7 KB
reports

api_reports_generation_post

Using this endpoint with the query parameter save set to true, will result in an 201 response, otherwise, the response will be 200.

Generate PDF report for transaction:

First, fetch the transaction from Get transaction.

Store the transaction in the transaction variable and send this payload:

[
  {
    "key": "transaction",
    "path": "/checkout/v1/transactions/{transaction.id}",
    "data": transaction
  }
]

with these query parameters set:

  • template_id=checkout_transaction_order
  • template_data_path=/checkout/v1/transactions/{transaction.id}
  • template_accept=application/pdf
  • template_accept_language=en

scopes:

  • admin:reports
  • write:reports
  • read:reports
post/accounts/{aid}/reports/generation

Path parameters

aidstring ^[PT]{1}\d{8}$ required

An id that uniquely identifies the account.

Query parameters

template_idstring required

The template to generate report from

example:

  • checkout_transaction_order
template_data_pathstring required

Path to the data for the report

examples:

  • /checkout/v1/transactions/{transaction.id}
template_acceptstring required

The Content-Type for the report

examples:

  • application/pdf
template_accept_languagestring required

The Content-Language for the report

examples:

  • no
  • en
template_accept_timezonestring iana-timezone

The timezone for the report List of timezones: https://en.wikipedia.org/wiki/List_of_tz_database_time_zones Defaults to Europe/Oslo

examples:

  • Europe/Stockholm
  • Europe/London
  • Europe/Helsinki
data_fromstring date-time

The start of the data interval

data_tostring date-time

The end of the data interval

schedule'monthly' | 'weekly' | 'daily' | 'custom' | 'none'

Schedule for the report

saveboolean

Whether to save the generated report in s3 or not, if set to true returns 201

Request body

keystring required
pathstring required
dataobject required

Response

Report file

string required