Skip to main content
Glama

PPTX MCP サーバー

FastMCP を搭載した、PowerPoint (PPTX) プレゼンテーションをプログラムで作成、編集、レンダリングできるサーバーです。スライドの作成、テキストと図形の挿入、画像の埋め込み、PNG へのスライドレンダリング (LibreOffice を使用) をサポートします。

特徴

  • **プレゼンテーションの作成/クリア:**新しい PPTX ファイルを開始するか、既存の PPTX ファイルをリセットします。

  • **スライドの追加:**カスタマイズ可能なレイアウトでスライドを挿入します。

  • **テキストとコンテンツ:**スライドにタイトル、コンテンツ、カスタム テキスト ボックスを追加します。

  • **図形:**さまざまな PowerPoint 図形 (フローチャート要素を含む) を挿入します。

  • **画像:**スライドに画像を埋め込みます。

  • **スライドの説明:**検証のためにスライドの内容のテキスト要約を取得します。

  • **スライドのレンダリング:**スライドを PNG 画像としてレンダリングします (LibreOffice が必要です)。

  • **PPTX をダウンロード:**生成されたプレゼンテーション ファイルをダウンロードします。

Related MCP server: PowerPoint MCP Server

要件

  • Python 3.12以上

  • Python-pptx

  • ファストMCP

  • LibreOffice (スライド画像のレンダリング用。別途インストールし、システム PATH で利用可能にする必要があります)

インストール

  1. Python の依存関係をインストールします。

    pip install -r requirements.txt

    (依存関係については

  2. LibreOffice をインストールします(画像レンダリング用):

使用法

サーバーを起動します。

python server.py

環境変数を使用してサーバーのホストとポートを設定できます。

  • HOST (デフォルト: 127.0.0.1

  • PORT (デフォルト: 8000

たとえば、すべてのインターフェースとポート 9000 で実行するには、次のようにします。

HOST=0.0.0.0 PORT=9000 python server.py

または (FastMCP を使用した開発の場合):

fastmcp dev server.py

APIの概要

サーバーは、FastMCP を介して次のようなツールとリソースを公開します。

  • create_or_clear_presentation(filename)

  • add_slide(filename, layout_index)

  • add_title_and_content(filename, slide_index, title, content)

  • add_textbox(filename, slide_index, text, left_inches, top_inches, width_inches, height_inches, font_size_pt, bold)

  • add_shape(filename, slide_index, shape_type_name, left_inches, top_inches, width_inches, height_inches, text)

  • add_picture(filename, slide_index, image, left_inches, top_inches, width_inches, height_inches)

  • get_slide_content_description(filename, slide_index)

  • get_slide_image(filename, slide_index)(LibreOfficeが必要)

  • get_pptx_file(filename)

完全なパラメータの詳細と使用可能なシェイプ タイプについては、コードを参照してください。

プレゼンテーションとテンプレート

  • プレゼンテーションはpresentations/ディレクトリに保存されます。

  • presentations/templates/に独自のテンプレートを追加できます。

ライセンス

詳細についてはライセンスを参照してください。

-
security - not tested
A
license - permissive license
-
quality - not tested

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/samos123/pptx-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server