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

palantir-mcp

v0.13.0

Published

A lightweight open-source MCP wrapper for downloading and installing the @palantir/mcp package from secure Foundry environments.

Readme

Palantir MCP

A lightweight open-source wrapper for downloading and installing the @palantir/mcp package from secure Foundry environments.

Overview

This tool provides a streamlined way to access and run Palantir's Model Context Protocol (MCP) server from within Foundry environments. It handles authentication, package retrieval, and environment setup automatically.

How It Works

  1. Preflight Checks: Validates Node.js version, network connectivity to Foundry, and token authentication
  2. Registry Setup: Configures NPM to use Foundry's internal package registry
  3. Package Execution: Downloads and runs the latest @palantir/mcp package from your secure Foundry environment with your provided arguments

🛠️ Installation

Requirements

  • Node.js 18 or higher
  • Valid Foundry instance access
  • Foundry user token with appropriate permissions

MCP Inspector

Test the palantir-mcp using the mcp-inspector package.

# Replace the below with your Foundry URL
export FOUNDRY_HOST="<enrollment>.palantirfoundry.com"

# Replace the below with your Foundry Token
export FOUNDRY_TOKEN=<token>

npx @modelcontextprotocol/inspector \
  npx -y palantir-mcp \
  --foundry-api-url \
  https://$FOUNDRY_HOST

Claude Code

# Replace the below with your Foundry URL
export FOUNDRY_HOST="<enrollment>.palantirfoundry.com"

# Replace the below with your Foundry Token
export FOUNDRY_TOKEN=<token>

claude mcp add palantir-mcp \
    --scope user \
    -e FOUNDRY_TOKEN=$FOUNDRY_TOKEN \
    -- npx "-y" "palantir-mcp" "--foundry-api-url" "https://$FOUNDRY_HOST"

Cursor

{
  "mcpServers": {
    "palantir-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "palantir-mcp",
        "--foundry-api-url",
        "https://<enrollment>.palantirfoundry.com" // Replace with your Foundry URL
      ],
      "env": {
        "FOUNDRY_TOKEN": "<token>" // Replace with your Foundry Token
      }
    }
  }
}

VS Code Copilot

"mcp": {
    "inputs": [
        {
            "type": "promptString",
            "id": "foundry-token",
            "description": "Foundry user token",
            "password": true
        }
    ],
    "servers": {
        "Palantir": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "palantir-mcp",
                "--foundry-api-url",
                "https://<enrollment>.palantirfoundry.com" // Replace with your Foundry URL
            ],
            "env": {
                "FOUNDRY_TOKEN": "${input:foundry-token}"
            }
        }
    }
}

Cline

{
  "mcpServers": {
    "palantir-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "palantir-mcp",
        "--foundry-api-url",
        "https://<enrollment>.palantirfoundry.com" // Replace with your Foundry URL
      ],
      "env": {
        "FOUNDRY_TOKEN": "<token>" // Replace with your Foundry Token
      },
      "disabled": false
    }
  }
}

Development

# Install dependencies
npm install

# Run in development mode
npm run dev -- --foundry-api-url https://<enrollment>.palantirfoundry.com --foundry-token <token>

# Run tests
npm test

# Run tests with coverage
npm run test:coverage

# Build for production
npm run build

# Lint and format
npm run lint
npm run format

Architecture

The tool is organized into focused modules:

  • cli.ts - Command-line argument parsing and validation
  • spawn.ts - Process spawning and signal handling
  • registry.ts - NPM registry URL construction
  • errors.ts - Custom error classes for better error handling
  • preflightChecks.ts - Validation of environment and credentials
  • index.ts - Main orchestration logic

Error Handling

The tool provides detailed error messages for common issues:

  • Node Version Error: When Node.js version is below 18
  • Network Error: When unable to reach Foundry API
  • Authentication Error: When token is invalid or expired
  • Package Fetch Error: When unable to retrieve the MCP package

Contributing

Contributions are welcome! Please ensure:

  1. All tests pass (npm test)
  2. Code is properly linted (npm run lint)
  3. Code is formatted (npm run format)
  4. Type checking passes (npm run typecheck)

License

MIT - See LICENSE file for details

Support

For issues related to:

  • This wrapper tool: Please open an issue in this repository
  • The underlying @palantir/mcp package: Contact Foundry support
  • Foundry access or tokens: Contact your Foundry administrator