Depending on its type, a request is either processed immediately or may be queued for processing later. Generally, requests that are seeking information will get an immediate response; requests that are modifying or adding data may be queued for later.

Response Codes

The following HTTP status codes are possible in response to a request:
HTTP Status Code Status Description
200 OK (Immediate response) The request was a success and the response includes the requested data.
202 OK (Immediate response) The request was received and queued for processing, but not yet processed.
400 Bad Request The request was malformed or unexpected.
401 Unauthorized The request did not include a valid API key, secret token, resource (e.g. petition) authorization key, or request signature.
403 Forbidden The request included an API key, secret, or a petition authorization key that has been revoked.
404 Not Found The requested resource was not found.
415 Unsupported Media Type The request was sent with a specified format that is not supported.
429 Too Many Requests The rate limit has been reached for this API key. See Rate Limits.
500 Internal Server Error The request could not be fulfilled due to an unexpected error.
503 Service Unavailable is temporarily unable to fulfill the request. The request can be tried again later.

Response Format

All responses are sent in JSON.

Here is an example request to retrieve the most recent signature of a petition:

=> [{ 
"first_name": "Jean-Luc",
"last_name": "Picard",
"city": "San Francisco",
"state_province": "CA",
"country": "US",
"signed_on": "2012-02-15T23:39:31Z"

Note: A public API key is a required parameter on all requests. For readability, it has been omitted from the example above.