Back to Index

POST v1/Statements

Retrieves statement details for an account

Request Information

URI Parameters

NameDescriptionTypeAdditional information
version

string

None.

Body Parameters

statements_request
NameDescriptionTypeAdditional information
account_token

The token used to identify the Peloton account

string

None.

from_date_utc

The UTC date from which statement information is requested

date

None.

to_date_utc

The UTC date to which statement information is requested

date

None.

application_name

The name of the calling application

string

Required

String length: inclusive between 0 and 128

language_code

Determines the Language of the response data. 2 Character ISO LanguageCode. Supported language codes are: 'en' (English), 'fr' (French). Default is 'en'.

string

None.

Request Formats

application/json, text/json

Sample:
{
  "account_token": "sample string 1",
  "from_date_utc": "2019-03-19T11:49:46.8613999-07:00",
  "to_date_utc": "2019-03-19T11:49:46.8613999-07:00",
  "application_name": "sample string 4",
  "language_code": "en"
}

Response Information

Resource Description

statements_response
NameDescriptionTypeAdditional information
opening_balance

The opening balance of the account

decimal number

None.

statement_details

Collection of line items for the requested period

Collection of statement_detail

None.

from_date_utc

The UTC date from which statement information was requested

date

None.

to_date_utc

The UTC date to which statement information was requested

date

None.

success

True if successful, false otherwise

boolean

None.

message

The message related to the operation in the language specified by the request

string

None.

message_code

The code associated with the message

integer

None.

errors

List of validation errors that occured, otherwise empty

Collection of string

None.

Response Formats

application/json, text/json

Sample:
{
  "opening_balance": 1.0,
  "statement_details": [
    {
      "amount": 1.0,
      "transaction_description": {
        "name": "sample string 1",
        "code": "sample string 2"
      },
      "transaction_type": {
        "name": "sample string 1",
        "code": "sample string 2"
      },
      "references": [
        {
          "name": "sample string 1",
          "value": "sample string 2"
        },
        {
          "name": "sample string 1",
          "value": "sample string 2"
        }
      ],
      "transaction_datetime_utc": "2019-03-19T11:49:46.877021-07:00",
      "post_datetime_utc": "2019-03-19T11:49:46.877021-07:00",
      "transaction_ref_code": "sample string 4",
      "ledger_type": "sample string 5"
    },
    {
      "amount": 1.0,
      "transaction_description": {
        "name": "sample string 1",
        "code": "sample string 2"
      },
      "transaction_type": {
        "name": "sample string 1",
        "code": "sample string 2"
      },
      "references": [
        {
          "name": "sample string 1",
          "value": "sample string 2"
        },
        {
          "name": "sample string 1",
          "value": "sample string 2"
        }
      ],
      "transaction_datetime_utc": "2019-03-19T11:49:46.877021-07:00",
      "post_datetime_utc": "2019-03-19T11:49:46.877021-07:00",
      "transaction_ref_code": "sample string 4",
      "ledger_type": "sample string 5"
    }
  ],
  "from_date_utc": "2019-03-19T11:49:46.877021-07:00",
  "to_date_utc": "2019-03-19T11:49:46.877021-07:00",
  "success": true,
  "message": "sample string 5",
  "message_code": 6,
  "errors": [
    "sample string 1",
    "sample string 2"
  ]
}