> For the complete documentation index, see [llms.txt](https://docs.flowretail.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.flowretail.com/docs/developers/api-documentation/reports/accounting-report-file-for-stores.md).

# Accounting report file for stores

Get an accounting report for a store UID and a time period. Depending on the header you set, the response is either a json containing a base 64 encoded pdf or a direct download. The file is base64 encoded. You can set choose among the supported file types, default is PDF.

Required permissions: REPORTING

```json
{"openapi":"3.0.2","info":{"title":"Flow Retail API version 2","version":"2.0.0"},"tags":[{"name":"Reports","description":"Reports"}],"servers":[{"description":"Flow Retail Production","url":"https://api.flowretail.com/v2"},{"description":"Flow Retail Stage","url":"https://api.stage.flowretail.com/v2"}],"security":[{"accessToken":[]},{"authToken":[]},{"integrationToken":[]}],"components":{"securitySchemes":{"accessToken":{"description":"Access token recevied after user login with a deviceToken","scheme":"bearer","type":"http"},"authToken":{"description":"Token received from the auth service","scheme":"bearer","type":"http"},"integrationToken":{"scheme":"bearer","type":"http"}},"requestBodies":{"AccountingFileRequest":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountingFileRequestSchema"}}}}},"schemas":{"AccountingFileRequestSchema":{"title":"AccountingFileRequestSchema","allOf":[{"$ref":"#/components/schemas/AccountingRequestSchema"},{"type":"object","properties":{"reportFormat":{"$ref":"#/components/schemas/ReportFormatENUM"}}}]},"AccountingRequestSchema":{"title":"AccountingRequestSchema","type":"object","properties":{"fromDate":{"format":"date","minLength":10,"type":"string"},"toDate":{"format":"date","minLength":10,"type":"string"},"organizationUid":{"$ref":"#/components/schemas/OptionalUID"},"storeUids":{"type":"array","description":"List of storeUids to include in report.","items":{"$ref":"#/components/schemas/UID"}}},"required":["fromDate","toDate","organizationUid"]},"OptionalUID":{"title":"OptionalUID","type":"string","pattern":"^[A-Za-z0-9-_]*"},"UID":{"title":"UID","type":"string","pattern":"^[A-Za-z0-9-_]+"},"ReportFormatENUM":{"title":"ReportFormatENUM","type":"string","enum":["PDF","VISMANET","VISMABUSINESS","UNI","24SEVEN","XLEDGER","NAVISION"],"description":"Supported report formats"},"Base64EncodedFileContentSchema":{"title":"Base64EncodedFileContentSchema","type":"object","properties":{"content":{"type":"string","description":" base64 encoded"},"contentType":{"description":"mime type","type":"string"},"filename":{"type":"string"}},"required":["content","contentType","filename"]}},"responses":{"FileResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Base64EncodedFileContentSchema"}},"application/pdf":{"schema":{"format":"binary","type":"string"}},"text/html":{"schema":{"type":"string"}},"application/octet-stream":{"schema":{"type":"string","format":"binary"}}},"description":"Based on the Accept header the response will be base64 json encoded or a raw file.\napplication/octet-stream will return a binary file\napplication/json will return a json with the file content base64 encoded."}}},"paths":{"/tenants/{tenantUid}/reports/accounting/download":{"post":{"description":"Get an accounting report for a store UID and a time period.\nDepending on the header you set, the response is either a json containing a base 64 encoded pdf or a direct download. The file is base64 encoded. You can set choose among the supported file types, default is PDF.\n\nRequired permissions: REPORTING","operationId":"post-tenants-reports-accounting-download","parameters":[],"requestBody":{"$ref":"#/components/requestBodies/AccountingFileRequest"},"responses":{"200":{"$ref":"#/components/responses/FileResponse"}},"summary":"Accounting report file for stores","tags":["Reports"]}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.flowretail.com/docs/developers/api-documentation/reports/accounting-report-file-for-stores.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
