Fire in da houseTop Tip:Paying $100+ per month for Perplexity, MidJourney, Runway, ChatGPT and other tools is crazy - get all your AI tools in one site starting at $15 per month with Galaxy AI Fire in da houseCheck it out free

box-mcp-server

MCP.Pizza Chef: hmk

The box-mcp-server is a Model Context Protocol server designed to integrate Box cloud storage with AI models. It allows secure searching, reading, and accessing of files stored in Box by leveraging JSON Web Token (JWT) authentication. This server supports persistent connections through JWT configuration, requiring a Box enterprise or developer account. It facilitates seamless interaction between AI models and Box file repositories, enabling real-time context retrieval and file operations within AI-enhanced workflows. The server is ideal for developers looking to embed Box file access into their MCP-enabled applications.

Use This MCP server To

Search files stored in Box cloud storage Read contents of Box files for AI context Access Box files securely via JWT authentication Integrate Box file data into AI workflows Enable persistent Box connections with JWT config

README

box-mcp-server

CI

Usage

You will need:

  • BOX_USER_ID

and one of the following:

  • BOX_JWT_BASE64 (recommended)
  • BOX_JWT_CONFIG_PATH
  • BOX_JWT

Auth

JSON Web Token (JWT) Authorization (recommended)

How to get a JWT

Using a JWT Config allows persistent connection to Box.

You will need a paid Box enterprise account, or you can sign up for a free developer account (make sure you are signed out of Box before clicking that link).

Visit the Box Developer Console and create a new application. Make sure the authorization type is JSON Web Token.

Go to Configuration > Add and Manage Public Keys and Generate a Public/Private Keypair. If you have not already, Box prompt you to set up 2 factor authentication and Authorize the application as an administrator in your box account. You will need to:

  1. give the application App + Enterprise Access, and
  2. enable the make API calls using the as-user header option

via the Box Application's Configuration page. Make sure to reauthorize the application if you are modifying these settings.

Base64 encoding JWT

To encode your JWT in Base64, you can use the following command in your terminal:

cat /path/to/your/box-jwt-config.json | base64

Replace /path/to/your/box-jwt-config.json with the actual path to your JWT configuration file. This will output the Base64 encoded JWT which you can then use in your environment variables.

Claude Desktop Configuration
{
  "mcpServers": {
    "box": {
      "command": "npx",
      "args": ["box-mcp-server"],
      "env": {
        "BOX_JWT_BASE64": "YOUR_BASE64_ENCODED_JWT",
        "BOX_USER_ID": "123456"
      }
    }
  }
}

Developer Token Authorization (easiest)

Using a developer token is the easiest way to integrate with Box, but will only last 60 minutes.

To get started, set the BOX_DEV_TOKEN to a Box Developer Token.

Begin by visiting the Box Developer Console and create a new application. The authorization type does not currently matter, as all support Box Developer Token.

Once your application is created, navigate to its configuration setings and click Generate Developer Token.

Claude Desktop Configuration
{
  "mcpServers": {
    "box": {
      "command": "npx",
      "args": ["box-mcp-server"],
      "env": {
        "BOX_DEV_TOKEN": "YOUR_DEV_TOKEN_GOES_HERE"
      }
    }
  }
}

Capabilities

  1. Searching files
  2. Reading files
  • PDF
  • Word
  • Others

Development

Prerequisites

Before you begin, ensure you have the following installed:

  • Node.js (recommended v22 or higher)
  • npm
  • git
  • dotenv

Setting up Development Environment

To set up the development environment, follow these steps:

  1. Fork the repository

    • Click the "Fork" button in the top-right corner of this repository
    • This creates your own copy of the repository under your Github acocunt
  2. Clone Your Fork:

    git clone https://github.com/YOUR_USERNAME/box-mcp-server.git
    cd box-mcp-server
  3. Add Upstream Remote

    git remote add upstream https://github.com/hmk/box-mcp-server.git
  4. Copy the dotenv file

    cp .env.template .env
  5. Install dependencies:

    npm install
  6. Run watch to keep index.js updated:

    npm run watch
  7. Start the model context protocol development server:

    dotenv npx @modelcontextprotocol/inspector node PATH_TO_YOUR_CLONED_REPO/dist/index.js
  8. If the development server did not load the environment variable correctly, set the BOX_DEV_TOKEN on the left-hand side of the mcp inspector.

box-mcp-server FAQ

How do I authenticate the box-mcp-server?
The server uses JSON Web Token (JWT) authentication, requiring a Box enterprise or developer account with JWT credentials.
What credentials are needed to run box-mcp-server?
You need a BOX_USER_ID and one of BOX_JWT_BASE64, BOX_JWT_CONFIG_PATH, or BOX_JWT for JWT-based authentication.
Can I use a free Box developer account with box-mcp-server?
Yes, a free developer account can be used, but you must set up JWT authorization and 2-factor authentication.
How do I obtain the JWT credentials for box-mcp-server?
Create a Box app in the Box Developer Console with JWT authorization, generate a public/private keypair, and authorize the app as an admin.
Does box-mcp-server support persistent connections?
Yes, using a JWT config file allows persistent connections to Box for continuous access.
Is two-factor authentication required for box-mcp-server?
Yes, Box requires 2FA setup to authorize the application for JWT authentication.
What is the recommended JWT authentication method?
Using BOX_JWT_BASE64 is recommended for ease of use and security.
Can box-mcp-server be integrated with multiple AI models?
Yes, it is designed to work with various LLM providers like OpenAI, Claude, and Gemini.