Getting payments list for a specified date
This method allows requesting lists of invoices by app identifiers.
tip
If you are in doubt read the instruction in the usage scenarios.
Interaction parameters
GET
https://public-api.rustore.ru/public/applications/{appId}/invoices
Attribute | Type | Description | Mandatory | Location | Example |
---|---|---|---|---|---|
Public-Token | string | Jwe token to Public API Rustore. How to get an authorization token. | Yes | header | N/A |
appId | int | Applicatio conde (see SDK documentation). | Yes | path | 3399750 |
invoiceStatuses | array | Payment statuses that will be included in the list.
| Yes | query | created |
invoiceDate | string | Date for which you need to get the list in the YYYY-MM-DD format | Yes | query | 2024-10-23 |
pageNumber | int | Page number with the payments list, starting from 0 . The default is 0 . | No | query | 1 |
pageSize | int | Number of elements on a page. The default value is 20 . | No | query | 20 |
Response parameters
Attribute | Type | Description | Mandatory | Location | Example |
---|---|---|---|---|---|
code | string | Response code | Yes | body | • OK ;• ERROR ;• BAD_REQUEST ;• NOT_FOUND . |
message | string | Decoded response code | No | body | Jwe token is expired |
body | object | Response body | No | body | N/A |
timestamp | string | Response time | Yes | body | 2023-08-02T10:11:04.655684723+03:00 |
body{}
Attribute | Type | Description | Example |
---|---|---|---|
content [] | array | Response contents. | N/A |
pageNumber | int | Page No. | 2 |
pageSize | int | Number of records per page. | 20 |
totalElements | int | Total amount of payments that according to the criteria specified in the response. | 14 |
totalPages | int | Total amount of pages in the response. | 8 |
content[]
Attribute | Type | Description | Mandatory | Example |
---|---|---|---|---|
invoiceId | string | Invoice No. | Yes | 12345 |
invoiceDate | string | Invoice date | Yes | 2020-04-29T08:18:03+03:00 |
refundDate | string | Refund date. Returns value only for payments in the REFUNDED status. | No, nullable | 2020-04-29T08:18:03+03:00 |
invoiceStatus | string | Invoice status | Yes | Payment statuses that will be included in the list.
|
developerPayload | string | String with additional information about the order that you can set during purchase initialization in SDK. | No, nullable | N/A |
appId | int | App code | Yes | 3399750 |
ownerCode | int | App owner code | Yes | 4384191 |
paymentInfo{} | object | Payment info | No, if the payment tool is not selected (invoice is in the CREATED status) | N/A |
order{} | object | Order info | Yes | N/A |
paymentInfo{}
Attribute | Type | Description | Mandatory | Example |
---|---|---|---|---|
paymentDate | string | Payment date and time. | No | 2024-10-24T14:31:33+03:00 |
maskedPan | string | Masked card number | No | **1111 |
paymentSystem | string | Payment system. | No | Visa |
paymentWay | string | Payment Method. | No | SberPay |
paymentWayCode | string | Payment Method ID. | No | SberPay |
bankName | string | Issuing bank name. | No | Sberbank |
order{}
Attribute | Type | Description | Mandatory | Example |
---|---|---|---|---|
orderId | string | Unique order ID | Yes | d290f1ee-6c54-4b01-90e6-d701748f0851 |
orderNumber | string | Order No. | No | 145 |
visualName | string | Operation name. | Yes | Purchase of digital content |
amountCreate | integer | Order amount in minimum currency units. | Yes | 10000 |
amountCurrent | number | Purchase amount with discounts in minimum currency units. | Yes | 9000 |
currency | string | Currency code | Yes | RUB |
itemCode | string | Product code specified in the RuStore Console on product creation. | Yes | 1day |
description | string | Order Description | Yes | Mash and the Bear in-app purchase — 100 crystals |
language | string | Description language. | Yes | ru-RU |
Successful response
{
"code": "string",
"message": "string",
"body": {
"content": [
{
"invoiceId": "2850",
"invoiceDate": "2023-07-18T14:31:33+03:00",
"refundDate": null,
"invoiceStatus": "confirmed",
"developerPayload": null,
"appId": "3399750",
"ownerCode": "4384191",
"paymentInfo": {
"paymentDate": "2024-10-24T14:31:33+03:00",
"maskedPan": "XX1111",
"paymentSystem": "Visa",
"paymentWay": "Payment with a saved card",
"paymentWayCode": "CARD_BINDING",
"bankName": "Sberbank"
},
"order": {
"orderId": "a090a93c-ca06-493d-a90a-ce2bac722358",
"orderNumber": "311",
"visualName": "Masha and the Bear in-app purchase — 100 crystals",
"amountCreate": 10000,
"amountCurrent": 9000,
"currency": "RUB",
"itemCode": "1day",
"description": "1day",
"language": "en-US",
},
}
],
"pageNumber": 1,
"pageSize": 20,
"totalElements": 20,
"totalPages": 1
},
"timestamp": "2024-10-22T23:39:23.557Z"
}
Error response example
{
"code": "string",
"message": "string",
"body": {},
"timestamp": "2024-10-22T23:39:23.560Z"
}
Response verification
On receiving a request the authorization token is checked (see [generating a security token] (/work-with-rustore-api/api-authorization-token)):
- the owner and/or app must not be blocked;
- the token must be valid;
- the
appId
matches to the token owner.