Skip to content

argotdev/plaid-mcp-ts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Plaid MCP Server

A Model Context Protocol (MCP) server for integrating with Plaid's API in sandbox mode. This server provides tools for linking bank accounts, retrieving transactions, balances, and account information.

Features

  • Create Link tokens for Plaid Link initialization
  • Exchange public tokens for access tokens
  • Retrieve account information
  • Fetch transactions within date ranges
  • Get real-time balance information

Prerequisites

  • Node.js 18 or higher
  • Plaid account with sandbox credentials

Setup

  1. Get Plaid Credentials

    • Sign up at Plaid Dashboard
    • Navigate to Developers > Keys
    • Copy your client_id and sandbox secret
  2. Install Dependencies

    npm install
  3. Configure Environment

    cp .env.example .env

    Edit .env and add your credentials:

    PLAID_CLIENT_ID=your_client_id_here
    PLAID_SECRET=your_sandbox_secret_here
    
  4. Build the Server

    npm run build

Usage

Running the Server

npm start

Available Tools

1. create_link_token

Create a Link token for initializing Plaid Link.

Parameters:

  • user_id (required): Unique ID for the user
  • client_name (required): Name of your application
  • products (optional): Array of products (default: ["transactions"])
  • country_codes (optional): Array of country codes (default: ["US"])
  • language (optional): Language code (default: "en")

2. exchange_public_token

Exchange a public token for an access token.

Parameters:

  • public_token (required): Public token from Plaid Link

3. get_accounts

Retrieve account information.

Parameters:

  • access_token (required): Access token for the linked item

4. get_transactions

Fetch transactions within a date range.

Parameters:

  • access_token (required): Access token for the linked item
  • start_date (required): Start date (YYYY-MM-DD)
  • end_date (required): End date (YYYY-MM-DD)

5. get_balance

Get real-time balance information.

Parameters:

  • access_token (required): Access token for the linked item

Testing in Sandbox

The server is configured to use Plaid's sandbox environment. Use these test credentials when testing with Plaid Link:

  • Username: user_good
  • Password: pass_good

See Plaid's Sandbox Guide for more test credentials and scenarios.

Development

Watch mode for development:

npm run dev

Connecting to Claude Desktop

To use this MCP server with Claude Desktop, add the following to your Claude Desktop config:

MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "plaid": {
      "command": "node",
      "args": ["/absolute/path/to/plaid-mcp/build/index.js"],
      "env": {
        "PLAID_CLIENT_ID": "your_client_id_here",
        "PLAID_SECRET": "your_sandbox_secret_here"
      }
    }
  }
}

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published