Metadata-Version: 2.4
Name: ru-store-mcp
Version: 0.1.0
Summary: MCP server for managing app publishing on RuStore (Android app store)
Project-URL: Homepage, https://github.com/eustatos/RuStoreMcp
Project-URL: Repository, https://github.com/eustatos/RuStoreMcp
Project-URL: Issues, https://github.com/eustatos/RuStoreMcp/issues
License: MIT
Keywords: android,mcp,publish,rustore
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Libraries
Classifier: Topic :: Utilities
Requires-Python: >=3.11
Requires-Dist: httpx>=0.27.0
Requires-Dist: mcp>=1.0.0
Requires-Dist: pycryptodome>=3.20.0
Requires-Dist: python-dotenv>=1.0.0
Provides-Extra: dev
Requires-Dist: mypy>=1.0.0; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.23.0; extra == 'dev'
Requires-Dist: pytest-cov>=4.0.0; extra == 'dev'
Requires-Dist: pytest>=7.0.0; extra == 'dev'
Description-Content-Type: text/markdown

# RuStore MCP Server

MCP server for managing app publishing on RuStore (Android app store).
Provides 34 tools: APK/AAB uploads, icon and screenshot management, version control,
moderation, reviews, payments, subscriptions, access control, and product catalog.

## Status

> [!WARNING]
> The package is **not yet published** to PyPI. Only local installation is available at this time.

## Prerequisites

- Python 3.11+
- RuStore Console API key (keyId + Base64-encoded private key)

## Local Installation

### Windows (PowerShell)

```powershell
git clone https://github.com/eustatos/RuStoreMcp.git
cd RuStoreMcp
python -m venv .venv
.venv\Scripts\activate
pip install -e ".[dev]"
```

### Windows (CMD)

```cmd
git clone https://github.com/eustatos/RuStoreMcp.git
cd RuStoreMcp
python -m venv .venv
.venv\Scripts\activate.bat
pip install -e ".[dev]"
```

### macOS / Linux

```bash
git clone https://github.com/eustatos/RuStoreMcp.git
cd RuStoreMcp
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"
```

After installation, the `rustore-mcp` executable (`rustore-mcp.exe` on Windows)
is available inside the virtual environment at:

| Platform | Path |
|----------|------|
| Windows  | `.venv\Scripts\rustore-mcp.exe` |
| macOS    | `.venv/bin/rustore-mcp` |
| Linux    | `.venv/bin/rustore-mcp` |

## Configuration

Create a `.env` file in the project root based on `.env.example`:

```
RUSTORE_KEY_ID=your_key_id
RUSTORE_PRIVATE_KEY=your_base64_private_key
RUSTORE_PACKAGE_NAME=com.example.app  # optional
```

- `RUSTORE_KEY_ID` — key identifier from RuStore Console
- `RUSTORE_PRIVATE_KEY` — Base64-encoded private key
- `RUSTORE_PACKAGE_NAME` — default package name (can be overridden per-request)

## Usage

### Direct execution

```bash
# Windows
.venv\Scripts\rustore-mcp.exe

# macOS / Linux
.venv/bin/rustore-mcp
```

### Claude Desktop integration

Add to your Claude Desktop configuration (`claude_desktop_config.json`):

**Windows:**

```json
{
  "mcpServers": {
    "rustore": {
      "command": "C:\\Users\\<user>\\path\\to\\RuStoreMcp\\.venv\\Scripts\\rustore-mcp.exe",
      "env": {
        "RUSTORE_KEY_ID": "your_key_id_here",
        "RUSTORE_PRIVATE_KEY": "your_base64_private_key_here",
        "RUSTORE_PACKAGE_NAME": "com.example.app"
      }
    }
  }
}
```

**macOS / Linux:**

```json
{
  "mcpServers": {
    "rustore": {
      "command": "/path/to/RuStoreMcp/.venv/bin/rustore-mcp",
      "env": {
        "RUSTORE_KEY_ID": "your_key_id_here",
        "RUSTORE_PRIVATE_KEY": "your_base64_private_key_here",
        "RUSTORE_PACKAGE_NAME": "com.example.app"
      }
    }
  }
}
```

### Logging

Log level is controlled via the `RUSTORE_LOG_LEVEL` environment variable:

```bash
# Windows (CMD)
set RUSTORE_LOG_LEVEL=DEBUG
.venv\Scripts\rustore-mcp.exe

# macOS / Linux
RUSTORE_LOG_LEVEL=DEBUG .venv/bin/rustore-mcp
```

Supported values: `DEBUG`, `INFO`, `WARNING`, `ERROR`, `CRITICAL`. Default: `INFO`.

## Available Tools (34)

### Publishing
| Tool | Description |
|------|-------------|
| `get_app_list` | List applications |
| `create_draft_version` | Create a draft version |
| `get_version_status` | Get version status |
| `upload_apk` | Upload APK file |
| `upload_aab` | Upload AAB file |
| `upload_icon` | Upload app icon |
| `upload_screenshot` | Upload screenshot |
| `delete_draft` | Delete a draft version |
| `change_publish_settings` | Update publish settings |
| `commit_to_moderation` | Submit for moderation |
| `publish_version` | Publish a version |
| `archive_version` | Archive a version |

### Reviews & Rating
| Tool | Description |
|------|-------------|
| `get_feedback_list` | List reviews |
| `get_feedback_csv` | Export reviews as CSV |
| `answer_feedback` | Reply to a review |
| `get_answer_status` | Get reply status |
| `get_answers_statuses` | Get reply statuses in bulk |
| `change_answer` | Edit a reply |
| `delete_answer` | Delete a reply |
| `get_app_rating` | Get app rating stats |

### Payments
| Tool | Description |
|------|-------------|
| `get_payment_info` | Get payment details |
| `refund_payment` | Refund a payment |
| `get_invoices_by_date` | Get invoices by date range |
| `confirm_purchase` | Confirm a purchase |
| `cancel_purchase` | Cancel a purchase |
| `get_user_purchases` | Get user purchases |

### Subscriptions
| Tool | Description |
|------|-------------|
| `get_subscription_info` | Get subscription details |
| `cancel_subscription` | Cancel a subscription |
| `approve_subscription` | Approve a subscription |

### Access & Catalog
| Tool | Description |
|------|-------------|
| `get_access_list` | List access grants |
| `grant_access` | Grant access to a user |
| `revoke_access` | Revoke access from a user |
| `get_catalog_products` | List catalog products |
| `get_catalog_subscriptions` | List catalog subscriptions |

## Development

```bash
# Install dev dependencies
pip install -e ".[dev]"

# Run all tests
pytest -v

# Run tests with coverage
pytest -v --cov=rustore_mcp --cov-report=term-missing

# Type checking
mypy rustore_mcp/

# Run a single test file
pytest tests/test_auth.py -v
```

## License

MIT
