npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@paubox/mcp

v2.1.0

Published

This is the official Model Context Protocol (MCP) server for Paubox Email API, designed to be hosted by Paubox and used by customers with their own API credentials.

Readme

Official Paubox MCP Server

This is the official Model Context Protocol (MCP) server for Paubox Email API, designed to be hosted by Paubox and used by customers with their own API credentials.

Overview

This MCP server enables AI assistants to send secure, HIPAA-compliant emails through the Paubox Email API and to retrieve and submit Paubox Forms. Users provide their own API key per session, ensuring security and multi-tenant support.

Features

  • Send secure emails with optional encryption
  • Check email delivery status
  • Retrieve Paubox Form metadata and field schemas
  • Submit Paubox Form responses (with optional file attachments)
  • Manage Paubox Forms — create, update, archive, copy, list submissions, and export data (requires a scoped API key)
  • HIPAA-compliant communication
  • Easy integration with AI assistants that support MCP
  • Paubox-branded UI with official components and styling
  • Proxy support for custom endpoints (development/testing)

For Paubox Customers

You don't host or clone anything to use Paubox MCP — Paubox runs the server at https://mcp.paubox.com/mcp. Add it as a connector in your AI client and enter your Paubox API key in the connector configuration form when prompted. See Connecting to AI Assistants below for client-specific setup.

The rest of this README covers self-hosting and local development.

Proxy Configuration (Development/Testing)

For development or testing purposes, you can configure the MCP server to proxy requests to a custom endpoint instead of the official Paubox API.

Manual Setup

To enable the proxy, you need to manually import the proxy module in your application. Add this import to your main application file or where you initialize your server:

// Import this in your main app file to enable proxy functionality
import './lib/paubox-proxy'

Environment Variables

Set these environment variables to enable proxy functionality:

# Enable proxy mode
PAUBOX_PROXY_ENABLED=true

# Custom base URL for proxying requests
PAUBOX_CUSTOM_BASE_URL=https://your-custom-endpoint.com

How It Works

The proxy system uses axios interceptors to automatically redirect all Paubox API requests from:

  • https://api.paubox.com/v1/email/

To your custom endpoint:

  • https://your-custom-endpoint.com/v1/email/

The proxy replaces the original API domain (https://api.paubox.com) with your custom base URL while preserving the API path structure.

Use Cases

  • Testing: Point to a mock API server for testing
  • Development: Use a local development server
  • Custom Deployment: Route through your own proxy server
  • Staging: Use a staging environment

Example Configuration

# For local development
PAUBOX_PROXY_ENABLED=true
PAUBOX_CUSTOM_BASE_URL=http://localhost:8080

# For staging environment
PAUBOX_PROXY_ENABLED=true
PAUBOX_CUSTOM_BASE_URL=https://staging-api.paubox.com

Implementation Details

The proxy is implemented in lib/paubox-proxy.ts and only initializes when the PAUBOX_PROXY_ENABLED environment variable is set to true. It intercepts all HTTP requests made by the email API client (lib/paubox-email.ts) and modifies the base URL accordingly.

Note: The proxy is not automatically loaded by the MCP server to avoid test interference. You must manually import it if you want to use proxy functionality.

Styling & Components

This project uses Paubox's official design system:

  • Brand Colors: Implements Paubox's official color palette
  • Logo: Features the official Paubox logo
  • Typography: Uses Paubox's design tokens and spacing

Color System

The application uses Paubox's official color palette:

  • Primary (Blue): #2E70FF - Main brand color
  • Success (Green): #0EA472 - Success states
  • Warning (Yellow): #FFCA2F - Warning states
  • Danger (Red): #E02D3C - Error states
  • Neutral (Gray): Various shades for text and backgrounds

Components

Available Paubox components include:

  • Buttons with various styles and states
  • Cards with branded headers and content areas
  • Alerts for notifications and warnings
  • Typography components
  • Form inputs and controls

Connecting to AI Assistants

There are three ways to provide your Paubox API key, in resolution priority order:

  • Per-call tool parameters (highest priority): Pass apiKey directly in each tool call. Useful for one-off use or scripted clients.
  • Custom connector headers: Set x-paubox-api-key as a custom request header on the connector. Some MCP clients expose this in Advanced Settings when adding a custom connector.
  • OAuth (recommended for Claude.ai and Claude Desktop): Add the connector URL and a "Configure Paubox" form appears automatically. Enter your API key once — the client stores a short-lived encrypted Bearer token and sends it on every future request. The key is validated against the Paubox API at the moment you submit the form, so typos or expired keys are caught immediately.

Claude.ai — Claude Connectors (recommended)

  1. Go to claude.ai and open Settings → Integrations
  2. Click Add connector and enter URL https://mcp.paubox.com/mcp
  3. A "Configure Paubox" form opens — enter your API key
  4. Click Save

Claude stores your API key as a secure token in the system keychain and sends it automatically on every request. You never need to include credentials in your prompts.

Claude Code

Install once with your API key — no credential prompts afterward:

claude mcp add paubox \
  -e PAUBOX_API_KEY=your_api_key \
  -- npx @paubox/mcp@latest

Claude Code spawns the package locally and injects the API key as an environment variable. All tools — email, forms, and forms management — work without passing credentials in each call.

Claude Desktop

  1. Open Claude Desktop and navigate to Settings
  2. Under the Developer tab, tap Edit Config
  3. Add this configuration:
{
  "mcpServers": {
    "paubox": {
      "url": "https://mcp.paubox.com/mcp"
    }
  }
}
  1. Save the file — Claude Desktop will open a browser window to the "Configure Paubox" form to collect your API key.

Cursor (for local testing)

Add to .cursor/mcp.json:

{
  "mcpServers": {
    "paubox": {
      "url": "https://mcp.paubox.com/mcp"
    }
  }
}

Available Tools

Note: When connecting via the @paubox/mcp npm package (Claude Code / stdio), the API key comes from the PAUBOX_API_KEY environment variable set at install time — apiKey is not required in any tool call. When connecting via the hosted HTTP server (https://mcp.paubox.com/mcp), the API key is resolved from the OAuth token, the x-paubox-api-key header, or tool parameters.

validate_credentials

Confirms that a Paubox API key is present and correctly formatted.

Parameters (HTTP / hosted server only):

  • apiKey: Your Paubox API key (string, optional if provided via connector headers or OAuth)

Example Usage: ``` Validate my Paubox credentials with API key "pk_live_..." ```

send_secure_email

Sends a secure email using your Paubox API key.

Parameters:

  • apiKey: Your Paubox API key (string, optional — HTTP/hosted server only)
  • from: Sender email address (string, required)
  • to: Recipient email addresses (array, required)
  • subject: Email subject (string, required)
  • message: Email content (string, required). Plain text; blank lines become paragraphs and single newlines become line breaks in the HTML version. Bare URLs are made clickable.
  • html: HTML body (string, optional). Used verbatim as the text/html part when provided; message is still sent as the text/plain fallback. Omit it to have message rendered to HTML automatically.
  • cc: CC recipients (array, optional)
  • bcc: BCC recipients (array, optional)
  • forceSecureNotification: Force secure notification (boolean, optional)
  • attachments: File attachments (array, optional). Each item is { fileName, contentType, content } where content is the base64-encoded file. 25 MB total limit across all attachments.

schedule_email accepts the same parameters (including attachments) plus an ISO 8601 scheduledAt.

Example Usage (credentials via connector): ``` Send a secure email from "[email protected]" to "[email protected]" with subject "Test Results" and message "Your results are ready." ```

Example Usage (credentials as parameters): ``` Send a secure email using my API key "pk_live_..." from "[email protected]" to "[email protected]" with subject "Test Results" and message "Your results are ready." ```

check_email_status

Checks the delivery status of a sent email.

Parameters:

  • apiKey: Your Paubox API key (string, optional — HTTP/hosted server only)
  • sourceTrackingId: Tracking ID from sent email (string, required)

Example Usage: ``` Check the status of email with tracking ID "abc123" ```

get_form

Retrieves metadata and the field schema for a Paubox Form. No API credentials required.

Parameters:

  • formId: UUID of the Paubox Form (string, required)

Returns: id, title, description, field definitions (form_json), active status, signable flag, submission count, and timestamps.

Example Usage: ``` Get the form schema for Paubox form "550e8400-e29b-41d4-a716-446655440000" ```

submit_form

Submits a response to a Paubox Form. No API credentials required.

Parameters:

  • formId: UUID of the Paubox Form (string, required)
  • formData: Key-value pairs matching the form's field schema (object, required)
  • attachments: Optional file attachments (array of { name, content } where content is base64-encoded)

Example Usage: ``` Submit form "550e8400-e29b-41d4-a716-446655440000" with first_name "Jane", last_name "Smith", and email "[email protected]" ```

Paubox Forms management

The following tools manage forms and their submissions. Unlike get_form and submit_form (which remain credential-free), they require a scoped Paubox API key carrying the forms scope, sent as a Bearer token. This reuses the existing apiKey credential — via OAuth, x-paubox-api-key header, tool parameter, or the PAUBOX_API_KEY env var on stdio. Scoped API keys are managed in the Paubox admin dashboard.

  • list_forms: List a customer's forms with search, sorting, archived/active filters, and pagination (customerId required)
  • create_form: Create a new form from a title, field schema (formJson), and customerId, with optional description, HTML/CSS, notification recipients, and signable settings
  • update_form: Partially update a form — title, description, formJson, vanity URL, recipients, active status, or subscription list
  • archive_form / unarchive_form: Archive a form (deactivates it) or restore it
  • copy_form: Duplicate an existing form under a new title
  • get_form_stats: Active form count, total submissions, and submissions in the last 7 days
  • list_form_submissions: List a form's submissions with parsed field data, submitter email, and attachment info
  • export_submissions_csv: Export a form's submissions (or a single submission) as CSV
  • export_submission_pdf: Export a single submission as a base64-encoded PDF

With an apiKey available, get_form also uses the authenticated API, so inactive and archived forms become retrievable.

Example Usage: ``` List the active forms for customer 1234, then show me the submissions for the intake form ```

Paubox Email Marketing

These tools read and write Paubox Email Marketing data using the same apiKey credential as the email tools — no extra scope is needed, but the account must have Email Marketing provisioned. Run validate_marketing_access first if another marketing tool reports that no marketing customer was found.

This tranche is read-only plus safe subscriber and list writes. Campaign sending and bulk deletion are deliberately not exposed; they need their own confirmation model first.

Access and subscribers

  • validate_marketing_access: Confirm Email Marketing is provisioned and return the marketing customer profile (name, from_name, from_email, physical address, global unsubscribe setting)
  • list_subscribers: List subscribers with full-text search, scoping to a subscription or dynamic list, ordering, and pagination; omit subscriptionListId to search the default "All contacts" list
  • get_subscriber: Retrieve one subscriber by UUID, with custom field values and list memberships
  • create_subscriber: Add a subscriber (email or phone required); always joins "All contacts", updates rather than duplicates an existing match, and auto-creates unknown custom field names
  • update_subscriber: Partially update a subscriber by UUID; omitted fields stay unchanged
  • get_subscribed_count: Count currently subscribed (not unsubscribed, not deleted) contacts on a list
  • list_subscriber_custom_fields: Discover which custom field names create_subscriber and update_subscriber can set

Audiences

  • list_marketing_lists: All audiences — static subscription lists and filter-based dynamic lists — in one view with subscriber counts
  • list_subscription_lists: Static lists with their integer IDs, subscriber counts, and which is the default "All contacts" list. These IDs are what subscriptionListId expects elsewhere
  • create_subscription_list: Create a new empty subscription list and return its integer ID
  • list_dynamic_lists: Filter-based segments with their UUIDs, filter definitions, and subscriber counts

Campaigns and reporting

  • list_campaign_sends: Each time a marketing email went out to a list, with per-send delivered / viewed / clicked / bounced / unsubscribed counts
  • list_campaign_deliveries: One row per recipient per campaign; scope with campaignMailingId or campaignMailingSendId
  • get_campaign_analytics: Run one of five reports — campaign_mailing_sends_table, campaign_mailing_send_totals, campaign_mailing_deliveries_table, subscribers_by_tracking_link, tracking_links_by_unique_link
  • get_marketing_bulk_job: Check progress of an async bulk job; bulk imports and CSV exports return a job ID (jid/bid) instead of a result

Example Usage: ``` Which campaign send last month had the worst click rate, and who clicked the pricing link? ```

Keeping the tool list honest

tools.json is the manifest of every tool this server exposes. A test in __tests__/mcp-server.test.ts calls tools/list and asserts the live set matches it exactly, so adding or removing a tool fails CI until the manifest is updated in the same change.

When you update tools.json, update these too:

Security & Compliance

  • HIPAA Compliant: All emails are sent through Paubox's HIPAA-compliant infrastructure
  • Credential Security: API credentials are never stored or logged
  • Encrypted Transit: All communications use HTTPS/TLS encryption
  • Audit Trail: Email sending and status checking activities are logged (without credentials)

Support

For technical support or API access questions, contact Paubox support at [email protected].

Development

Environment variables

Copy .env.example to .env.local and fill in the required value:

cp .env.example .env.local

| Variable | Required | Description | |----------|----------|-------------| | JWT_SECRET | Yes | Signing secret for OAuth tokens. Generate with: openssl rand -base64 32 | | PAUBOX_API_KEY | No | Local-dev fallback. Honored only when NODE_ENV !== 'production' and no OAuth token / x-paubox-* headers / tool parameters are present. Deliberately ignored in production to prevent cross-user credential bleed. |

Testing

Run the test suite:

pnpm test

Building

Build for production:

pnpm build

Deployment

This project uses GitHub Actions for automated deployment to AWS ECR with three distinct deployment workflows:

Deployment Workflows

  1. Staging Deployment (.github/workflows/deploy-staging.yml)

    • Trigger: Pushes to develop branch and pull requests to develop
    • Purpose: Builds and pushes Docker images to staging ECR for testing
    • Repository: paubox-mcp-server-staging
    • Tags: Git SHA, branch name, PR number, and latest for develop branch
  2. Production Deployment (.github/workflows/deploy-prod.yml)

    • Trigger: Pull request merges to main branch
    • Purpose: Automatically deploys approved changes to production
    • Repository: paubox-mcp-server-production
    • Tags: Git SHA and latest
    • Process: Builds Docker image directly from source code
  3. Hotfix Deployment (.github/workflows/deploy-hotfix.yml)

    • Trigger: Manual workflow dispatch
    • Purpose: Emergency deployments and urgent fixes
    • Repository: paubox-mcp-server-production
    • Use Cases: Critical bug fixes, security patches, rollbacks

GitHub Secrets

The deployment workflows use the following secrets configured at the organization level:

  1. AWS_GITHUB_ACTIONS_ACCESS_KEY_ID: AWS access key ID
  2. AWS_GITHUB_ACTIONS_SECRET_ACCESS_KEY: AWS secret access key

These credentials have permissions to:

  • Push to staging ECR repository: 285263271540.dkr.ecr.us-west-2.amazonaws.com/paubox-mcp-server-staging
  • Push to production ECR repository: 285263271540.dkr.ecr.us-west-2.amazonaws.com/paubox-mcp-server-production
  • Authenticate with ECR

Deployment Process

Staging Flow:

  1. Code pushed to develop branch or PR created
  2. GitHub Actions builds Docker image
  3. Image pushed to staging ECR with appropriate tags
  4. Available for testing and validation

Production Flow:

  1. PR merged to main branch
  2. GitHub Actions automatically builds production Docker image
  3. Image pushed to production ECR with git SHA and latest tags
  4. Ready for production deployment

Hotfix Flow:

  1. Manual workflow trigger
  2. Builds and deploys specific code version
  3. Bypasses normal PR process for urgent situations

Manual Deployment

To deploy a feature branch manually to staging:

  1. Go to the Actions tab in GitHub
  2. Select Deploy to Staging workflow
  3. Click Run workflow
  4. Enter the branch name you want to deploy
  5. Click Run workflow

For production hotfixes:

  1. Go to the Actions tab in GitHub
  2. Select Deploy Hotfix workflow
  3. Click Run workflow
  4. Follow the workflow prompts

Styling

The project uses a hybrid approach:

  • Tailwind CSS: For layout and responsive design
  • Paubox Colors: Official brand colors via lib/paubox-colors.ts
  • Component Styling: Inline styles for Paubox-specific theming

License

Licensed under the Apache License, Version 2.0.

Copyright © 2026 Paubox, Inc.

💬 Community & support

Questions, ideas, or want to share what you built? Join the Paubox Community — the single home for discussions across every Paubox SDK and API.

🔐 Found a security issue? Email [email protected] — please don't post it publicly.