Skip to main content
Glama

import_csv_to_sheet

Destructive

Creates a Google Spreadsheet from a local CSV file and resizes the sheet to fit all rows before writing data in batches.

Instructions

Create a new Google Spreadsheet populated from a local CSV file. Not available when the server runs with LOCAL_FILE_ACCESS=off.

Reads the CSV, creates the spreadsheet, expands the sheet's grid to fit the data (avoiding the default 1000-row/26-column limit), and writes every row in one or more batched value updates.

Row chunks write concurrently rather than one at a time (#183). If the caller supplied a progressToken, a notifications/progress update is sent as each chunk finishes (#355).

Args: local_path: Absolute path to the local .csv file. title: Title for the new spreadsheet. folder_id: Optional Google Drive folder ID where the spreadsheet should be created. If not provided, uses the configured default folder or creates in root. sheet_name: Name of the sheet the data is written to (default "Sheet1").

Returns: spreadsheetId, title, web_link, and rows_written on full success. Rows are written in row-range chunks that run concurrently; if one or more chunks fail, the spreadsheet (already created) may have some rows missing — not necessarily a clean prefix. In that case returns an 'error' summary plus spreadsheetId, title, web_link, rows_attempted, failed_ranges (start_row, end_row, error per failed chunk), and written_ranges (start_row, end_row per chunk that succeeded), so the missing rows can be retried precisely.

Note: Requires OAuth or ADC auth. Service accounts cannot create files in personal Drive (no storage quota). Works on Shared Drives regardless of auth method. Check server://auth-status for your current auth method.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "local_path": "<local_path>",
      "title": "<title>"
    },
    "name": "import_csv_to_sheet"
  }
}

Input Schema

NameRequiredDescriptionDefault
titleYes
folder_idNo
local_pathYes
sheet_nameNoSheet1

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.9.6

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With only destructiveHint=true in annotations, the description carries the burden well: it discloses grid expansion beyond the 1000-row/26-column default, concurrent chunked writes, progress notifications when a progressToken is supplied, and — most importantly — that partial failures leave an already-created spreadsheet with missing non-prefix rows plus failed_ranges for targeted retry.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the purpose and the availability gate, then structured Args/Returns/Note. The issue references (#183, #355) and the long returns enumeration are slightly noisy, and return values are already covered by an output schema, but every block still carries usable information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a four-parameter mutation that creates files, the definition covers the auth model, the feature-flag prerequisite, the write strategy, and the exact shape of a partial-failure outcome. An agent has everything needed to call it and to interpret an incomplete result, even though the output schema made the returns section optional.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must carry all four parameters, and it does: local_path as an absolute .csv path, title, folder_id with its default-folder/root fallback, and sheet_name with its Sheet1 default. That fully compensates for the empty schema documentation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource with the crucial distinguishing detail: 'Create a new Google Spreadsheet populated from a local CSV file.' That separates it from the plain create_sheet sibling without needing to name it, since the source of the data is the differentiator.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives real gating context an agent must check before calling: unavailable when LOCAL_FILE_ACCESS=off, and requires OAuth/ADC with the warning that service accounts cannot create files in personal Drive. It does not explicitly route to alternatives (e.g. create_sheet plus a separate import path), so it stops short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools