Private
Company creation
New company registration in LiqPay for agent scheme

Forming a request to API for self-integration:
Example of using SDK:
#!/bin/bash
PUBLIC_KEY='your_public_key'
PRIVATE_KEY='your_private_key'
API_URL='https://www.liqpay.ua/api/request'
JSON="{ 
	\"action\" : \"agent_shop_create\",
    \"version\" : 3,
    \"public_key\" : \"${PUBLIC_KEY}\", 
    \"phone\" : \"380950000001\",
    \"order_id\" : \"order_id_1\",
    \"site\" : \"agent1.site.com\",
    \"description\" : \"site description\",
    \"email\" : \"email@gmail.com\",
    \"name\" : \"Site name\"
}"
# DATA is base64_encode result from JSON string
DATA=$(echo -n ${JSON} | base64)
# SIGNATURE is base64 encode result from sha1 binary hash from concatenate string ${PRIVATE_KEY}${DATA}${PRIVATE_KEY}
SIGNATURE=$(echo -n "${PRIVATE_KEY}${DATA}${PRIVATE_KEY}" | openssl dgst -binary -sha1 | base64)
# REQ is json response from liqpay
REQ=$(curl --silent -XPOST ${API_URL} --data-urlencode data="${DATA}" --data-urlencode signature="${SIGNATURE}")
echo "Result: ${REQ}"
$liqpay = new LiqPay($public_key, $private_key);
$res = $liqpay->api("request", array(
'action'         => 'agent_shop_create',
'version'        => '3',
'phone'          => '380950000001',
'site'           => 'agent1.site.com',
'description'    => 'site description',
'email'          => 'email@gmail.com',
'name'           => 'Site name',
'card'           => '4731195301524634',
'card_exp_month' => '03',
'card_exp_year'  => '22',
'card_cvv'       => '111'
));
HashMap<String, String> params = new HashMap<String, String>();
params.put("action", "agent_shop_create");
params.put("version", "3");
params.put("phone", "380950000001");
params.put("site", "agent1.site.com");
params.put("description", "site description");
params.put("email", "email@gmail.com");
params.put("name", "Site name");  
params.put("card", "4731195301524634");
params.put("card_exp_month", "03");
params.put("card_exp_year", "22");
params.put("card_cvv", "111");

LiqPay liqpay = new LiqPay(PUBLIC_KEY, PRIVATE_KEY);
HashMap<String, Object> res = liqpay.api("request", params);    
System.out.println(res.get("result"));
from liqpay import LiqPay

liqpay = LiqPay(public_key, private_key)
res = liqpay.api("request", {
"action"         : "agent_shop_create",
"version"        : "3",
"phone"          : "380950000001",
"site"           : "agent1.site.com",
"description"    : "site description",
"email"          : "email@gmail.com",
"name"           : "Site name",
"card"           : "4731195301524634",
"card_exp_month" : "03",
"card_exp_year"  : "22",
"card_cvv"       : "111"
})
liqpay = Liqpay::Liqpay.new(
:public_key  => 'public_key',
:private_key => 'private_key'
)
res = liqpay.api("request", {
:action         => "agent_shop_create",
:version        => "3", 
:phone          => "380950000001",    
:site           => "agent1.site.com",
:description    => "site description",
:email          => "email@gmail.com",
:name           => "Site name",
:card           => "4731195301524634",
:card_exp_month => "03",
:card_exp_year  => "22",
:card_cvv       => "111"
})
LiqPay = liqpay:init(PublicKey, PrivateKey),
Res = liqpay:api("request", [
{<<"action">>, <<"agent_shop_create">>},
{<<"version">>, <<"3">>}, 
{<<"phone">>, <<"380950000001">>}, 
{<<"site">>, <<"agent1.site.com">>}, 
{<<"description">>, <<"site description">>}, 
{<<"email">>, <<"email@gmail.com">>}, 
{<<"name">>, <<"Site name">>}, 
{<<"card">>, <<"4731195301524634">>}, 
{<<"card_exp_month">>, <<"03">>}, 
{<<"card_exp_year">>, <<"22">>}, 
{<<"card_cvv">>, <<"111">>}
], LiqPay).
var LiqPay = require('liqpay');
var liqpay = new LiqPay(public_key, private_key);
liqpay.api("request", {
"action"         : "agent_shop_create",
"version"        : "3",
"phone"          : "380950000001",
"site"           : "agent1.site.com",
"description"    : "site description",
"email"          : "email@gmail.com",
"name"           : "Site name",
"card"           : "4731195301524634",
"card_exp_month" : "03",
"card_exp_year"  : "22",
"card_cvv"       : "111"
}, function( json ){
console.log( json.result );
});
my $liqpay = Liqpay->new($public_key,$private_key);
my $res = $liqpay->api("request",
{
'action'         => 'agent_shop_create',
'version'        => '3',  
'phone'          => '380950000001',     
'site'           => 'agent1.site.com',
'description'    => 'site description',
'email'          => 'email@gmail.com',
'name'           => 'Site name',
'card'           => '4731195301524634',
'card_exp_month' => '03',
'card_exp_year'  => '22',
'card_cvv'       => '111'
}
);
Init("my_public_key", "my_private_key")
Api("request", map[string]interface{}{
    "action": "agent_shop_create",
    "version": 3,
    "public_key": "PublicKey", 
    "phone": "380950000001",
    "card": "4731195301524634",
    "card_exp_month": "03",
    "card_exp_year": "22",
    "card_cvv": "111",
    "site": "agent1.site.com",
    "description": "site description",
    "email": "email@gmail.com",
    "name": "Site name",
})
Options for generating data:
Main
Parameter Required Type Description
version Required Number Version API. Current value - 3
public_key Required String Public key - the store identifier. You can get the key in the store settings
action Required String agent_shop_create
description Required String Store description
email Required String Store email
name Required String Store name
phone Required String Shop phone number
site Required String Store URL
iban Required** String IBAN to receive payments in this store. Maximum length 34 symbols
company Required** String Account name
okpo Required** String OKPO account
amount_procent_agent Optional Number Agent fee in %
amount_static_agent Optional* Number Agent static fee
currency_static_agent Optional* String Currency of agent static fee
can_reports Optional String Allows the owner of the main company to view the payment history of the created company, pass the value true
can_checkout_edit Optional String Allows the owner of the main company to edit the payment page settings of the company created, pass the value true
logo Optional String URL shop logo
public_phone Optional String Shop public phone number
Parameters for aggregators
Enter info about enterprise for which the company is being created
law_okpo Required String USREOU of an enterprise. The maximum length is 255 characters
law_name Optional* String Enterprise name. The maximum length is 255 characters
law_contacts Optional* Object Contact details of an enterprise
law_cto_info Optional* Object Information about the head of an enterprise
law_owners_info Optional* Array Information about owners of an enterprise
law_co_owners_info Optional* Array Information about owners of major shareholding
* Parameters required for clients that are not registered in PrivatBank
Contact details of an enterprise (object law_contacts)
phone Optional String Contact number of an enterprise
email Optional String Contact email of an enterprise
Info about the head of an enterprise (object law_cto_info)
name Optional String Full name of the head of an enterprise
inn Optional String TIN of the head of an enterprise
birth_date Optional String Birth date of the head of an enterprise. Enter the date in this format: 2015-03-31
citizenship Optional String Nationality of the head of an enterprise. Enter the country in Latin letters. Example: Ukraine
Info about the owner(s) of an enterprise (array law_cto_info)
You can transfer up to three objects with data about owners to an array.
name Optional String Full name of the owner of an enterprise
inn Optional String TIN of the owner of an enterprise
birth_date Optional String Birth date of the owner of an enterprise. Enter the date in this format: 2015-03-31
citizenship Optional String Nationality of the owner of an enterprise. Enter the country in Latin letters. Example: Ukraine
share_in_capital Optional String The ownership interest in the authorized capital of an enterprise
Information about the owner (s) of significant participation (array law_co_owners_info)
You can transfer up to ten objects with data about owners of major shareholding to an array
name Optional String Full name of the owner of major shareholding. Transfer if the owner is an individual
inn Optional String TIN of the owner of major shareholding. Transfer if the owner is an individual
birth_date Optional String Birth date of the owner of major shareholding. Transfer if the owner is an individual
citizenship Optional String Nationality of the owner of major shareholding. Enter the country in Latin letters. Example: Ukraine. Transfer if the owner is an individual
share_in_capital Optional String The size of the ownership interest. Transfer for both individuals and legal entities
company_name Optional String Enterprise name. The maximum length is 255 characters. Transfer if the owner is a legal entity
company_okpo Optional String USREOU of an enterprise. The maximum length is 255 characters. Transfer if the owner is a legal entity
Example response:
{
"status": "success",
"public_key": "i000000000",
"private_key": "wGsqoko5412LcD0vB215XK2wQSgLDVBrsaPIRi6"
}
Response parameters
Parameter Type Description
private_key String Company private_key
public_key String Shop public key
status String Payment status.
Available values:
Final payment statuses
error Failed payment. Data is incorrect
failure Failed payment
success Successful payment
Statuses that required payment confirmation
3ds_verify 3DS verification is required.
To finish the payment you will require a 3ds_verify
cvv_verify Sender's card CVV is required.
To finish the payment you will require a cvv_verify
otp_verify OTP confirmation is required. OTP is sent to a customer phone number.
To finish the payment it is required otp_verify