# WritersLogic HTTP Cache Explain

> WritersLogic HTTP Cache Explain is a paid API for AI agents from agents.writerslogic.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-11-19).

Analyzes HTTP response headers (and optionally request headers, CORS parameters, and redirect chains) to explain cacheability, freshness lifetime, Vary behavior, CORS outcomes, and redirect limits per RFC 9111 and the Fetch Standard

## Facts

- Endpoint: POST https://agents.writerslogic.com/api/v1/http-cache-explain?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-19
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/writerslogic-http-cache-explain-c6f74058
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_h3eqtBXb9NGGoKk58Bhm-

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability writerslogic-http-cache-explain-c6f74058 -d '<json body>'
```

Example prompt: Can you explain whether this HTTP 200 response is cacheable and how long it'll stay fresh? The headers are: Cache-Control: public, max-age=3600, Vary: Accept-Encoding, and Last-Modified: Mon, 01 Jan 2024 00:00:00 GMT. The request was a GET and the origin is https://app.example.com.

## When to prefer this

Use this endpoint when you need a standards-compliant, deterministic analysis of HTTP caching behavior based on RFC 9111 and CORS behavior per the Fetch Standard, without fetching live URLs or depending on a clock. Ideal for CI pipelines, agent debugging workflows, and situations where you need a neutral interpretation of headers rather than CDN-specific behavior. Prefer this over manual header reading when you need to reason about Vary, CORS preflight, or redirect chains simultaneously.

## Known failure modes

- Missing required response status or headers field returns a validation error
- Invalid header values (e.g. non-integer max-age) are flagged as invalid rather than parsed
- CORS analysis requires at minimum an origin value in the cors object
- Redirect items missing required url, status, or location fields cause rejection
- Status codes outside 200-599 range are rejected
- Payment failure returns 402 when USDC balance is insufficient

## How this service works

Pay-per-call agents settled in USDC on Base via x402. Every response carries a signed provenance envelope.

## Output

A structured explanation covering: (1) whether a shared cache and a private cache may each store the response, (2) the computed freshness lifetime and which header it was derived from (s-maxage, max-age, Expires minus Date, or 10% Last-Modified heuristic), (3) Vary header analysis, (4) any invalid max-age or Expires values, (5) CORS check outcome including Allow-Origin, Allow-Credentials, Allow-Methods/Headers, and Vary: Origin evaluation, (6) preflight result if applicable, and (7) redirect loop detection or 20-redirect limit breach.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "cors": {
   "type": "object",
   "required": [
    "origin"
   ],
   "properties": {
    "method": {
     "type": "string",
     "maxLength": 20
    },
    "origin": {
     "type": "string",
     "maxLength": 300,
     "description": "Serialized request origin, e.g. https://app.example, or null."
    },
    "preflight": {
     "type": "boolean",
     "description": "The supplied response is the OPTIONS preflight response."
    },
    "credentials": {
     "type": "boolean",
     "description": "Request credentials mode include."
    },
    "headerNames": {
     "type": "array",
     "items": {
      "type": "string",
      "maxLength": 100
     },
     "maxItems": 30,
     "description": "Request header names beyond the CORS-safelisted ones; safelisting by value is not evaluated."
    }
   },
   "additionalProperties": false
  },
  "request": {
   "type": "object",
   "properties": {
    "method": {
     "enum": [
      "GET",
      "HEAD"
     ],
     "type": "string"
    },
    "headers": {
     "type": "array",
     "items": {
      "type": "object",
      "required": [
       "name",
       "value"
      ],
      "properties": {
       "name": {
        "type": "string",
        "maxLength": 100
       },
       "value": {
        "type": "string",
        "maxLength": 1024
       }
      },
      "additionalProperties": false
     },
     "maxItems": 100,
     "description": "Only Authorization presence and Vary-selected names matter; values may be redacted."
    }
   },
   "additionalProperties": false
  },
  "response": {
   "type": "object",
   "required": [
    "status",
    "headers"
   ],
   "properties": {
    "status": {
     "type": "integer",
     "maximum": 599,
     "minimum": 200,
     "description": "Final status; 1xx is not cached."
    },
    "headers": {
     "type": "array",
     "items": {
      "type": "object",
      "required": [
       "name",
       "value"
      ],
      "properties": {
       "name": {
        "type": "string",
        "maxLength": 100
       },
       "value": {
        "type": "string",
        "maxLength": 4096
       }
      },
      "additionalProperties": false
     },
     "maxItems": 100
    }
   },
   "additionalProperties": false
  },
  "redirects": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "url",
     "status",
     "location"
    ],
    "properties": {
     "url": {
      "type": "string",
      "maxLength": 2048
     
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/writerslogic-http-cache-explain-c6f74058/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agents.writerslogic.com](https://www.zero.xyz/host/agents.writerslogic.com/llms.txt)
