@@ -26,6 +26,24 @@ user is involved including:
2626Notifications come back as Summary objects. A Summary contains information
2727about the current discussion of an Issue/PullRequest/Commit.
2828
29+ Notifications are optimized for polling with the "Last-Modified" header. If
30+ there are no new notifications, you will see a "304 Not Modified" response,
31+ leaving your current rate limit untouched. There is an "X-Poll-Interval"
32+ header that specifies how often (in seconds) you are allowed to poll. In times
33+ of high server load, the time may increase. Please obey the header.
34+
35+ # Add authentication to your requests
36+ $ curl -I https://api.github.com/notifications
37+ HTTP/1.1 200 OK
38+ Last-Modified: Thu, 25 Oct 2012 15:16:27 GMT
39+ X-Poll-Interval: 60
40+
41+ # Pass the Last-Modified header exactly
42+ $ curl -I https://api.github.com/notifications
43+ -H "If-Modified-Since: Thu, 25 Oct 2012 15:16:27 GMT"
44+ HTTP/1.1 304 Not Modified
45+ X-Poll-Interval: 60
46+
2947##List your notifications
3048
3149List all notifications for the current user, grouped by repository.
@@ -153,3 +171,4 @@ repository.
153171###Response
154172
155173<%= headers 204 %>
174+