Get Prefetch request list - GET /api/prefetch

Parent Previous Next

GET /api/prefetch                            

Get a list of prefetch requests.   Request parameters allow you to specify when the requests were made as well as the URL to match on.


Request Syntax


Request Headers


Header

Description

Required

Authorization

Authorization string for the request

Yes

Host

URI for the QUANTIL SDK (i.e., api.quantil.com)

Yes

Date

The date and time of the request.

Yes

Accept

Indicates the accepted format (i.e., application/xml)

Yes

Request Body Elements


Parameter

Description

Required

datefrom

RFC3339 formatted date indicating the starting date. Example: 2013-01-01T22:30:00+08:00

No

dateto

RFC3339 formatted date indicating the ending date. Example: 2013-01-01T22:30:00+08:00

No


Request Syntax:


GET /api/prefetch HTTP/1.1

Authorization: <authorization string>

Host: api.quantil.com

Date: <date>

Accept: application/xml


Here is the structure of a request using the curl utility.


curl -i -url https://api.quantil.com/api/prefetch

-X GET

-u {user}: {password}

-H 'Date: Thu, 17 May 2012 19:37:58 GMT'

-H 'Accept: application / xml'



Sample Request:


curl -i --url 'https://api.quantil.com/api/prefetch' -X GET -u username:fZ+hemqgaTF9DkgyBlkQLidctH4= -H 'Date: Thu, 24 Sep 2015 14:03:51 PDT' -H 'Accept: application/xml'

Response Details:


Response Headers:

HTTP / 1.1 202 Accepted

Date: <date>

Content-Type: application / xml; charset = utf-8

x-cnc-request-id: {id string auto generated by the QUANTIL server}


Response Body Elements

Element

Description

prefetch-list

A container which has zero or more <prefetch-request> elements describing the list of prefetch requests that have been made

prefetch-request

A container which describes a specific prefetch.  It contains a <request-date> element, a <prefetch-id> element, and an <items> element which lists the URLs that were part of the request.

request-date

RFC1123 format date indicating when the request was made.

prefetch-id

A unique ID representing the prefetch request.

items

A container describing a list of URLs that are prefetched. It contains zero or more <item> elements.

item

A container which describes a URL that is prefetched. It includes the following child elements: <path>, <status>, <rate>.

path

A URL being prefetched. The URL should begin with http:// or https://.

status

Indicates the status of the prefetch. It can be success, failure, running, or wait.

rate

Indicates the percentage of servers that have the content.



Sample Response:

HTTP/1.1 200 OK

Date: Thu, 24 Sep 2015 21:03:50 GMT

Accept-Ranges: bytes

Server: WS-web-server

x-cnc-request-id: 14266378

ContentType: application/xml;charset=UTF-8

Content-Type: application/xml;charset=UTF-8

Content-Length: 2382


<?xml version="1.0" encoding="UTF-8" standalone="yes"?><prefetch-list><prefetch-request><request-date>Wed, 23 Sep 2015 19:29:52 GMT</request-date><prefetch-id>ab4fd419-4ec3-4eeb-b2e8-4fc66b200727</prefetch-id><items><item><path>http://mynewtestdomain15.com/abc</path><status>wait</status></item></items></prefetch-request><prefetch-request><request-date>Sat, 12 Sep 2015 00:17:43 GMT</request-date><prefetch-id>01758525-646e-4a7e-8666-6bbc1a5ca7d1</prefetch-id><items><item><path>http://mynewtestdomain1.com/mydir</path><status>wait</status></item><item><path>http://mynewtestdomain1.com/1.txt</path><status>success</status><rate>100.0</rate></item></items></prefetch-request><prefetch-request><request-date>Fri, 11 Sep 2015 22:51:55 GMT</request-date><prefetch-id>78dd95bf-feed-4fb7-81d1-bcc7b0861eac</prefetch-id><items><item><path>http://mynewtestdomain1.com/mydir</path><status>wait</status></item><item><path>http://mynewtestdomain1.com/1.txt</path><status>success</status><rate>100.0</rate></item></items></prefetch-request><prefetch-request><request-date>Thu, 24 Sep 2015 21:03:50 GMT</request-date><prefetch-id>c37ac227-eff3-4f56-a440-1f0eeaa49e9f</prefetch-id><items><item><path>http://mynewtestdomain1.com/mydir</path><status>wait</status></item><item><path>http://mynewtestdomain1.com/1.txt</path><status>success</status><rate>100.0</rate></item></items></prefetch-request><prefetch-request><request-date>Thu, 24 Sep 2015 21:03:50 GMT</request-date><prefetch-id>42173164-a497-4073-b867-688cacfde1ae</prefetch-id><items><item><path>http://mynewtestdomain1.com/mydir</path><status>wait</status></item><item><path>http://mynewtestdomain1.com/1.txt</path><status>success</status><rate>100.0</rate></item></items></prefetch-request><prefetch-request><request-date>Thu, 24 Sep 2015 21:03:50 GMT</request-date><prefetch-id>10f1e770-eb21-47bf-943d-9479b6ea2fd0</prefetch-id><items><item><path>http://mynewtestdomain1.com/mydir</path><status>wait</status></item><item><path>http://mynewtestdomain1.com/1.txt</path><status>success</status><rate>100.0</rate></item></items></prefetch-request><prefetch-request><request-date>Thu, 24 Sep 2015 21:03:50 GMT</request-date><prefetch-id>86b48ed3-f544-490a-9807-8bc49bd452cb</prefetch-id><items><item><path>http://mynewtestdomain1.com/1.txt</path><status>success</status><rate>100.0</rate></item></items></prefetch-request></prefetch-list>



Error List


This API has no special error codes.