customer/v1/statements

[GET] customer/v1/statements

Get recent statements

The statement endpoint is used to retrieve customer statements; lists of transactions within the statement period. Statements are created at the end of every month.

Example [GET] Request

{{avenu_base_url}}/customer/v1/statements

Example Response

{
  "pagination": {
    "next": "https://sandbox.openroad.avenu.bank/customer/v1/statments?limit=3&before=2013-12-27T16:43:40"
},
  "statements": [
    {
      "transactions": [
        {
          "transactionId": "",
          "date": "",
          "categoryCode": "",
          "memo": "",
          "amount": 0,
          "runningBalance": 0,
          "outgoingAccountOwner": 0
        }
      ],
      "statementId": "",
      "statementDate": "",
      "daysInPeriod": 0,
      "endingBalance": 0,
      "previousBalance": 0,
      "totalCredits": 0,
      "totalDebits": 0,
      "creditsAmount": 0,
      "debitsAmount": 0
    }
  ]
}

By providing a `statementId` the statement endpoint allows drilling down into a statement to see individual transactions and other more specific statement data.

#### Example [GET] Request

http URL
{{avenu_base_url}}/customer/v1/statements/{{statementId}}

#### Request Parameter

| Parameter     | Format      | Required |
| ------------- | ----------- | -------- |
| "statementId" | UUID String | Y        |

#### Example Response

```json
{
  "transactions": [
    {
      "transactionId": "",
      "date": "",
      "categoryCode": "",
      "memo": "",
      "amount": xxx,
      "runningBalance": xxx,
      "outgoingAccountOwner": ""
    }
  ],
  "statementId": "",
  "statementDate": "",
  "daysInPeriod": 0,
  "endingBalance": 0,
  "previousBalance": 0,
  "totalCredits": 0,
  "totalDebits": 0,
  "creditsAmount": 0,
  "debitsAmount": 0
}

Response Elements

ElementDetails
statementIdUUID statement identifier
statementDateStatement date in format ISO 8601 YYYY-MM-DD
daysInPeriodDays in statement period
endingBalanceEnding balance after current period
previousBalanceEnding balance after previous period
totalCreditsTotal number of credit transactions in period
totalDebitsTotal number of credit transactions in period
creditsAmountTotal sum of credit transactions in period
debitsAmountTotal sum of debit transactions in period