Skip to main content
Glama

inject_latency

Adds artificial delay to matching browser requests, then observes whether the app shows loading indicators or skeleton screens and handles timeouts gracefully.

Instructions

Opens the browser, navigates directly to the user application, and adds artificial delay to requests matching a URL pattern. Observes whether loading indicators or skeleton screens appear. Use to answer: does the app show loading states when the API takes 3 seconds? Does it time out gracefully?

Input Schema

NameRequiredDescriptionDefault
urlYesURL of the page to test
headlessNoWhether to run in headless mode (default: false, launches real browser so user sees application)
viewportNoViewport size (default: 1280×720)
jitter_msNoRandom additional delay in milliseconds (default: 0)
latency_msNoBase delay in milliseconds to add to each matched request (default: 3000)
loading_selectorNoCSS selector for the loading state that should appear (e.g., '.skeleton-loader')
preview_delay_msNoMilliseconds to pause after simulation before closing browser, allowing visual inspection (default: 2000)
intercept_patternYesGlob pattern for requests to delay (e.g., '**/api/**')
keep_browser_openNoKeep browser window open after test completes so user can interactively inspect the app (default: false)
api_health_check_urlNoOptional backend or hosted API health check URL to verify before running chaos test. Aborts if backend is down or errors.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.2

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description carries the full burden and does disclose that it launches a real browser, adds delay, and inspects for loading states. However it does not say what the tool returns or how it reports the observation (pass/fail, screenshots, detected selector or not), and the health-check abort behavior is documented only in the schema.

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?

Three short sentences, front-loaded with the action and followed by the outcome and use case. Slight redundancy between the observation sentence and the two example questions, but nothing wasted.

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

Completeness3/5

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

For a 10-parameter, no-annotation, no-output-schema tool, the description covers the mechanism and the intent but not the outcome contract: what an agent gets back, whether loading_selector omission changes behavior, or how timeouts are surfaced. That is a meaningful gap given the complexity.

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 description coverage is 100%, so every one of the 10 parameters is already documented with types, defaults, and bounds. The description only reinforces 'requests matching a URL pattern' and the 3-second example; baseline 3 is appropriate.

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

Purpose4/5

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

States a specific action chain: opens the browser, navigates to the app, and injects artificial delay on requests matching a URL pattern, plus observes loading indicators. That is a clear verb+resource. It never names or contrasts with siblings such as simulate_api_failure or simulate_network_drop, so an agent must infer the latency-vs-failure distinction from the name alone.

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

Usage Guidelines4/5

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

The closing questions ('does the app show loading states when the API takes 3 seconds? does it time out gracefully?') give concrete scenarios that select this tool. No when-not conditions or named alternatives are given, so it falls short of a 5.

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