インストール不要。2分以内に動きます。
cloud.anythingmcp.com で無料トライアルを開始し、Word (Microsoft 365) をワンクリックで追加して、AI クライアント(Claude、ChatGPT、Copilot、Cursor)を生成された MCP エンドポイントに向けるだけ。Docker も git clone も、開発経験も不要です。
概要
OneDrive と SharePoint の Word 文書を AI で扱えます:文書の検索、詳細、バージョン履歴、アクセス権の確認、PDF または元のファイルでの取得、テンプレートからの新規作成、名前の変更、移動、チェックアウトとチェックイン、以前のバージョンの復元。Microsoft Graph 経由の Microsoft 365 で、Microsoft アカウントでサインインします。共有リンクと削除はインストール時にオフです。
こう聞いてみよう
Word (Microsoft 365) のサンプルプロンプト
プロンプトをクリックでコピー。Claude / ChatGPT / Cursor / Gemini / Copilot / OpenClaw に貼り付けて、このコネクターで実行できます。
Claude は AI のため誤ることがあります。回答をご確認ください。
💡 インストール不要? cloud.anythingmcp.com を直接利用してください。 サインインし、Connectors → Word (Microsoft 365) をクリック、認証情報を貼り付け、MCP API キーを発行すれば完了です。Docker も
git cloneもローカルサーバーも不要。
Word (Microsoft 365)
OneDrive と SharePoint の Word 文書を AI で扱えます:文書の検索、詳細、バージョン履歴、アクセス権の確認、PDF または元のファイルでの取得、テンプレートからの新規作成、名前の変更、移動、チェックアウトとチェックイン、以前のバージョンの復元。Microsoft Graph 経由の Microsoft 365 で、Microsoft アカウントでサインインします。共有リンクと削除はインストール時にオフです。
セットアップ
設定は約 10 分です。文書が保存されている OneDrive または SharePoint の Microsoft アカウントと、Microsoft Entra の無料のアプリ登録が必要です。
-
https://entra.microsoft.com(または https://portal.azure.com)を開き、**Applications → App registrations → New registration** に進みます。
-
アプリに名前を付け(例: "AnythingMCP Microsoft 365")、Supported account types を選びます。この選択で
MICROSOFT_TENANT_IDに入れる値が決まります:- Accounts in this organizational directory only(シングルテナント):アプリの Overview ページにある Directory (tenant) ID(GUID)、または
contoso.onmicrosoft.comのような自社ドメイン。 - Accounts in any organizational directory(マルチテナント):
organizations。 - Accounts in any organizational directory and personal Microsoft accounts:
common(職場、学校、個人のアカウント)またはconsumers(個人アカウントのみ)。
値がアカウントの種類と合わないと、Microsoft は AADSTS50194 または AADSTS50020 でサインインを拒否します。
- Accounts in this organizational directory only(シングルテナント):アプリの Overview ページにある Directory (tenant) ID(GUID)、または
-
Redirect URI でプラットフォーム Web を選び、
<your AnythingMCP URL>/api/mcp-oauth/callbackを、AnythingMCP Cloud ではhttps://cloud.anythingmcp.com/api/mcp-oauth/callbackを入力します。一字一句一致している必要があり、違うと Microsoft は AADSTS50011 を返します。 -
API permissions → Add a permission → Microsoft Graph → Delegated permissions を開き、
offline_access、User.Read、Files.ReadWriteを追加します。SharePoint や Teams の文書、共有された文書にも AI がアクセスする場合はFiles.ReadWrite.Allも追加します(スコープ を参照)。 -
Certificates & secrets → New client secret を開き、シークレットの Value をコピーします(Secret ID ではありません)。表示されるのは一度だけです。有効期限を控えておいてください。期限が切れると、新しいシークレットを貼り付けるまでコネクタは動きません。
-
Application (client) ID を
MICROSOFT_CLIENT_IDに、シークレットの値をMICROSOFT_CLIENT_SECRETに、手順 2 のテナントの値をMICROSOFT_TENANT_IDに貼り付けて、コネクタをインストールします。 -
コネクタのページで Authorize with Provider をクリックし、AI に扱わせたい文書のアカウントでサインインします。リフレッシュトークンは暗号化して保存され、アクセストークン(約 1 時間有効)は自動的に更新されます。
-
microsoft_word_get_my_driveを実行します。コネクタがどの OneDrive に接続しているかが表示されます。
すべての Microsoft コネクタで 1 つの Entra アプリ: Outlook、OneDrive、Excel コネクタ用に作ったアプリ登録をここでも使えます。手順 4 の権限を追加し、同じリダイレクト URI のまま、同じクライアント ID、シークレット、テナントを再利用します。各コネクタは認可時に自分のスコープだけを要求します。
管理者の同意: これらの委任されたアクセス許可は通常は管理者を必要としませんが、ユーザーの同意をオフにしている組織も多くあります。サインイン時に "Need admin approval"(AADSTS65001 または AADSTS90094)と表示されたら、テナント管理者がアプリ登録を一度開き、組織に対して API permissions → Grant admin consent をクリックします。
誰の文書が見えるか: すべての操作はコネクタを認可したユーザーとして実行されるため、AI はそのユーザーができることだけを見て変更します。職場または学校のアカウント(Microsoft 365)ではすべてのツールが使えます。個人の OneDrive で使えるのは検索、詳細、ダウンロード、PDF、コピー、名前の変更、移動です。
スコープ: コネクタは offline_access User.Read Files.ReadWrite を要求します。offline_access があることで Microsoft がリフレッシュトークンを発行し、Files.ReadWrite は自分の OneDrive をカバーします。SharePoint ライブラリ、Teams チャネル、他の人が共有した文書、および microsoft_word_find_documents を使うには、アプリ登録に Files.ReadWrite.All を追加し、コネクタの OAuth 設定で Files.ReadWrite をそれに置き換えて、もう一度認可します。読み取り専用にするには offline_access User.Read Files.Read.All を使って再認可し、microsoft_word_copy_document、microsoft_word_rename_document、microsoft_word_move_document、microsoft_word_restore_version、microsoft_word_check_out、microsoft_word_check_in をオフにします。
読み取れるデータ: Word 文書(.docx、.docm、旧形式の .doc)。自分の OneDrive の名前と内容による検索(microsoft_word_search_my_documents、ほかの種類のファイルも返します)、Documents/Contracts/Offer 2026.docx のようなパス、フォルダーの閲覧、あるいはアクセスできるすべての場所(OneDrive、SharePoint、Teams、共有されたファイル)を対象にした Microsoft Search と KQL による microsoft_word_find_documents(職場または学校のアカウントのみ)で見つけます。各文書について、名前、サイズ、作成者と最終更新者とその日時、Word for the web で開く webUrl、チェックアウトの状態、バージョン履歴、アクセスできる人を読み取ります。内容を読むには microsoft_word_convert_to_pdf を使います。Microsoft 365 が文書を AI の読める PDF に変換します。Graph には文書のテキストを返す API がありません。microsoft_word_download_document と microsoft_word_download_version は元のファイルや以前のバージョンを渡します。
書き込める操作: Graph は文書の中身を書き換えられず、コネクタはファイルをアップロードできません。新しい文書は、microsoft_word_copy_document でテンプレートを新しい名前でコピーして作ります。コピーはバックグラウンドで実行され、数秒後に保存先フォルダーに現れます。さらに、文書の名前の変更、同じドライブ内での移動、microsoft_word_restore_version による以前のバージョンの復元(置き換えられた内容は履歴に残るので元に戻せます。職場または学校のアカウントのみ)、チェックアウトが必須の SharePoint ライブラリでのチェックアウトとコメント付きチェックインができます。文書の編集は webUrl からご自身で行います。
インストール時はオフ: microsoft_word_create_sharing_link(anonymous、organization、users 向けの view または edit リンク)と microsoft_word_delete_document です。共有リンクはファイルを他の人に渡すことになり、AI が読んだ文書が共有や削除を指示してくる可能性もあるため、チームに必要なときに管理者がオンにします。削除された文書はごみ箱に入り、そこから復元できます。
データ形式: どのツールも文書の drive_id と item_id を受け取ります。検索とパスによる取得では id と parentReference.driveId として返ります。microsoft_word_find_documents の結果は hitsContainers[0].hits[] にあり、resource.id と resource.parentReference.driveId を使います。microsoft_word_list_folder に item_id root を渡すとドライブの最上位を一覧できます。バージョン ID は 4.0 のような形で、新しい順に返ります。ファイル(PDF を含む)は 10 MB まで添付されます。それより大きいファイルは説明だけで添付されず、AI が代わりに webUrl を示します。PDF 変換は .docx、.docm、.doc、.dotx、.odt、.rtf のファイルで使え、保存されたファイルは変わりません。
ページングと制限: 一覧と検索の応答には、続きがある間 @odata.nextLink が含まれます。AI はそのリンクの $skiptoken の値を skip_token に入れて同じツールを呼び直します。microsoft_word_find_documents は from と size でページングし、moreResultsAvailable で続きの有無がわかります。Microsoft Graph はユーザーごと、アプリごとにリクエストを制限します。Retry-After 付きの 429 または 503 が返ったら、待ってから再試行します。大きな文書の PDF 変換には数秒かかることがあります。
よくあるエラー: 401 InvalidAuthenticationToken は認可が取り消されたか、クライアントシークレットの期限切れです。必要なら新しいシークレットを貼り付け、もう一度 Authorize with Provider をクリックします。403 accessDenied は権限やその同意が足りないか、他の人の文書なのにスコープに Files.ReadWrite.All がない状態です。microsoft_word_find_documents は Files.Read.All か Files.ReadWrite.All がないと 403 を返します。404 itemNotFound はドライブ、アイテム、バージョンの ID の誤りか、削除済みのアイテムです。PDF 変換での 406 または 415 は、変換できないファイル形式かパスワード保護されたファイルです。409 nameAlreadyExists はフォルダーに同じ名前があるという意味です。別の名前にするか、conflict_behavior を rename にします。423 resourceLocked は他の人がチェックアウト中か、編集のためにロックされています。
このコネクタは Word ファイルのアップロード、内容の編集、コメントや変更履歴の読み書き、SharePoint サイトの管理(Microsoft SharePoint コネクタが担当)は行いません。
前提条件: MICROSOFT_CLIENT_ID, MICROSOFT_CLIENT_SECRET, MICROSOFT_TENANT_ID
ローカルでコネクタをインストール
curl -fsSL https://raw.githubusercontent.com/HelpCode-ai/anythingmcp/main/docker-compose.quickstart.yml -o docker-compose.yml
printf 'JWT_SECRET=%s\nENCRYPTION_KEY=%s\n' "$(openssl rand -hex 32)" "$(openssl rand -hex 32)" > .env
docker compose up -d
http://localhost:3000/connectors/store を開き、 Word (Microsoft 365) を選択し、前提条件に記載された環境変数を入力します。
利用可能なツール
| Tool | What it does |
|---|---|
microsoft_word_get_my_drive | Get the signed-in user's OneDrive: drive id (the drive_id for documents stored there), type (personal or business), owner, storage quota… |
microsoft_word_search_my_documents | Search the user's own OneDrive by name, metadata and content, e.g. "offer 2026" |
microsoft_word_find_documents | Find Word documents everywhere the user has access (their OneDrive, SharePoint sites, Teams files, files shared with them) with Microsoft… |
microsoft_word_list_folder | List the files and folders inside a folder of a drive (item_id "root" for its top level), to browse to a document |
microsoft_word_get_document | Get a document's details: name, size, created and last modified (when and by whom), folder (parentReference), mimeType and hashes, sharing… |
microsoft_word_get_document_by_path | Get a document in the user's own OneDrive by its path, e.g. "Documents/Contracts/Offer 2026.docx" |
microsoft_word_download_document | Download the document file itself (.docx), as it is stored |
microsoft_word_convert_to_pdf | Get the document converted to PDF by Microsoft 365 (works for .docx, .docm, .doc, .dotx, .odt and .rtf files), attached to the result as a… |
microsoft_word_list_versions | List the document's version history: each version's id (e.g. "4.0"), when and by whom it was saved, and size, newest first |
microsoft_word_download_version | Download an earlier version of the document as an attached file (up to 10 MB), e.g. to compare it with the current one |
microsoft_word_list_permissions | List who has access to the document: each permission's id, roles (read, write, owner), the people or groups granted (grantedToV2… |
microsoft_word_copy_document | Create a new document as a copy of an existing one, typically a template (e.g. "Templates/Offer template.docx"), in a target folder under a… |
microsoft_word_rename_document | Rename a document in place |
microsoft_word_move_document | Move a document into another folder of the same drive, optionally renaming it on the way |
microsoft_word_restore_version | Make an earlier version the current content of the document |
microsoft_word_check_out | Check out a document in a SharePoint library that requires check-out, so that only the user can change it until it is checked in |
microsoft_word_check_in | Check a checked-out document back in, with a comment that is stored with the new version, so other people see the changes and can edit it… |
microsoft_word_create_sharing_link | Create a sharing link for the document: type "view" or "edit", scope "anonymous" (anyone with the link, if the organisation allows it)… |
microsoft_word_delete_document | Delete a document |
プロンプトの例
- 「SharePoint で Contoso との基本契約書を探して、支払条件と解約条件をまとめて。」
- 「Templates/Offer template.docx から Offers 2026 フォルダーに新しい見積書を作って、名前を Offer Acme 2026.docx にして。」
- 「Documents/Contracts/NDA Acme.docx には誰がアクセスできる?匿名リンクはある?」
- 「この文書のバージョン履歴を見せて、先週の月曜日に保存したバージョンに戻して。」
- 「人事ライブラリの出張規程をチェックアウトして編集できるようにし、Word で開くリンクをちょうだい。」
次のステップ
このガイドは役に立ちましたか?