Operations
URL /operation
TEST URL https://testepay.homebank.kz/api/operations
PROD URL https://epay-api.homebank.kz/operations
Authorization is required
Incoming parameters are sent in a form of JSON: The model is as followed:
{
"paging":{
"page": "",
"size": ""
},
"searchParameters":[
{
"name":"",
"method":"",
"searchParameter":["","",...]
}
],
"orderParameters":[
{
"field":"",
"typeOrder":"ASC/DESC"
}
]
}
"Paging" takes 2 parameters: "page" controls the number of entries that must be skipped; "size" controls the number of entries that are received.
"searchParameters" takes 3 parameters. It is also possible to perform a search by multiple fields (example shows how it is done) "name" is a filter parameter of a field that controls what is searched in a DB. "method" controls how to search the DB (possible options: between, in, like, =, <, >, <=, >=); "searchParameter" controls search parameters. When used in conjunction with "between" must specify 2 parameters. When used with "like" must use one parameter that contains %. When used with "in" must specify at least 1 parameter. In an event of wrong parameters, an error is returned. You must specify a transaction period in a request (it is required).
"orderParameters" can take 2 parameters. "Field" name of the field that is used for sorting. "typeOrder" controls order ASC/DESC. This field can be left blank if there is no need for sorting.
Фильтры:
Description | Name |
---|---|
Transaction Date | created_date |
Store | shop_id |
Order number | invoice_id |
Client Id in the store | account_id |
Phone | payer_phone |
payer_email | |
РРН | reference |
PostLink | post_link(bool) |
Amount | amount |
Card | card_mask |
Payer | client |
Installments | installment_id |
Transaction type | transaction_type_id |
Refund Date | payout_date |
Refund Amount | payout_amount |
Request example, JSON:
{
"paging":{
"page": 1,
"size": 2
},
"searchParameters":[
{
"name":"created_date",
"method":"between",
"searchParameter":["2017-11-19T00:00:00Z", "2018-11-20T00:00:00Z"]
},
{
"name":"description",
"method":"in",
"searchParameter":["description"]
},
{
"name":"payer_email",
"method":"like",
"searchParameter":["danatugumbayeva%"]
}
],
"orderParameters":[
{
"field":"payer_email",
"typeOrder":"ASC"
},
{
"field":"description",
"typeOrder":"DESC"
}
]
}
Response in a form of JSON:
{ "totalCount": 8, "records": [ { "id": "b9d46313-264e-41ec-814c-728dd51eb97f", "amount": 1000, "currencyID": "8d565e73-1f67-4169-99d9-6cbfc12c2e55", "amountBonus": 80, "invoiceId": "", "accountId": "", "payerIp": "10.6.50.57", "payerName": "Dana Tugumbayeva", "payerPhone": "77029085001", "payerEmail": "danatugumbayeva@gmail.com", "description": "description", "data": "", "createdDate": "2018-10-27T15:08:14+06:00", "authDate": "2018-10-27T15:08:14+06:00", "confirmDate": "2018-10-27T15:08:14+06:00", "payoutDate": "2018-12-29T00:01:01.374084+06:00", "payoutAmount": 1000, "ipCountry": "", "ipCity": "", "ipRegion": "", "ipDistrict": "", "ipLatitude": 0, "ipLongitude": 0, "cardNumber": "4003....9282", "cardExpDate": "05.22", "cardCVC": "000", "cardType": { "ID": "", "Name": "" }, "cardTypeID": "ec1e3a6a-5687-4c50-95aa-80723d9b940c", "issuer": "", "issuerBankCountry": "", "statusID": "22eb5a3e-0737-455c-ab42-ea98f80f7963", "reference": "730681443792", "client": "test", "template": "", "language": "RUS", "transactionTypeID": "4303bed9-243c-48d8-94de-8102f53e2803", "backLink": "", "failureLink": "", "postLink": "false", "postLinkStatus": false, "merchantID": "a5bc9d98-38ea-4b9c-ba7f-65a4add02ed6", "shopID": "a5bc9d98-38ea-4b9c-ba7f-65a4add02ed6", "secure3D": false, "cardID": "000000", "cardHash": "", "cardMask": "4003...9282", "installmentID": "c44602ca-357d-4dbb-8c94-3c36f48defd8", "terminal": "", "initReference": "" }, { "id": "ac63c3b5-b369-42de-9ed3-d503a0840ee6", "amount": 100, "currencyID": "8d565e73-1f67-4169-99d9-6cbfc12c2e55", "amountBonus": 99, "invoiceId": "", "accountId": "", "payerIp": "10.6.50.57", "payerName": "Dana Tugumbayeva", "payerPhone": "77029085001", "payerEmail": "danatugumbayeva@gmail.com", "description": "description", "data": "", "createdDate": "2018-10-01T15:08:14+06:00", "authDate": "2018-10-01T15:08:14+06:00", "confirmDate": "2018-10-01T15:08:14+06:00", "payoutDate": "2018-12-28T21:57:18.314319+06:00", "payoutAmount": 100, "ipCountry": "", "ipCity": "", "ipRegion": "", "ipDistrict": "", "ipLatitude": 0, "ipLongitude": 0, "cardNumber": "4003....9282", "cardExpDate": "05.22", "cardCVC": "000", "cardType": { "ID": "", "Name": "" }, "cardTypeID": "ec1e3a6a-5687-4c50-95aa-80723d9b940c", "issuer": "", "issuerBankCountry": "", "statusID": "22eb5a3e-0737-455c-ab42-ea98f80f7963", "reference": "", "client": "test", "template": "", "language": "RUS", "transactionTypeID": "4303bed9-243c-48d8-94de-8102f53e2803", "backLink": "", "failureLink": "", "postLink": "false", "postLinkStatus": false, "merchantID": "a5bc9d98-38ea-4b9c-ba7f-65a4add02ed6", "shopID": "a5bc9d98-38ea-4b9c-ba7f-65a4add02ed6", "secure3D": false, "cardID": "000000", "cardHash": "", "cardMask": "4003...9282", "installmentID": "c44602ca-357d-4dbb-8c94-3c36f48defd8", "terminal": "", "initReference": "" } ] }
Response with an error in a form of JSON:
{
"code": 232,
"message": "Search Method Unavailable"
}