6 * Class TransferReversal
9 * @property string $object
10 * @property int $amount
11 * @property string $balance_transaction
12 * @property int $created
13 * @property string $currency
14 * @property StripeObject $metadata
15 * @property string $transfer
19 class TransferReversal
extends ApiResource
22 const OBJECT_NAME
= "transfer_reversal";
24 use ApiOperations\Update
{
25 save
as protected _save
;
29 * @return string The API URL for this Stripe transfer reversal.
31 public function instanceUrl()
34 $transfer = $this['transfer'];
36 throw new Error\
InvalidRequest(
37 "Could not determine which URL to request: " .
38 "class instance has invalid ID: $id",
42 $id = Util\Util
::utf8($id);
43 $transfer = Util\Util
::utf8($transfer);
45 $base = Transfer
::classUrl();
46 $transferExtn = urlencode($transfer);
47 $extn = urlencode($id);
48 return "$base/$transferExtn/reversals/$extn";
52 * @param array|string|null $opts
54 * @return TransferReversal The saved reversal.
56 public function save($opts = null)
58 return $this->_save($opts);