Skip to main content

BLIK Pay Later

info

This payment method is not available by default. To enable it, you must activate it in the CashBill customer panel and complete the verification process.

With BLIK Pay Later (BLIK Płacę Później), customers can buy online now and pay within 30 days. To use it, customers choose BLIK Pay Later at checkout, enter a BLIK code and activate the service in their banking app. Online stores can offer it to give customers the option to buy now and pay later.

The service is available through participating banks and online stores. Approval and the available limit depend on the financing provider’s assessment. Late repayment may result in interest charges.

BLIK Pay Later uses the standard transaction implementation. To direct the customer to the BLIK Pay Later payment page, set paymentChannel to blik_7515_BL when creating the transaction, then redirect the customer's browser to the redirectUrl returned by the API.

The customer completes the BLIK Pay Later payment flow on the payment page.

Example request​

<?php

$shopId = ""; // Payment Point ID
$secretPhrase = ""; // Payment Point Secret
$mainUrl = "https://pay.cashbill.pl/ws/rest";

$transactionRequest = array(
"title" => "Example BLIK Pay Later #1",
"amount" => array(
"value" => 1.23,
"currencyCode" => "PLN",
),
"returnUrl" => "https://cashbill.pl",
"description" => "Transaction description example",
"additionalData" => "#1",
"paymentChannel" => "blik_7515_BL",
);

$transactionRequest['sign'] = sha1(
$transactionRequest['title']
. $transactionRequest['amount']['value']
. $transactionRequest['amount']['currencyCode']
. $transactionRequest['returnUrl']
. $transactionRequest['description']
. $transactionRequest['additionalData']
. $transactionRequest['paymentChannel']
. $secretPhrase
);

$ch = curl_init();
curl_setopt_array($ch, array(
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_URL => "{$mainUrl}/payment/{$shopId}",
CURLOPT_HTTPHEADER => array("Content-Type: application/json"),
CURLOPT_POSTFIELDS => json_encode($transactionRequest),
));

$ret = curl_exec($ch);
$response = json_decode($ret);

if (curl_getinfo($ch, CURLINFO_HTTP_CODE) != "200") {
echo "Error message: {$response->errorMessage}";
} else {
echo "Order ID [{$response->id}] and redirect URL [{$response->redirectUrl}]";
}

Schema of the response​

{
"id": "string",
"redirectUrl": "string"
}

Use id to identify the transaction and redirectUrl to redirect the customer to the BLIK Pay Later payment page. Process transaction status updates using the standard notification service.