#Max--

1 messages · Page 1 of 1 (latest)

fading pilotBOT
vast falcon
#

Hello, did you debug to check what exception is being thrown that you are returning a 400 for?

still spear
#

How can I debug this PHP webhook? PHP is not my specialty but it's what is needed for one of my client

vast falcon
#

It would probably be best if you have a way to run this code locally in a debugger and place breakpoints inside of your catch statements

#

Otherwise you can try print statement debugging. You can put print statements throughout your code and see which ones get printed out when you get this issue

still spear
#

Thanks, I will be looking into this

still spear
#

@vast falcon I'm getting a Stack trace error here: $email_response = \Stripe\Email::create($email_params);

What do you think that could be the problem?

Event ID: evt_1MuKuxCx0zdgDXMarPnp6g8u

sonic needle
#

Hi 👋 my teammate needed to step away and I'm taking over. Is that your function you're calling from your code that is causing that error?

still spear
#

It looks like that function is the problem as the stack trace error appears there

#

It seems that the Stripe PHP library I used in the code contains deprecated methods or functions

#

What would you recommend doing?

sonic needle
#

If your goal is to send emails, then I would suggest building or finding a library that would help you do that.

I just searched through the revision history of our PHP library, and don't see any mention of email functionality being removed. As far as I'm aware we've not included email functionality in our libraries either, so I would also suggest making sure you're using our official library and not a third party one.
https://github.com/stripe/stripe-php

GitHub

PHP library for the Stripe API. . Contribute to stripe/stripe-php development by creating an account on GitHub.

still spear
#

Do you know if there's a way to send an email reminder through Stripe of an upcoming invoice 7 days before the invoice?

sonic needle
still spear
#

Will that automatically send an email 7 days before the client's subscription automatic payment?

fading pilotBOT
sonic needle
#

I believe those emails will be sent out based on the dropdown you select in the previous section (the one controlling how many days before a renewal the renewal Events get generated).