Alpaca MCP Server Integration
Connect your AI assistant to Alpaca’s trading and market data platform using the Alpaca MCP Server for seamless financial workflows directly from your favorite LLM-based tools.

What does “Alpaca” MCP Server do?
The Alpaca MCP (Model Context Protocol) Server is a specialized integration layer that allows AI assistants and large language models (LLMs) to interact with Alpaca’s trading platform using natural language commands. By connecting through MCP, developers and users can trade stocks and options, analyze financial data, manage portfolios, handle watchlists, and access real-time market information directly from their favorite LLM tools and IDEs such as Claude Desktop, Cursor, and VScode. This server bridges the gap between AI agents and trading infrastructure, making tasks like placing orders, retrieving historical data, or monitoring asset watchlists seamless and accessible through conversational interfaces, thereby streamlining the workflow for algorithmic trading, financial analysis, and portfolio management.
List of Prompts
No prompt templates are explicitly mentioned in the provided repository or documentation.
List of Resources
No explicit MCP resources are described in the provided files or documentation.
List of Tools
No explicit list of tools is included in the accessible files or documentation.
Use Cases of this MCP Server
Stock and Options Trading
Use natural language to place, modify, and cancel stock and options trades directly from an LLM-powered interface, enabling algorithmic and discretionary trading workflows without manual platform navigation.Portfolio Management
View account balances, inspect open and closed positions, and manage your holdings using conversational commands to streamline portfolio oversight and rebalancing.Market Data Retrieval
Request real-time and historical market data, including quotes, trades, price bars, and option Greeks, to support research and strategy development.Watchlist Management
Create and manage personalized watchlists for tracking assets, helping users monitor multiple securities and react to market changes efficiently.Order History and Market Status
Retrieve full order history, check the market’s open/close status, and access corporate action data (earnings, splits, dividends) for comprehensive account and market awareness.
How to set it up
Windsurf
No Windsurf-specific instructions are provided in the available documentation or code.
Claude
Prerequisites:
- Install Python 3.10+
- Clone the repository and install dependencies
- Obtain Alpaca API keys
Create/Edit
.env
file:
Add the following to your.env
in the project directory:ALPACA_API_KEY = "your_alpaca_api_key" ALPACA_SECRET_KEY = "your_alpaca_secret_key" PAPER = True
Start MCP Server:
python alpaca_mcp_server.py
Configure Claude Desktop:
- Open Claude Desktop
- Navigate to:
Settings → Developer → Edit Config
- Update your
claude_desktop_config.json
:{ "mcpServers": { "alpaca": { "command": "<project_root>/venv/bin/python", "args": [ "/path/to/alpaca-mcp-server/alpaca_mcp_server.py" ], "env": { "ALPACA_API_KEY": "your_alpaca_api_key", "ALPACA_SECRET_KEY": "your_alpaca_secret_key" } } } }
Save configuration and restart Claude Desktop
Cursor
No Cursor-specific instructions are provided in the available documentation or code.
Cline
No Cline-specific instructions are provided in the available documentation or code.
Securing API Keys
API keys are specified using environment variables, as shown in the env
section of the JSON configuration:
"env": {
"ALPACA_API_KEY": "your_alpaca_api_key",
"ALPACA_SECRET_KEY": "your_alpaca_secret_key"
}
How to use this MCP inside flows
Using MCP in FlowHunt
To integrate MCP servers into your FlowHunt workflow, start by adding the MCP component to your flow and connecting it to your AI agent:

Click on the MCP component to open the configuration panel. In the system MCP configuration section, insert your MCP server details using this JSON format:
{
"MCP-name": {
"transport": "streamable_http",
"url": "https://yourmcpserver.example/pathtothemcp/url"
}
}
Once configured, the AI agent is now able to use this MCP as a tool with access to all its functions and capabilities. Remember to change “MCP-name” to whatever the actual name of your MCP server is (e.g., “alpaca”, “github-mcp”, etc.) and replace the URL with your own MCP server URL.
Overview
Section | Availability | Details/Notes |
---|---|---|
Overview | ✅ | Full overview in README.md |
List of Prompts | ⛔ | No prompt templates mentioned |
List of Resources | ⛔ | No explicit MCP resources listed |
List of Tools | ⛔ | No explicit tools documented |
Securing API Keys | ✅ | Via env in config JSON and .env file |
Sampling Support (less important in evaluation) | ⛔ | Not mentioned |
Between these two tables, the Alpaca MCP server offers strong documentation on setup and core use cases, but lacks explicit details on MCP prompt templates, exposed tools, and resource definitions. It’s well-suited for trading and market data workflows, but would benefit from more detailed MCP-specific documentation. Rating: 6/10.
MCP Score
Has a LICENSE | ✅ (MIT) |
---|---|
Has at least one tool | ⛔ |
Number of Forks | 26 |
Number of Stars | 90 |
Frequently asked questions
- What is the Alpaca MCP Server?
The Alpaca MCP Server is an integration layer that connects AI assistants and LLMs to Alpaca’s trading platform, enabling natural language commands for trading, portfolio management, and market data access.
- What can I do with Alpaca MCP in FlowHunt?
You can place, modify, or cancel trades, manage portfolios and watchlists, and retrieve real-time or historical market data—all from AI-driven interfaces.
- How do I keep my API keys secure?
API keys should be stored in environment variables or a `.env` file, not hardcoded in your code or configuration, to prevent accidental exposure.
- Which clients are supported?
The server is documented for use with Claude Desktop. Other clients like Cursor and Cline may require manual setup using similar MCP configurations.
- Are prompt templates or custom MCP tools available?
No explicit prompt templates or custom MCP tools are provided in the current documentation for Alpaca MCP.
Supercharge Your Trading with Alpaca MCP
Bring algorithmic trading and financial management to your AI flows by integrating the Alpaca MCP Server. Trade, analyze, and manage portfolios with natural language commands.