Operation get_documents_history

Операция получения истории операций.

This operation is deprecated. Please use another one: get_documents_history_ext.

Query parameters

Parameter Value
operation get_documents_history
login <User name>
token <TOKEN>. Obtained after invoking get_token.
encrypted_password Encrypted password. It is obtained after user password RSA encryption with the use of a public exponent and the modulus obtained in invoking the get_token operation.
period_fromThe start date for collecting documents (the default is 7 days before).
Format: DD.MM.YYYY
period_toThe end date of collecting documents (the default is today).
Format: DD.MM.YYYY
accountYour account number
document_stateDocument status.
May take one of the following values:
  • any — any document status
  • onexecution — on execution
  • executed — executed
  • declined — declined
If this parameter is empty or not provided, it accept the default value, any
limitThe maximum number of records returned per page (0 to 1000). The default is 30.
In the case of 0 – entries will not be returned.
pagePage number (1 and more).
If page < 1 or not provided, it will be set to 1.

See also

Response in the CSV format

Format

Line No. Data format
10;<total_count>;<page_count>;<page>;<page_size>;<page_doc_count>;<doc_currency>
2 ... n<doc_num>;<doc_datetime>;<doc_state>;<doc_correspondent>; <doc_comment>;<doc_amount>;<doc_description>;<doc_state_code>

Values

Value Description
<doc_num>Document number
<doc_datetime>Date and time of the document (Moscow time).
Format: DD.MM.YYYY HH:MM:SS
<doc_state>Localized status of the document.
May take the following values:
  • Being executed
  • Cancelled
  • Executed
  • Awaiting progress
<doc_state_code>Document status code.
May take the following values:
  • NEW — awaiting processing
  • ONEXECUTION — being executed
  • DECLINED — declined
  • EXECUTED — executed
<doc_correspondent>The correspondent of the format "Payment type: correspondent".
In case of a bank transfer, the field contains data about the bank, the account number and the recipient:
Wire: Recipient;Account;Bank
<doc_comment>Comment
<doc_amount>The amount of the document in the currency of the account where documents were collected. If the amount is negative, the account will be debited. If the amount is positive, the account will be credited
<total_count>The total number of documents without page breaks
<page_count>The total number of pages with size <page_size>
<page_size>Page size (number of records per page). If the request contains invalid limit parameter, <page_size> will contain an adjusted value; otherwise they will be the same
<page>Current page number
<page_doc_count>Number of records found in current page
<doc_currency>Currency of payment
<doc_description>Purpose of the payment

Response examples

JSON (recommended format, please set x-response-format=json header)

{
    "code": 0,
    "message": "",
    "data": {
        "pages": {
            "itemCount": 7,
            "pageCount": 1,
            "pageSize": 30,
            "currentPage": 0,
            "currentPageCount": 7
        },
        "history": [
            {
                "number": 92362566,
                "date": "22.01.2015 15:20:58",
                "state": "Исполнен",
                "corrDetails": "WebMoney: Z112224443331",
                "comment": null,
                "amount": "-1.40",
                "description": "Payout 6",
                "state_code": "EXECUTED"
            },
            {
                "number": 92362498,
                "date": "22.01.2015 15:20:57",
                "state": "Исполнен",
                "corrDetails": "WebMoney: Z112224443331",
                "comment": null,
                "amount": "-1.10",
                "description": "Payout 3",
                "state_code": "EXECUTED"
            },
            {
                "number": 92362519,
                "date": "22.01.2015 15:20:57",
                "state": "Отменен",
                "corrDetails": "WebMoney: Z112224443331",
                "comment": "Внешний сервис вернул ошибку: корреспондент не найден",
                "amount": "-1.20",
                "description": "Payout 4",
                "state_code": "DECLINED"
            },
            {
                "number": 92362585,
                "date": "22.01.2015 15:20:58",
                "state": "Исполнен",
                "corrDetails": "WebMoney: Z112224443331",
                "comment": null,
                "amount": "-1.50",
                "description": "Payout 7",
                "state_code": "EXECUTED"
            },
            {
                "number": 92362544,
                "date": "22.01.2015 15:20:57",
                "state": "Исполнен",
                "corrDetails": "WebMoney: Z112224443331",
                "comment": null,
                "amount": "-1.30",
                "description": "Payout 5",
                "state_code": "EXECUTED"
            }
        ]
    }
}

CSV

0;7;1;0;30;7;USD
92362566;"22.01.2015 15:20:58";Исполнен;"WebMoney: Z112224443331";;-1.40;"Payout 6";EXECUTED
92362498;"22.01.2015 15:20:57";Исполнен;"WebMoney: Z112224443331";;-1.10;"Payout 3";EXECUTED
92362519;"22.01.2015 15:20:57";Отменен;"WebMoney: Z112224443331";"Внешний сервис вернул ошибку: корреспондент не найден";-1.20;"Payout 4";DECLINED
92362585;"22.01.2015 15:20:58";Исполнен;"WebMoney: Z112224443331";;-1.50;"Payout 7";EXECUTED
92362544;"22.01.2015 15:20:57";Исполнен;"WebMoney: Z112224443331";;-1.30;"Payout 5";EXECUTED
API Capitalist