関数
Close::delete( string $chargePermissionId, string $closureReason, bool $cancelPendingCharges = false )
Closes a Charge Permission
説明 説明
- $chargePermissionId
(文字列) (必須) Charge Permission ID
- $closureReason
(文字列) (必須)
- $cancelPendingCharges
(bool) (任意)
ファイル: src/API/ChargePermission/Close.php
public function delete($chargePermissionId, $closureReason, $cancelPendingCharges = false) { try { $client = $this->module->getAmazonClient(); $result = $client->closeChargePermission($chargePermissionId, [ 'closureReason' => $closureReason, 'cancelPendingCharges' => $cancelPendingCharges, ]); if ($this->module->errors->hasError($result)) { return $this->module->errors->getAmzErrorResponse($result); } } catch (\Exception $e) { return $this->module->errors->getErrorResponse( GenericErrorStore::AMAZON_PAY_SDK_CLIENT_EXCEPTION, [$e->getMessage()] ); } return $result; }