コード例 #1
0
 */
$card = new Card('4111111111111111', '12', 2016, 123, 'Card Owner Name');
/**
 * Create new Request with params:
 *
 * Config object
 * Order object
 * Billing object
 * Delivery (or Billing object again, if you want to have the delivery address the same as the billing address)
 * User object
 */
$request = new Request($cfg, $order, $billing, $delivery, $user);
/**
 * Add the Credit Card to the Request
 */
$request->setCard($card);
/**
 * Create new API Client, passing the Config object as parameter
 */
$client = new Client($cfg);
/**
 * Will throw different Exceptions on errors
 */
try {
    /**
     * Sends the Request to ALU and returns a Response
     *
     * See documentation for Response params
     */
    $response = $client->pay($request);
    /**