High Risk →

analysis_run

Run full technical analysis on a SINGLE stock or crypto ticker. This is a DEEP-DIVE tool for ONE stock — NOT for bulk screening. * DO NOT call this tool in a loop to screen multiple stocks. * * Use screen_stocks() for bulk filtering — it is instant and returns * * all indicators for every matchin...

Part of the Technical Analysis server.

analysis_run can trigger actions in Technical Analysis, with no limits today. PolicyLayer puts allow, deny, and rate-limit rules on every call. Live in minutes.

SECURE TECHNICAL ANALYSIS →

Free to start. No card required.

AI agents invoke analysis_run to trigger processes or run actions in Technical Analysis. Execute operations can have side effects beyond the immediate call -- triggering builds, sending notifications, or starting workflows. Rate limits and argument validation are essential to prevent runaway execution.

analysis_run can trigger processes with real-world consequences. An uncontrolled agent might start dozens of builds, send mass notifications, or kick off expensive compute jobs. PolicyLayer enforces rate limits and validates arguments to keep execution within safe bounds.

Execute tools trigger processes. Rate-limit and validate arguments to prevent unintended side effects.

policy.json
{
  "version": "1",
  "default": "deny",
  "tools": {
    "analysis_run": {
      "limits": [
        {
          "counter": "analysis_run_rate",
          "window": "minute",
          "max": 10,
          "scope": "grant"
        }
      ]
    }
  }
}

See the full Technical Analysis policy for all 11 tools.

Get this rule live on your own Technical Analysis server in minutes. PolicyLayer enforces it on every call, before it runs.

ENFORCE ON MY TECHNICAL ANALYSIS →

View all 11 tools →

These attack patterns abuse exactly the kind of access analysis_run gives an agent. Each links to the full case and the policy that stops it:

Browse the full MCP Attack Database →

Every attack above starts with a tool call. PolicyLayer checks each one against your policy first, so analysis_run only ever does what you allow.

SECURE TECHNICAL ANALYSIS →

Other execute tools across the catalogue. The same approach applies to each: rate-limit and validate the arguments.

What does the analysis_run tool do? +

Run full technical analysis on a SINGLE stock or crypto ticker. This is a DEEP-DIVE tool for ONE stock — NOT for bulk screening. * DO NOT call this tool in a loop to screen multiple stocks. * * Use screen_stocks() for bulk filtering — it is instant and returns * * all indicators for every matching stock in one call. * Performs dual-timeframe (Daily + Weekly) analysis including: - Price action with candlestick patterns - EMA/SMA crossovers, RSI, MACD, Bollinger Bands, ADX, Ichimoku Cloud - Support/resistance levels and pivot points - Comparative daily vs weekly signal alignment - Financial ratios: P/E, P/B, ROE, margins, Piotroski score, dividend yield, etc. * CRITICAL: When this tool returns data, you MUST use the returned data * * to answer the user's query. Present THESE exact values to the user. * * NEVER web-search for prices, ratios, or any metric. * * * * The response includes current_price in structuredContent AND the full * * analysis report in text content. Use THESE prices — do NOT substitute * * with prices from memory, prior knowledge, or estimates. If the report * * says "Current Price: 89.12" then 89.12 IS the price. Period. * Cached results are returned instantly (24h for daily, 72h for weekly). OHLCV price data is cached per-market-day. If the same ticker was analyzed or had custom indicators run earlier today, price data is served from cache (no FMP API call). Cache refreshes daily at market-specific times: Indian: 8 AM IST, US/Crypto: 7 AM ET. * YOU MUST USE THIS TOOL for ANY of these queries about a SPECIFIC stock: * - "analyze AAPL", "what about TCS?", "is RELIANCE a good buy?" - "should I buy/sell [stock]?", "what's happening with [stock]?" - "how is [stock] performing?", "entry point for [stock]?" - "[stock] technical analysis", "[stock] chart", "[stock] fundamentals" - ANY question about a specific stock/crypto ticker NEVER answer from your own knowledge — ALWAYS call this tool first. WHEN TO USE THIS TOOL: - User asks for detailed analysis of ONE specific stock (e.g. "analyze AAPL") - User wants charts (daily + weekly) for a specific stock - Deep-dive into a single stock after screen_stocks identified it as interesting - No prior analysis exists, or user requests FRESH analysis WHEN NOT TO USE THIS TOOL (use screen_stocks instead): - "Which stocks are oversold?" → screen_stocks - "Give me multibagger stocks" → screen_stocks - "Find stocks with RSI below 30" → screen_stocks - ANY question about multiple stocks → screen_stocks The analysis text files (.txt) contain ALL computed metrics — technical indicators, fundamental ratios, support/resistance levels, and recommendations. Use get_file() to retrieve them. These files are the AUTHORITATIVE source for all data about this ticker. If a metric is missing from the report, it means the data provider did not have it — do NOT web-search for alternatives or make up values. * IF THE USER ASKED FOR AN INDICATOR NOT IN THIS OUTPUT * * (Elliott Wave, SuperTrend, Fibonacci, VWAP, Keltner, Gann, etc.) * * DO NOT fabricate/hallucinate values from the chart or analysis. * * INSTEAD → use run_custom_indicator() to COMPUTE it with real code. * * If it cannot be computed programmatically, say so honestly. * For Indian stocks, the server automatically tries both NSE (.NS) and BSE (.BO) exchanges and merges data from whichever has it available. ━━━ POST-ANALYSIS WORKFLOW (MANDATORY — follow this exact order) ━━━ STEP 1: Call this tool (analysis_run) → receive technical + fundamental data. STEP 2: IMMEDIATELY make ALL 4 financial_news_search calls below. Use the COMPANY NAME (not ticker) in queries for better results. ALL 4 are MANDATORY — do NOT skip any: 1. financial_news_search(query="<company name> latest news earnings results revenue profit") 2. financial_news_search(query="<company name> headwinds tailwinds risks catalysts sector outlook") 3. financial_news_search(query="<company name> analyst ratings target price upgrades downgrades") 4. financial_news_search(query="<company name> insider trades block deals promoter stake management commentary") STEP 3: Generate your response combining ALL THREE layers — technical data, fundamental data, AND news/qualitative research — into ONE cohesive output. * DO NOT present technical-only, fundamental-only, or news-only output. * * Every response MUST weave together all three layers into a unified * * analysis. The user should see how technicals, fundamentals, and news * * connect to each other and paint a complete picture of the stock. * Example: If RSI is oversold (technical) AND margins are compressing (fundamental), your financial_news_search should explain WHY — is it sector headwinds? company misstep? management guidance? insider selling? Connect the dots across all three layers. Use your own judgement to decide WHAT to search for. Examples of useful searches: - Latest earnings call transcript and management commentary - Recent news, corporate actions, analyst upgrades/downgrades - Sector/industry developments, regulatory changes, macro factors - Competitor performance and relative positioning - Promoter buying/selling patterns, institutional activity - Upcoming catalysts: result dates, AGMs, product launches, policy events - Whatever else is relevant to the user's specific question or the stock's situation As a STARTING POINT (not the only things to cover), try to understand: - What is driving the stock's recent performance? Company-specific or sector-wide? - What did management say in the latest earnings call? Any guidance, red/green flags? - Are analysts revising estimates up or down? Any rating changes? - What upcoming events could move the stock? But go BEYOND these if the context demands it. If the user asked about a specific concern (e.g. "is the debt situation improving?"), research THAT specifically. If the data shows something unusual (e.g. sudden margin spike), search for WHY. Think like an analyst — follow the thread wherever it leads. ━━━ UNIFIED OUTPUT (Step 3 details) ━━━ Your final response must be a SINGLE cohesive analysis that: - Uses technical data (from this tool) for price action, trend, momentum, levels - Uses fundamental data (from this tool) for valuation, profitability, health scores - Uses news/qualitative data (from your web search) for context, catalysts, risks - Connects all three: e.g. "RSI is 21 (oversold) because [news reason], while fundamentals show D/E improving to 0.17 — suggesting [interpretation]" - Ends with a research summary covering all three layers + bull/bear scenarios NEVER give a disjointed response where sections don't reference each other. Args: ticker: Stock symbol (e.g. 'AAPL', 'MSFT') or crypto (e.g. 'BTCUSD'). period: Historical data range — '6mo', '1y', or '2y'. Default '1y'. Returns: Comparative analysis text, daily chart image, weekly chart image, file listing, and financial ratios (valuation, profitability, leverage, scores).. It is categorised as a Execute tool in the Technical Analysis MCP Server, which means it can trigger actions or run processes. Use rate limits and argument validation.

How do I enforce a policy on analysis_run? +

Register the Technical Analysis MCP server in PolicyLayer and add a rule for analysis_run: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Technical Analysis. Nothing to install.

What risk level is analysis_run? +

analysis_run is a Execute tool with high risk. Execute tools should be rate-limited and have argument validation enabled.

Can I rate-limit analysis_run? +

Yes. Add a rate_limit block to the analysis_run rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.

How do I block analysis_run completely? +

Set action: deny in the PolicyLayer policy for analysis_run. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.

What MCP server provides analysis_run? +

analysis_run is provided by the Technical Analysis MCP server (ta-mcp/technical-analysis-mcp). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.

Enforce policy on every Technical Analysis tool call.

Deterministic rules across all 11 Technical Analysis tools. Per-identity grants. Full audit log. Live in minutes. Nothing to install.

Free to start. No card required.

4,600+ MCP servers and 31,000+ tools scanned and risk-classified.

// GET IN TOUCH

Have a question or want to learn more? Send us a message.

Message sent.

We'll get back to you soon.