Download statements in PDF

Download Statements in PDF

The GET /api/Statement/V2/pdf endpoint returns the account statement for a specified financial account and billing period as a downloadable PDF file. The response includes the file name, Base64-encoded content, and MIME content type so the caller can save or stream the PDF directly. Authentication is required to protect sensitive financial data.

Endpoint

GET /api/Statement/V2/pdf

Authentication

Bearer token required. Obtain via:

POST https://api.banking.netevia.dev/api/auth/v2

Include in header: Authorization: Bearer {token}
Token lifetime: 10 minutes. Refresh via POST /api/auth/refresh.

When to use

Use this endpoint when a customer needs to download a formatted account statement for a specific billing period — for example, to submit proof of account activity, for bookkeeping, or for regulatory compliance. It is suitable for both business and personal customers who need a structured PDF record of their transaction history.

Query Parameters

ParameterTypeRequiredDescription
financialAccountIdstringNoThe unique identifier of the financial account whose statement should be retrieved.
periodstring (date-time)NoThe statement period to retrieve, in ISO 8601 date-time format (e.g., 2024-01-01T00:00:00Z). When omitted, the most recent available statement is returned.

Response

200 OK

FieldTypeDescription
namestring (nullable)The file name of the generated PDF (e.g., statement_2024-01.pdf).
contentstring (nullable)The Base64-encoded binary content of the PDF file. Decode this value to obtain the raw PDF bytes.
contentTypestring (nullable)The MIME type of the file. Typically application/pdf.
{
  "name": "statement_2024-01.pdf",
  "content": "JVBERi0xLjQKJcOkw7zDtsOfCjIgMCBvYmoK...",
  "contentType": "application/pdf"
}

Error Codes

CodeWhen it happens
400financialAccountId or period is provided in an invalid format.
401Token missing, expired, or invalid.
403The authenticated user does not have access to the requested financial account.
404No statement found for the specified account and period.
500Internal server error.

Common Mistakes

  • Passing period as a plain date string (e.g., 2024-01) instead of a full ISO 8601 date-time string (e.g., 2024-01-01T00:00:00Z) will result in a 400 error.
  • Forgetting to Base64-decode the content field before writing it to disk will produce a corrupt PDF file.
  • Using a financialAccountId that belongs to a different customer or partner will return a 403 response. Always use an ID associated with the authenticated user's account.
  • The content field can be large for accounts with many transactions; ensure your HTTP client and file-handling logic support large response payloads.

Related Endpoints

  • GET /api/Statement/V2 — Retrieve account statement data in JSON format instead of PDF.
  • GET /api/FinancialAccount — List financial accounts and obtain valid financialAccountId values.

Example

curl -X GET "https://api.banking.netevia.dev/api/Statement/V2/pdf?financialAccountId=fa_XXXXXXXXXX&period=2024-01-01T00%3A00%3A00Z" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Accept: application/json"
Query Params
string
date-time
string
Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Response

Language
Credentials
Bearer
JWT
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
text/plain
application/json
text/json