API Methods¶
The API serves for payment acceptance within the Payment acceptance for providers via credit organizations product.
Get the status of the subscriber and extra parameters of payment without registering the payment¶
On receiving the request, the provider checks the presence of a subscriber with the specified ID in its database and, optionally, returns extra parameters for showing them to the customer. These extra parameters can then be transferred as additional payment details in check and pay requests.
Request parameters¶
Parameter | Description |
---|---|
command | Required. Identification of the request type: get additional payment data for the customer. Always getInfo |
account | Required. Subscriber’s identifier (account number, phone number, login etc) in the provider’s database. String of letters, digits, and special symbols, up to 200 symbols. Before sending the request, QIWI system verify the identifier to match to the regular expression given by the provider |
ccy | Required. Currency code according to ISO 4217 |
prv_id | Service identifier in the provider’s information system. Integer |
sum | Transaction amount. A number with two decimal places in the fractional part, the separator of the integer and fractional parts is a dot |
data1,data2,…,dataN | Additional parameters for the subscriber identification. Format specified by the provider |
Response parameters¶
In response, the provider’s interface must return a valid XML document containing the <response>
block with the following XML tags:
Tag | Description |
---|---|
result | Required. Operation result code (result=0 if payment is possible) |
comment | Text comment from the provider |
fields | Section with subscriber’s information or operation data |
fields.field1, …, fields.fieldN | Tags with information |
fields.field1.name, …, fields.fieldN.name | The name of the information parameter. If not specified, the name disp1 ,.., dispN according to the order number of the fieldN tag is assigned |
Examples¶
Check the status of the subscriber, get extra parameters of payment and register the payment¶
On receiving the request, the provider does the following:
- Checks the presence of a subscriber with the specified ID in its database.
- Performs internal checks of the payment data in accordance with the accepted logic of replenishment through payment systems.
- (Optionally) Returns extra parameters for showing them to the customer.
Attention
The provider’s information system must not contain two successful QIWI payments with the same txn_id
payment ID in QIWI system. If provider receives a request with a txn_id
already existing in the provider’s system, the provider must return the result of processing of the previous request.
Request parameters¶
Parameter | Description |
---|---|
command | Required. Identification of the request type: check the subscriber’s account and payment data. Always check |
txn_id | Required. Payment identifier in QIWI system |
account | Required. Subscriber’s identifier in the provider’s database |
sum | Required. Operation amount |
ccy | Required. Currency code according to ISO 4217. |
prv_id | Internal identifier of the provider in QIWI. Integer |
data1, data2,…, dataN | Additional parameters for the subscriber identification. Format specified by the provider |
Response parameters¶
In response, the provider’s interface must return a valid XML document containing the <response>
block with the following XML tags:
Tag | Description |
---|---|
osmp_txn_id | Required. QIWI system’s transaction identifier, that is txn_id from the original request |
result | Required. Operation result code (result=0 if payment is possible) |
comment | Text comment from the provider |
fields | Section with subscriber’s information or operation data |
fields.field1, …, fields.fieldN | Tags with information |
fields.field1.name, …, fields.fieldN.name | The name of the information parameter. If not specified, the name disp1 ,.., dispN (according to the order number of the fieldN tag) is assigned |
Examples¶
Confirm the payment¶
On getting the request, provider replenishes the subscriber’s balance in its system.
Attention
The provider’s information system must not contain two successful QIWI payments with the same txn_id
payment ID in QIWI system. If provider receives a request with a txn_id
already existing in the provider’s system, the provider must return the result of processing of the previous request.
Request parameters¶
Parameter | Description |
---|---|
command | Required. Identification of the request type: replenish the subscriber’s balance. Always pay |
txn_id | Required. Payment identifier in the QIWI system |
txn_date | Required. Date of the transaction with YYYYMMDDHHMMSS format |
account | Required. Subscriber identifier in the provider’s system |
sum | Required. Transaction amount. A number with two decimal places in the fractional part, the separator of the integer and fractional parts is a dot |
ccy | Required. Currency code according to ISO 4217 |
prv_id | Internal identifier of the provider in QIWI. Integer |
data1, data2,…, dataN | Additional parameters for the subscriber identification. Format specified by the provider |
Response parameters¶
In response, the provider’s interface must return a valid XML document containing the <response>
block with the following XML tags:
Tag | Description |
---|---|
osmp_txn_id | Required. QIWI system’s transaction identifier, that is txn_id from the original request |
prv_txn | Required. Unique ID of the replenishment operation in the provider’s system |
sum | Required. Payment amount transferred to the provider. A number with two decimal places in the fractional part, the separator of the integer and fractional parts is a dot |
result | Required. Operation result code (result=0 if payment is successfully registered) |
comment | Text comment from the provider |
fields | Section with customer information or operation data |
fields.field1, …, fields.fieldN | Tags with information |
fields.field1.type, …, fields.fieldN.type | Information data type. The following types are possible:disp – information to show to the customer when making a payment (default value);info – information to save in the QIWI system |
fields.field1.name, …, fields.fieldN.name | The name of the information parameter. If not specified, the name disp1 ,.., dispN (according to the order number of the fieldN tag) is assigned |