Skip to content

Latest commit

 

History

History
30 lines (22 loc) · 858 Bytes

README.md

File metadata and controls

30 lines (22 loc) · 858 Bytes

IPay Unoffical Client

static analysis tests

<?php

declare(strict_types=1);

use IPay\Enum\TransactionType;
use IPay\IPayClient;

require __DIR__.'/vendor/autoload.php';

try {
    $session = IPayClient::fromCredentials('username', 'password');

    $transactions = $session->transactions()
        ->type(TransactionType::CREDIT)
        ->today()
        ->getIterator();

    foreach ($transactions as $transaction) {
        echo $transaction->remark.PHP_EOL;
    }
} catch (Throwable $e) {
    echo $e->getMessage();
}