Print this pageEmail this pageGo to the ForumsView the PDFShare this page on TwitterShare this page on FacebookBookmark this page on DeliciousSubmit this page to RedditSubmit this page to Digg

TrafficHistory

Description

The TrafficHistory action returns the daily Alexa Traffic Rank, Reach per Million Users, and Unique Page Views per Million Users for each day going back 4 years. Sites with a rank in excess of 1,000,000 are not included.

Request Parameters

The TrafficHistory Action takes the following parameters. Required parameters must be provided for the request to succeed.

NameDescriptionRequired
Action

TrafficHistory

Yes
Url

Any valid URL.

Yes
ResponseGroup

History is the only available response group.

Yes
Range

Number of days to return. Note that the response document may contain fewer results than this maximum if data is not available. Default value is '31'. Maximum value is '31'.

No
Start

Start date for results. A date within the last 4 years in format YYYYMMDD.

No

Example

The following example shows a query-style request and response

Request

http://awis.amazonaws.com/?
            Action=TrafficHistory
            &AWSAccessKeyId=[Your AWS Access Key ID]
            &Signature=[signature calculated from request]
            &SignatureMethod=[HmacSha1 or HmacSha256]
            &SignatureVersion=2
            &Timestamp=[timestamp used in signature]
            &Url=[Valid URL]
            &ResponseGroup=History
            &Range=[maximum number of results]
            &Start=[start date for results]
            

Response

The response contains an aws:Data element for each day in the date range specified.

<aws:TrafficHistoryResponse xmlns:aws="http://alexa.amazonaws.com/doc/2005-10-05/">
<aws:Response xmlns:aws="http://awis.amazonaws.com/doc/2005-07-11">
<aws:OperationRequest><aws:RequestId>c3b86545-6036-14ce-ca6c-58b75881cbdb</aws:RequestId>
</aws:OperationRequest>
<aws:TrafficHistoryResult>
<aws:Alexa>
<aws:TrafficHistory>
    <aws:Range>31</aws:Range>
    <aws:Site>amazon.com</aws:Site>
    <aws:Start>2015-01-01</aws:Start>
    <aws:HistoricalData>
      <aws:Data>
        <aws:Date>2015-01-01</aws:Date>
        <aws:PageViews>
          <aws:PerMillion>14220</aws:PerMillion>
          <aws:PerUser>11.60</aws:PerUser>
        </aws:PageViews>
        <aws:Rank>6</aws:Rank>
        <aws:Reach>
          <aws:PerMillion>102100</aws:PerMillion>
        </aws:Reach>
      </aws:Data>
    </aws:HistoricalData>
</aws:TrafficHistory>
</aws:Alexa>
</aws:TrafficHistoryResult>
<aws:ResponseStatus xmlns:aws="http://alexa.amazonaws.com/doc/2005-10-05/">
<aws:StatusCode>Success</aws:StatusCode>
</aws:ResponseStatus></aws:Response>
</aws:TrafficHistoryResponse>