1 | <?php namespace Arcanedev\Stripe\Resources; |
||
23 | class ApplicationFeeRefund extends StripeResource implements ApplicationFeeRefundContract |
||
24 | { |
||
25 | /* ------------------------------------------------------------------------------------------------ |
||
26 | | Getters & Setters |
||
27 | | ------------------------------------------------------------------------------------------------ |
||
28 | */ |
||
29 | /** |
||
30 | * Get instance URL - The API URL for this Stripe refund. |
||
31 | * |
||
32 | * @return string |
||
33 | */ |
||
34 | 4 | public function instanceUrl() |
|
35 | { |
||
36 | 4 | $this->checkId($this['id']); |
|
37 | |||
38 | 2 | return implode('/', [ |
|
39 | 2 | self::classUrl(ApplicationFee::class), |
|
40 | 2 | urlencode(str_utf8($this['fee'])), |
|
41 | 2 | 'refunds', |
|
42 | 2 | urlencode(str_utf8($this['id'])) |
|
43 | ]); |
||
44 | } |
||
45 | |||
46 | /* ------------------------------------------------------------------------------------------------ |
||
47 | | Main Functions |
||
48 | | ------------------------------------------------------------------------------------------------ |
||
49 | */ |
||
50 | /** |
||
51 | * Update/Save an Application Fee Refund. |
||
52 | * |
||
53 | * @link https://stripe.com/docs/api/php#update_fee_refund |
||
54 | * |
||
55 | * @param array|string|null $options |
||
56 | * |
||
57 | * @return self |
||
58 | */ |
||
59 | public function save($options = null) |
||
63 | |||
64 | /* ------------------------------------------------------------------------------------------------ |
||
65 | | Check Functions |
||
66 | | ------------------------------------------------------------------------------------------------ |
||
67 | */ |
||
68 | /** |
||
69 | * Check if id is not empty. |
||
70 | * |
||
71 | * @param string $id |
||
72 | * |
||
73 | * @throws \Arcanedev\Stripe\Exceptions\InvalidRequestException |
||
74 | */ |
||
75 | 4 | protected function checkId($id) |
|
82 | } |
||
83 |