@@ -82,104 +82,112 @@ public function getByOrderId(string $orderId): Response
8282 * Endpoint para capturar um recurso `Payment`
8383 *
8484 * @param string $id
85+ * @param ?float $amount
8586 * @return Response
8687 *
8788 * @codeCoverageIgnore
8889 */
89- public function captureById (string $ id ): Response
90+ public function captureById (string $ id, ? float $ amount = null ): Response
9091 {
91- return $ this ->_POST ([], [ 'id ' => $ id ] , [], '/capture ' );
92+ return $ this ->_POST ([], compact ( 'id ' , ' amount ' ) , [], '/capture ' );
9293 }
9394
9495 /**
9596 * Endpoint para capturar um recurso `Payment`
9697 *
9798 * @param string $uuid
99+ * @param ?float $amount
98100 * @return Response
99101 *
100102 * @codeCoverageIgnore
101103 */
102- public function captureByUuid (string $ uuid ): Response
104+ public function captureByUuid (string $ uuid, ? float $ amount = null ): Response
103105 {
104- return $ this ->_POST ([], [ 'uuid ' => $ uuid ] , [], '/capture ' );
106+ return $ this ->_POST ([], compact ( 'uuid ' , ' amount ' ) , [], '/capture ' );
105107 }
106108
107109 /**
108110 * Endpoint para capturar um recurso `Payment`
109111 *
110112 * @param string $tid
113+ * @param ?float $amount
111114 * @return Response
112115 *
113116 * @codeCoverageIgnore
114117 */
115- public function captureByTid (string $ tid ): Response
118+ public function captureByTid (string $ tid, ? float $ amount = null ): Response
116119 {
117- return $ this ->_POST ([], [ 'tid ' => $ tid ] , [], '/capture ' );
120+ return $ this ->_POST ([], compact ( 'tid ' , ' amount ' ) , [], '/capture ' );
118121 }
119122
120123 /**
121124 * Endpoint para capturar um recurso `Payment`
122125 *
123- * @param string $orderId
126+ * @param string $order_id
127+ * @param ?float $amount
124128 * @return Response
125129 *
126130 * @codeCoverageIgnore
127131 */
128- public function captureByOrderId (string $ orderId ): Response
132+ public function captureByOrderId (string $ order_id , ? float $ amount = null ): Response
129133 {
130- return $ this ->_POST ([], [ 'order_id ' => $ orderId ] , [], '/capture ' );
134+ return $ this ->_POST ([], compact ( 'order_id ' , ' amount ' ) , [], '/capture ' );
131135 }
132136
133137 /**
134138 * Endpoint para cancelar um recurso `Payment`
135139 *
136140 * @param string $id
141+ * @param ?float $amount
137142 * @return Response
138143 *
139144 * @codeCoverageIgnore
140145 */
141- public function cancelById (string $ id ): Response
146+ public function cancelById (string $ id, ? float $ amount = null ): Response
142147 {
143- return $ this ->_POST ([], [ 'id ' => $ id ] , [], '/cancel ' );
148+ return $ this ->_POST ([], compact ( 'id ' , ' amount ' ) , [], '/cancel ' );
144149 }
145150
146151 /**
147152 * Endpoint para cancelar um recurso `Payment`
148153 *
149154 * @param string $uuid
155+ * @param ?float $amount
150156 * @return Response
151157 *
152158 * @codeCoverageIgnore
153159 */
154- public function cancelByUuid (string $ uuid ): Response
160+ public function cancelByUuid (string $ uuid, ? float $ amount = null ): Response
155161 {
156- return $ this ->_POST ([], [ 'uuid ' => $ uuid ] , [], '/cancel ' );
162+ return $ this ->_POST ([], compact ( 'uuid ' , ' amount ' ) , [], '/cancel ' );
157163 }
158164
159165 /**
160166 * Endpoint para cancelar um recurso `Payment`
161167 *
162168 * @param string $tid
169+ * @param ?float $amount
163170 * @return Response
164171 *
165172 * @codeCoverageIgnore
166173 */
167- public function cancelByTid (string $ tid ): Response
174+ public function cancelByTid (string $ tid, ? float $ amount = null ): Response
168175 {
169- return $ this ->_POST ([], [ 'tid ' => $ tid ] , [], '/cancel ' );
176+ return $ this ->_POST ([], compact ( 'tid ' , ' amount ' ) , [], '/cancel ' );
170177 }
171178
172179 /**
173180 * Endpoint para cancelar um recurso `Payment`
174181 *
175- * @param string $orderId
182+ * @param string $order_id
183+ * @param ?float $amount
176184 * @return Response
177185 *
178186 * @codeCoverageIgnore
179187 */
180- public function cancelByOrderId (string $ orderId ): Response
188+ public function cancelByOrderId (string $ order_id , ? float $ amount = null ): Response
181189 {
182- return $ this ->_POST ([], [ 'order_id ' => $ orderId ] , [], '/cancel ' );
190+ return $ this ->_POST ([], compact ( 'order_id ' , ' amount ' ) , [], '/cancel ' );
183191 }
184192
185193}
0 commit comments