Documentation API Docs Flow Report QueryBacktoOriginTrafficAndRequest

QueryBacktoOriginTrafficAndRequest

Update time: 2026-07-13 15:49:56

Applicable Products

universal

API Description

This interface is designed to query the back-to-source traffic and number of requests for multiple domain names. Users can obtain this data by entering information such as the start time, end time, and specified domain name. The interface returns the total traffic, total number of requests, request and bandwidth peaks for each domain name and their corresponding time points, and supports providing detailed traffic, request, and bandwidth data at a minute granularity. This feature helps users monitor and analyze website back-to-source traffic. Limitation: Generally, data is delayed by 5 to 15 minutes.

Call frequency

Single user trigger frequency: 300/5min

Request parameter(s)

Body Params

JSON
NameDescription
*dateFromString
Start Time: 1.The Time format is yyyy-MM-ddTHH:mm:ss±HH:mm. Please note: ±HH:mm is the time zone offset, which can be adjusted according to your data needs, for example, +00:00 represents UTC time, +08:00 represents East 8th District, and -05:00 represents West 5th District. 2024-01-15T10:30:45+00:00 means UTC time January 15, 2024 10:30:45 AM 2.Cannot exceed the current time 3.Up to the past six months (183 days) of data can be obtained
*dateToString
End time: 1. The time format is yyyy-MM-ddTHH:mm:ss±HH:mm. Please note: ±HH:mm is the time zone offset, which can be adjusted according to your data needs, for example, +00:00 represents UTC time, +08:00 represents East 8th District, and -05:00 represents West 5th District. 2024-01-15T10:30:45+00:00 means UTC time January 15, 2024 10:30:45 AM; 2. End time should be greater than start time. If the end time is greater than current time, current time will be used. 3. If both fields of dataFrom and dateTo are left empty, then data in the last 24 hours will be queried by default; if one field is filled and one is left empty, then exception will occur. 4. Maximum query time interval allowed: 1 day by default, that is, the difference between dateFrom and dateTo cannot exceed 1 day (you can contact technical support to adjust it, the maximum adjustment is 31 days)
*dataIntervalString
Data granularity: 1. Support 5m (granularity of 5 minutes) and 1m 2. 5m by default if the value is empty
*domainList
Domain name: 1. The default upper limit of domains that can be entered is 200 (if you want to adjust, please, contact technical support); 2. All domains under the account will be queried if this input parameter is not specified. But if the number of domains under the account exceeds the limits, no query will be executed (Error)
*groupByList
Grouping keywords: 1. By default, data will be displayed by group; 2. If there are keywords entered, value details shall be displayed by keywords; If groupBy is specified as domain, it means the results are returned according to domains. 3. Only domain can be specified
*backsrcOnlyObject
Optional values 0, 1. Input 0 returns all data, input 1 only returns source site data, default is0 

Response parameter(s)

Body Params

JSON
NameDescription
resultList
domainString
Domain
totalFlowString
totalFlow, unit :MB, 2 decimal places reserved, example (74099.92)
totalRequestString
totalRequest
peakRequestString
peak of Request
peakRequestTimeString
peaktime of Request
peakBandwidthString
peakBandwidth, unit :Mbps, 2 decimal places reserved, example (74099.92)
peakBandwidthTimeString
Peak time of Bandwidth
flowRequestOriginDataList
timestampString
1. When the querying data granularity is 5m, then the format is yyyy-MM-dd HH:mm; the data value of every time slice represents the data value within the previous time granularity range. The first time slice of the day is yyyy-MM-dd 12:05 AM, and the last one is (yyyy-MM-dd+1) 00:00. 2. Return the time slices that contained in start time and in end time.
flowString
Traffic unit is MB and keep the number to two decimal places
bandwidthString
Bandwidth, unit: Mbps, 2 decimal places reserved, example (931556.21)
requestString
Total number of requests

Error code

Error code(code)Description(message)HTTP statusSemantic
DateSpanErrorPeriod between dataFrom and dateTo is longer than 1 days400Period between dataFrom and dateTo is longer than 1 days
InternalErrorSystem has encountered an error500System has encountered an error
InvalidDatePerioddataFrom or dateTo not compliant to specifications400dataFrom or dateTo not compliant to specifications
InvalidHTTPRequestIncorrect format of request body400Incorrect format of request body
NotAcceptableAccept as request header is not supported, as interface only supports json and xml formats, with json as the default format400Accept as request header is not supported, as interface only supports json and xml formats, with json as the default format
NumberLimitExceededNumber of queried domains exceeds set limit400Number of queried domains exceeds set limit
PARAM_INVALIDParameter of dataInterval not compliant to specifications400Parameter of dataInterval not compliant to specifications
PARAM_INVALIDparam: domain is null or invalid.400param: domain is null or invalid.
PARAM_INVALIDparam: groupBy is null or invalid.400param: groupBy is null or invalid.

Example

XML
JSON
XML
Request example
Copy Copy success
#!/bin/bash
# Please remember to change the param (-H "X-Time-Zone") in this demo to the TimeZone you want in response

  username='example_username'
  apiKey='example_apiKey'
  date=`env LANG="en_US.UTF-8" date -u "+%a, %d %b %Y %H:%M:%S   GMT"`
  password=`echo -en "$date" | openssl dgst -sha1 -hmac $apiKey   -binary | openssl enc -base64`
  curl -i --url "https://api.atomile.com/api/report/flow-request/origin"   \
  -X "POST" \
-H "X-Time-Zone:GMT+00:00" \
  -u "$username:$password" \
  -H "Date: $date" \
  -H "Accept: application/xml" \
  -d '{
  "dateFrom": "2016-12-02T10:00:00+00:00",
  "dateTo": "2016-12-03T10:00:00+00:00",
  "domain": ["www.111.com","www.222.com"],
  "dataInterval": "5m",
  "groupBy": ["domain"]
  }'
Response example
Copy Copy success
<?xml version="1.0" encoding="UTF-8"?>
<report>
    <result>
        <data>
            <total-flow>774.67</total-flow>
            <total-request>25659</total-request>
            <peak-bandwidth>20.66</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:04</peak-bandwidth-time>
            <peak-request>25659</peak-request>
            <peak-request-time>2019-07-22 14:04</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:04</timestamp>
                    <bandwidth>20.66</bandwidth>
                    <flow>774.67</flow>
                    <request>25659</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>774.67</total-flow>
            <total-request>25659</total-request>
            <peak-bandwidth>20.66</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:04</peak-bandwidth-time>
            <peak-request>25659</peak-request>
            <peak-request-time>2019-07-22 14:04</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:04</timestamp>
                    <bandwidth>20.66</bandwidth>
                    <flow>774.67</flow>
                    <request>25659</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1394.00</total-flow>
            <total-request>25920</total-request>
            <peak-bandwidth>37.17</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:05</peak-bandwidth-time>
            <peak-request>25920</peak-request>
            <peak-request-time>2019-07-22 14:05</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:05</timestamp>
                    <bandwidth>37.17</bandwidth>
                    <flow>1394.00</flow>
                    <request>25920</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>2013.33</total-flow>
            <total-request>26181</total-request>
            <peak-bandwidth>53.69</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:06</peak-bandwidth-time>
            <peak-request>26181</peak-request>
            <peak-request-time>2019-07-22 14:06</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:06</timestamp>
                    <bandwidth>53.69</bandwidth>
                    <flow>2013.33</flow>
                    <request>26181</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>2013.33</total-flow>
            <total-request>26181</total-request>
            <peak-bandwidth>53.69</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:06</peak-bandwidth-time>
            <peak-request>26181</peak-request>
            <peak-request-time>2019-07-22 14:06</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:06</timestamp>
                    <bandwidth>53.69</bandwidth>
                    <flow>2013.33</flow>
                    <request>26181</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>2632.66</total-flow>
            <total-request>26442</total-request>
            <peak-bandwidth>70.20</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:07</peak-bandwidth-time>
            <peak-request>26442</peak-request>
            <peak-request-time>2019-07-22 14:07</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:07</timestamp>
                    <bandwidth>70.20</bandwidth>
                    <flow>2632.66</flow>
                    <request>26442</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>2632.66</total-flow>
            <total-request>26442</total-request>
            <peak-bandwidth>70.20</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:07</peak-bandwidth-time>
            <peak-request>26442</peak-request>
            <peak-request-time>2019-07-22 14:07</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:07</timestamp>
                    <bandwidth>70.20</bandwidth>
                    <flow>2632.66</flow>
                    <request>26442</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1015.18</total-flow>
            <total-request>8872</total-request>
            <peak-bandwidth>27.07</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:08</peak-bandwidth-time>
            <peak-request>8872</peak-request>
            <peak-request-time>2019-07-22 14:08</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:08</timestamp>
                    <bandwidth>27.07</bandwidth>
                    <flow>1015.18</flow>
                    <request>8872</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1015.18</total-flow>
            <total-request>8872</total-request>
            <peak-bandwidth>27.07</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:08</peak-bandwidth-time>
            <peak-request>8872</peak-request>
            <peak-request-time>2019-07-22 14:08</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:08</timestamp>
                    <bandwidth>27.07</bandwidth>
                    <flow>1015.18</flow>
                    <request>8872</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>2374.43</total-flow>
            <total-request>17889</total-request>
            <peak-bandwidth>63.32</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:09</peak-bandwidth-time>
            <peak-request>17889</peak-request>
            <peak-request-time>2019-07-22 14:09</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:09</timestamp>
                    <bandwidth>63.32</bandwidth>
                    <flow>2374.43</flow>
                    <request>17889</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>2374.43</total-flow>
            <total-request>17889</total-request>
            <peak-bandwidth>63.32</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:09</peak-bandwidth-time>
            <peak-request>17889</peak-request>
            <peak-request-time>2019-07-22 14:09</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:09</timestamp>
                    <bandwidth>63.32</bandwidth>
                    <flow>2374.43</flow>
                    <request>17889</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1290.44</total-flow>
            <total-request>8988</total-request>
            <peak-bandwidth>34.41</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:10</peak-bandwidth-time>
            <peak-request>8988</peak-request>
            <peak-request-time>2019-07-22 14:10</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:10</timestamp>
                    <bandwidth>34.41</bandwidth>
                    <flow>1290.44</flow>
                    <request>8988</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1290.44</total-flow>
            <total-request>8988</total-request>
            <peak-bandwidth>34.41</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:10</peak-bandwidth-time>
            <peak-request>8988</peak-request>
            <peak-request-time>2019-07-22 14:10</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:10</timestamp>
                    <bandwidth>34.41</bandwidth>
                    <flow>1290.44</flow>
                    <request>8988</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1359.25</total-flow>
            <total-request>9017</total-request>
            <peak-bandwidth>36.25</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:11</peak-bandwidth-time>
            <peak-request>9017</peak-request>
            <peak-request-time>2019-07-22 14:11</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:11</timestamp>
                    <bandwidth>36.25</bandwidth>
                    <flow>1359.25</flow>
                    <request>9017</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1359.25</total-flow>
            <total-request>9017</total-request>
            <peak-bandwidth>36.25</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:11</peak-bandwidth-time>
            <peak-request>9017</peak-request>
            <peak-request-time>2019-07-22 14:11</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:11</timestamp>
                    <bandwidth>36.25</bandwidth>
                    <flow>1359.25</flow>
                    <request>9017</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1428.07</total-flow>
            <total-request>9046</total-request>
            <peak-bandwidth>38.08</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:12</peak-bandwidth-time>
            <peak-request>9046</peak-request>
            <peak-request-time>2019-07-22 14:12</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:12</timestamp>
                    <bandwidth>38.08</bandwidth>
                    <flow>1428.07</flow>
                    <request>9046</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1428.07</total-flow>
            <total-request>9046</total-request>
            <peak-bandwidth>38.08</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:12</peak-bandwidth-time>
            <peak-request>9046</peak-request>
            <peak-request-time>2019-07-22 14:12</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:12</timestamp>
                    <bandwidth>38.08</bandwidth>
                    <flow>1428.07</flow>
                    <request>9046</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1496.88</total-flow>
            <total-request>9075</total-request>
            <peak-bandwidth>39.92</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:13</peak-bandwidth-time>
            <peak-request>9075</peak-request>
            <peak-request-time>2019-07-22 14:13</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:13</timestamp>
                    <bandwidth>39.92</bandwidth>
                    <flow>1496.88</flow>
                    <request>9075</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1496.88</total-flow>
            <total-request>9075</total-request>
            <peak-bandwidth>39.92</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:13</peak-bandwidth-time>
            <peak-request>9075</peak-request>
            <peak-request-time>2019-07-22 14:13</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:13</timestamp>
                    <bandwidth>39.92</bandwidth>
                    <flow>1496.88</flow>
                    <request>9075</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1565.70</total-flow>
            <total-request>9104</total-request>
            <peak-bandwidth>41.75</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:14</peak-bandwidth-time>
            <peak-request>9104</peak-request>
            <peak-request-time>2019-07-22 14:14</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:14</timestamp>
                    <bandwidth>41.75</bandwidth>
                    <flow>1565.70</flow>
                    <request>9104</request>
                </detail>
            </flow-request-origin-data>
        </data>
        <data>
            <total-flow>1565.70</total-flow>
            <total-request>9104</total-request>
            <peak-bandwidth>41.75</peak-bandwidth>
            <peak-bandwidth-time>2019-07-22 14:14</peak-bandwidth-time>
            <peak-request>9104</peak-request>
            <peak-request-time>2019-07-22 14:14</peak-request-time>
            <flow-request-origin-data>
                <detail>
                    <timestamp>2019-07-22 14:14</timestamp>
                    <bandwidth>41.75</bandwidth>
                    <flow>1565.70</flow>
                    <request>9104</request>
                </detail>
            </flow-request-origin-data>
        </data>
    </result>
</report>