๐Ÿ“ˆDaily sales reports

This page provides a description of the available API routes for managing daily sales reports.

The fiscal device sends record closure information after each closed ticket or cash transfer. If a daily sales report record does not already exist (identified by fiscal name, fiscal memory serial number, and daily sales report number), it is automatically created by API.

Each ticket is associated with a specific daily sales report, and this information is stored in the ticket's closeInfo property.

Daily sales report record is modified by API after following actions are performed on fiscal device:

  • cash transfer: new element is added to cash transfers collection

  • daily sales report closure: fiscal info model is fulfilled and daily sales report is considered as closed.

Daily sales report is closed, when it's state property is set to closed or manuallyClosed. Closed daily sales reports cannot be modified.

Daily sales report is represented by DailySalesReport class.

API methods

Get daily sales reports

GET http://{server-address}/dailysalesreports

Returns all daily sales reports that matches query parameters. Result is of type QueryResult<DailySalesReport>.

Query Parameters

NameTypeDescription

isClosed

bool

Supports NData syntax.

$skip

int

Pagination property. Describing number of records to skip from beginning of result collection.

$take

int

Pagination property. Maximum count of items to be returned.

$sort

string[]

Comma separated list of property names. Please see NData syntax.

$count

bool

If set to true, response will not contain items collection. Use to get resource count, not the resources themselves.

id

bool

Supports NData syntax.

openDate

DateTime

currencyLabel

string

fiscalMemorySerialNumber

string

number

int

fiscalName

string

state

DailySalesReportStatus

closeDate

DateTime

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

{
    "items":
    [
        {
            "id": "646f5d625527869ae467b117",
            "fiscalName": "eKasa",
            "number": 2,
            "fiscalMemorySerialNumber": "1326585810",
            "openDate": "2023-06-28T08:06:40Z",
            "closeDate": null,
            "currencyLabel": "EUR",
            "cashTransfers":
            [],
            "fiscalInfo": null,
            "state": "Open",
            "_v": 1
        },
        {
            "id": "649ad7516413d6a4de6c8cb4",
            "fiscalName": "eKasa",
            "number": 1,
            "fiscalMemorySerialNumber": "1326585810",
            "openDate": "2023-06-27T08:04:25.605Z",
            "closeDate": "2023-06-27T22:42:13.662Z",
            "currencyLabel": "EUR",
            "cashTransfers":
            [],
            "fiscalInfo":
            {
                "ticketsCount": 7,
                "ticketsAmountIncludingVat":
                {
                    "amount": 80.65,
                    "currencyLabel": "EUR"
                },
                "invalidTicketsCount": 0,
                "invalidTicketsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "invoiceTicketsCount": 0,
                "invoiceTicketsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "positiveTicketItemsCount": 8,
                "positiveTicketItemsAmountIncludingVat":
                {
                    "amount": 80.65,
                    "currencyLabel": "EUR"
                },
                "returnedContainerTicketItemsCount": 0,
                "returnedContainerTicketItemsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "returnedTicketItemsCount": 0,
                "returnedTicketItemsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "correctionTicketItemsCount": 0,
                "correctionTicketItemsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "discountTicketItemsCount": 0,
                "discountTicketItemsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "advanceTicketItemsCount": 0,
                "advanceTicketItemsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "creditTicketItemsCount": 0,
                "creditTicketItemsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "voucherTicketItemsCount": 0,
                "voucherTicketItemsAmountIncludingVat":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "vatIncomes":
                [
                    {
                        "vatCategory": 1,
                        "vatRate": 20.0,
                        "totalAmount":
                        {
                            "amount": 9.45,
                            "currencyLabel": "EUR"
                        },
                        "vatAmount":
                        {
                            "amount": 1.58,
                            "currencyLabel": "EUR"
                        }
                    },
                    {
                        "vatCategory": 2,
                        "vatRate": 10.0,
                        "totalAmount":
                        {
                            "amount": 71.2,
                            "currencyLabel": "EUR"
                        },
                        "vatAmount":
                        {
                            "amount": 6.47,
                            "currencyLabel": "EUR"
                        }
                    },
                    {
                        "vatCategory": 3,
                        "vatRate": 0.0,
                        "totalAmount":
                        {
                            "amount": 0.0,
                            "currencyLabel": "EUR"
                        },
                        "vatAmount":
                        {
                            "amount": 0.0,
                            "currencyLabel": "EUR"
                        }
                    },
                    {
                        "vatCategory": 4,
                        "vatRate": 0.0,
                        "totalAmount":
                        {
                            "amount": 0.0,
                            "currencyLabel": "EUR"
                        },
                        "vatAmount":
                        {
                            "amount": 0.0,
                            "currencyLabel": "EUR"
                        }
                    },
                    {
                        "vatCategory": 5,
                        "vatRate": 0.0,
                        "totalAmount":
                        {
                            "amount": 0.0,
                            "currencyLabel": "EUR"
                        },
                        "vatAmount":
                        {
                            "amount": 0.0,
                            "currencyLabel": "EUR"
                        }
                    }
                ],
                "grandTotalAmountIncludingVat":
                {
                    "amount": 1619.31,
                    "currencyLabel": "EUR"
                },
                "roundingDown":
                {
                    "amount": -0.02,
                    "currencyLabel": "EUR"
                },
                "roundingUp":
                {
                    "amount": 0.02,
                    "currencyLabel": "EUR"
                }
            },
            "state": "Closed",
            "_v": 2
        }
    ],
    "count": 2,
    "totalCount": 2
}

Get daily sales report

GET http://{server-address}/dailysalesreports/{id}

Result is of type DailySalesReport.

Path Parameters

NameTypeDescription

id*

string

Unique identifier.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

{
    "id": "649ad7516413d6a4de6c8cb4",
    "fiscalName": "eKasa",
    "number": 1,
    "fiscalMemorySerialNumber": "1326585810",
    "openDate": "2023-06-27T08:04:25.605Z",
    "closeDate": "2023-06-27T22:42:13.662Z",
    "currencyLabel": "EUR",
    "cashTransfers":
    [],
    "fiscalInfo":
    {
        "ticketsCount": 7,
        "ticketsAmountIncludingVat":
        {
            "amount": 80.65,
            "currencyLabel": "EUR"
        },
        "invalidTicketsCount": 0,
        "invalidTicketsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "invoiceTicketsCount": 0,
        "invoiceTicketsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "positiveTicketItemsCount": 8,
        "positiveTicketItemsAmountIncludingVat":
        {
            "amount": 80.65,
            "currencyLabel": "EUR"
        },
        "returnedContainerTicketItemsCount": 0,
        "returnedContainerTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "returnedTicketItemsCount": 0,
        "returnedTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "correctionTicketItemsCount": 0,
        "correctionTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "discountTicketItemsCount": 0,
        "discountTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "advanceTicketItemsCount": 0,
        "advanceTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "creditTicketItemsCount": 0,
        "creditTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "voucherTicketItemsCount": 0,
        "voucherTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "vatIncomes":
        [
            {
                "vatCategory": 1,
                "vatRate": 20.0,
                "totalAmount":
                {
                    "amount": 9.45,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 1.58,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 2,
                "vatRate": 10.0,
                "totalAmount":
                {
                    "amount": 71.2,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 6.47,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 3,
                "vatRate": 0.0,
                "totalAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 4,
                "vatRate": 0.0,
                "totalAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 5,
                "vatRate": 0.0,
                "totalAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                }
            }
        ],
        "grandTotalAmountIncludingVat":
        {
            "amount": 1619.31,
            "currencyLabel": "EUR"
        },
        "roundingDown":
        {
            "amount": -0.02,
            "currencyLabel": "EUR"
        },
        "roundingUp":
        {
            "amount": 0.02,
            "currencyLabel": "EUR"
        }
    },
    "state": "Closed",
    "_v": 2
}

Create or update daily sales report

PUT http://{server-address}/dailysalesreports/{id}

Creates new or updates existing (non-closed) daily sales report. Result is of type DailySalesReport.

Required rights

Authorized user must have assigned DsrCreate or DsrUpdate right.

Path Parameters

NameTypeDescription

id*

string

Unique identifier.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

Request Body

NameTypeDescription

(body)*

DailySalesReport

Model to create or update.

{
    "id": "649ad7516413d6a4de6c8cb4",
    "fiscalName": "eKasa",
    "number": 1,
    "fiscalMemorySerialNumber": "1326585810",
    "openDate": "2023-06-27T08:04:25.605Z",
    "closeDate": "2023-06-27T22:42:13.662Z",
    "currencyLabel": "EUR",
    "cashTransfers":
    [],
    "fiscalInfo":
    {
        "ticketsCount": 7,
        "ticketsAmountIncludingVat":
        {
            "amount": 80.65,
            "currencyLabel": "EUR"
        },
        "invalidTicketsCount": 0,
        "invalidTicketsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "invoiceTicketsCount": 0,
        "invoiceTicketsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "positiveTicketItemsCount": 8,
        "positiveTicketItemsAmountIncludingVat":
        {
            "amount": 80.65,
            "currencyLabel": "EUR"
        },
        "returnedContainerTicketItemsCount": 0,
        "returnedContainerTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "returnedTicketItemsCount": 0,
        "returnedTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "correctionTicketItemsCount": 0,
        "correctionTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "discountTicketItemsCount": 0,
        "discountTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "advanceTicketItemsCount": 0,
        "advanceTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "creditTicketItemsCount": 0,
        "creditTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "voucherTicketItemsCount": 0,
        "voucherTicketItemsAmountIncludingVat":
        {
            "amount": 0.0,
            "currencyLabel": "EUR"
        },
        "vatIncomes":
        [
            {
                "vatCategory": 1,
                "vatRate": 20.0,
                "totalAmount":
                {
                    "amount": 9.45,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 1.58,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 2,
                "vatRate": 10.0,
                "totalAmount":
                {
                    "amount": 71.2,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 6.47,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 3,
                "vatRate": 0.0,
                "totalAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 4,
                "vatRate": 0.0,
                "totalAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                }
            },
            {
                "vatCategory": 5,
                "vatRate": 0.0,
                "totalAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                },
                "vatAmount":
                {
                    "amount": 0.0,
                    "currencyLabel": "EUR"
                }
            }
        ],
        "grandTotalAmountIncludingVat":
        {
            "amount": 1619.31,
            "currencyLabel": "EUR"
        },
        "roundingDown":
        {
            "amount": -0.02,
            "currencyLabel": "EUR"
        },
        "roundingUp":
        {
            "amount": 0.02,
            "currencyLabel": "EUR"
        }
    },
    "state": "Closed",
    "_v": 2
}

Manually close daily sales report

POST http://{server-address}/dailysalesreports/{id}/close

Changes state of daily sales report to manuallyClosed. Result is of type DailySalesReport.

Required rights

Authorized user must have dsrCloseManually right assigned.

Path Parameters

NameTypeDescription

id

string

Unique identifier.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

{
    "id": "646f5d625527869ae467b117",
    "fiscalName": "eKasa",
    "number": 2,
    "fiscalMemorySerialNumber": "1326585810",
    "openDate": "2023-06-28T08:06:40Z",
    "closeDate": "2023-06-28T15:06:40Z",
    "currencyLabel": "EUR",
    "cashTransfers":
    [],
    "fiscalInfo": null,
    "state": "ManuallyClosed",
    "_v": 2
}

Delete daily sales report

DELETE http://{server-address}/dailysalesreports/{id}

Required rights

Authorized user must have DsrDelete right assigned.

Path Parameters

NameTypeDescription

id*

string

Unique identifier.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

{
    "id": "646f5d625527869ae467b117",
    "fiscalName": "eKasa",
    "number": 2,
    "fiscalMemorySerialNumber": "1326585810",
    "openDate": "2023-06-28T08:06:40Z",
    "closeDate": null,
    "currencyLabel": "EUR",
    "cashTransfers":
    [],
    "fiscalInfo": null,
    "state": "Open",
    "_v": 1
}

Last updated