Office & Productivity
Microsoft 365 CLI
Word, Excel, PowerPoint, Outlook — full COM automation
✓ Live
Install
$ pip install cli-anything-ms365
About
Control Microsoft 365 applications via Windows COM automation. Create Word documents, manipulate Excel spreadsheets, build PowerPoint presentations and send Outlook emails — fully programmatic.
Requirements
Windows + Microsoft Office installed
Command Reference
| Command | Arguments | Description |
|---|---|---|
detect |
Check Office COM availability | |
word create |
--content TEXT --output OUT.docx |
Create Word document |
word convert |
INPUT.docx --format pdf --output OUT |
Convert to PDF |
excel create |
--data JSON --output OUT.xlsx |
Create Excel file |
excel read |
INPUT.xlsx --sheet SHEET |
Read spreadsheet data |
ppt create |
--title TITLE --slides JSON --output OUT.pptx |
Create presentation |
outlook send |
--to EMAIL --subject SUBJ --body BODY |
Send email via Outlook |
Usage Examples
# Install
$ pip install cli-anything-ms365
# Health check
$ ms365-cli detect
# Get capabilities schema (Agent-ready, no token needed)
$ ms365-cli schema
# Run with JSON output (for AI Agent integration)
$ ms365-cli --json detect
# Example JSON response:
{"application":"Word","version":"16.0","path":"C:\\doc.docx","pages":3}
Agent Integration
# Python — call from AI Agent
import subprocess, json
result = subprocess.run(
["ms365-cli", "--json", "detect"],
capture_output=True, text=True
)
data = json.loads(result.stdout)
print(data)
# Discover all commands without credentials:
schema = subprocess.run(
["ms365-cli", "schema"],
capture_output=True, text=True
)
capabilities = json.loads(schema.stdout)