Financial History - average

This provides financial history, in addition to average values over the period.

METHOD: POST

RESOURCE URL

{base-url}/api/v1/request/customer-insights/financial-attributes-avg

Sample Request

{
	"phone":"2348082135806",
    "startYearMonth":"2024-02",
    "endYearMonth":"2024-07"
}

_Sample Response

_

{
    "responseCode": "00",
    "responseMessage": "Successful",
    "data": {
        "monthOnMonth": [
            {
                "phone": "2348082135806",
                "totalDebit": 4000.0,
                "debitCount": 1.0,
                "totalCredit": 4133200.0,
                "creditCount": 15.0,
                "yearMonth": "2024-04",
                "averageBalance": 369248.425
            },
            {
                "phone": "2348082135806",
                "totalDebit": 1500.0,
                "debitCount": 1.0,
                "totalCredit": 0.0,
                "creditCount": 0.0,
                "yearMonth": "2024-05",
                "averageBalance": 0.0
            },
            {
                "phone": "2348082135806",
                "totalDebit": 581954.0,
                "debitCount": 73.0,
                "totalCredit": 0.0,
                "creditCount": 0.0,
                "yearMonth": "2024-07",
                "averageBalance": 0.0
            }
        ],
        "averageValue": {
            "totalDebit": 195818.0,
            "debitCount": 25.0,
            "totalCredit": 1377733.3333333333,
            "creditCount": 5.0,
            "averageBalance": 123082.80833333333
        }
    }
}