Skip to main content
Glama

Rank the most requested assets

cloudcdn_insights_top
Read-onlyIdempotent

Rank files by request volume over the last N days, busiest first, to identify assets to optimize, cache longer, or purge after a release.

Instructions

Rank the files that received the most requests over the last N days, busiest first: use it to find what to optimise, cache longer, or purge with cloudcdn_purge after a release. For totals across all files use cloudcdn_insights_summary; to list files regardless of traffic use cloudcdn_assets. Calls GET /api/insights/top-assets and returns the response's Assets list as a JSON array, each entry with Path (with a leading slash, e.g. "/acme/v1/hero.webp") and Requests (the request count over the window); the API reports no bytes per file. A response without an Assets list gives an empty array. Read-only. days outside 1..90 fails with exit code 64 before any request. Sends CLOUDCDN_ACCESS_KEY, or else CLOUDCDN_ACCOUNT_KEY; without a valid key the API answers 401 (exit code 77).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "cloudcdn_insights_top"
  }
}

Input Schema

NameRequiredDescriptionDefault
daysNoLook-back window in whole days ending today (UTC), 1 to 90. Default 7.
limitNoHow many files to return, busiest first. Default 10.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.0.24
    • addedInput schema / properties / days / description
      Added value: +"Look-back window in whole days ending today (UTC), 1 to 90. Default 7."
    • addedInput schema / properties / limit / description
      Added value: +"How many files to return, busiest first. Default 10."
  2. First observedv0.0.23

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the readOnly/openWorld/idempotent annotations: discloses the underlying endpoint, the return shape (Assets array with Path and Requests), that no bytes are reported, that a missing Assets list yields an empty array, that out-of-range days fails with exit code 64 before any request, and the auth key resolution plus 401/exit code 77 behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core purpose and alternatives before the implementation and error details. It is dense but every sentence carries actionable information; minor cost is the long single block covering endpoint, return shape, validation, and auth in one breath.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Though there is no output schema, the description fully specifies the return value (JSON array of Path/Requests entries with leading-slash paths), the empty-result case, failure modes, and auth requirements, leaving nothing essential unstated for a two-parameter read-only insights tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so both parameters are already documented, establishing a baseline of 3. The description reinforces the days window and adds the pre-request validation failure behavior, but says nothing about the limit parameter's semantics beyond what the schema states.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Rank the files that received the most requests over the last N days, busiest first') and explicitly distinguishes itself from cloudcdn_insights_summary (totals) and cloudcdn_assets (list regardless of traffic), so an agent can select it without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives concrete use cases ('find what to optimise, cache longer, or purge with cloudcdn_purge after a release') and names the exact alternatives for the two adjacent needs (summary totals, unfiltered listing). When-to-use and when-to-use-something-else are both explicit.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.