ReaderService.php 978 B

1234567891011121314151617181920212223242526272829
  1. <?php
  2. // File generated from our OpenAPI spec
  3. namespace Stripe\Service\TestHelpers\Terminal;
  4. /**
  5. * @phpstan-import-type RequestOptionsArray from \Stripe\Util\RequestOptions
  6. * @psalm-import-type RequestOptionsArray from \Stripe\Util\RequestOptions
  7. */
  8. class ReaderService extends \Stripe\Service\AbstractService
  9. {
  10. /**
  11. * Presents a payment method on a simulated reader. Can be used to simulate
  12. * accepting a payment, saving a card or refunding a transaction.
  13. *
  14. * @param string $id
  15. * @param null|array $params
  16. * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
  17. *
  18. * @throws \Stripe\Exception\ApiErrorException if the request fails
  19. *
  20. * @return \Stripe\Terminal\Reader
  21. */
  22. public function presentPaymentMethod($id, $params = null, $opts = null)
  23. {
  24. return $this->request('post', $this->buildPath('/v1/test_helpers/terminal/readers/%s/present_payment_method', $id), $params, $opts);
  25. }
  26. }