Skip to main content
Glama
MCP Avantage

MCP Avantage

by MissionSquad

MCP Server for Alpha Vantage API (@missionsquad/avantage)

This project provides a Model Context Protocol (MCP) server that wraps the @missionsquad/avantage library, exposing Alpha Vantage API functionalities as tools for Language Learning Models (LLMs).

Overview

This server allows LLMs to interact with the Alpha Vantage API to retrieve financial data, including:

  • Core Stock Data (Time Series, Quotes, Search)

  • Fundamental Data (Company Overview, Financials, Calendars)

  • Forex (FX) Data

  • Cryptocurrency Data

  • Commodities Data

  • Economic Indicators

  • Technical Indicators

  • Alpha Intelligence (News, Sentiments, etc.)

  • Options Data (Premium)

It leverages the @missionsquad/avantage TypeScript library and follows the architecture of the generic MCP server template, including multi-user API key handling and resource management for AVantage client instances.

Key Features:

  • Comprehensive Coverage: Implements MCP tools for nearly all functions available in the @missionsquad/avantage library.

  • Multi-User Support: Handles Alpha Vantage API keys securely via extraArgs (preferred) or fallback to environment variables.

  • Resource Management: Efficiently manages AVantage client instances using the ResourceManager.

  • Strongly Typed: Built with TypeScript, leveraging types from @missionsquad/avantage and Zod schemas for tool parameters.

  • Standard MCP Interface: Uses @missionsquad/fastmcp for MCP communication.

Related MCP server: Zentickr - Yahoo Finance MCP Server

Getting Started

Prerequisites

  • Node.js v20 or later

  • npm or yarn

  • An Alpha Vantage API Key (Get one here)

Setup

  1. Clone or Copy: Clone this repository or copy the files.

    git clone <repository-url> mcp-avantage-server
    cd mcp-avantage-server
  2. Install Dependencies:

    npm install
    # or
    yarn install
  3. Configure Environment:

    • Copy .env.example to .env.

    • Edit .env and set API_KEY to your Alpha Vantage API key.

    • Optionally set AV_PREMIUM=true if you have a premium subscription.

    • Adjust LOG_LEVEL or RESOURCE_CLEANUP_INTERVAL if needed.

  4. Build the Project:

    npm run build
    # or
    yarn build
  5. Start the Server:

    npm start
    # or
    yarn start

    The server will listen for MCP requests on stdio.

Authentication

The server uses the standard multi-user token handling pattern:

  1. extraArgs.apiKey (Recommended): Pass the user-specific Alpha Vantage API key in the apiKey field of the extraArgs object during the MCP call_tool request. This key is not part of the tool's schema.

  2. .env Fallback: If extraArgs.apiKey is not provided, the server uses the API_KEY value from the .env file.

Available Tools

This server exposes numerous tools corresponding to the methods in the @missionsquad/avantage library. Tools are generally named module_method (e.g., coreStock_intraday, fundamentalData_companyOverview).

Refer to the Alpha Vantage documentation and the @missionsquad/avantage library's types (src/types/* within the library) for details on parameters and return structures.

Example Tool Call (Conceptual MCP Request):

{
  "type": "call_tool",
  "requestId": "req-123",
  "tool": {
    "name": "coreStock_quote",
    "arguments": {
      "symbol": "IBM"
    }
  },
  "context": {
    "extraArgs": {
      "apiKey": "USER_SPECIFIC_AV_KEY" // Optional: User's key
    }
  }
}

Tool Categories (Modules):

  • alphaIntelligence_*

  • commodities_*

  • coreStock_*

  • crypto_*

  • economicIndicators_*

  • forex_*

  • fundamentalData_*

  • optionsData_* (Premium)

  • technicalIndicators_*

Use the MCP list_tools command to get the full list of available tools, their descriptions, and parameter schemas.

Configuration

Configure via .env file:

Variable

Description

Default

API_KEY

Fallback Alpha Vantage API key if not in extraArgs

null

LOG_LEVEL

Logging level (error, warn, info, debug)

info

RESOURCE_CLEANUP_INTERVAL

Interval (ms) to clean up inactive AVantage client instances

1800000 (30m)

AV_PREMIUM

Set to true to enable premium endpoint access in avantage

false

Project Structure

Follows the generic MCP server template structure. Key files:

  • src/index.ts: Main server entry point, tool definitions.

  • src/config.ts: Configuration loading.

  • src/logger.ts: Logging utility.

  • src/resource-manager.ts: Manages AVantage instances.

  • src/schemas.ts: Zod schemas for tool parameters.

  • .nexus/: Nexus documentation.

Nexus Documentation

License

MIT (Assuming the template license is MIT. Verify.)

Available Tools

94 tools
alphaIntelligence_insiderTransactionsC

Fetches aggregated insider trading information for a given symbol.

Inputs: symbol (required).

alphaIntelligence_newsSentimentsC

Fetches market news and sentiment data from Alpha Vantage.

Inputs: tickersList, topics, time_from, time_to, +2 more.

alphaIntelligence_topGainersLosersB

Retrieves the top N gainers, losers, and most actively traded US tickers.

Inputs: no named parameters.

commodities_aluminumC

Retrieves aluminum prices.

Inputs: interval, datatype.

commodities_brentCrudeOilC

Retrieves Brent crude oil prices.

Inputs: interval, datatype.

commodities_coffeeB

Retrieves coffee prices.

Inputs: interval, datatype.

commodities_copperC

Retrieves copper prices.

Inputs: interval, datatype.

commodities_cornC

Retrieves corn prices.

Inputs: interval, datatype.

commodities_cottonC

Retrieves cotton prices.

Inputs: interval, datatype.

commodities_globalIndexC

Retrieves the global commodity index.

Inputs: interval, datatype.

commodities_naturalGasC

Retrieves natural gas prices.

Inputs: interval, datatype.

commodities_sugarC

Retrieves sugar prices.

Inputs: interval, datatype.

commodities_wheatC

Retrieves wheat prices.

Inputs: interval, datatype.

commodities_wtiCrudeOilC

Retrieves West Texas Intermediate (WTI) crude oil prices.

Inputs: interval, datatype.

coreStock_bulkQuotesA

Fetches realtime quotes for multiple stock symbols (up to 100). Premium endpoint.

Inputs: symbols (required), datatype.

coreStock_dailyC

Fetches daily time series data for a stock symbol.

Inputs: symbol (required), outputsize, datatype.

coreStock_dailyAdjustedC

Fetches daily adjusted time series data for a stock symbol.

Inputs: symbol (required), outputsize, datatype.

coreStock_intradayC

Fetches intraday time series data for a stock symbol.

Inputs: symbol (required), interval (required), adjusted, extended_hours, +3 more.

coreStock_monthlyC

Fetches monthly time series data for a stock symbol.

Inputs: symbol (required), datatype.

coreStock_monthlyAdjustedB

Fetches monthly adjusted time series data for a stock symbol.

Inputs: symbol (required), datatype.

coreStock_quoteC

Fetches a global quote for a single stock symbol.

Inputs: symbol (required), datatype.

coreStock_weeklyC

Fetches weekly time series data for a stock symbol.

Inputs: symbol (required), datatype.

coreStock_weeklyAdjustedC

Fetches weekly adjusted time series data for a stock symbol.

Inputs: symbol (required), datatype.

crypto_dailyB

Fetches daily time series data for a cryptocurrency.

Inputs: symbol (required), market (required), datatype.

crypto_exchangeRatesC

Fetches the realtime exchange rate for a cryptocurrency pair (e.g., BTC to USD).

Inputs: from_currency (required), to_currency (required).

crypto_intradayC

Fetches intraday time series data for a cryptocurrency.

Inputs: symbol (required), market (required), interval (required), outputsize, +1 more.

crypto_monthlyB

Fetches monthly time series data for a cryptocurrency.

Inputs: symbol (required), market (required), datatype.

crypto_weeklyC

Fetches weekly time series data for a cryptocurrency.

Inputs: symbol (required), market (required), datatype.

economicIndicators_cpiC

Retrieves US Consumer Price Index (CPI) data.

Inputs: interval, datatype.

economicIndicators_durableGoodsOrdersB

Retrieves US durable goods orders data.

Inputs: datatype.

economicIndicators_federalFundsRateB

Retrieves the effective federal funds rate.

Inputs: interval, datatype.

economicIndicators_inflationC

Retrieves US inflation rate data.

Inputs: datatype.

economicIndicators_nonfarmPayrollC

Retrieves US nonfarm payroll data.

Inputs: datatype.

economicIndicators_realGDPB

Retrieves US Real Gross Domestic Product (GDP) data.

Inputs: interval, datatype.

economicIndicators_realGDPPerCapitaC

Retrieves US Real GDP per Capita data.

Inputs: datatype.

economicIndicators_retailSalesC

Retrieves US retail sales data.

Inputs: datatype.

economicIndicators_treasuryYieldC

Retrieves US Treasury yield curve data for various maturities.

Inputs: interval, maturity, datatype.

economicIndicators_unemploymentRateC

Retrieves US unemployment rate data.

Inputs: datatype.

forex_dailyC

Fetches daily time series data for a Forex pair.

Inputs: from_symbol (required), to_symbol (required), outputsize, datatype.

forex_exchangeRatesC

Fetches the realtime exchange rate for a currency pair (e.g., EUR to USD).

Inputs: from_currency (required), to_currency (required).

forex_intradayB

Fetches intraday time series data for a Forex pair.

Inputs: from_symbol (required), to_symbol (required), interval (required), outputsize, +1 more.

forex_monthlyC

Fetches monthly time series data for a Forex pair.

Inputs: from_symbol (required), to_symbol (required), datatype.

forex_weeklyB

Fetches weekly time series data for a Forex pair.

Inputs: from_symbol (required), to_symbol (required), datatype.

fundamentalData_balanceSheetC

Fetches balance sheet data (annual/quarterly). Premium endpoint.

Inputs: symbol (required).

fundamentalData_cashFlowB

Fetches cash flow data (annual/quarterly). Premium endpoint.

Inputs: symbol (required).

fundamentalData_companyOverviewC

Fetches company overview details. Premium endpoint.

Inputs: symbol (required).

fundamentalData_dividendsC

Fetches historical dividend data for a symbol.

Inputs: symbol (required).

fundamentalData_earningsC

Fetches earnings data (annual/quarterly). Premium endpoint.

Inputs: symbol (required).

fundamentalData_earningsCalendarC

Fetches upcoming earnings calendar (CSV endpoint).

Inputs: symbol, horizon.

fundamentalData_etfProfileC

Fetches ETF profile details.

Inputs: symbol (required).

fundamentalData_incomeStatementC

Fetches income statement data (annual/quarterly). Premium endpoint.

Inputs: symbol (required).

fundamentalData_ipoCalendarB

Fetches upcoming IPO calendar (CSV endpoint).

Inputs: no named parameters.

fundamentalData_listingStatusC

Fetches active or delisted symbols (CSV endpoint).

Inputs: symbol, date, state.

fundamentalData_splitsC

Fetches historical stock split data for a symbol.

Inputs: symbol (required).

optionsData_historicalOptionsC

Fetches historical options chain data. Premium endpoint.

Inputs: symbol (required), date, datatype.

optionsData_realtimeOptionsC

Fetches realtime options chain data. Premium endpoint.

Inputs: symbol (required), contract, datatype.

technicalIndicators_adD

Chaikin A/D Line

Inputs: symbol (required), interval (required), datatype, month.

technicalIndicators_adoscD

Chaikin A/D Oscillator

Inputs: symbol (required), interval (required), datatype, month, +2 more.

technicalIndicators_aroonD

Aroon

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_aroonoscD

Aroon Oscillator

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_atrD

Average True Range (ATR)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_bbandsD

Bollinger Bands (BBANDS)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_demaD

Double Exponential Moving Average (DEMA)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_dxD

Directional Movement Index (DX)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_emaC

Exponential Moving Average (EMA)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_htDcperiodD

Hilbert Transform - Dominant Cycle Period

Inputs: symbol (required), interval (required), series_type (required), datatype, +1 more.

technicalIndicators_htDcphaseD

Hilbert Transform - Dominant Cycle Phase

Inputs: symbol (required), interval (required), series_type (required), datatype, +1 more.

technicalIndicators_htPhasorC

Hilbert Transform - Phasor Components

Inputs: symbol (required), interval (required), series_type (required), datatype, +1 more.

technicalIndicators_htSineD

Hilbert Transform - Sine Wave

Inputs: symbol (required), interval (required), series_type (required), datatype, +1 more.

technicalIndicators_htTrendlineC

Hilbert Transform - Instantaneous Trendline

Inputs: symbol (required), interval (required), series_type (required), datatype, +1 more.

technicalIndicators_htTrendmodeC

Hilbert Transform - Trend vs Cycle Mode

Inputs: symbol (required), interval (required), series_type (required), datatype, +1 more.

technicalIndicators_kamaC

Kaufman Adaptive Moving Average (KAMA)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_mamaC

MESA Adaptive Moving Average (MAMA)

Inputs: symbol (required), interval (required), series_type (required), datatype, +3 more.

technicalIndicators_mfiD

Money Flow Index (MFI)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_midpointD

Midpoint over period

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_midpriceC

Midpoint price over period

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_minusDID

Minus Directional Indicator (-DI)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_minusDMD

Minus Directional Movement (-DM)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_natrD

Normalized Average True Range (NATR)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_obvD

On Balance Volume (OBV)

Inputs: symbol (required), interval (required), datatype, month.

technicalIndicators_plusDID

Plus Directional Indicator (+DI)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_plusDMD

Plus Directional Movement (+DM)

Inputs: symbol (required), interval (required), time_period (required), datatype, +1 more.

technicalIndicators_rocrD

Rate of change ratio (ROCR)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_sarD

Parabolic SAR

Inputs: symbol (required), interval (required), datatype, month.

technicalIndicators_smaD

Simple Moving Average (SMA)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_t3D

Triple Exponential Moving Average (T3)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_temaD

Triple Exponential Moving Average (TEMA)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_trangeD

True Range

Inputs: symbol (required), interval (required), datatype, month.

technicalIndicators_trimaD

Triangular Moving Average (TRIMA)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_trixC

1-day Rate Of Change (ROC) of a Triple Smooth EMA (TRIX)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

technicalIndicators_ultoscD

Ultimate Oscillator

Inputs: symbol (required), interval (required), datatype, month.

technicalIndicators_vwapA

Volume Weighted Average Price (VWAP). Premium endpoint, requires intraday interval.

Inputs: symbol (required), interval (required), datatype, month.

technicalIndicators_wmaD

Weighted Moving Average (WMA)

Inputs: symbol (required), interval (required), time_period (required), series_type (required), +2 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.7/5.0

    Scored across 94 tools

    Disambiguation4/5

    Tools are well-organized into clear categories (e.g., commodities, coreStock, technicalIndicators) with distinct purposes within each category. However, some overlap exists, such as multiple time-series tools (daily, weekly, monthly) across different asset classes, which could cause confusion if an agent doesn't carefully note the category prefix.

    Naming Consistency5/5

    Naming follows a highly consistent pattern throughout: category_prefix followed by snake_case descriptor (e.g., coreStock_daily, technicalIndicators_sma). This structure is predictable and aids in tool identification, with no mixing of conventions or chaotic naming.

    Tool Count2/5

    With 94 tools, the count is excessive for a single server, making it overwhelming and difficult for an agent to navigate efficiently. While the server covers a broad financial data domain, the sheer volume suggests poor scoping, as many tools (e.g., individual technical indicators) could be consolidated into fewer, more flexible endpoints.

    Completeness5/5

    The tool set provides comprehensive coverage across financial data domains, including stocks, forex, crypto, commodities, economic indicators, and technical analysis. It supports full CRUD-like operations for data retrieval with various granularities (intraday to monthly) and includes premium endpoints, leaving no obvious gaps for the stated purpose of financial data access.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      A Model Context Protocol (MCP) server that provides real-time access to financial market data through the free Alpha Vantage API. This server implements a standardized interface for retrieving stock quotes and company information.
      12
      104
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      A Model Context Protocol server providing comprehensive access to Yahoo Finance data through the yahooquery library, enabling AI assistants to retrieve stock prices, financial statements, market data, and company analytics.
      12
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol server that retrieves real-time financial and company data using the financialdatasets API. It provides a standardized interface for integrating financial data into agentic frameworks like Agno and Smol Agent.
      MIT