0

I have a curl request example, it is working once I'm checking it with command line.

curl https://api.stripe.com/v1/payment_intents/search -u secret key: --data-urlencode query="status:'succeeded' AND metadata['order #']:'1000210589'" -G

I'm trying to convert this code in Magento. I have to use the GET method. I would like to know how we can pass these following options in Magento code.

--data-urlencode

query="status:'succeeded' AND metadata['order #']:'1000210589'"*

If you know something, please let me know your comments and suggestions. Thank You.

1 Answer 1

0

In your case I suggest to install Stripe PHP bindings library with composer and use it for communications with Stripe

$stripe = new \Stripe\StripeClient(
  'YOUR_SECRET'
);
$stripe->paymentIntents->search([
  'query' => 'status:\'succeeded\' AND metadata[\'order #\']:\'1000210589\'',
]);

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.