forked from LiveCarta/PayPal-PHP-SDK
Added invoice samples
This commit is contained in:
22
sample/invoicing/ListInvoice.php
Normal file
22
sample/invoicing/ListInvoice.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
require __DIR__ . '/../bootstrap.php';
|
||||
use PayPal\Api\Invoice;
|
||||
|
||||
try {
|
||||
$invoices = Invoice::get_all($apiContext);
|
||||
} catch (PayPal\Exception\PPConnectionException $ex) {
|
||||
echo "Exception:" . $ex->getMessage() . PHP_EOL;
|
||||
var_dump($ex->getData());
|
||||
exit(1);
|
||||
}
|
||||
?>
|
||||
<html>
|
||||
<head>
|
||||
<title>Lookup invoice history</title>
|
||||
</head>
|
||||
<body>
|
||||
<div>Got invoices </div>
|
||||
<pre><?php var_dump($invoices->toArray());?></pre>
|
||||
<a href='../index.html'>Back</a>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user