Embedding PortmoneDirect bill payment service into customer service banking systems. Technical description
Glossary
| Term | Definition |
|---|---|
| Merchant, Partner | Organization which has signed a payment acceptance agreement with Portmone.com |
| Buyer, Client or Customer | A person who visits the Merchant's Online Store in order to learn about the range of goods (services) and to make a purchase |
| Card, Payment Card | Payment cards of Visa, Mastercard international card associations and the National payment system PROSTIR |
| Authorization | The process of giving access rights or other powers to the Buyer, program or process |
| CVV2/CVC2 | CVV2 (Card Verification Value 2) is a three-digit card security code that helps to verify legitimacy of a Visa payment card. The Mastercard payment system has similar card security code called CVC2 (Card Validation Code 2) |
| Acquiring Bank | A bank that organizes banking cards acceptance points (terminals, ATM’s) and processes full range of financial operations connected with performing bank settlements and payments by banking cards at that points |
| Issuing Bank (Card Issuing Bank) | A bank licensed as a member of a card association (like Visa or Mastercard), that issues and maintains payment cards |
| IBAN | International Bank Account Number |
1. General information
The PortmoneDirect uses Representational State Transfer (REST) technology. Requests and responses are transferred over the HTTPS channel (note that at the moment only TLS 1.2 protocol is supported by the server).
The execution of methods with the required parameters is to be formed on the side of merchant and to be transferred to the Portmone.com server by POST requests.
** Please note ** that all parameters are transferred in the body of the POST request, in no case in the body of the URL. In query examples, the
?sign is specified at the beginning of the string - this is not an indication for the use of GET messages.
Endpoint URL: https://direct.portmone.com.ua/api/directcash/.
Each request must contain two mandatory parameters - login and password (login and password of the reseller company). The login, password and HTTPS certificate should be provided by the Portmone manager.
The response format is XML. UTF-8 encoding is used for data transferring.
The date format is DD.MM.YYYY.
An example of request for bill delivery:
method=bills.create&login=login&password=password&version=2&payeeId=value&contractNumber=value
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
[xml-data there]
</rsp>
An example of response in case of an error:
For version 1:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
For version 2 and higher:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
<error_description>Detailed error description (protocol version - 2)</error_description>
</rsp>
Protocol
By default, the protocol version is “1”.
If the parameter version = 2 is transferred in the request, additional tags entered for the protocol version “2” become available.
Localization
Optional parameter lang added to the protocol version “2” (possible values are: ru - Russian, uk - Ukrainian, en - English). The parameter localizes attribute values and service names in the response (but not the company name). If the parameter is not passed, the result is returned in Ukrainian.
If you use the protocol version 2 (version = 2) and the values of the lang parameter in the request, the values of <name/> and <*_name/> tags in the <tariff_items> block of the response will be returned localized to the needed language.
For the protocol version 2 (version = 2), the <tariff_items> block of the response does not contain the <name_ua/> and the <name_en/> tags (due to the lang parameter using).
An example of using the lang parameter.
Request:
method=bills.create&payeeId=1755&login=PortmoneDirectTest&password=**************
&version=2&contractNumber=639512625&lang=uk
Response:
<rsp status="ok">
<bill id="598984149">
<payee id="1755">lifecell</payee>
<contractNumber title="Номер телефона (без +380)">639512625</contractNumber>
<attribute1/>
<attribute2/>
<attribute3/>
<attribute4/>
<bill_attribute1/>
<bill_attribute2/>
<bill_attribute3/>
<bill_attribute4/>
<date>21.01.2020</date>
<description>Рахунок створений автоматично для поповнення балансу</description>
<amount>0.00</amount>
<debt>0.00</debt>
<sum>0.00</sum>
<status>created</status>
<paidAmount/>
<payDate/>
<payee_export_flag/>
<auth_code/>
<transaction_id/>
<payment_point/>
</bill>
</rsp>
The <contractNumber title> parameter is localized in Russian.
Description of XML-structure
To study structure of XML-response refer to Attachment 1.
Notifications of Invoice Uploads by Company
Partner notifications are sent after an invoice is uploaded for each company. The partner must provide a URL that can receive a POST request for further processing on their side.
Request examples:
<?xml version="1.0" encoding="UTF-8"?><req name="billsLoaded"><payee id="16020"/></req>
<?xml version="1.0" encoding="UTF-8"?><req name="billsLoaded"><payee id="140264"><payee id="140235"></req>
2. Methods
| Method name | Description |
|---|---|
| 2.1. bills.create | this method is used to create a subscription on the Portmone.com side to receive bills for the required company and return the bill ID (billId) |
| 2.2. bills.createByPhone | this method is used to create a bill on the Portmone.com side to add funds to a mobile phone account and return the ID of the payee company (payeeId) and the bill ID (billId) |
| 2.3. bills.createAll | this method is used to get bills from companies issuing several bills for the current month |
| 2.4. bills.pay | this method is used to pay bills |
| 2.5. bills.get | This method is used when you need to get information about a bill. You need to send request l if the method bills.pay received a connection error, received a response of an unexpected format that does not match the protocol. And also if errors p009, p017, p100 are received. |
| 2.6. bills.paymentOrder | this method is used to transfer a list of transactions and payment details of cover payment from bank to the Portmone.com system |
| 2.7. bills.date | this method is used to obtain a control registry of transactions for the period (day) |
| 2.8. bills.exported | this method is used to obtain a control registry of transactions for the period (day), the funds for which were sent to the service provider (biller) |
| 2.9. bills.balance | this method is used to view the current balance of the biller company (PAYEE) |
| 2.10. bills.payees | this method is used to get biller (PAYEE) parameters |
| 2.11. bills.regions | this method is used to obtain a list of available regions and a list of billers (PAYEE) for each region |
| 2.12. bills.additionalPayees | this method is used to get a list of companies for which the client can pay bills |
| 2.13. search.regions | this method is used to obtain a complete list of regions of Ukraine |
| 2.14. search.regionsExtended | this method is used to obtain a list of regions of Ukraine with additional filtering by region name |
| 2.15. search.citiesByRegion | this method is used to get a list of cities for the specified region |
| 2.16. search.citiesByRegionExtended | this method is used to get a list of cities for the specified region with additional filtering by city name |
| 2.17. search.streetsByCity | this method is used to get a list of streets for the specified city |
| 2.18. search.streetsByCityExtended | this method is used to get a list of streets for the specified city with additional filtering by street name |
| 2.19. search.housesByStreet | this method is used to get a list of buildings for the specified street |
| 2.20. search.housesByStreetExtended | this method is used to get a list of buildings for the specified street with additional filtering by building number |
| 2.21. search.apartmentsByHouse | this method is used to obtain a list of apartments by known houseId. For apartment buildings only |
| 2.22. search.apartmentsByHouseExtended | this method is used to obtain a list of apartments by known houseId with additional filtering by apartment number. For apartment buildings only |
| 2.23. search.userDocsByAddress* | this method is used to obtain a list of bills by known houseId (for private houses) or apartmentId (for apartment buildings). Returns bills with the full match by the address |
| 2.24. companies.top10ByRegion* | this method is used to get a list of the TOP 10 companies by regionId (partial match) |
| 2.25. companies.top10ByCity* | this method is used to get a list of the TOP 10 companies by cityId (partial match) |
| 2.26. companies.top10ByStreet* | this method is used to get a list of the TOP 10 companies by streetId (partial match) |
| 2.27. companies.top10ByHouse* | this method is used to get a list of the TOP 10 companies by known houseId (full match for house or partial match for apartment) |
| 2.28. companies.top10ByAddress* | this method is used to get a list of the companies by known houseId (for private houses) or apartmentId (for apartment buildings). Returns bills with the full or partial match by the address |
| 2.29. bills.getreference | this method is used to obtain a list of values of the specified dictionary using the related value from the upper-level dictionary |
| 2.30. bills.update | is a part of method 2.4. bills.pay, is used for update a bill with no change of its status |
| 2.31. bank.params.guaranteeAmount | the method of checking the amount of the guarantee payment for the partner according to the individual login |
| 2.32. bills.recreate | this method to create a copy of a paid invoice |
| 2.33. bills.cancel | this method for canceling payments that are in PAYED status (all versions of the protocol) |
| 2.34. counters.get | мethod for submitting meter readings without payment (for incoming companies) — creating a request |
| 2.35. counters.set | мethod for submitting meter readings without payment (data transmission to the company, readings entered by the customer). |
* How to use companies searching methods
- If only the
regionIdis known, use the companies.top10ByRegion method for searching bills by region- If the
cityIdis known, use the companies.top10ByCity method for searching bills by the specified locality (city)- If the
streetIdis known, use the companies.top10ByStreet method for searching bills for a specified street- If the
houseIdis known, use the companies.top10ByHouse method for searching bills for a specified building- If house has apartments (
hasApartments=Y) andapartment idis known, use the companies.top10ByAddress method (if there is no full match by the address, the method searches for bills by higher steps (by home, street, city, etc.)) or the search.userDocsByAddress method (returns bills with the full match for search parameter).
2.1. Request for bill delivery
Method: bills.create
Description of the method: the result of calling this method is creating a subscription on the Portmone.com side to receive bills for the required company and return the bill ID (billId - unique payment identifier). The answer contains data about the last available unpaid bill. If the company does not provide invoices, the wallet system creates an invoice for 0 amount and returns it to the partner for payment.
Before calling the bills.create method, you need to pay attention to <balance_source> tag value, obtained during the execution of the bills.payees method. If the value is <balance_source>Y</balance_source> for the company, you should use the bills.create method. In other cases call the bills.createAll method.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| payeeId | ID of the payee company | Yes |
| contractNumber | The main requisite (identifier) of the client in this company | Yes |
| billNumber | Order number | No |
| attribute1-4 | For additional information | No |
An example of request:
method=bills.create&login=login&password=password&version=2&payeeId=value&contractNumber=value
An example of successful response: see Attachment 1.
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.2. Request for bill delivery by phone number
Method: bills.createByPhone
Description of the method: this method is used to create a bill on the Portmone.com side to add funds to a mobile phone account and return the ID of the payee company (payeeId) and the bill ID (billId).
To pay the bill call the bills.pay method.
Interaction scheme:
- The Client enters the mobile phone number on the Partner's website.
- The Partner sends this data to the Portmone.com using the bills.createByPhone method.
- Portmone.com identifies the ID of the company to which the client’s phone belongs by the mobile network operator code, and sends an XML-message with the ID of the payee company (
payeeId) and the bill ID (billId) to the Partner. - The Partner sends the payment request using the bills.pay method.
- Portmone.com transfers funds to the service provider.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| payeeId | ID of the payee company | Yes |
| contractNumber | Phone number to which funds are transferred. Format of the number: 9 digits, without "+380" (for example, 673334411) | Yes |
| billAmount | Amount of payment (default to 0) | No |
| billNumber | Order number | No |
| attribute1-4 | For additional information | No |
An example of request:
method=bills.createByPhone&login=login&password=password&version=2&contractNumber=value&billAmount=value
An example of successful response:
<rsp status="ok">
<bill id="508828105">
<payee id="2065">Київст ар</payee>
<contractNumber title="Номер телефону (без +380)">973452341</contractNumber>
<attribute1/>
<attribute2 title="Номер квитанції Київстар"/>
<attribute3/>
<attribute4/>
<bill_attribute1/>
<bill_attribute2/>
<bill_attribute3/>
<bill_attribute4/>
<date>12.06.2019</date>
<description>Рахунок створений автоматично для поповнення балансу</description>
<amount>0.00</amount>
<debt>0.00</debt>
<sum>0.00</sum>
<status>created</status>
<paidAmount/>
<payDate/>
<payee_export_flag/>
<auth_code/>
<transaction_id/>
<payment_point/>
</bill>
</rsp>
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.3. Request for delivery of all bills issued for the current month
Method: bills.createAll
Description of the method: to get bills from companies issuing several bills for the current month, use the bills.createAll method. In terms of parameter set, this method is completely identical to the bills.create method.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| payeeId | ID of the payee company | Yes |
| contractNumber | The main requisite (identifier) of the client in this company | Yes |
| billNumber | Order number | No |
| attribute1-4 | For additional information | No |
An example of request:
method=bills.createAll&login=login&password=password&version=2&payeeId=value&contractNumber=value
An example of successful response: in case of success, the bills section is returned, containing XML described in Attachment 1 for each of the bills.
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<bills>
<bill id="id">
…
</bill>
<bill id="id">
…
</bill>
<bill id="id">
…
</bill>
</bills>
</rsp>
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
Main company and recipient companies:
The Portmone.com system allows you to split a payment, that is, crediting the amount of payment received from the client to several recipients (suppliers of goods or service providers).
Main company is a company that you display to the client when paying for a service/product and indicate in requests for getting bills. Such companies are created, for example, in order to group services provided (e.g. a company with payeeId = 8004 and a company with payeeId = 4568).
Recipient company is an active company that provides a service or a product, but it is not displayed to the client.
When you send a request with payeeId of main company, the bills.createAll method returns you bills with the payeeId of recipient companies for which payments will be made.
2.4. Bill payment
Method: bills.pay
Description of the method: performs debiting of funds on the client's payment card.
In the event that the service debt_state <> 'E', then the corresponding debt should not be taken into account in the total amount of payment on the account
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| billId | Bill ID. The value returned by the bills.create method (or by the bills.createByPhone method in case of a mobile phone replenishment) | Yes |
| amount | Amount for payment by order (it may differ from the one proposed in the bill) | Yes |
| auth_code | Authorization code | No |
| transaction_id | Transaction ID | No |
| payment_point | Unique description of a partner sales point | Yes |
| payer_iban or payer_card_number or payer_phone_number | the sender's iban, who initiates the transfer, takes the value of 29 characters ------------------------------------------------------------------------------ The card, the sender, who initiates the transfer, takes the value of 16 digits ------------------------------------------------------------------------------ Payer's phone number in the format | Yes |
An example of request for company without items:
method=bills.pay&login=login&password=password&version=2&billId=value&amount=value&payer_iban=value
or
method=bills.pay&login=login&password=password&version=2&billId=value&amount=value&payer_card_number=value
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<bill id="1046347926">
<payee id="6968">Воля ТБ та/або Інтернет</payee>
<contractNumber title="Номер договору">901386637</contractNumber>
<attribute1 title="Адреса">Київ, Архипенка Олександра, б.4А, кв.185</attribute1>
<attribute2 />
<attribute3 />
<attribute4 />
<bill_attribute1 />
<bill_attribute2 />
<bill_attribute3 />
<bill_attribute4 />
<date>11.01.2022</date>
<description>Рахунок створений автоматично для поповнення балансу</description>
<amount>0.00</amount>
<debt>0.00</debt>
<sum>0.00</sum>
<status>paid</status>
<paidAmount>31000.00</paidAmount>
<payDate>12.01.2022 08:49:29</payDate>
<payee_export_flag>N</payee_export_flag>
<auth_code />
<transaction_id />
<payment_point>PORTMONEDIRECTTEST</payment_point>
<bill_attribute10>UA77*********************6900</bill_attribute10>
</bill>
</rsp>
If payer_iban and payer_card_number are missing, the system will return an error
An example of response in case of an error:
<rsp status="fail">
<error code="р013">Incorrect customer identification parameters</error>
<error_description>Incorrect customer identification parameters</error_description>
</rsp>
Parameters for "universal" items (transferred into <tariff_items> array):
| Parameter | Description | Required |
|---|---|---|
| id | Counter ID | Yes |
| amount | The amount of the counter in UAH | Yes |
| prev_counter | Previous counter value | No |
| counter | Current counter value | No |
| tariff | Tariff value in UAH | No |
| subsidy | Subsidy in UAH | No |
| debt | Debt in UAH | No |
| attribute1 | Optional tag (depends on biller) (protocol version - 2) | No |
| attribute2 | Optional tag (depends on biller) (protocol version - 2) | No |
| attribute3 | Optional tag (depends on biller) (protocol version - 2) | No |
prev_counter, counter, tariff, subsidy, debt, attribute1, attribute2, attribute3 parameters are transferred if the corresponding tags in the received bill are not empty.
If a parameter is transferred, it must have a value (“empty” parameters are not allowed).
The invoiced amount entirely paid must be equal to the sum of the transferred amount and debt values for all items.
An example of request for company without items:
method=bills.pay&login=login&password=password&version=2&billId=value&amount=value
An example of request for company with items:
?method=bills.pay&login=login&password=password&billId=value&amount=value&
tariff_items[111111][id]=value&tariff_items[111111][counter]=value&
tariff_items[111111][prev_counter]=value&tariff_items[111111][tariff]=value&
tariff_items[111111][subsidy]=value&tariff_items[111111][debt]=value
where tariff_items – the name of the array with data on the items; 111111 – item ID; counter, prev_counter, tariff, subsidy, debt and amount – item data.
An example of successful response: see Attachment 1.
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.5. Information about a bill
Method: bills.get
Description of the method: This method is used when you need to get information about a bill. You need to send request l if the method bills.pay received a connection error, received a response of an unexpected format that does not match the protocol. And also if errors p009, p017, p100 are received. Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| billId | Bill ID (the value returned by the bills.create method) | Yes |
An example of request:
method=bills.get&login=login&password=password&version=2&billId=value
An example of successful response: see Attachment 1.
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.6. Transactions list
Method: bills.paymentOrder
Description of the method: the registry is transferred by the bank to Portmone.com to control the payments which were sent and to generate the necessary control registries to each organization using the required protocol. Contains a list of transactions and payment details of cover payment.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| xml | Registry in XML format | Yes |
An example of registry in XML format:
<?xml version="1.0" encoding="utf-8"?>
<payment_order order_date="DD.MM.YYYY" order_number="Number of payment order"
payee_id="ID of the payee company" total_amount="Amount of payments accepted"
total_compensation="Amount of compensations of payment order"
total_commission="Amount of commissions of payment order" trx_count="2">
<transactions>
<trx>
<bill_id>Bill ID</bill_id>
<trx_amount>Transaction amount</trx_amount>
<compensation>Amount transferred to biller</compensation>
</trx>
<trx>
<bill_id>Bill ID</bill_id>
<trx_amount>Transaction amount</trx_amount>
<compensation>Amount transferred to biller</compensation>
</trx>
</transactions>
</payment_order>
Where total_commission – the amount of the commissions of all transactions of the payment order, total_compensation – the amount of compensation for all transactions of this payment order. For each transaction (<trx>) commission = trx_amount - compensation.
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<paymentOrder>
<record id="value"/>
</paymentOrder>
</rsp>
Successful response – fields description:
| Parameter | Description |
|---|---|
| record id | Payment ID in the Portmone.com system that recorded this message |
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
Please note: if the transactions list for a date has not been transferred for any reason (communication timed out, an error message received from the PortmoneDirect system, etc.), this transactions list must be transferred to the next communication session along with the list for the current date.
2.7. Control registry of transactions
Method: bills.date
Description of the method: the method is used to obtain a control registry of transactions for a period (day). Required to control passed / non-passed transactions.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| date | Date for which the registry is displayed. Format: DD.MM.YYYY | Yes |
An example of request:
method=bills.date&login=login&password=password&version=2&date=DD.MM.YYYY
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<bills>
<bill id="value">
<name>Short name of the recipient company</name>
<contractNumber title="value">value</contractNumber>
<attribute1 title="value">value</attribute1>
<attribute2 title="value">value</attribute2>
<attribute3 title="value">value</attribute3>
<attribute4 title="value">value</attribute4>
<bill_attribute1>value</bill_attribute1>
<bill_attribute2>value</bill_attribute2>
<bill_attribute3>value</bill_attribute3>
<bill_attribute4>value</bill_attribute4>
<status>value</status>
<transaction_id>value</transaction_id>
<paidAmount>value</paidAmount>
<payDate>DD.MM.YYYY HH:mm:ss</payDate>
<payee_export_date>DD.MM.YYYY HH:mm:ss</payee_export_date>
<payee_export_flag>value</payee_export_flag>
<bank_commission>value</bank_commission>
<payee_id>value</payee_id>
</bill>
</bills>
</rsp>
Successful response – fields description:
| Parameter | Description |
|---|---|
| bill id | Bill ID (для транзакції устатусі RETURN, bill id набуває нового унікального значення) |
| сontractNumber title | Number of contract |
| status | Transaction status on the Portmone.com side. Possible values: PAYED, RETURN |
| transaction_id | The identifier assigned to the transaction by the partner bank (transferred when calling the bills.pay method). For transactions with RETURN status will take on the original transaction ID value (charge-off) |
| paidAmount | Amount of payment |
| payDate | Date of payment |
| payee_export_date | Date of funds transfer to the service provider |
| payee_export_flag | Transfer status (possible values: Y, N, R, E) |
| bank_commission | Bank remuneration in UAH (protocol version – 2). The parameter may takes both positive and negative values |
| name | Name of the recipient company |
| payee_id | A unique company identifier (protocol version – 3) |
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
An example of a transaction response in the RETURN status:
<bill id="1367371577"> - unique bill id upon return
<name>lifecell</name>
<contractNumber title="Phone number (without +380)">667678994</contractNumber>
<attribute1/>
<bill_attribute1/>
<attribute2/>
<bill_attribute2/>
<attribute3/>
<bill_attribute3/>
<attribute4/>
<bill_attribute4/>
<status>RETURN</status> - return status
<paidAmount>-5.00</paidAmount> - return amount, a negative value
<payDate>28.03.2023 16:04:01</payDate> - payment date
<transaction_id>1367371282</transaction_id> - bill ID of the original transaction for which the return was made
<payee_export_date>28.03.2023 16:04:01</payee_export_date> - return date and time
<payee_export_flag/>
<bank_commission>-0.50</bank_commission>
2.8. Control registry of funds transferred to the service provider
Method: bills.exported
Description of the method: the method is used to obtain a control registry of transactions for a period (day), the funds for which were sent to the service provider (biller). Required to control the binding of funds.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| payeeId | Company ID | Yes |
| date | Date for which the registry is displayed. Format: DD.MM.YYYY | Yes |
An example of request:
method=bills.exported&login=login&password=password&version=2&payeeId=value&date=DD.MM.YYYY
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<bills>
<bill id="value">
<contractNumber title="value">value</contractNumber>
<attribute1 title="value">value</attribute1>
<attribute2 title="value">value</attribute2>
<attribute3 title="value">value</attribute3>
<attribute4 title="value">value</attribute4>
<bill_attribute1>value</bill_attribute1>
<bill_attribute2>value</bill_attribute2>
<bill_attribute3>value</bill_attribute3>
<bill_attribute4>value</bill_attribute4>
<status>value</status>
<transaction_id>value</transaction_id>
<paidAmount>value</paidAmount>
<payDate>DD.MM.YYYY HH:mm:ss</payDate>
<payee_export_date>DD.MM.YYYY HH:mm:ss</payee_export_date>
<payee_export_flag>value</payee_export_flag>
</bill>
</bills>
</rsp>
Successful response – fields description:
| Parameter | Description |
|---|---|
| bill id | Bill ID |
| сontractNumber title | Number of contract |
| status | Transaction status on the Portmone.com side. Possible values: PAYED, RETURN |
| transaction_id | The identifier assigned to the transaction by the partner bank (transferred when calling the bills.pay method). For transactions with RETURN status will take of the original transaction ID value (charge-off) |
| paidAmount | Amount of payment |
| payDate | Date of payment |
| payee_export_date | Date of funds transfer to the service provider |
| payee_export_flag | Transfer status (possible values: Y, N, R, E) |
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.9. Request for data on the reseller company balance
Method: bills.balance
Description of the method: this method is used to view the current balance of the biller company (PAYEE).
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| payeeId | ID of the company for which the balance is requested | Yes |
An example of request:
method=bills.balance&login=login&password=password&version=2&payeeId=value
An example of successful response:
<?xml version="1.0" encoding="UTF-8"?>
<rsp status="ok">
<payee id="value">
<balance>value</balance>
</payee>
</rsp>
Successful response – fields description:
| Parameter | Description |
|---|---|
| payee id | ID of the company for which the balance is requested |
| balance | The balance of the company |
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.10. Request for information on available biller companies
Method: bills.payees
Description of the method: the method is used to get biller* (PAYEE) parameters. By default, all data on available companies at the current moment is downloaded. When adding the optional LastUpdateDate parameter, only data that has had any changes since the specified date.
When adding the additional parameter LastUpdateDate and deleted with the value on at the same time, only the company is deactivated starting from the date in the parameter LastUpdateDate
*from among those for whom payment terminals have been established for this login.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| LastUpdateDate | Date from which any changes were made. Format: DD.MM.YYYY | No |
| deleted | Deactivated companies | No |
An example of request:
1. method=bills.payees&login=login&password=password&version=2
2. method=bills.payees&login=логін&password=пароль&version=2&lastUpdateDate=DD.MM.YYYY
3. method=bills.payees&login=логін&password=пароль&version=2&lastUpdateDate=DD.MM.YYYY&deleted=on
Successful response structure:
<?xml version="1.0" encoding="UTF-8"?>
<rsp status="ok">
<payee id="value">
<header_payee> Used by some partners </header_payee>
<merchant> Used by some partners </merchant>
<terminal> Used by some partners </terminal>
<name> Short name of the recipient company (for menu items)</name>
<name_in_check> Legal name of the recipient company </name_in_check>
<image_file> Link to company logo </image_file>
<contact_info> The contact person </contact_info>
<zkpo> EDRPO code of the company </zkpo>
<bank_name> Bank name of the recipient company </bank_name>
<bank_code> MFO of the bank of the recipient company </bank_code>
<bank_account> Account number or IBAN of the recipient company bank
</bank_account>
<contract_number_title> Name of the 1st contract detail </contract_number_title>
<contract_number_type> Type of the 1st contract detail (N - numeric; C - string;
P – payment card; R, L - hierarchical dictionary) </contract_number_type>
<related_references>
<reference id="Dictionary ID" order_number="Order number">
Dictionary name</reference>
</related_references>
<contract_number_size> Size of the 1st contract detail </contract_number_size>
<contract_number_hint> Hint to the client for entering the first contract detail
</contract_number_hint>
<contract_number_mask> Input mask for the first contract detail
</contract_number_mask>
<attributes>
<attribute1>
<title> Attribute name </title>
<type> Attribute type (N - numeric; C - character; D - data;
R, L - hierarchical dictionary) </type>
<size> Maximum size </size>
<related_references>
<reference id="Dictionary ID" order_number="Order number">
Dictionary name</reference>
</related_references>
</attribute1>
<attribute2>
<title> Attribute name </title>
<type> Attribute type (N - numeric; C - character; D - data;
R, L - hierarchical dictionary) </type>
<size> Maximum size </size>
<related_references>
<reference id="Dictionary ID" order_number="Order number">
Dictionary name</reference>
</related_references>
</attribute2>
<attribute3>
<title> Attribute name </title>
<type> Attribute type (N - numeric; C - character; D - data;
R, L - hierarchical dictionary) </type>
<size> Maximum size </size>
<related_references>
<reference id="Dictionary ID" order_number="Order number">
Dictionary name</reference>
</related_references>
</attribute3>
<attribute4>
<title> Attribute name </title>
<type> Attribute type (N - numeric; C - character; D - data;
R, L - hierarchical dictionary) </type>
<size> Maximum size </size>
<related_references>
<reference id="Dictionary ID" order_number="Order number">
Dictionary name</reference>
</related_references>
</attribute4>
</attributes>
<min_pay_amount> The size of the minimum payment </min_pay_amount>
<pay_round_amount> Whether to allow payments with kopecks (Y - only whole sums,
N - allow sums with kopecks) </pay_round_amount>
<pay_different_amount> Whether to allow payment with the amount different from
that obtained in the bill (Y, N) </pay_different_amount>
<payee_group_id> ID of the type of services provided by biller </payee_group_id>
<payee_group_name> Type of services provided by biller </payee_group_name>
<bill_source> The company allows payment of bills (Y, N) (payment by
invoices) </bill_source>
<balance_source> The company allows the replenishment of the balance (Y, N)
(payment without invoice) </balance_source>
<pay_order_description_format> Pay order description format
</pay_order_description_format>
<billing_day> Date of loading bills(protocol version – 2) </billing_day>
<max_pay_amount> Maximum payment amount(protocol version – 2) </max_pay_amount>
<bank_tariff> Bank remuneration, which must be converted to a percentage
(protocol version – 2) </bank_tariff>
<bank_tariff (value with minus)>FC reward to be converted into interest
(protocol version – 2)</bank_tariff>
<bank_amount> Portmone remuneration in UAH (protocol version – 2) </bank_amount>
<min_bank_amount> The minimum amount of the Portmone remuneration from each
transaction, in UAH (protocol version – 2) </min_bank_amount>
<min_bank_amount (value with minus)>Not used (protocol version – 2)</min_bank_amount>
<max_bank_amount> Currently not used (protocol version – 2) </max_bank_amount>
<bank_deduction> Currently not used (protocol version – 2) </bank_deduction>
<bank_deduction_amount> Remuneration of the bank, which is held by the bank before
sending coverage. This value must be converted to percentage
(protocol version – 2) </bank_deduction_amount>
<min_bank_deduction_amount> Currently not used (protocol version – 2)
</min_bank_deduction_amount>
<max_bank_deduction_amount> Currently not used (protocol version – 2)
</max_bank_deduction_amount>
<hide> Recipient company that is not displayed to clients
(protocol version - 2)</hide>
<payee_groups>
<payee_group id="1001">Type of services provided by biller: Mobile Communication</payee_group>
<payee_group id="1003">Type of services provided by biller: Internet</payee_group>
<payee_group id="1006">Type of services provided by biller: telephony</payee_group>
</payee_groups> (protocol version – 3)
<payee_group_name> name of the group to which the service belongs </payee_group_name> (protocol version – 2 or more)
<service_in_check> the name of the service for the receipt </service_in_check> (protocol version – 2 or more)
</payee>
…
</rsp>
Note!
The<hide>parameter:
<hide>N</hide>- the main (front) company, designed to display the service for the client
<hide>Y</hide>- hidden service, hidden when displayed for the client
The parameter<image_file>must be analyzed only for the main (cap) companies on which `N `` is passed. The URL of the source from where the logo can be downloaded is specified in image_file.
Parameter<pay_different_amount>Whether to allow payment for an amount different from that received in the account (Y, N) (protocol version – 1)</pay_different_amount>
Important! in the absence of "universal" items (passed in thetariff_itemsarray) in the response to the bills.create/bills.createAll method (protocol version - 2 and more)</pay_different_amount>is analyzed by<pay_different_amount>
Dictionaries
For fields attribute1_type, attribute2_type, attribute3_type, attribute4_type, contract_number_type, values R and L are possible.
This means that the corresponding fields attribute1, attribute2, attribute3, attribute4, contract_number have a complex data type and the values of these fields must be formed on the basis of hierarchical directories.
That is, if any of the attribute1_type, attribute2_type, attribute3_type, attribute4_type, contract_number_type fields is either R or L, you must call bills.getreference method with the appropriate parameters to obtain the end hierarchy level and find the identifier / value of the dictionary item.
After that, use the bills.create method to create the bill with correct payment details. Use the identifier of the dictionary item (<item id>) obtained for the end dictionary level (for R-type field) or value (<name>) of the dictionary item (for L-type field) and send them at the appropriate request field (attribute1, attribute2, attribute3, attribute4, contract_number).
An example of the R-type dictionary:
<contract_number_type>R</contract_number_type>
<related_references>
<reference id="1180" order_number="1">
Регіон:
</reference>
<reference id="1183" order_number="2">
Найменування отримувача:
</reference>
<reference id="4308" order_number="3">
Населений пункт/район:
</reference>
</related_references>
where:
<related_references> – describes a hierarchy of dictionaries;
<reference id> – a unique dictionary identifier in the Portmone.com system (integer);
<reference order_number="1"> – dictionary sequence number in the hierarchy (ascending; integer);
<reference></reference> – name of the current dictionary level for the client (string).
For the L-type dictionary, the response will look the same, except for the value of the contract_number_type parameter.
Examples of using dictionaries are give in Section 5 "Examples" (Using R-type dictionaries, Using L-type dictionaries).
An example of successful response:
<?xml version="1.0" encoding="UTF-8"?>
<rsp status="ok">
...
<payee id="23782">
<header_payee>1185</header_payee>
<merchant>X</merchant>
<terminal>X</terminal>
<name>Єдиний податок з фіз. осіб підприємців</name>
<name_in_check>Платежі до бюджету</name_in_check>
<image_file>https://cdn-images.portmone.com.ua/company/128_128/9974.png</image_file>
<contact_info></contact_info>
<zkpo>00032129</zkpo>
<bank_name>АТ «Ощадбанк»</bank_name>
<bank_code>300465</bank_code>
<bank_account>29240000087016</bank_account>
<contract_number_title>Управление казначейства</contract_number_title>
<contract_number_type>R</contract_number_type>
<related_references>
<reference id="1180" order_number="1">Регіон:</reference>
<reference id="1183" order_number="2">Найменування отримувача:</reference>
<reference id="4308" order_number="3">Населений пункт/район:</reference>
</related_references>
<contract_number_size>4308</contract_number_size>
<attributes>
<attribute1>
<title>ІПН</title>
<type>N</type>
<size/>
</attribute1>
<attribute2>
<title>За період</title>
<type>L</type>
<size>4311</size>
<related_references>
<reference id="4310" order_number="1"parent_value="attribute1">Групи дитячіх садочків м. Київ</reference>
<reference id="4311" order_number="2 parent_value="attribute2">Вихованці дитячіх садочків м. Київ</reference>
</related_references>
</attribute2>
<attribute3>
<title>Період</title>
<type>N</type>
<size/>
</attribute3>
<attribute4>
<title>ФИО</title>
<type>C</type>
<size/>
</attribute4>
</attributes>
<min_pay_amount>1</min_pay_amount>
<pay_round_amount>N</pay_round_amount>
<pay_different_amount>N</pay_different_amount>
<payee_group_id>1100</payee_group_id>
<payee_group_name>Податки, платежі до бюджету</payee_group_name>
<bill_source>N</bill_source>
<balance_source>Y</balance_source>
<pay_order_description_format>(_____) Покриття по транзакцiям сплати рахункiв
через систему Portmone.com згiдно договору ____вiд____ на суму___
(_____) - код банку)</pay_order_description_format>
</payee>
...
</rsp>
parent_value- an optional parameter, passed in case the parent company uses linked dictionaries.header_payee- parameter for binding companies, passed only in the response to the bills.payees method. Indicates to which main company the current payee id belongs. The parameter exists only for protocol versions – 2, 3. For main companies, this field will be empty.
Please note When money transfer document contains two payment details (account number of the recipeient company bank and MFO of the bank), MFO of recipient's bank is transferred in the
bank_codefield. When the IBAN account number is used in payment details, a "0" (zero) is transferred in thebank_codefield.Recipient's bank account number or IBAN of a recipient (depending on payment details filled out in money transfer document) is transferred in the
bank_accountfield. Note that not only numbers but also letters will be contained in this field, according to the IBAN format (29 alphanumeric characters).The
merchantparameter will be transferred to Payany if the company provides services without a direct agreement.
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.11. Request for information on biller companies in the context of regions
Method: bills.regions
Description of the method: the method is used to obtain a list of available* regions and a list of billers (PAYEE) for each region.
*from among those for whom payment terminals have been established for this login.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
An example of request:
method=bills.regions&login=login&password=password&version=2
An example of successful response:
<?xml version="1.0" encoding="UTF-8"?>
<rsp status="ok">
<regions>
<region id="value">
<name>Name of the region (for example, Kyiv)</name>
<payees>
<payee id="value">
<name>Company name (for example, VOLIA Broadband, Kyiv)</name>
</payee>
…
</payees>
</region>
…
</regions>
</rsp>
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.12. Request for companies providing bills for a client, by a previously received bill
Method: bills.additionalPayees
Description of the method: this method is used to get a list of companies for which the client can pay bills. After a client has received the requested bill, you can request a list of companies and client IDs in these companies that provide services at the same address. If the returned list is not empty, you can offer a client to choose companies whose bills they want to pay and request these bills using the standard method. Companies search is carried out at the client's address.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| method | A name of the method | Yes |
| billId | Bill ID (the value returned by the bills.create method) | Yes |
An example of request:
method=bills.additionalPayees&login=login&password=password&version=2&billId=value
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<payee id="ID of the company whose bill can be offered to the client">
<contract_number> client’s ID in this company </contract_number>
<attribute1> additional client’s identifier in this company </attribute1>
<attribute2> additional client’s identifier in this company </attribute2>
<attribute3> additional client’s identifier in this company </attribute3>
<attribute4> additional client’s identifier in this company </attribute4>
</payee>
</rsp>
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.13. Request for information about regions
Method: search.regions
Description of the method: this method is used to obtain a complete list of regions of Ukraine.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
An example of request:
method=search.regions&login=login&password=password&version=2
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<regions>
<region id="44">
<name>м. Київ</name>
<orderIndex>1</orderIndex>
</region>
<region id="45">
<name>Київська область</name>
<orderIndex>2</orderIndex>
</region>
<region id="34">
<name>Івано-Франківська область</name>
<orderIndex>3</orderIndex>
</region>
<region id="43">
<name>Вінницька область</name>
<orderIndex>4</orderIndex>
</region>
<region id="33">
<name>Волинська область</name>
<orderIndex>5</orderIndex>
</region>
<region id="56">
<name>Дніпропетровська область</name>
<orderIndex>6</orderIndex>
</region>
<region id="62">
<name>Донецька область</name>
<orderIndex>7</orderIndex>
</region>
<region id="41">
<name>Житомирська область</name>
<orderIndex>8</orderIndex>
</region>
<region id="31">
<name>Закарпатська область</name>
<orderIndex>9</orderIndex>
</region>
<region id="61">
<name>Запорізька область</name>
<orderIndex>10</orderIndex>
</region>
<region id="52">
<name>Кіровоградська область</name>
<orderIndex>11</orderIndex>
</region>
<region id="64">
<name>Луганська область</name>
<orderIndex>12</orderIndex>
</region>
<region id="32">
<name>Львівська область</name>
<orderIndex>13</orderIndex>
</region>
<region id="51">
<name>Миколаївська область</name>
<orderIndex>14</orderIndex>
</region>
<region id="48">
<name>Одеська область</name>
<orderIndex>15</orderIndex>
</region>
<region id="53">
<name>Полтавська область</name>
<orderIndex>16</orderIndex>
</region>
<region id="36">
<name>Рівненська область</name>
<orderIndex>17</orderIndex>
</region>
<region id="54">
<name>Сумська область</name>
<orderIndex>18</orderIndex>
</region>
<region id="35">
<name>Тернопільська область</name>
<orderIndex>19</orderIndex>
</region>
<region id="57">
<name>Харківська область</name>
<orderIndex>20</orderIndex>
</region>
<region id="55">
<name>Херсонська область</name>
<orderIndex>21</orderIndex>
</region>
<region id="38">
<name>Хмельницька область</name>
<orderIndex>22</orderIndex>
</region>
<region id="47">
<name>Черкаська область</name>
<orderIndex>23</orderIndex>
</region>
<region id="37">
<name>Чернівецька область</name>
<orderIndex>24</orderIndex>
</region>
<region id="46">
<name>Чернігівська область</name>
<orderIndex>25</orderIndex>
</region>
</regions>
</rsp>
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.14. Request for information about regions (with a filter by region name)
Method: search.regionsExtended
Description of the method: this method is used to obtain a list of regions of Ukraine with additional filtering by region name.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| searchQuery | Substring for filtering by name (specify the part of region name, from 3 characters) | Yes |
An example of request:
method=search.regions&login=login&password=password&version=2&searchQuery=filter
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<regions>
<region id="44">
<name>м. Київ</name>
<orderIndex>1</orderIndex>
</region>
<region id="45">
<name>Київська область</name>
<orderIndex>2</orderIndex>
</region>
</regions>
</rsp>
An example of response in case of an error (if searchQuerry is not specified):
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="p019">
<![CDATA[ Server error while processing the request ]]>
</error>
<error_description>
<![CDATA[ search.regionsExtended p019 ]]>
</error_description>
</rsp>
2.15. Request for information about cities in the region
Method: search.citiesByRegion
Description of the method: this method is used to get a list of cities for the specified region.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| regionId | ID of the region obtained using the search.regions method or the search.regionsExtended method | Yes |
An example of request:
method=search.citiesByRegion&login=login&password=password&version=2®ionId=regionID
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<cities>
<city id="12">
<name>м. Бровари</name>
<orderIndex>8</orderIndex>
<regionId>45</regionId>
</city>
...
</cities>
</rsp>
Pay attention! The
city idparameter in the response may take negative values
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="p022">
<![CDATA[ Incorrect param regionId (citiesByRegion) ]]>
</error>
<error_description>
<![CDATA[ search.citiesByRegion p022 ]]>
</error_description>
</rsp>
2.16. Request for information about cities in the region (with a filter by city name)
Method: search.citiesByRegionExtended
Description of the method: this method is used to get a list of cities for the specified region with additional filtering by city name.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| regionId | ID of the region obtained using the search.regions method or the search.regionsExtended method | Yes |
| searchQuery | Substring for filtering by city name, from 3 characters | Yes |
An example of request:
method=search.citiesByRegionExtended&login=login&password=password&version=2®ionId=
regionID&searchQuery=filter
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<cities>
<city id="147">
<name>с. Киданівка</name>
<orderIndex>404</orderIndex>
<regionId>45</regionId>
</city>
<city id="1912">
<name>с. Кийлів</name>
<orderIndex>405</orderIndex>
<regionId>45</regionId>
</city>
<city id="-11929">
<name>с. Кип'ячка</name>
<orderIndex>406</orderIndex>
<regionId>45</regionId>
</city>
<city id="215">
<name>с. Кирдани</name>
<orderIndex>407</orderIndex>
<regionId>45</regionId>
</city>
<city id="-11931">
<name>с. Кириївщина</name>
<orderIndex>408</orderIndex>
<regionId>45</regionId>
</city>
<city id="239">
<name>с. Кислівка</name>
<orderIndex>409</orderIndex>
<regionId>45</regionId>
</city>
<city id="78">
<name>с. Кищинці</name>
<orderIndex>410</orderIndex>
<regionId>45</regionId>
</city>
</cities>
</rsp>
Pay attention! The
city idparameter in the response may take negative values
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.17. Request for information about the city streets
Method: search.streetsByCity
Description of the method: this method is used to get a list of streets for the specified city.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| cityId | ID of the city obtained using the search.citiesByRegion method or the search.citiesByRegionExtended method | Yes |
An example of request:
method=search.streetsByCity&login=login&password=password&version=2&cityId=cityID
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<streets>
<street id="662">
<name>бульвар Незалежності</name>
<orderIndex>36</orderIndex>
<cityId>12</cityId>
</street>
...
</streets>
</rsp>
Pay attention! The
street idparameter in the response may take negative values
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>
2.18. Request for information about the city streets (with a filter by street name)
Method: search.streetsByCityExtended
Description of the method: this method is used to get a list of streets for the specified city with additional filtering by street name.
Method parameters:
| Parameter | Description | Required |
|---|---|---|
| login | Your company login in the Portmone.com system | Yes |
| password | Your company password in the Portmone.com system | Yes |
| cityId | ID of the city obtained using the search.citiesByRegion method or the search.citiesByRegionExtended method | Yes |
| searchQuery | Substring for filtering by street name, from 3 characters | Yes |
An example of request:
method=search.streetsByCityExtended&login=login&password=password&version=2&cityId=cityID
&searchQuery=filter
An example of successful response:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="ok">
<streets>
<street id="3059">
<name>проспект Миколи Бажана</name>
<orderIndex>15</orderIndex>
<cityId>22</cityId>
</street>
...
</streets>
</rsp>
Pay attention! The
street idparameter in the response may take negative values
An example of response in case of an error:
<?xml version="1.0" encoding="utf-8"?>
<rsp status="fail">
<error code="Error code">Error description</error>
</rsp>