
Microsoft Forms API
io.github.Maxim-Mazurok由 GitHub 帳號 Maxim-Mazurok 發布v0.2.2更新於 Oct 24, 2026
Inspect, validate, upload, and submit Microsoft Forms responses
發布方自己的服務:Microsoft Learn MCP
概覽
本機 MCP 伺服器,讓助理透過已登入的瀏覽器工作階段檢視 Microsoft Forms、驗證答案、上傳檔案並送出回覆。
- 可以做什麼
- 檢視表單:讀取正規化及原始表單結構、題型、選項、必填狀態、文字驗證、矩陣列、檔案限制與分支目標,並透過可見的瀏覽器登入完成驗證。驗證答案:解析分支並在不送出的情況下檢查或序列化答案。上傳檔案:透過已驗證的 Forms 前端上傳本機檔案並回傳答案中繼資料。送出回覆:在明確確認後建立回覆,並在已登入帳戶中儲存或列出回覆連結。
- 適用情境
- 適合需要助理閱讀 Microsoft Form 並說明其問題與分支、在人工送出前準備與檢查答案,或自動化填寫並送出你有權回覆的表單等情境。
- 執行需求
- 透過 npx 在本機執行,需要 Node.js 22 或更新版本。需要 Google Chrome 或 Microsoft Edge,兩者皆不可用時會自動安裝 Playwright Chromium。首次使用需登入 Microsoft Forms,工作階段儲存在本機瀏覽器設定目錄,可用 MSFORMS_PROFILE_DIRECTORY 覆寫。MSFORMS_BROWSER_CHANNEL 選擇 chrome 或 msedge,MSFORMS_HEADLESS 設為 false 可顯示瀏覽器視窗。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Microsoft Forms API,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
msforms-api
AI-native Microsoft Forms automation for inspecting forms, resolving branching, validating answers, uploading files, submitting responses, and saving response links.
Use it as:
- MCP server for AI agents and editors — recommended for most users.
- Agent skill backed by the CLI for agents that can run shell commands.
- CLI for scripts and terminal workflows.
- TypeScript SDK for custom applications.
[Install in VS Code] [Install in VS Code Insiders] [Install in Cursor] [npm version] [CI]
[!NOTE] This project was generated by GitHub Copilot App using GPT-5.6 Sol with Extra High reasoning in Autopilot mode.
[!WARNING] This project uses reverse-engineered Microsoft Forms web APIs. Microsoft does not document or guarantee these endpoints. They can change without notice. This project is not affiliated with or endorsed by Microsoft.
Quick start
Prerequisites
- Node.js 22 or later.
- Google Chrome or Microsoft Edge. Playwright Chromium is installed automatically when neither is available.
Install as an agent skill
The CLI skill teaches agents how to inspect branching, prepare and validate answers, upload authorized files, and require explicit approval before submission:
The installer detects supported agents such as Claude Code, Cursor, GitHub Copilot, and Codex, then asks where to install the skill. Choose global scope to use it across projects.
The skill runs msforms-api through npx, so it does not require a global
package installation or MCP configuration. It is an alternative interface to
the MCP server; both use the same CLI and SDK behavior.
Install in an AI tool
Click an install badge above, or use this MCP configuration. For Cursor, save
it as ~/.cursor/mcp.json:
On first use, ask your agent to authenticate Microsoft Forms. A browser opens for sign-in, then future operations reuse the persistent session.
Try:
Inspect this Microsoft Form and explain every question, validation, upload rule, and branch:
https://forms.cloud.microsoft/...
The agent can prepare and validate answers without submitting. Submission uses a separate destructive MCP tool and requires explicit confirmation.
VS Code CLI installation
macOS / Linux:
Windows PowerShell:
Claude Desktop
Add the MCP configuration above to claude_desktop_config.json.
Claude Code
Windsurf and other MCP clients
Add the MCP configuration above to your client's MCP configuration file.
What agents can do
- Read complete form metadata, including raw API objects.
- Understand question types, options, required state, and text validation.
- Resolve choice branching through stable question identifiers.
- Inspect matrix rows and their shared options.
- Inspect file count, size, and extension restrictions.
- Validate and serialize answers without submitting.
- Upload files through the authenticated Forms frontend.
- Submit only after explicit confirmation.
- Save and list response links in the signed-in account.
MCP tools
forms_submit is marked destructive and non-idempotent. It uses MCP v2
multi-round-trip elicitation. Declined or false confirmation never reaches
submission code.
Cross-cutting workflow and safety guidance is also available through:
CLI
Run without installing globally:
Frequent CLI users can install globally:
Every command emits JSON. Add --compact for single-line output.
Authentication and local data
Authentication opens a visible browser and stores its profile under:
The SDK uses that profile to obtain scoped Forms cookies, an anti-forgery token, and session metadata. It does not print or return those credentials. Normal reads and submissions use direct Forms HTTP requests. File upload is browser-assisted because the Forms frontend manages SharePoint authorization.
Override the profile or browser:
MCP environment variables:
Delete ~/.msforms-api/browser-profile to remove the local session.
Answer format
Answers are keyed by exact question ID returned from forms_inspect.
Matrix answers use each row question ID, not the matrix group ID.
SDK
submitResponse() is direct at SDK level. Applications using the SDK must
implement their own user confirmation boundary. CLI requires --confirm; MCP
requires elicitation.
submissionStatus: "submitted" or a returned responseId means the permanent
response exists. A requested response-link save can fail independently. In
that case, saveResponseStatus is "failed", submission details remain in the
result, and callers must not submit again. Retry only the idempotent
saveResponse() operation.
Form structure
The normalized form model includes:
- IDs, titles, subtitles, order, type, and required state.
- Choice labels and
branchTargetIdvalues. - Matrix rows with inherited options.
- Text validation boundaries and rules.
- File upload restrictions.
- Parsed form settings.
- Full raw form and question objects for forward compatibility.
Example branch:
forms_validate returns visible question IDs, issues, and the exact serialized
answer array. Questions skipped by branching are omitted.
How it works
Browser bootstrap exposes the anti-forgery token, server session ID, form-owner tenant and user, responder tenant and user, and form prefetch URL. The client combines that data with scoped Forms cookies for direct requests.
Observed endpoint families:
The normalized model retains raw objects so newly introduced Forms properties remain inspectable before this package adds first-class support.
Limitations
- APIs are private and may change.
- File upload currently requires the upload question to be visible in the rendered branch.
- Authentication depends on Microsoft Forms web login behavior.
- The package is for legitimate form automation. Respect form owners, tenant policies, privacy requirements, and applicable law.
Development
See CONTRIBUTING.md.
License
來源:README.md,提交 c2726ad
工具
0版本歷史
1- v0.2.2最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分
其他 Microsoft 整合

Microsoft Learn MCP
com.microsoft官方發布者
一個免費的遠端 MCP 伺服器,讓 AI 助理搜尋微軟官方 Learn 文件、尋找程式碼範例,並把文件頁面抓取為 markdown。

Playwright Cloud Browsers
com.microsoft官方發布者
遠端 MCP 伺服器,為 AI 代理提供受管理的 Playwright 雲端瀏覽器,可建立工作階段、瀏覽並檢視頁面、與頁面元素互動。

Microsoft Sentinel Data Exploration
com.microsoft官方發布者
遠端 Microsoft Sentinel MCP 伺服器,讓助理以自然語言尋找相關資料表,並從 Sentinel 資料湖擷取安全性資料。
Visio
com.microsoft
讓助理透過桌面自動化,在使用者的 Windows 電腦上建立、更新與讀取 Microsoft Visio 圖表。

Microsoft Clarity MCP
由 GitHub 帳號 surendranb 發布
本機 MCP 伺服器,把 Microsoft Clarity 的行為 UX 資料(暴怒點擊、無效點擊、快速返回、JS 錯誤)提供給 AI 助理分析。