Skip to main content
Glama

set_chaos_config

Configure fault injection rules to test system resilience by setting latency, error rates, bandwidth throttling, or advanced stateful faults like circuit breakers and progressive degradation.

Instructions

Configure chaos fault injection rules. For simple chaos: set latency ranges, error rates, or bandwidth throttling. For advanced stateful faults: pass raw rules with fault types like circuit_breaker, retry_after, progressive_degradation, or chunked_dribble. Pass enabled=false to disable all chaos. For pre-built configurations, use named profiles like "slow-api" or "flaky".

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bandwidth_bytes_per_secNoBandwidth throttle in bytes/sec
enabledYesEnable or disable chaos injection
error_codesNoHTTP status codes to return on error (e.g., [500, 502, 503])
error_rateNoError rate 0.0-1.0 (e.g., 0.2 = 20% of requests fail)
latency_max_msNoMaximum random latency in milliseconds
latency_min_msNoMinimum random latency in milliseconds
latency_msNoFixed latency in milliseconds
profileNoNamed chaos profile
rulesNoRaw chaos rules for advanced fault types. Each rule has probability (0-1), optional pathPattern, optional methods, and faults array. Fault types: latency, error, slow_body, corrupt_body, partial_response, connection_reset, circuit_breaker, retry_after, progressive_degradation, chunked_dribble. Each fault has type, probability (0-1), and config object.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/getmockd/mockd'

If you have feedback or need assistance with the MCP directory API, please join our Discord server