PHP code example of selyakovadim / paykassa

1. Go to this page and download the library: Download selyakovadim/paykassa library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

selyakovadim / paykassa example snippets


$api = new Paykassa\PaykassaApi($api_id, $api_key);
$sci = new Paykassa\PaykassaSci($sci_id, $sci_key);

$api = new Paykassa\PaykassaApi();
$sci = new Paykassa\PaykassaSci();

$balance = $api->getBalance($shop_id)

$response = $api->makePayment([
    'shop' => 999,
    'system' => 1,
    'number' => 'P123456',
    'amount' => 100,
    'currency' => 'USD',
    'comment' => 'Payment #654',
]);

$address = $sci->getAddress([
    'system' => 11,
    'currency' => 'BTC',
    'order_id' => 100500,
    'comment' => 'Invoice #100500',
    'amount' => 100
]);

$invoice = $sci->getInvoice([
    'system' => 1,
    'currency' => 'USD',
    'order_id' => 100500,
    'comment' => 'Invoice #100500',
    'amount' => 100
]);

$response = $sci->checkPayment($payment_hash);