I'm using Mandrill to send email and I need to track the emails' statuses. Mandrill use Webhooks to send a POST request to a specific url to notify when an event happens.
I'm using Services to implement the webservice to get that information. However, before sending a POST request, Mandrill use HEAD request to check if that url works.
I tried using a REST client name Postman (Chrome extension) to test http requests and the server always return 404 for HEAD. But Mandrill requires the response code 200 to work properly.
Does Services module support HEAD requests? If not, please help me to make it work. Thank you.
Comment | File | Size | Author |
---|---|---|---|
#5 | services-HEAD-1993776.patch | 954 bytes | ygerasimov |
#3 | services.restful_head_1993776_d7__03.patch | 642 bytes | rfay |
#2 | services.restful_head_1993776_02.patch | 705 bytes | rfay |
Comments
Comment #1
rfayYes, I'm facing this also.
@trickyken, I'm working on mandrill too (but to receive emails). Is your code available anywhere?
Comment #2
rfayHere's one way to provide a trivial HEAD. This just treats HEAD on the index as if it were GET. (this is for 6.x-3.x, but I imagine it's the same)
Comment #3
rfayI haven't tested it, but this patch looks to me like what's required for D7
Comment #5
ygerasimov CreditAttribution: ygerasimov commentedPlease test attached patch.
Comment #7
ygerasimov CreditAttribution: ygerasimov commented#5: services-HEAD-1993776.patch queued for re-testing.
Comment #9
ygerasimov CreditAttribution: ygerasimov commentedTest bot does something wrong. I have committed HEAD method patch. Please test using dev version.
Comment #10
rfayThe reason the patch didn't apply was that the version was set to 7.x-3.3 instead of 7.x-3.x-dev.
Would you mind putting this into 6.x-3.x-dev as well?
Thanks!
Comment #11
rfayComment #12
ygerasimov CreditAttribution: ygerasimov commented6.x branch is no more supported (there are huge debates in #2014573 about it). We need maintainer for 6.x branch
Comment #13
rfayYeah... I understand :-) Just had hopes, as my deployment is 6.x.
Comment #14
trickyken CreditAttribution: trickyken commentedComment #15
trickyken CreditAttribution: trickyken commented#5: services-HEAD-1993776.patch queued for re-testing.
Comment #17
trickyken CreditAttribution: trickyken commentedComment #18
trickyken CreditAttribution: trickyken commented#5: services-HEAD-1993776.patch queued for re-testing.
Comment #19
ygerasimov CreditAttribution: ygerasimov commented@trickyken patch #5 has been committed to 7.x branch. Please keep this issue as needs port status.
Comment #20
marcingy CreditAttribution: marcingy commentedThis is fixed there is no d6.