Command-line interface for Nudocs.ai
Upload, manage, and export documents from your terminal
Installation • Quick Start • Commands • AI Agents • Formats
npm install -g @nutrient-sdk/nudocs-cliOr use directly with npx:
npx @nutrient-sdk/nudocs-cli upload my-document.mdSign in at nudocs.ai and click "Integration" to get your API key.
# Option A: Environment variable (recommended for CI)
export NUDOCS_API_KEY="nudocs_your_key_here"
# Option B: Config file (recommended for personal use)
mkdir -p ~/.config/nudocs
echo "nudocs_your_key_here" > ~/.config/nudocs/api_keynudocs upload my-document.mdYou'll get back an edit link to open in Nudocs! ✨
nudocs upload report.md
nudocs upload presentation.docxUploads the file and returns an edit link. The document ID is saved for quick access.
nudocs listnudocs link # Last uploaded document
nudocs link 01ABC123XYZ # Specific document by IDnudocs pull # Last doc as .docx (default)
nudocs pull --format md # Last doc as markdown
nudocs pull 01ABC123XYZ --format pdf # Specific doc as PDF
nudocs pull --output report.docx # Custom output filenamenudocs delete 01ABC123XYZnudocs config| Format | Extensions |
|---|---|
| Markdown | .md |
| Microsoft Word | .doc, .docx |
.pdf |
|
| HTML | .html |
| Plain text | .txt |
| OpenDocument | .odt |
| Rich Text | .rtf |
| EPUB | .epub |
| LaTeX | .tex, .latex |
| Format | Flag |
|---|---|
| Word (default) | --format docx |
| Markdown | --format md |
--format pdf |
|
| HTML | --format html |
| Plain text | --format txt |
This CLI is designed to work seamlessly with AI coding assistants and agents:
# Upload a document
nudocs upload my-blog.md
# Get the edit link
nudocs link
# Pull back after editing
nudocs pull --format mdInstall the Nudocs skill for native integration:
clawdhub install nudocsFor native MCP integration, use @nutrient-sdk/nudocs-mcp-server.
| Variable | Description |
|---|---|
NUDOCS_API_KEY |
Your Nudocs API key |
NUDOCS_URL |
API base URL (default: https://nudocs.ai) |
# Write your post
echo "# My Blog Post\n\nContent here..." > blog.md
# Upload to Nudocs for rich editing
nudocs upload blog.md
# → Opens in Nudocs with AI assistance
# Pull back the polished version
nudocs pull --format md --output blog-final.md# Upload a markdown file
nudocs upload report.md
# Export as PDF
nudocs pull --format pdf --output report.pdf
# Export as Word
nudocs pull --format docx --output report.docxMIT © Nutrient