voxel.voxcast.ondemand.testing.cacheability

Test the cacheability of content on the origin.

Parameters

device_id (required)
Numeric Voxel device id, available from voxel.devices.list
origin_url (required)
Absolute URL to the content on origin server
verbosity (optional)
Verbosity of response. Should be one of "compact", "normal", or "extended".

Example Response

<?xml version="1.0"?>
<rsp stat="ok">
  <cacheability cacheable="true">
  <expires source_type="header" source_field="Cache-Control : max-age">
    Tue, 18 May 2010 04:18:43 GMT
</expires>
  <warnings>
    <warning>
      VoxCAST ignore_cache_control is disabled which will cause cache miss for
      requests with Cache-Control heardes
    </warning>
  </warnings>
  <http_headers>
    <header name="status">HTTP/1.1 200 OK</header>
    <header name="date">Tue, 18 May 2010 04:17:03 GMT</header>
    <header name="server">Apache/2.2.3 (CentOS)</header>
    <header name="x-powered-by">PHP/5.1.6</header>
    <header name="cache-control">max-age=100</header>
    <header name="connection">close</header>
    <header name="content-type">text/html; charset=UTF-8</header>
  </http_headers>
</cacheability>
</rsp>

Notes

This method can be used to test cacheability of your web assets in VoxCDN environment. You should pass complete url of your web asset "origin_url" to this method, for example http://www.mysite.com/my_image.jpg". Optionally you can pass "verbosity" parameter to get more detailed test results, possible values: compact, normal, extended

Method Specific Error Codes

100: Unknown device
The device_id passed in can't be matched to a valid device.
203: Origin request failed (HTTP response code)
On trying to contact the origin, the HTTP error specified in parenthesis was received.
402: Requested server configuration unavailable
The server configuration you requested is not currently available for provisioning at this facility