UB

ukenn2112/bangumimcp

Developer tools

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

27 stars 15 forks 品質 61 トレンド 0

bgm.tv MCPサーバー

概要

「Bangumi TV API」にプログラマティックなアクセスを提供するモデル・コンテキスト・プロトコル(MCP)サーバーで、ClaudeのようなAIアシスタントが、包括的なアニメ、マンガ、音楽、ゲーム、リアル・ワールド・メディア・データと相互作用することを可能にします。 - : Bangumi API エンドポイントの完全なカバレッジ - : 一般的なタスクの事前ビルドされたマルチステップのワークフロー - API ドキュメントのフル OpenAPI 仕様 - : MCP のベストプラクティスに従うクリーンで保守可能なコードベース - : 完全な Python 型ヒントとエンウムの定義 - : httpx を使用して API 呼び出しをブロックしない - Python 3.10以上 - uvパッケージマネージャ(推奨)またはピップ : BANGUMI TOKEN はオプションですが、: - 認証された操作(収集、個人データ) - R18 コンテンツアクセス - 書き込み操作(作成、更新、削除) トークンの取得: [https://next.bgm.]

概要(AI 翻訳)

日本語 English

お問い合わせ

##英語

「Bangumi TV API」にプログラマティックなアクセスを提供するモデル・コンテキスト・プロトコル(MCP)サーバーで、ClaudeのようなAIアシスタントが、包括的なアニメ、マンガ、音楽、ゲーム、リアル・ワールド・メディア・データと相互作用することを可能にします。

###特徴

  • ** 55 MCP ツール**: Bangumi APIエンドポイントの完全なカバレッジ
  • 3 ワークフロー プロンプト: 一般的なタスクの既定のマルチステップワークフロー -1 Resource: API ドキュメントのフル OpenAPI 仕様
  • モジュラーアーキテクチャ:MCPのベストプラクティスに従うクリーンでメンテナンス可能なコードベース
  • Type-Safe:完全なPythonのタイプ先端および列の定義 -Async Support: httpx を使用して API 呼び出しをブロックしない

クイックスタート

前提条件
  • Python 3.10以上
  • uvパッケージマネージャ(推奨)またはピップ

インストール

###Claudeデスクトップの設定

[claude_desktop_config.json]に追加します。

注意:[BANGUMI_TOKEN]はオプションです。

  • 認証された操作(収集、個人データ)
  • R18コンテンツアクセス
  • 書き込み操作(作成、更新、削除)

トークンの取得: [https://next.bgm.tv/demo/access-token]

###プロジェクトアーキテクチャ

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。

README

以下は原文 README の抜粋です。原文を見る。

Bangumi MCP Server

English | 中文


English

A Model Context Protocol (MCP) server that provides programmatic access to the Bangumi TV API, enabling AI assistants like Claude to interact with comprehensive anime, manga, music, game, and real-world media data.

Features

  • 55 MCP Tools: Complete coverage of Bangumi API endpoints
  • 3 Workflow Prompts: Pre-built multi-step workflows for common tasks
  • 1 Resource: Full OpenAPI specification for API documentation
  • Modular Architecture: Clean, maintainable codebase following MCP best practices
  • Type-Safe: Full Python type hints and enum definitions
  • Async Support: Non-blocking API calls using httpx

Quick Start

Prerequisites

  • Python 3.10 or higher
  • uv package manager (recommended) or pip

Installation

# Clone the repository
git clone https://github.com/Ukenn2112/BangumiMCP.git
cd BangumiMCP

# Create and activate virtual environment
uv venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate

# Install dependencies
uv pip install -e .

Configuration for Claude Desktop

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "bangumi-tv": {
      "command": "uv",
      "args": [
        "--directory",
        "/path/to/BangumiMCP",
        "run",
        "main.py"
      ],
      "env": {
        "BANGUMI_TOKEN": "your_token_here"
      }
    }
  }
}

Note: BANGUMI_TOKEN is optional but required for:

  • Authenticated operations (collections, personal data)
  • R18 content access
  • Write operations (create, update, delete)

Get your token at: https://next.bgm.tv/demo/access-token

Project Architecture

BangumiMCP follows a modular architecture designed for maintainability and scalability:

BangumiMCP/
├── main.py                           # Server initialization (44 lines)
├── src/
│   ├── config.py                     # Configuration constants
│   ├── enums.py                      # API enum definitions (8 types)
│   ├── utils/
│   │   ├── api_client.py             # HTTP client & error handling
│   │   └── formatters.py             # Data formatting utilities
│   ├── resources/
│   │   └── openapi_resource.py       # OpenAPI specification resource
│   ├── tools/                        # 55 MCP tools organized by domain
│   │   ├── subject_tools.py          # Subjects & episodes (10 tools)
│   │   ├── character_tools.py        # Characters (7 tools)
│   │   ├── person_tools.py           # Persons & companies (7 tools)
│   │   ├── user_tools.py             # User information (3 tools)
│   │   ├── collection_tools.py       # Collections (11 tools)
│   │   ├── revision_tools.py         # Edit history (8 tools)
│   │   └── index_tools.py            # Indices/directories (9 tools)
│   └── prompts/
│       └── workflow_prompts.py       # Composite prompts (3)
GitHub で README 全文を見る

インストール

This server does not publish a one-line install command.

Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →

設定

{ "mcpServers": { "bangumi-tv": { "command": "uv", "args": [ "--directory", "/path/to/BangumiMCP", "run", "main.py" ], "env": { "BANGUMI_TOKEN": "your_token_here" } } } }