Morelogin Mcp

Morelogin Mcp

ryanao

Developer Tools
Visit Server

README

MoreLogin MCP API

MoreLogin MCP API 是一个基于 MoreLogin API 的 MCP 协议兼容实现,提供了浏览器环境管理、代理管理和分组管理等功能。

功能特点

  • 浏览器环境管理
    • 创建、获取、更新和删除浏览器环境
    • 批量操作浏览器环境
    • 环境模板管理
  • 代理管理
    • 代理服务器配置
    • 代理规则设置
    • 代理分组管理
  • 分组管理
    • 创建和管理分组
    • 批量分配环境到分组
    • 分组权限控制

安装

PyPI 安装

pip install morelogin-mcp

源码安装

git clone https://github.com/ryanao/morelogin-mcp.git
cd morelogin-mcp
pip install -e .

使用方法

作为独立服务运行

  1. 配置环境变量:
cp .env.example .env
# 编辑 .env 文件,填入您的 API 密钥
  1. 启动服务:
python -m morelogin_mcp.main

在 Cursor 应用中使用

from morelogin_mcp import MoreLoginClient, MCPHandler

# 创建客户端
client = MoreLoginClient(api_key="your_api_key")

# 创建处理器
handler = MCPHandler(client)

# 处理 MCP 请求
response = handler.handle_request({
    "method": "create_profile",
    "params": {
        "name": "test_profile",
        "platform": "windows",
        "browser": "chrome"
    }
})

API 文档

浏览器环境管理

创建环境

response = client.create_profile(
    name="test_profile",
    platform="windows",
    browser="chrome"
)

获取环境

profile = client.get_profile(profile_id="123")

更新环境

response = client.update_profile(
    profile_id="123",
    name="new_name",
    platform="mac"
)

删除环境

response = client.delete_profile(profile_id="123")

代理管理

添加代理

response = client.add_proxy(
    proxy_type="http",
    host="127.0.0.1",
    port=8080,
    username="user",
    password="pass"
)

获取代理列表

proxies = client.get_proxies()

更新代理

response = client.update_proxy(
    proxy_id="123",
    host="new.host.com",
    port=9090
)

删除代理

response = client.delete_proxy(proxy_id="123")

分组管理

创建分组

response = client.create_group(
    name="test_group",
    description="测试分组"
)

获取分组列表

groups = client.get_groups()

更新分组

response = client.update_group(
    group_id="123",
    name="new_name",
    description="新的描述"
)

删除分组

response = client.delete_group(group_id="123")

开发指南

环境设置

  1. 克隆仓库:
git clone https://github.com/ryanao/morelogin-mcp.git
cd morelogin-mcp
  1. 创建虚拟环境:
python -m venv venv
source venv/bin/activate  # Linux/Mac
# 或
.\venv\Scripts\activate  # Windows
  1. 安装开发依赖:
pip install -r requirements.txt
pip install -r requirements-dev.txt

运行测试

pytest

代码规范

  • 遵循 PEP 8 代码风格指南
  • 使用类型注解
  • 编写清晰的文档字符串
  • 为所有公共 API 编写单元测试

贡献指南

请参阅 CONTRIBUTING.md 文件了解如何贡献代码。

许可证

本项目采用 MIT 许可证,详见 LICENSE 文件。

联系方式

  • 项目主页:https://github.com/ryanao/morelogin-mcp
  • 问题反馈:https://github.com/ryanao/morelogin-mcp/issues

更新日志

v0.1.1 (2024-03-21)

  • 修复了错误处理机制
  • 优化了测试用例
  • 改进了响应处理逻辑
  • 统一了错误消息格式

v0.1.0 (2024-03-20)

  • 初始版本发布
  • 支持基本的配置文件管理
  • 支持代理管理
  • 支持分组管理

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
@kazuph/mcp-taskmanager

@kazuph/mcp-taskmanager

Model Context Protocol server for Task Management. This allows Claude Desktop (or any MCP client) to manage and execute tasks in a queue-based system.

Featured
Local
JavaScript
Claude Code MCP

Claude Code MCP

An implementation of Claude Code as a Model Context Protocol server that enables using Claude's software engineering capabilities (code generation, editing, reviewing, and file operations) through the standardized MCP interface.

Featured
Local
JavaScript
MCP Package Docs Server

MCP Package Docs Server

Facilitates LLMs to efficiently access and fetch structured documentation for packages in Go, Python, and NPM, enhancing software development with multi-language support and performance optimization.

Featured
Local
TypeScript
Linear MCP Server

Linear MCP Server

A Model Context Protocol server that integrates with Linear's issue tracking system, allowing LLMs to create, update, search, and comment on Linear issues through natural language interactions.

Featured
JavaScript
Sequential Thinking MCP Server

Sequential Thinking MCP Server

This server facilitates structured problem-solving by breaking down complex issues into sequential steps, supporting revisions, and enabling multiple solution paths through full MCP integration.

Featured
Python
mermaid-mcp-server

mermaid-mcp-server

A Model Context Protocol (MCP) server that converts Mermaid diagrams to PNG images.

Featured
JavaScript
Jira-Context-MCP

Jira-Context-MCP

MCP server to provide Jira Tickets information to AI coding agents like Cursor

Featured
TypeScript
Linear MCP Server

Linear MCP Server

Enables interaction with Linear's API for managing issues, teams, and projects programmatically through the Model Context Protocol.

Featured
JavaScript