npm package: @striderlabs/mcp-paypal
Description: MCP server for PayPal - browser automation via Playwright
Latest version: 0.1.0

# @striderlabs/mcp-paypal

An MCP (Model Context Protocol) server for PayPal that uses Playwright browser automation to interact with paypal.com.

## Overview

This MCP server allows AI assistants (such as Claude) to interact with a PayPal account by automating a real browser session. It supports checking balances, viewing transaction history, viewing subscriptions, and initiating money transfers.

## Tools

| Tool | Description |
|------|-------------|
| `get_balance` | Get the current PayPal account balance |
| `get_transactions` | Retrieve recent transaction history (configurable limit) |
| `get_activity` | Get detailed activity feed filtered by date range |
| `get_subscriptions` | View recurring payments and active subscriptions |
| `send_money` | Initiate a money transfer to an email or phone number |
| `request_money` | Request money from an email or phone number |

## Installation

```bash
npm install @striderlabs/mcp-paypal
```

Or install Playwright browsers after installing:

```bash
npx playwright install chromium
```

## Configuration

The server reads credentials from environment variables:

| Variable | Description | Required |
|----------|-------------|----------|
| `PAYPAL_EMAIL` | PayPal account email address | No (can log in manually) |
| `PAYPAL_PASSWORD` | PayPal account password | No (can log in manually) |

If credentials are not provided, the server will launch a browser and wait for a session that is already logged in. You can log in manually when prompted.

## Usage

### As a standalone MCP server

```bash
PAYPAL_EMAIL=you@example.com PAYPAL_PASSWORD=yourpassword npx mcp-paypal
```

### In Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "paypal": {
      "command": "node",
      "args": ["/path/to/node_modules/@striderlabs/mcp-paypal/dist/index.js"],
      "env": {
        "PAYPAL_EMAIL": "you@example.com",
        "PAYPAL_PASSWORD": "yourpassword"
      }
    }
  }
}
```

### With npx

```json
{
  "mcpServers": {
    "paypal": {
      "command": "npx",
      "args": ["-y", "@striderlabs/mcp-paypal"],
      "env": {
        "PAYPAL_EMAIL": "you@example.com",
        "PAYPAL_PASSWORD": "yourpassword"
      }
    }
  }
}
```

## Security Notes

- Credentials are passed via environment variables and never stored on disk by this package.
- The `send_money` and `request_money` tools fill out the payment form but do **not** automatically confirm the transaction. You must review and confirm manually in the browser for safety.
- This tool automates a real browser session. Be careful with credentials.
- Two-factor authentication (2FA) will require manual intervention in the browser window (set `headless: false` in browser.ts for interactive use).

## Development

```bash
# Install dependencies
npm install

# Build
npm run build

# Run in dev mode
npm run dev
```

### Project Structure

```
src/
  index.ts    - MCP server entry point, tool definitions and handlers
  browser.ts  - Playwright browser automation helpers for paypal.com
dist/         - Compiled JavaScript output (generated by tsc)
```

## Requirements

- Node.js 18+
- Playwright (Chromium browser will be downloaded automatically)

## License

MIT