The Base URL
Every QUERY request to Alexa Site Thumbnail web service begins with the following:
Base URL
http://ast.amazonaws.com/Xino
Request Parameters
The base URL is followed by a series of parameters that define the request. Parameters are separated from the base URL by a question mark ( ? ) and each other by an ampersand ( & ) character. Each parameter consists of a key and a value, separated from each other by an equals sign ( = ). Note that parameters and their values are case-sensitive; for example, Action=Thumbnail works correctly, but Action=thumbnail produces an error. Also note that all HTTP parameters must be UrlEncoded.
The following example shows a simple QUERY request that returns a thumbnail for a given URL.
Sample Request
http://ast.amazonaws.com/Xino?
AWSAccessKeyId=
[your AWSAccessKeyId]
&Timestamp=
[timestamp now, format as described in http://www.w3.org/TR/xmlschema-2/#dateTime]
&Signature=
[signature calculated from request]
&Action=
[desired action, such as Thumbnail]
&Url=
[URL of website to get thumbnail for]
Parameter Details
The parameters in the example are described in the following table:
| Parameter | Required | Description |
|---|---|---|
| AWSAccessKeyId | yes |
This is your Amazon Web Services Access Key ID. This parameter
is used to identify the sender of the request.
Note: To obtain an AWS Access Key ID, you must sign up for an Amazon Web Services Account. To sign up, please use the sign in page. |
| Action | yes | This parameter tells the service what action it should perform. See the Actions section for the list of all supported actions for AST. |
| Signature | yes | This parameter holds the computed signature for this request. Request signatures are used to authenticate requests, and assure that the request contents were not altered between the sender and AWS. For more information about request signatures, please see the Request Authentication section. |
| Url | required for Action=Thumbnail | This parameter is required when the action is Thumbnail, and tells the service what website to retrieve a thumbnail for. See the Thumbnail Action section for more information. |
| Size | optional for Action=Thumbnail | This parameter specifies the size of the thumbnail to be returned. Possible values are "Large" and "Small". When this parameter is not specified, defaults to "Large". See the Thumbnail Action section for more information. |