Question

I'm currently attempting to write a basic client that listens to events from (enterprise) github, and makes API calls accordingly.

The problem I have is that I can't manage to get the PubSubHubbub client configured. I thought it was the client/authentication I'm using, but I now can't get the basic call from the docs working!

In an attempt to work out what I'm doing wrong, I'm making a curl request to my normal github account:

curl -u "joepym" -i \
 https://api.github.com/hub \
 -F "hub.mode=subscribe" \
 -F "hub.topic=http://github.com/JoePym/faraday/events/push" \
 -F "hub.callback=*callbackurl*"

and I'm getting back

HTTP/1.1 100 Continue

HTTP/1.1 422 Unprocessable Entity
Server: GitHub.com
Date: Wed, 08 May 2013 18:13:24 GMT
Content-Type: application/json; charset=utf-8
Connection: keep-alive
Status: 422 Unprocessable Entity
X-RateLimit-Limit: 5000
X-RateLimit-Remaining: 4989
X-GitHub-Media-Type: github.beta
X-Content-Type-Options: nosniff
Content-Length: 38

{
  "message": "Invalid event: nil"
}

This invalid event message is what my main client is also getting when I attempt to call my enterprise github account with enterprise credentials.

Has anyone encountered this before?

Was it helpful?

Solution

Try using https://github.com/JoePym/faraday/events/push as your hub.topic. Note that we are now using 'https'.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top