PostCrash: Difference between revisions

86 bytes removed ,  3 March 2011
Line 76: Line 76:
Discussed with Laura and came up with this API. Ping jsocol if changes are necessary.
Discussed with Laura and came up with this API. Ping jsocol if changes are necessary.


  GET /some/url/<sig>
  GET /postcrash?s=<signature>
 
or
 
GET /some/url?sig=<sig>
 
(opinions?)


Return values:
Return values:
Line 95: Line 89:
  HTTP/1.0 404 Not Found
  HTTP/1.0 404 Not Found


We'll set <code>Expires:</code> and/or <code>Cache-control: max-age=###</code> headers so repeated requests should bounce off Zeus, though conditional <code>GET</code> is still encouraged. :)
A request without an <code>s</code> parameter will result in
 
HTTP/1.0 400 Bad Request


We'll only return English articles for now. In the future we can make this locale-aware.
Responses may set caching headers. Conditional GET is encouraged. Consumers should wait before requesting again in the event of a 5xx error.


=Timeline=
=Timeline=
664

edits