@Stefan_Riedmann I’ll have a look at your code.
In the meantime, do you have a capture of your request to the Infusionsoft server and its response? It would really help!
Here’s an example of what I mean.
My request:
POST /crm/rest/v1/hooks HTTP/1.1
Accept: application/json, */*
Accept-Encoding: gzip, deflate
Authorization: Basic …
Connection: keep-alive
Content-Type: application/json
Host: api.infusionsoft.com:443
{
"eventKey": "contact.edit",
"hookUrl": "https://mikec.example.com/hook/callback"
}
Response from server:
HTTP/1.1 200 OK
Cache-Control: no-cache, no-store
Content-Type: application/json;charset=UTF-8
Date: Tue, 03 Oct 2017 20:30:54 GMT
Expires: Tue, 03 Oct 2017 20:30:54 GMT
{
"eventKey": "contact.edit",
"hookUrl": "https://mikec.example.com/hook/callback",
"key": "37",
"status": "Unverified"
}