cubeparser-mcp


Namecubeparser-mcp JSON
Version 0.1.1 PyPI version JSON
download
home_pageNone
SummaryMCP Server for CubeParser document extraction API
upload_time2025-08-30 05:28:13
maintainerNone
docs_urlNone
authorNone
requires_python>=3.10
licenseMIT
keywords api cubeparser document-extraction mcp
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # CubeParser MCP Server

A Model Context Protocol (MCP) server that provides access to CubeParser document extraction API. This server can be run directly using `uvx` with absolute paths for easy deployment and sharing.

## ๐Ÿš€ Quick Start with uvx

### For End Users (Running the Server)

If someone has shared this project with you, you can run it directly using uvx with the absolute path:

```bash
# Replace with the actual absolute path provided to you
uvx --from "C:\path\to\cubeparser_mcp" cubeparser-mcp
```

**Example:**
```bash
uvx --from "C:\Users\Remy\sensedeal\code\projects\work\CITICS2025\zhangkai\cubeparser_mcp" cubeparser-mcp
```

### For Developers (Setting Up for Sharing)

1. **Clone and Setup**:
```bash
git clone <repository-url>
cd cubeparser_mcp
uv sync
```

2. **Run Setup Script**:
```bash
uv run python setup_uvx.py
```

This creates:
- `mcp_config.json` - MCP client configuration with absolute paths
- `.env.template` - Environment variables template
- `run_cubeparser_mcp.bat` - Quick run script for Windows

3. **Configure Environment**:
```bash
cp .env.template .env
# Edit .env with your CubeParser credentials
```

## ๐Ÿ“‹ Features

This MCP server provides three main tools:

1. **get_templates** - Retrieve available extraction templates from CubeParser
2. **create_task** - Upload files and create extraction tasks with specified templates
3. **download_results** - Get extraction results from completed tasks

## ๐Ÿ› ๏ธ Installation Methods

### Method 1: Direct uvx Usage (Recommended for Sharing)

```bash
# Run from absolute path (replace with actual path)
uvx --from "/absolute/path/to/cubeparser_mcp" cubeparser-mcp

# Or on Windows
uvx --from "C:\absolute\path\to\cubeparser_mcp" cubeparser-mcp
```

### Method 2: Local Development

```bash
# Install dependencies
uv sync

# Run directly
uv run python main.py

# Or use the generated batch file
.\run_cubeparser_mcp.bat  # Windows
./run_cubeparser_mcp.sh   # Linux/Mac
```

## โš™๏ธ Configuration

### Environment Variables

Create a `.env` file with your CubeParser credentials:

```env
CUBEPARSER_USERNAME=your_username_here
CUBEPARSER_PASSWORD=your_password_here
CUBEPARSER_BASEURL=https://cubeparser.cn/
```

### MCP Client Configuration

Use the generated `mcp_config.json` file in your MCP client (e.g., Claude Desktop):

```json
{
  "mcpServers": {
    "cubeparser": {
      "command": "uvx",
      "args": [
        "--from",
        "C:\\absolute\\path\\to\\cubeparser_mcp",
        "cubeparser-mcp"
      ],
      "env": {
        "CUBEPARSER_USERNAME": "your_username",
        "CUBEPARSER_PASSWORD": "your_password",
        "CUBEPARSER_BASEURL": "https://cubeparser.cn/"
      }
    }
  }
}
```

## ๐Ÿ”ง Available Tools

### get_templates()

Retrieves a list of available extraction templates from CubeParser.

**Returns:** List of template objects with IDs, names, and descriptions.

### create_task(file_path: str, template_id: str)

Creates an extraction task by uploading a file and specifying a template.

**Parameters:**
- `file_path`: Absolute path to the file to be processed
- `template_id`: ID of the template to use for extraction

**Returns:** Task information including task ID and status.

### download_results(task_id: str)

Downloads extraction results for a completed task.

**Parameters:**
- `task_id`: ID of the extraction task

**Returns:** Extraction results and task status information.

## ๐Ÿงช Testing

### Test the Installation

```bash
# Test that the server starts correctly
uvx --from "C:\your\absolute\path\to\cubeparser_mcp" cubeparser-mcp

# Or use the batch file
.\run_cubeparser_mcp.bat
```

### Run Tests

```bash
uv run pytest
```

## ๐Ÿ“ Generated Files

After running `setup_uvx.py`, you'll have:

- **`mcp_config.json`** - Ready-to-use MCP client configuration
- **`.env.template`** - Template for environment variables
- **`run_cubeparser_mcp.bat`** - Windows batch script for easy testing
- **`run_cubeparser_mcp.sh`** - Linux/Mac shell script for easy testing

## ๐Ÿšจ Troubleshooting

### Common Issues

1. **Server won't start**: Check that environment variables are set correctly
2. **uvx command not found**: Install uv first: `pip install uv`
3. **Permission errors**: Ensure the absolute path is accessible
4. **Network errors**: Verify CubeParser API credentials and network access

### Debug Mode

Run with verbose logging:

```bash
uvx --from "C:\your\path\to\cubeparser_mcp" cubeparser-mcp --verbose
```

## ๐Ÿ“ค Sharing with Others

To share this MCP server with others:

1. **Provide the absolute path** to your project directory
2. **Share the uvx command**:
   ```bash
   uvx --from "C:\your\absolute\path\to\cubeparser_mcp" cubeparser-mcp
   ```
3. **Include environment setup instructions** (they need their own CubeParser credentials)

## ๐Ÿ“„ License

MIT License - see LICENSE file for details.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "cubeparser-mcp",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "api, cubeparser, document-extraction, mcp",
    "author": null,
    "author_email": "CubeParser MCP <support@example.com>",
    "download_url": "https://files.pythonhosted.org/packages/e6/5c/0c740cf7124e28a76fde5afcb08d9305efa372f2cfe9806a3ed6ab5d0504/cubeparser_mcp-0.1.1.tar.gz",
    "platform": null,
    "description": "# CubeParser MCP Server\n\nA Model Context Protocol (MCP) server that provides access to CubeParser document extraction API. This server can be run directly using `uvx` with absolute paths for easy deployment and sharing.\n\n## \ud83d\ude80 Quick Start with uvx\n\n### For End Users (Running the Server)\n\nIf someone has shared this project with you, you can run it directly using uvx with the absolute path:\n\n```bash\n# Replace with the actual absolute path provided to you\nuvx --from \"C:\\path\\to\\cubeparser_mcp\" cubeparser-mcp\n```\n\n**Example:**\n```bash\nuvx --from \"C:\\Users\\Remy\\sensedeal\\code\\projects\\work\\CITICS2025\\zhangkai\\cubeparser_mcp\" cubeparser-mcp\n```\n\n### For Developers (Setting Up for Sharing)\n\n1. **Clone and Setup**:\n```bash\ngit clone <repository-url>\ncd cubeparser_mcp\nuv sync\n```\n\n2. **Run Setup Script**:\n```bash\nuv run python setup_uvx.py\n```\n\nThis creates:\n- `mcp_config.json` - MCP client configuration with absolute paths\n- `.env.template` - Environment variables template\n- `run_cubeparser_mcp.bat` - Quick run script for Windows\n\n3. **Configure Environment**:\n```bash\ncp .env.template .env\n# Edit .env with your CubeParser credentials\n```\n\n## \ud83d\udccb Features\n\nThis MCP server provides three main tools:\n\n1. **get_templates** - Retrieve available extraction templates from CubeParser\n2. **create_task** - Upload files and create extraction tasks with specified templates\n3. **download_results** - Get extraction results from completed tasks\n\n## \ud83d\udee0\ufe0f Installation Methods\n\n### Method 1: Direct uvx Usage (Recommended for Sharing)\n\n```bash\n# Run from absolute path (replace with actual path)\nuvx --from \"/absolute/path/to/cubeparser_mcp\" cubeparser-mcp\n\n# Or on Windows\nuvx --from \"C:\\absolute\\path\\to\\cubeparser_mcp\" cubeparser-mcp\n```\n\n### Method 2: Local Development\n\n```bash\n# Install dependencies\nuv sync\n\n# Run directly\nuv run python main.py\n\n# Or use the generated batch file\n.\\run_cubeparser_mcp.bat  # Windows\n./run_cubeparser_mcp.sh   # Linux/Mac\n```\n\n## \u2699\ufe0f Configuration\n\n### Environment Variables\n\nCreate a `.env` file with your CubeParser credentials:\n\n```env\nCUBEPARSER_USERNAME=your_username_here\nCUBEPARSER_PASSWORD=your_password_here\nCUBEPARSER_BASEURL=https://cubeparser.cn/\n```\n\n### MCP Client Configuration\n\nUse the generated `mcp_config.json` file in your MCP client (e.g., Claude Desktop):\n\n```json\n{\n  \"mcpServers\": {\n    \"cubeparser\": {\n      \"command\": \"uvx\",\n      \"args\": [\n        \"--from\",\n        \"C:\\\\absolute\\\\path\\\\to\\\\cubeparser_mcp\",\n        \"cubeparser-mcp\"\n      ],\n      \"env\": {\n        \"CUBEPARSER_USERNAME\": \"your_username\",\n        \"CUBEPARSER_PASSWORD\": \"your_password\",\n        \"CUBEPARSER_BASEURL\": \"https://cubeparser.cn/\"\n      }\n    }\n  }\n}\n```\n\n## \ud83d\udd27 Available Tools\n\n### get_templates()\n\nRetrieves a list of available extraction templates from CubeParser.\n\n**Returns:** List of template objects with IDs, names, and descriptions.\n\n### create_task(file_path: str, template_id: str)\n\nCreates an extraction task by uploading a file and specifying a template.\n\n**Parameters:**\n- `file_path`: Absolute path to the file to be processed\n- `template_id`: ID of the template to use for extraction\n\n**Returns:** Task information including task ID and status.\n\n### download_results(task_id: str)\n\nDownloads extraction results for a completed task.\n\n**Parameters:**\n- `task_id`: ID of the extraction task\n\n**Returns:** Extraction results and task status information.\n\n## \ud83e\uddea Testing\n\n### Test the Installation\n\n```bash\n# Test that the server starts correctly\nuvx --from \"C:\\your\\absolute\\path\\to\\cubeparser_mcp\" cubeparser-mcp\n\n# Or use the batch file\n.\\run_cubeparser_mcp.bat\n```\n\n### Run Tests\n\n```bash\nuv run pytest\n```\n\n## \ud83d\udcc1 Generated Files\n\nAfter running `setup_uvx.py`, you'll have:\n\n- **`mcp_config.json`** - Ready-to-use MCP client configuration\n- **`.env.template`** - Template for environment variables\n- **`run_cubeparser_mcp.bat`** - Windows batch script for easy testing\n- **`run_cubeparser_mcp.sh`** - Linux/Mac shell script for easy testing\n\n## \ud83d\udea8 Troubleshooting\n\n### Common Issues\n\n1. **Server won't start**: Check that environment variables are set correctly\n2. **uvx command not found**: Install uv first: `pip install uv`\n3. **Permission errors**: Ensure the absolute path is accessible\n4. **Network errors**: Verify CubeParser API credentials and network access\n\n### Debug Mode\n\nRun with verbose logging:\n\n```bash\nuvx --from \"C:\\your\\path\\to\\cubeparser_mcp\" cubeparser-mcp --verbose\n```\n\n## \ud83d\udce4 Sharing with Others\n\nTo share this MCP server with others:\n\n1. **Provide the absolute path** to your project directory\n2. **Share the uvx command**:\n   ```bash\n   uvx --from \"C:\\your\\absolute\\path\\to\\cubeparser_mcp\" cubeparser-mcp\n   ```\n3. **Include environment setup instructions** (they need their own CubeParser credentials)\n\n## \ud83d\udcc4 License\n\nMIT License - see LICENSE file for details.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "MCP Server for CubeParser document extraction API",
    "version": "0.1.1",
    "project_urls": {
        "Homepage": "https://github.com/your-org/cubeparser-mcp",
        "Issues": "https://github.com/your-org/cubeparser-mcp/issues",
        "Repository": "https://github.com/your-org/cubeparser-mcp"
    },
    "split_keywords": [
        "api",
        " cubeparser",
        " document-extraction",
        " mcp"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "b03f2806db908177878fa8e8e723b818fc10b01b27268d42b2ed22689ac1423a",
                "md5": "ddbe91f7f2d23a5d5f79337191371583",
                "sha256": "e45a967e19704920ceba9f9cecb5cd4926aaad617bc1bd6fcea5b27f1006f71b"
            },
            "downloads": -1,
            "filename": "cubeparser_mcp-0.1.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ddbe91f7f2d23a5d5f79337191371583",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 8112,
            "upload_time": "2025-08-30T05:28:11",
            "upload_time_iso_8601": "2025-08-30T05:28:11.804933Z",
            "url": "https://files.pythonhosted.org/packages/b0/3f/2806db908177878fa8e8e723b818fc10b01b27268d42b2ed22689ac1423a/cubeparser_mcp-0.1.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "e65c0c740cf7124e28a76fde5afcb08d9305efa372f2cfe9806a3ed6ab5d0504",
                "md5": "d59ac0eb0e374746ca210ff458e2f347",
                "sha256": "dfe9946b67932e8c19e053df791394e4630c83e2d29b4bf292fb82b919e57c7a"
            },
            "downloads": -1,
            "filename": "cubeparser_mcp-0.1.1.tar.gz",
            "has_sig": false,
            "md5_digest": "d59ac0eb0e374746ca210ff458e2f347",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 7062,
            "upload_time": "2025-08-30T05:28:13",
            "upload_time_iso_8601": "2025-08-30T05:28:13.309744Z",
            "url": "https://files.pythonhosted.org/packages/e6/5c/0c740cf7124e28a76fde5afcb08d9305efa372f2cfe9806a3ed6ab5d0504/cubeparser_mcp-0.1.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-08-30 05:28:13",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "your-org",
    "github_project": "cubeparser-mcp",
    "github_not_found": true,
    "lcname": "cubeparser-mcp"
}
        
Elapsed time: 1.28929s