1. Go to this page and download the library: Download mews/pos 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/ */
mews / pos example snippets
// 1. Banka hesabı oluşturunuz (her banka için farklı bir factory metodu vardır)
$account = \Mews\Pos\Factory\AccountFactory::createAkbankPosAccount(
'akbank-pos',
'MERCHANT_SAFE_ID',
'TERMINAL_SAFE_ID',
'SECRET_KEY'
);
// 2. Event dispatcher oluşturunuz (symfony/event-dispatcher önerilir)
// Elinizde farklı PSR-14 uygumlu EventDispatcher var ise kullanabilirsiniz.
$eventDispatcher = new \Symfony\Component\EventDispatcher\EventDispatcher();
// 3. Ayarları yükleyip ilgili bankanın dilimini alınız
$yeniAyarlar =