Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| MCP_TIMEOUT | No | The timeout for the MCP server connection in milliseconds (e.g., 30000). | |
| MCP_TOOL_TIMEOUT | No | The timeout for MCP tool execution in milliseconds (e.g., 90000). | |
| GOOGLE_CLIENT_SECRET_PATH | No | Path to the Google Cloud OAuth client secret JSON file. Defaults to ~/.appscript-mcp/client_secret.json, ./client_secret.json, or ~/.secrets/client_secret.json if not provided. |
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tasks | {
"list": {},
"cancel": {},
"requests": {
"tools": {
"call": {}
},
"prompts": {
"get": {}
},
"resources": {
"read": {}
}
}
} |
| tools | {
"listChanged": true
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| start_google_auth_tool | Start Google OAuth authentication flow. Returns an authorization URL that must be opened in a browser. After authorizing, call complete_google_auth with the redirect URL. |
| complete_google_auth_tool | Complete the Google OAuth flow with the redirect URL. Args: redirect_url: The full URL from the browser after authorization (looks like: http://localhost/?code=4/0A...&scope=...) |
| list_script_projects_tool | List Google Apps Script projects accessible to the user. Args: page_size: Number of results per page (default: 50) page_token: Token for pagination (optional) |
| get_script_project_tool | Retrieve complete project details including all source files. Args: script_id: The script project ID |
| get_script_content_tool | Retrieve content of a specific file within a project. Args: script_id: The script project ID file_name: Name of the file to retrieve (e.g., "Code", "appsscript") |
| create_script_project_tool | Create a new Apps Script project (standalone or bound to a document). Args: title: Project title parent_id: Optional - the Google Drive ID of a container document to bind to. Leave empty for standalone scripts. To create a BOUND script, pass the ID of:
- Google Sheet (from the URL: docs.google.com/spreadsheets/d/{ID}/edit)
- Google Doc (from the URL: docs.google.com/document/d/{ID}/edit)
- Google Form (from the URL: docs.google.com/forms/d/{ID}/edit)
- Google Slides (from the URL: docs.google.com/presentation/d/{ID}/edit)
Bound scripts can use document-specific features like custom menus,
onOpen triggers, and getActiveSpreadsheet(). |
| delete_script_project_tool | Delete an Apps Script project. WARNING: This permanently deletes the script project. The action cannot be undone. Args: script_id: The script project ID to delete |
| update_script_content_tool | Update or create files in a script project. Args: script_id: The script project ID files: List of file objects, each with: - name: File name (e.g., "Code", "Utils") - type: File type ("SERVER_JS", "HTML", or "JSON") - source: File content as string Example files parameter: [{"name": "Code", "type": "SERVER_JS", "source": "function main() { Logger.log('Hello'); }"}] |
| run_script_function_tool | Execute a function in a deployed script. Note: Requires the script to be deployed as "API Executable" in the Apps Script editor. See README for setup instructions. Args: script_id: The script project ID function_name: Name of function to execute parameters: Optional list of parameters to pass to the function dev_mode: If True, run latest code; if False, run deployed version |
| create_deployment_tool | Create a new deployment of the script. Args: script_id: The script project ID description: Deployment description version_description: Optional version description (defaults to deployment description) |
| list_deployments_tool | List all deployments for a script project. Args: script_id: The script project ID |
| update_deployment_tool | Update an existing deployment configuration. Args: script_id: The script project ID deployment_id: The deployment ID to update description: New description for the deployment |
| delete_deployment_tool | Delete a deployment. Args: script_id: The script project ID deployment_id: The deployment ID to delete |
| list_versions_tool | List all versions of a script project. Versions are immutable snapshots of your script code. They are created when you deploy or explicitly create a version. Args: script_id: The script project ID |
| create_version_tool | Create a new immutable version of a script project. Versions capture a snapshot of the current script code. Once created, versions cannot be modified. Args: script_id: The script project ID description: Optional description for this version |
| get_version_tool | Get details of a specific version. Args: script_id: The script project ID version_number: The version number to retrieve (1, 2, 3, etc.) |
| list_script_processes_tool | List recent execution processes for user's scripts. Args: page_size: Number of results (default: 50) script_id: Optional filter by script ID |
| get_script_metrics_tool | Get execution metrics for a script project. Returns analytics data including active users, total executions, and failed executions over time. Args: script_id: The script project ID metrics_granularity: Granularity of metrics - "DAILY" or "WEEKLY" |
| generate_trigger_code | Generate Apps Script code for creating triggers. The Apps Script API cannot create triggers directly - they must be created from within Apps Script itself. This tool generates the code you need. Args: trigger_type: Type of trigger. One of: - "time_minutes" (run every N minutes: 1, 5, 10, 15, 30) - "time_hours" (run every N hours: 1, 2, 4, 6, 8, 12) - "time_daily" (run daily at a specific hour: 0-23) - "time_weekly" (run weekly on a specific day) - "on_open" (simple trigger - runs when document opens) - "on_edit" (simple trigger - runs when user edits) - "on_form_submit" (runs when form is submitted) - "on_change" (runs when content changes) function_name: The function to run when trigger fires (e.g., "sendDailyReport")
schedule: Schedule details (depends on trigger_type):
- For time_minutes: "1", "5", "10", "15", or "30"
- For time_hours: "1", "2", "4", "6", "8", or "12"
- For time_daily: hour as "0"-"23" (e.g., "9" for 9am)
- For time_weekly: "MONDAY", "TUESDAY", etc.
- For simple triggers (on_open, on_edit): not needed Returns: Apps Script code to create the trigger. User should add this to their script and run the setup function once to install the trigger. |
| search_gmail_messages_tool | Search for Gmail messages matching a query. Args: user_google_email: The user's Google email address query: Gmail search query (e.g., "from:user@example.com subject:hello") max_results: Maximum number of messages to return (default: 10) |
| get_gmail_message_tool | Get a specific Gmail message by ID. Args: user_google_email: The user's Google email address message_id: The message ID to retrieve format: Message format - "full", "metadata", or "minimal" |
| send_gmail_message_tool | Send a Gmail message. Args: user_google_email: The user's Google email address to: Recipient email address(es), comma-separated subject: Email subject body: Email body content cc: Optional CC recipients, comma-separated bcc: Optional BCC recipients, comma-separated html: If True, body is treated as HTML |
| list_gmail_labels_tool | List all Gmail labels for the user. Args: user_google_email: The user's Google email address |
| modify_gmail_labels_tool | Modify labels on a Gmail message. Common label IDs:
Args: user_google_email: The user's Google email address message_id: The message ID to modify add_labels: List of label IDs to add (e.g., ["STARRED", "IMPORTANT"]) remove_labels: List of label IDs to remove (e.g., ["UNREAD", "INBOX"]) Examples: - Archive: remove_labels=["INBOX"] - Mark read: remove_labels=["UNREAD"] - Mark unread: add_labels=["UNREAD"] - Star: add_labels=["STARRED"] - Move to trash: add_labels=["TRASH"] |
| search_drive_files_tool | Search for files and folders in Google Drive. Args: user_google_email: The user's Google email address query: Search query string. Supports Drive query operators: - name contains 'example' - mimeType = 'application/vnd.google-apps.spreadsheet' - fullText contains 'keyword' - modifiedTime > '2024-01-01' page_size: Maximum number of files to return (default: 10) |
| list_drive_items_tool | List files and folders in a Drive folder. Args: user_google_email: The user's Google email address folder_id: The folder ID to list (default: 'root' for My Drive root) page_size: Maximum number of items to return (default: 50) |
| get_drive_file_content_tool | Get the content of a Google Drive file. Supports Google Docs (-> text), Sheets (-> CSV), Slides (-> text), and text files. Args: user_google_email: The user's Google email address file_id: The Drive file ID |
| create_drive_file_tool | Create a new file in Google Drive. Args: user_google_email: The user's Google email address file_name: Name for the new file content: File content (text) folder_id: Parent folder ID (default: 'root') mime_type: MIME type of the file (default: 'text/plain') |
| create_drive_folder_tool | Create a new folder in Google Drive. Args: user_google_email: The user's Google email address folder_name: Name for the new folder parent_id: Parent folder ID (default: 'root' for My Drive root) |
| delete_drive_file_tool | Permanently delete a file from Google Drive. WARNING: This permanently deletes the file. Use trash_drive_file for recoverable deletion. Args: user_google_email: The user's Google email address file_id: The file ID to delete |
| trash_drive_file_tool | Move a file to trash in Google Drive (recoverable). Args: user_google_email: The user's Google email address file_id: The file ID to trash |
| share_drive_file_tool | Share a file or folder with a user. Args: user_google_email: The user's Google email address file_id: The file or folder ID to share email: Email address of the user to share with role: Permission role - "reader", "writer", "commenter", or "owner" send_notification: Whether to send an email notification (default: True) |
| list_drive_permissions_tool | List all permissions on a file or folder. Args: user_google_email: The user's Google email address file_id: The file or folder ID |
| remove_drive_permission_tool | Remove a permission from a file or folder. Args: user_google_email: The user's Google email address file_id: The file or folder ID permission_id: The permission ID to remove (from list_drive_permissions) |
| list_spreadsheets_tool | List Google Sheets spreadsheets in Drive. Args: user_google_email: The user's Google email address query: Optional search query to filter spreadsheets page_size: Maximum number of spreadsheets to return (default: 20) |
| get_sheet_values_tool | Get values from a Google Sheet. Args: user_google_email: The user's Google email address spreadsheet_id: The spreadsheet ID range: A1 notation range (e.g., "Sheet1!A1:D10" or just "Sheet1") value_render: How values should be rendered - "FORMATTED_VALUE", "UNFORMATTED_VALUE", or "FORMULA" |
| update_sheet_values_tool | Update values in a Google Sheet. Args: user_google_email: The user's Google email address spreadsheet_id: The spreadsheet ID range: A1 notation range (e.g., "Sheet1!A1:D10") values: 2D array of values to write. Example: [["Header1", "Header2"], ["Value1", "Value2"]] value_input: How input values should be interpreted - "USER_ENTERED" or "RAW" |
| create_spreadsheet_tool | Create a new Google Spreadsheet. Args: user_google_email: The user's Google email address title: Title for the new spreadsheet sheet_names: Optional list of sheet names to create (default: ["Sheet1"]) |
| append_sheet_values_tool | Append values to a Google Sheet (adds rows after existing data). Args: user_google_email: The user's Google email address spreadsheet_id: The spreadsheet ID range: A1 notation range to append to (e.g., "Sheet1!A:D" or "Sheet1") values: 2D array of values to append. Example: [["Value1", "Value2"], ["Value3", "Value4"]] value_input: How input values should be interpreted - "USER_ENTERED" or "RAW" |
| get_spreadsheet_metadata_tool | Get metadata about a spreadsheet including all sheet names and properties. Args: user_google_email: The user's Google email address spreadsheet_id: The spreadsheet ID |
| list_calendars_tool | List all calendars accessible to the user. Args: user_google_email: The user's Google email address |
| get_events_tool | Get events from a calendar. Args: user_google_email: The user's Google email address calendar_id: Calendar ID (default: 'primary') max_results: Maximum number of events to return (default: 10) time_min: Start time in ISO format (default: now) time_max: End time in ISO format (default: 7 days from now) query: Optional search query string |
| create_event_tool | Create a new calendar event. Args: user_google_email: The user's Google email address summary: Event title start_time: Start time in ISO format (e.g., "2024-01-15T09:00:00") or date for all-day (e.g., "2024-01-15") end_time: End time in ISO format (e.g., "2024-01-15T10:00:00") or date for all-day (e.g., "2024-01-16") calendar_id: Calendar ID (default: 'primary') description: Optional event description location: Optional event location attendees: Optional comma-separated list of attendee emails all_day: If True, create an all-day event (use date format for start/end) |
| delete_event_tool | Delete a calendar event. Args: user_google_email: The user's Google email address event_id: The event ID to delete calendar_id: Calendar ID (default: 'primary') |
| update_event_tool | Update an existing calendar event. Args: user_google_email: The user's Google email address event_id: The event ID to update calendar_id: Calendar ID (default: 'primary') summary: New event title (optional) start_time: New start time in ISO format (optional) end_time: New end time in ISO format (optional) description: New description (optional) location: New location (optional) attendees: New comma-separated list of attendee emails (optional) all_day: If True and updating times, use date format |
| search_docs_tool | Search for Google Docs by name. Args: user_google_email: The user's Google email address query: Search query string page_size: Maximum number of docs to return (default: 10) |
| get_doc_content_tool | Get the content of a Google Doc. Args: user_google_email: The user's Google email address document_id: The document ID |
| create_doc_tool | Create a new Google Doc. Args: user_google_email: The user's Google email address title: Document title content: Optional initial content |
| modify_doc_text_tool | Modify text in a Google Doc. Args: user_google_email: The user's Google email address document_id: The document ID text: Text to insert (or replace with) index: Position to insert text (default: 1, start of document) replace_text: If provided, find and replace this text with 'text' |
| append_doc_text_tool | Append text to the end of a Google Doc. Args: user_google_email: The user's Google email address document_id: The document ID text: Text to append to the end of the document |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |