Skip to main content
Glama
patch-ridermg48

TradingView MCP Server

volume_confirmation_analysis

Analyze volume confirmation patterns for cryptocurrency trades to validate price movements and identify potential entry/exit signals using specified timeframes and exchanges.

Instructions

Detailed volume confirmation analysis for a specific coin.

Args: symbol: Coin symbol (e.g., BTCUSDT) exchange: Exchange name timeframe: Time frame for analysis

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
exchangeNoKUCOIN
symbolYes
timeframeNo15m

Implementation Reference

  • Handler function implementing the volume_confirmation_analysis tool logic, including volume ratio calculation, signal generation, and technical analysis integration. Registered via @mcp.tool() decorator.
    @mcp.tool() def volume_confirmation_analysis(symbol: str, exchange: str = "KUCOIN", timeframe: str = "15m") -> dict: """Detailed volume confirmation analysis for a specific coin. Args: symbol: Coin symbol (e.g., BTCUSDT) exchange: Exchange name timeframe: Time frame for analysis """ exchange = sanitize_exchange(exchange, "KUCOIN") timeframe = sanitize_timeframe(timeframe, "15m") if not symbol.upper().endswith('USDT'): symbol = symbol.upper() + 'USDT' screener = EXCHANGE_SCREENER.get(exchange, "crypto") try: analysis = get_multiple_analysis(screener=screener, interval=timeframe, symbols=[symbol]) if not analysis or symbol not in analysis: return {"error": f"No data found for {symbol}"} data = analysis[symbol] if not data or not hasattr(data, 'indicators'): return {"error": f"No indicator data for {symbol}"} indicators = data.indicators # Get volume data volume = indicators.get('volume', 0) close = indicators.get('close', 0) open_price = indicators.get('open', 0) high = indicators.get('high', 0) low = indicators.get('low', 0) # Calculate price metrics price_change = ((close - open_price) / open_price) * 100 if open_price > 0 else 0 candle_range = ((high - low) / low) * 100 if low > 0 else 0 # Volume analysis sma20_volume = indicators.get('volume.SMA20', 0) volume_ratio = volume / sma20_volume if sma20_volume > 0 else 1 # Technical indicators rsi = indicators.get('RSI', 50) bb_upper = indicators.get('BB.upper', 0) bb_lower = indicators.get('BB.lower', 0) bb_middle = (bb_upper + bb_lower) / 2 if bb_upper and bb_lower else close # Volume confirmation signals signals = [] # Strong volume + price breakout if volume_ratio >= 2.0 and abs(price_change) >= 3.0: signals.append(f"๐Ÿš€ STRONG BREAKOUT: {volume_ratio:.1f}x volume + {price_change:.1f}% price") # Volume divergence if volume_ratio >= 1.5 and abs(price_change) < 1.0: signals.append(f"โš ๏ธ VOLUME DIVERGENCE: High volume ({volume_ratio:.1f}x) but low price movement") # Low volume on price move (weak signal) if abs(price_change) >= 2.0 and volume_ratio < 0.8: signals.append(f"โŒ WEAK SIGNAL: Price moved but volume is low ({volume_ratio:.1f}x)") # Bollinger Band + Volume confirmation if close > bb_upper and volume_ratio >= 1.5: signals.append(f"๐Ÿ’ฅ BB BREAKOUT CONFIRMED: Upper band breakout + volume confirmation") elif close < bb_lower and volume_ratio >= 1.5: signals.append(f"๐Ÿ“‰ BB SELL CONFIRMED: Lower band breakout + volume confirmation") # RSI + Volume analysis if rsi > 70 and volume_ratio >= 2.0: signals.append(f"๐Ÿ”ฅ OVERBOUGHT + VOLUME: RSI {rsi:.1f} + {volume_ratio:.1f}x volume") elif rsi < 30 and volume_ratio >= 2.0: signals.append(f"๐Ÿ›’ OVERSOLD + VOLUME: RSI {rsi:.1f} + {volume_ratio:.1f}x volume") # Overall assessment if volume_ratio >= 3.0: volume_strength = "VERY STRONG" elif volume_ratio >= 2.0: volume_strength = "STRONG" elif volume_ratio >= 1.5: volume_strength = "MEDIUM" elif volume_ratio >= 1.0: volume_strength = "NORMAL" else: volume_strength = "WEAK" return { "symbol": symbol, "price_data": { "close": close, "change_percent": round(price_change, 2), "candle_range_percent": round(candle_range, 2) }, "volume_analysis": { "current_volume": volume, "volume_ratio": round(volume_ratio, 2), "volume_strength": volume_strength, "average_volume": sma20_volume }, "technical_indicators": { "RSI": round(rsi, 1), "BB_position": "ABOVE" if close > bb_upper else "BELOW" if close < bb_lower else "WITHIN", "BB_upper": bb_upper, "BB_lower": bb_lower }, "signals": signals, "overall_assessment": { "bullish_signals": len([s for s in signals if "๐Ÿš€" in s or "๐Ÿ’ฅ" in s or "๐Ÿ›’" in s]), "bearish_signals": len([s for s in signals if "๐Ÿ“‰" in s or "โŒ" in s]), "warning_signals": len([s for s in signals if "โš ๏ธ" in s]) } } except Exception as e: return {"error": f"Analysis failed: {str(e)}"}
  • Registration of the tool via FastMCP decorator.
    @mcp.tool()

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/patch-ridermg48/tradingview-mcp'

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