You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// from a webhook handlerurl:=r.PostFormValue("message-url")
urlp:=strings.Split(url, "/")
err:=mailgun.Client.GetStoredMessage(urlp[len(urlp)-1])
Generates an error that reads as
UnexpectedResponseError
URL=https://api.mailgun.net/v2/domains/mydomain.com/messages/eyJwIjpmYWxzZSaWFwiayZDgxNzc0LWJaWFlMzItNGYS1hM2E2LTc4NzUwYWRhZjMaWF3OCIsInMiOiJkYzRjZmIiwiYyI6InNhaWFkIn0=
ExpectedOneOf=[]int{200, 202, 204}
Got=400
Error: {"message":"Please use URLs as they are given in events/webhooks"}
While the value of url was https://si.api.mailgun.net/v3/domains/mydomain.com/messages/eyJwIjpmYWxzZSaWFwiayZDgxNzc0LWJaWFlMzItNGYS1hM2E2LTc4NzUwYWRhZjMaWF3OCIsInMiOiJkYzRjZmIiwiYyI6InNhaWFkIn0=.
The text was updated successfully, but these errors were encountered:
@fiatjaf the tests run without any problems. Mailgun have migrated everything to API v3 - v2 is legacy now. As you see in your original description the "v2" is returning URLs for "v3" - that alone should be a good indicator that you should migrate asap.
If you have any tests you can run to verify integrity that would be awesome - I wouldn't recommend dumping the APIv3-branch right into production code. This should wait it is merged into master - at that point I've been running the code in production for some time (it is running now - no problems so far - afaik the new branch is more stable).
Generates an error that reads as
While the value of
url
washttps://si.api.mailgun.net/v3/domains/mydomain.com/messages/eyJwIjpmYWxzZSaWFwiayZDgxNzc0LWJaWFlMzItNGYS1hM2E2LTc4NzUwYWRhZjMaWF3OCIsInMiOiJkYzRjZmIiwiYyI6InNhaWFkIn0=
.The text was updated successfully, but these errors were encountered: