The API responds with events, but it’s not respecting my parameters in $eventParams. It’s like the CURLOPT_POSTFIELDS setting is being ignored. Any ideas what I’m doing wrong here? Thanks for any help!
I’ve encountered a similar issue when working with Mailgun’s API. The problem lies in how you’re passing the parameters. For GET requests, you need to append the parameters to the URL instead of using CURLOPT_POSTFIELDS.
This should properly include your parameters in the GET request. Also, ensure your API key and domain are correct. If you’re still having issues, double-check Mailgun’s documentation for any recent changes to their API endpoints or parameter names.
I’ve dealt with this exact problem before when integrating Mailgun’s API. The issue is that you’re using CURLOPT_POSTFIELDS for a GET request, which doesn’t work as expected. Instead, you need to build the query string into the URL.
This approach ensures your parameters are properly sent with the GET request. Also, double-check that your API key has the necessary permissions to access event data. If you’re still having trouble, Mailgun’s support team is quite responsive and can help troubleshoot further.