Mila is a collaborative platform for documents, spreadsheets, and slide presentations. This skill teaches you how to interact with Mila's REST API and MCP tools to manage content programmatically.
Get started at https://mila.gg -- create an account, generate an API key, and start building.
All requests require a Mila API key. Keys use the format mila_sk_*.
API keys have scopes that control access (e.g. documents:read, documents:write, sheets:read, sheets:write, slides:read, slides:write).
Include the API key as a Bearer token:
text
Authorization: Bearer mila_sk_your_key_here
Base URL: https://api.mila.gg/v1
The MCP server uses the same API keys. Include the key in the Authorization header when connecting to the MCP endpoint.
MCP endpoint: https://mcp.mila.gg
If the user wants to connect Mila to an AI client via MCP, use these configurations:
Claude Desktop ( claude_desktop_config.json):
json
{
"mcpServers": {
"mila": {
"url": "https://mcp.mila.gg",
"headers": {
"Authorization": "Bearer mila_sk_your_key_here"
}
}
}
}
Cursor ( .cursor/mcp.json):
json
{
"mcpServers": {
"mila": {
"url": "https://mcp.mila.gg",
"headers": {
"Authorization": "Bearer mila_sk_your_key_here"
}
}
}
}
VS Code Copilot ( .vscode/mcp.json):
json
{
"servers": {
"mila": {
"type": "http",
"url": "https://mcp.mila.gg",
"headers": {
"Authorization": "Bearer mila_sk_your_key_here"
}
}
}
}
bash
curl -X POST https://api.mila.gg/v1/documents \
-H "Authorization: Bearer mila_sk_your_key_here" \
-H "Content-Type: application/json" \
-d '{"title": "Meeting Notes", "content": "<h1>Meeting Notes</h1><p>Discussed roadmap.</p>"}'
MCP tool: create_document with title and content (HTML string).
bash
curl -X POST https://api.mila.gg/v1/sheets \
-H "Authorization: Bearer mila_sk_your_key_here" \
-H "Content-Type: application/json" \
-d '{"title": "Budget", "cells": {"A1": {"value": "Item"}, "B1": {"value": "Cost"}, "A2": {"value": "Hosting"}, "B2": {"value": 99}}}'
MCP tool: create_sheet with title and cells (A1 notation object).
bash
curl -X POST https://api.mila.gg/v1/slides \
-H "Authorization: Bearer mila_sk_your_key_here" \
-H "Content-Type: application/json" \
-d '{"title": "Demo", "data": [{"html": "<div style=\"display:flex;align-items:center;justify-content:center;height:100%\"><h1 style=\"font-size:48px\">Hello</h1></div>", "background": "#ffffff", "notes": "Title slide"}]}'
MCP tool: create_slide_presentation with title and data (array of slide objects).
All resource IDs are opaque strings (e.g. "xK9mP2wQ"). Use them as-is in URLs and parameters.
List endpoints accept limit (1-100, default 50) and offset (default 0). Responses include a pagination object:
json
{
"data": [...],
"pagination": { "total": 42, "limit": 50, "offset": 0 }
}
List endpoints accept sort ( created_at, updated_at, last_edited_at, title) and order ( asc, desc).
Content can belong to a server (workspace) or to personal files.
server_id: returns all contentserver_id=personal: returns only personal filesserver_id=<id>: returns content in that serverPass server_id in the request body when creating content to place it in a server. Omit for personal files.
All responses use this structure:
json
{
"success": true,
"data": { ... }
}
Errors return:
json
{
"success": false,
"error": { "message": "Description of the error" }
}
<script> tags are stripped.{"A1": {"value": "Name"}, "B1": {"value": 42}}). Formulas start with =.html, background, and notes fields.For complete endpoint documentation with all parameters, response shapes, and examples:
ToolDescriptionlist_serversList all servers (workspaces)list_documentsList documents with pagination and filteringget_documentGet a document with full contentcreate_documentCreate a document with HTML contentupdate_documentUpdate title and/or contentdelete_documentDelete a documentappend_to_documentAppend HTML to a documentlist_sheetsList workbooks with tab metadataget_sheetGet a workbook with all tabs and cellscreate_sheetCreate a workbook with an initial tabupdate_sheetUpdate workbook titledelete_sheetDelete a workbook and all tabsget_sheet_tabGet a single tab with cell datacreate_sheet_tabAdd a tab to a workbookupdate_sheet_tabUpdate cells, name, color, or grid sizedelete_sheet_tabRemove a tab from a workbookappend_rowsAppend rows of data to a tablist_slidesList presentationsget_slide_presentationGet a presentation with all slidescreate_slide_presentationCreate a presentationupdate_slide_presentationUpdate title, slides, theme, or aspect ratiodelete_slide_presentationDelete a presentationappend_slidesAdd slides to a presentation