Skip to main content

Local Server

This instruction describes how to connect to the DocSpace MCP server running on your local machine.

Docker Image

Using the Docker image requires Docker to be installed on your system.

Configure your MCP client to use the Docker image by adding the following configuration to your client's configuration file:

{
"mcpServers": {
"onlyoffice-docspace": {
"command": "docker",
"args": [
"run",
"--interactive",
"--rm",
"--env",
"DOCSPACE_BASE_URL",
"--env",
"DOCSPACE_API_KEY",
"onlyoffice/docspace-mcp"
],
"env": {
"DOCSPACE_BASE_URL": "https://your-instance.onlyoffice.com",
"DOCSPACE_API_KEY": "your-api-key"
}
}
}
}

Configuration options

OptionDescription
--interactiveKeeps STDIN open, allowing the MCP client to communicate with the server
--rmAutomatically removes the container when it exits, preventing container accumulation
--env DOCSPACE_BASE_URLPasses your DocSpace instance URL to the container
--env DOCSPACE_API_KEYPasses your API key to the container for authentication
onlyoffice/docspace-mcpThe official DocSpace MCP server image from Docker Hub

Environment variables

VariableDescription
DOCSPACE_BASE_URLThe full URL of your DocSpace instance (e.g., https://your-instance.onlyoffice.com)
DOCSPACE_API_KEYYour personal API key generated in DocSpace settings -> Developer Tools -> API keys

For example, you can see step-by-step instructions for Claude Desktop.

Docker MCP Server

Using the Docker MCP Toolkit requires Docker Desktop to be installed on your system and the Docker MCP Toolkit to be enabled. See the Enable Docker MCP Toolkit guide for how to enable the Docker MCP Toolkit.

  1. Install the server through the Docker Desktop interface using the Install an MCP Server guide.

  2. Connect the server to an MCP client through the Docker Desktop interface using the Install an MCP Client guide.

  3. Configure the server through the Docker Desktop interface. In general:

    • Select the DocSpace MCP server in Docker Desktop
    • Open the server's configuration or settings panel
    • Enter your DocSpace base URL (e.g., https://your-instance.onlyoffice.com)
    • Enter your personal API key generated in DocSpace settings -> Developer Tools -> API keys
    • Save the configuration

MCP Bundle

Running the MCP bundle requires Node.js version 18 or higher to be installed on your system.

  1. Download the latest MCP bundle from GitHub Releases (typically named docspace-mcp-bundle-x.x.x.zip or similar).

  2. Install the MCP bundle in an application by following the application's MCP bundles installation procedure.

  3. Configure the server through the application's interface. In general:

    • Open the server settings within your application
    • Enter your DocSpace base URL (e.g., https://your-instance.onlyoffice.com)
    • Enter your personal API key generated in DocSpace settings -> Developer Tools -> API keys
    • Save the configuration and restart the application if required

For example, you can see step-by-step instructions for Claude Desktop.

Node.js Application

Running the Node.js application requires Node.js version 18 or higher to be installed on your system.

Configure your MCP client to use the Node.js application by adding the following configuration to your client's configuration file:

{
"mcpServers": {
"onlyoffice-docspace": {
"command": "npx",
"args": ["--yes", "@onlyoffice/docspace-mcp"],
"env": {
"DOCSPACE_BASE_URL": "https://your-instance.onlyoffice.com",
"DOCSPACE_API_KEY": "your-api-key"
}
}
}
}

Configuration options

OptionDescription
npxThe Node.js package runner, which downloads and executes packages on demand
--yesAutomatically confirms the installation prompt, enabling unattended startup
@onlyoffice/docspace-mcpThe official DocSpace MCP server package from npm

Environment variables

VariableDescription
DOCSPACE_BASE_URLThe full URL of your DocSpace instance (e.g., https://your-instance.onlyoffice.com)
DOCSPACE_API_KEYYour personal API key generated in DocSpace settings -> Developer Tools -> API keys