Private
Server-server card payment
Receiving payment from the customer on your site without the customer go to the payment page

Scheme of API server-server card payment
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\" : \"pay\",
	\"version\" : 3,
	\"public_key\" : \"${PUBLIC_KEY}\", 
	\"phone\" : \"380950000001\", 
	\"amount\" : \"1\", 
	\"currency\" : \"USD\", 
	\"description\" : \"description text\", 
	\"order_id\" : \"order_id_1\", 
	\"card\" : \"4731195301524634\", 
	\"card_exp_month\" : \"03\", 
	\"card_exp_year\" : \"22\", 
	\"card_cvv\" : \"111\"
}"
# 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'         => 'pay',
	'version'        => '3',
	'phone'          => '380950000001',
	'amount'         => '1',
	'currency'       => 'USD',
	'description'    => 'description text',
	'order_id'       => 'order_id_1',
	'card'           => '4731195301524634',
	'card_exp_month' => '03',
	'card_exp_year'  => '22',
	'card_cvv'       => '111'
));
HashMap<String, String> params = new HashMap<String, String>();
params.put("action", "pay");
params.put("version", "3");
params.put("phone", "380950000001");
params.put("amount", "1");
params.put("currency", "USD");
params.put("description", "description text");
params.put("order_id", "order_id_1"); 
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("status"));
  
liqpay = LiqPay(public_key, private_key)
res = liqpay.api("request", {
	"action"         : "pay",
	"version"        : "3",
	"phone"          : "380950000001",
	"amount"         : "1",
	"currency"       : "USD",
	"description"    : "description text",
	"order_id"       : "order_id_1",
	"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         => "pay",
	:version        => "3",
	:phone          => "380950000001",
	:amount         => "1",
	:currency       => "USD",
	:description    => "description text",
	:order_id       => "order_id_1",
	:card           => "4731195301524634",
	:card_exp_month => "03",
	:card_exp_year  => "22",
	:card_cvv       => "111"
})
LiqPay = liqpay:init(PublicKey, PrivateKey),
Res = liqpay:api("request", [
	{<<"action">>,         <<"pay">>}, 
	{<<"version">>,        <<"3">>}, 
	{<<"phone">>,          <<"380950000001">>}, 
	{<<"amount">>,         <<"1">>}, 
	{<<"currency">>,       <<"USD">>}, 
	{<<"description">>,    <<"description text">>}, 
	{<<"order_id">>,       <<"order_id_1">>}, 
	{<<"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"         : "pay",
	"version"        : "3",
	"phone"          : "380950000001",
	"amount"         : "1",
	"currency"       : "USD",
	"description"    : "description text",
	"order_id"       : "order_id_1",
	"card"           : "4731195301524634",
	"card_exp_month" : "03",
	"card_exp_year"  : "22",
	"card_cvv"       : "111"
}, function( json ){
	console.log( json.status );
});
my $liqpay = Liqpay->new($public_key,$private_key);
my $res = $liqpay->api("request",
	{
	'action'         => 'pay',
	'version'        => '3',
	'phone'          => '380950000001',
	'amount'         => '1',
	'currency'       => 'USD',
	'description'    => 'description text',
	'order_id'       => 'order_id_1',
	'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": "pay",
    "version": 3,
    "public_key": PublicKey,
    "phone": "380950000001",
    "amount": 1,
    "currency": "UAH",
    "description": "Test payment",
    "order_id": "order_id_1",
    "card": "4731195301524634",
    "card_exp_month": "03", 
    "card_exp_year": "22", 
    "card_cvv": "111",
    //split if needed
    "split_rules": []interface{}{
        map[string]interface{}{
            "public_key": PublicKey,
            "amount": 0.1,
        },
        map[string]interface{}{
            "public_key": PublicKey,
            "amount": 0.2,
        },
    },
})
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 pay
amount Required Number Payment amount. For example: 5, 7.34
card Required String Card number of the payer
card_cvv Optional String CVV/CVV2. The parameter is required if the card number is being passed
card_exp_month Optional String Expiry month of the payer's card. For example: 08. This parameter is required if the card number or an unencrypted token is being passed
card_exp_year Optional String Expiry year of the payer's card.For example: 19. This parameter is required if the card number or an unencrypted token is being passed
currency Required String Payment currency. Possible values: USD, EUR, RUB, UAH
description Required String Payment description.
order_id Required String Unique purchase ID in your shop. Maximum length is 255 symbols.
phone Required String Payer's mobile phone. One time password will be sent to the number to confirm the payment. Mobile number should be in the international format (Ukraine +380, Russia +7). For example: +380950000001 (with +) or 380950000001 (without +)
paytype Optional String Payment type. Possible values: apay — payment using an encrypted Apple token, gpay — payment using an encrypted Google token, apay_tavv — payment using an unencrypted Apple token, gpay_tavv — payment using an unencrypted Google token, tavv — payment using an unencrypted token of international payment systems (MasterCard, Visa). This parameter is required for payments using encrypted and unencrypted tokens
tavv Optional String A cryptogram is a dynamic one-time code for every transaction accompanying a token. This parameter is required when making a payment using unencrypted tokens by Apple, Google, international payment systems (MasterCard, Visa)
tid Optional String Previous transaction ID. For recurring payments using tokens of Visa international payment system
language Optional String Customer's language ru, uk, en
prepare Optional String The preliminary preparation of the payment. This mode allows you to determine whether all data is complete, whether 3DS is required to check the card, whether the limit is exceeded. The funds are not debited from the payer's card. To activate the mode, you need to transfer the value of 1, and to work with DCC (dynamic currency conversion) - the value of tariffs
recurringbytoken Optional String This parameter allows to generate payer card_token which you receive in callback request to server_url. card_token allows to make recurring payments without payer card requisites using API paytoken. To receive card_token please send in request value: 1
result_url Optional String URL of your shop where the buyer would be redirected after completion of the purchase. Maximum length 510 symbols.
recurring Optional Boolean Token recurring payment flag. Used for payments with tokens of international payment systems (MasterCard, Visa). Possible values: true — the operation is performed without the participation of the client, false — the operation is performed by the client
server_url Optional String URL API in your store for notifications of payment status change (server->server). Maximum length is 510 symbols. Learn more
tavv Required String Token reference received from decrypting apple device data
Parameters of splitting the payments
split_rules Optional String Payment with split amount for a few receivers. This parameter is a JSON array containing split rules. While using split_rules parameter, card is being charged and amount is split and credited to a few receivers. Acquiring fee is being charged from each shop in the split_rules. Example JSON string:
[
  {
    "public_key": "i000000001",
    "amount": 1,
    "commission_payer": "sender",
    "server_url": "https://server1/callback"
  },
  {
    "public_key": "i000000002",
    "amount": 2,
    "commission_payer": "receiver",
    "server_url": "https://server2/callback"
  }
]
Sender parameters
sender_address NEW Optional String Sender's address
sender_city Optional String Sender's city
sender_country_code Optional String Country code of the sender. Digital ISO 3166-1 code
sender_first_name Optional String Sender's first name
sender_last_name Optional String Sender's last name
sender_postal_code Optional String Sender's zip code
3DS parameters
mpi_md Optional String Parameter that returns from ACS MD.
This parameter is transmitted only in case when is used the API MPI
mpi_pares Optional String Parameter that returns from ACS pares.
This parameter is transmitted only in case when is used the API MPI
Letter of credit parameters
letter_of_credit Optional String To enable receipt of payments within letter of credit send request with the value1
letter_of_credit_date Optional String The expiry date of the letter of credit in the following format 2015-03-31 00:00:00 by UTC.
Regular payment parameters
subscribe Optional String Regular payment. Possible values: 1
subscribe_date_start Optional String Date of the first payment. Time must be specified in the following format 2015-03-31 00:00:00 по UTC. If past date is indicated - subscription will be activated with the date and time of request
subscribe_periodicity Optional String Period of payments. Possible values:
month - once in a month
year - once in a year
Other parameters
customer Optional String Unique customer ID in your shop. Max length 100 symbols.
dae Optional String Detail Addenda.
Parameter dae is JSON string, to which function base64. JSON can contain the following parameters:
{
  "airLine": "Avia", // airline abbreviation, max 4 symbols.
  "ticketNumber": "ACSFD12354SA", // ticket number, max 15 symbols. 
  "passengerName": "John Doe", // passenger name, max 29 symbols.
  "flightNumber": "742", // flight number, max 5 number.
  "originCity": "DP", // departure city/airport code, max 5 symbols.
  "destinationCity": "NY", // arrival city/airport code, max 5 symbols.
  "departureDate": "100514" // departure date in format YYMMDD, max 6 number.
}
Example of parameter dae: ewogICJhaXJMaW5lIjogIkROSVBST0FWSUEiLAogICJ0aWNrZXROdW1iZXIiOiAiQUNTRkQxMjM1NFNBIiwKICAicGFzc2VuZ2VyTmFtZSI6ICJKb2huIERvZSIsCiAgImZsaWdodE51bWJlciI6ICI3NDIiLAogICJvcmlnaW5DaXR5IjogIkRQIiwKICAiZGVzdGluYXRpb25DaXR5IjogIk5ZIiwKICAiZGVwYXJ0dXJlRGF0ZSI6ICIxMDA1MTQiCn0=
info Optional String Information to add details to payment. For example: "External information for payments"
product_category Optional String Product category in your shop. The maximum length is 25 symbols.
product_description Optional String Product description in your shop. The maximum length is 500 symbols.
product_name Optional String Product name in your shop. The maximum length is 100 symbols.
product_url Optional String Product page address. The maximum length is 2000 symbols.
Example response:
{
  "action": "pay",
  "payment_id": 165172,
  "status": "success",
  "version": 3,
  "type": "buy",
  "paytype": "card",
  "public_key": "i000000000",
  "acq_id": 414963,
  "order_id": "98R1U1OV1485849059893399",
  "liqpay_order_id": "NYMK3AE61501685438251925",
  "description": "description",
  "sender_phone": "380950000001",
  "sender_first_name": "first_name",
  "sender_last_name": "last_name",
  "sender_card_mask2": "473118*50",
  "sender_card_bank": "pb",
  "sender_card_type": "visa",
  "sender_card_country": 804,
  "dcc_allowed": [{
    "amount": 3.5984,
    "rate": 27.7905,
    "commission": 0.0,
    "currency": "USD"
  }],
  "ip": "8.8.8.8",
  "card_token": "CDRES215658546306B200061FCC53A86B",
  "amount": 100.0,
  "currency": "UAH",
  "sender_commission": 0.0,
  "receiver_commission": 0.0,
  "agent_commission": 0.0,
  "amount_debit": 100.0,
  "amount_credit": 100.0,
  "commission_debit": 0.0,
  "commission_credit": 0.0,
  "currency_debit": "UAH",
  "currency_credit": "UAH",
  "sender_bonus": 0.0,
  "amount_bonus": 0.0,
  "bonus_type": "bonusplus",
  "bonus_procent": 0.0,
  "authcode_debit": "388000",
  "authcode_credit": "329007",
  "rrn_debit": "000663747000",
  "rrn_credit": "000663747003",
  "mpi_eci": "7",
  "is_3ds": false,
  "create_date": 1501685446633,
  "end_date": 1501685446633,
  "transaction_id": 165172
}
Response parameters
Parameter Type Description
acq_id Number Acquirer ID
action String Transaction type. Possible values: pay - payment, hold - amount of hold on sender's account, paysplit - splitting payments, subscribe - creation of a regular payment, paydonate - donation, auth - card preauth, regular - regular payment
agent_commission Number Agent comission in payment currency
amount Number Payment amount
amount_bonus Number Payer bonus amount in payment currency debit
amount_credit Number Payment amount for credit in currency of currency_credit
amount_debit Number Payment amount for debit in currency of currency_debit
authcode_credit String Authorization code for transaction of credit
authcode_debit String Authorization code for transaction of debit
bonus_procent Number Discount rate in percent
bonus_type String Bonus type, possible values ​​of bonusplus, discount_club, personal, promo
card_token String Sender's card token
commission_credit Number Commission from the receiver in currency_credit
commission_debit Number Commission from the sender in currency_debit
create_date String Date of payment creation
currency String Payment currency
currency_credit String Transaction currency of credit
currency_debit String Transaction currency of debit
description String Payment description
end_date String Date of payment edition/end
ip String sender's IP address
is_3ds Boolean Possible values:
true - transaction passed with 3DS,
false - transaction passed without 3DS
liqpay_order_id String Payment order_id in LiqPay system
mpi_eci Number Possible values: 5 - the transaction passed with 3DS (issuer and acquirer support 3d Secure technology), 6 - the issuer of the payer card does not support 3d Secure technology, 7 - the operation passed without 3d Secure
order_id String Order_id payment
payment_id Number Payment id in LiqPay system
paytype String Methods of payment. Possible values card - card payment, liqpay - with liqpay account, privat24 - with privat24 account, masterpass - with masterpass account, moment_part - installments, cash - cash, invoice - to email, qr - qr code scanning.
public_key String Shop public key
receiver_commission Number Receiver comission in payment currency
status String Possible meaning: activated - the store is activated with refund, wait_accept - the store is activated without refund
rrn_credit String Unique transaction ID in authorization and settlement system of issuer bank Retrieval Reference number
rrn_debit String Unique transaction ID in authorization and settlement system of issuer bank Retrieval Reference number
sender_bonus Number Sender's bonus in the payment currency
sender_card_bank String Sender's card bank
sender_card_country String Sender's card country. Digital ISO 3166-1 code
sender_card_mask2 String Sender's card
sender_card_type String Sender's card type MC/Visa
sender_commission Number Commission from the sender in the payment currency
sender_first_name String The name of the sender
sender_last_name String sender's last name
sender_phone String Sender's phone number
status String Payment status.
Available values:
Final payment statuses
error Failed payment. Data is incorrect
failure Failed payment
reversed Payment refunded
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
receiver_verify Receiver additional data is required.
To finish the payment you will require a receiver_verify
sender_verify Sender's additional data is required.
To finish the payment you will require a sender_verify
Other payment statuses
wait_accept Money are withdrawn from client but the store is still not verified. If the store is not activated for 90 days, payment will be automatically cancelled
wait_secure Payment is verified
transaction_id Number Id transactions in the LiqPay system
type String Payment type
version Number Version API. Present value - 3