```json
{
"tests": [
{
"name": "basic_connectivity",
"endpoint": "/v1/ticker",
"method": "GET",
"headers": {"X-API-Key": "{api_key}"},
"payload": {},
"expected_status": 200,
"expected_behavior": "Returns cryptocurrency price data",
"metrics": ["latency", "status_code", "response_size"],
"validation": {"field": "data", "type": "object", "required_fields": ["price", "symbol"]}
},
{
"name": "specific_ticker_data",
"endpoint": "/v1/ticker",
"method": "GET",
"headers": {"X-API-Key": "{api_key}"},
"payload": {"symbol": "BTC"},
"expected_status": 200,
"expected_behavior": "Returns Bitcoin price data",
"metrics": ["latency", "accuracy", "status_code"],
"validation": {"field": "symbol", "type": "string", "expected": "BTC"}
},
{
"name": "markets_endpoint",
"endpoint": "/v1/markets",
"method": "GET",
"headers": {"X-API-Key": "{api_key}"},
"payload": {},
"expected_status": 200,
"expected_behavior": "Returns market data across exchanges",
"metrics": ["latency", "accuracy", "status_code"],
"validation": {"field": "data", "type": "array", "min_length": 1}
},
{
"name": "volume_statistics",
"endpoint": "/v1/volume",
"method": "GET",
"headers": {"X-API-Key": "{api_key}"},
"payload": {},
"expected_status": 200,
"expected_behavior": "Returns trading volume statistics",
"metrics": ["latency", "accuracy", "status_code"],
"validation": {"field": "volume", "type": "number", "min_value": 0}
},
{
"name": "historical_data",
"endpoint": "/v1/historical",
"method": "GET",
"headers": {"X-API-Key": "{api_key}"},
"payload": {"symbol": "BTC", "period": "1d"},
"expected_status": 200,
"expected_behavior": "Returns historical price data",
"metrics": ["latency", "accuracy", "status_code"],
"validation": {"field": "data", "type": "array", "required_fields": ["timestamp", "price"]}
},
{
"name": "invalid_symbol_error",
"endpoint": "/v1/ticker",
"method": "GET",
"headers": {"X-API-Key": "{api_key}"},
"payload": {"symbol": "INVALID123"},
"expected_status": 404,
"expected_behavior": "Returns error for invalid cryptocurrency symbol",
"metrics": ["error_handling", "status_code"],
"validation": {"field": "error", "type": "string"}
},
{
"name": "missing_auth_error",
"endpoint": "/v1/ticker",
"method": "GET",
"headers": {},
"payload": {},
"expected_status": 401,
"expected_behavior": "Returns authentication error without API key",
"metrics": ["error_handling", "status_code"],
"validation": {"field": "error", "type": "string"}
},
{
"name": "multiple_symbols_request",
"endpoint": "/v1/ticker",
"method": "GET",
"headers": {"X-API-Key": "{api_key}"},
"payload": {"symbols": "BTC,ETH,ADA"},
"expected_status": 200,
"expected_behavior": "Returns price data for multiple cryptocurrencies",
"metrics": ["latency", "accuracy", "status_code"],
"validation": {"field": "data", "type": "array", "min_length": 3}
}
],
"pricing_probes": [
{
"name": "verify_rate_limits",
"description": "Test if rate limiting headers are present and accurate",
"endpoint": "/v1/ticker",
"method": "GET",
"payload": {"symbol": "BTC"},
"check": "response.headers should include X-RateLimit-Remaining or similar rate limit indicators"
},
{
"name": "check_free_tier_limits",
"description": "Verify free tier request limitations",
"endpoint": "/v1/ticker",
"method": "GET",
"payload": {},
"check": "response.headers should indicate remaining requests in free tier"
},
{
"name": "verify_data_freshness",
"description": "Check if market data timestamp is recent",
"endpoint": "/v1/ticker",
"method": "GET",
"payload": {"symbol": "BTC"},
"check": "response.timestamp should be within last 5 minutes for real-time data"
}
],
"stress_profile": {
"concurrent_requests": 3,
"duration_seconds": 180,
"ramp_up": true,
"max_rps": 0.8,
"comment": "Respecting 60 RPM rate limit (1 req/sec max) with safety buffer"
}
}
```