Invoice statistics

Description

Allows you to get general statistics on your invoices and payments.

Request

curl -X POST https://api.bitsby.app/statistics/invoices \
  -H "Authorization: Token MSvL2ltaDZdWVjmZURURMVWhqSJLT2NURjhL2Fla1Z1T1IxQTltKs1T3Ay" \
	-F "startDate=2000-01-01" \
	-F "endDate=2030-01-01"

Request parameters

Example answer

{
    "result": "success",
    "data": {
        "invoicesTotalNum": 51,
        "invoicesPaidNum": 24,
        "invoicesTotalUSD": 335.03,
        "invoicesByProjects": {
            "9deea1e2-0c08-41a3-bdc2-a34eada3892d": 335.03
        },
        "invoicesByCurrencies": {
            "USD": 335.03
        },
        "invoicesByMonths": {
            "March-2024": 42,
            "February-2024": 293.03
        },
        "invoicesByDate": {
            "2024-03-04": {
                "date": 1709510400000,
                "value": 21
            },
            "2024-03-03": {
                "date": 1709424000000,
                "value": 10
            },
            "2024-03-01": {
                "date": 1709251200000,
                "value": 11
            },
            "2024-02-27": {
                "date": 1708992000000,
                "value": 12
            },
            "2024-02-26": {
                "date": 1708905600000,
                "value": 38
            }
        }
    }
}

Answer parameters

Last updated