import_sheet_tsv

Server-side parse + write of TSV (tab-separated) text.

destructiveGoogle Sheets, Docs & Drive

Use this to dump SP-API report previews, clipboard pastes, or any raw TSV blob directly into a sheet without pre-splitting on the client. The server splits on newlines then tabs, trims trailing empty rows, and writes every cell as text (RAW): '14' stays the string "14" and formulas are not evaluated. Use write_sheet when the values must be numbers, dates or formulas.

Call it

In an AI client (MCP)

tools/call
{
  "name": "import_sheet_tsv",
  "arguments": {
    "spreadsheet_id": "<spreadsheet_id>",
    "range_": "<range_>",
    "tsv_text": "<tsv_text>"
  }
}

From code (Tool API)

curl -X POST https://api.sellersheetai.com/api/v1/tools/import_sheet_tsv \
  -H "Authorization: Bearer $SELLERSHEET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"spreadsheet_id":"<spreadsheet_id>","range_":"<range_>","tsv_text":"<tsv_text>"}'
Early access — the Tool API is open on request, contact us.

Arguments

NameTypeDescription
spreadsheet_idrequiredstringthe spreadsheet ID (from its URL or get_sheet_metadata).
range_requiredstringthe top-left anchor cell, e.g. 'Sheet1!A1'. The block expands right and down.
tsv_textrequiredstringRaw TSV text. Lines separated by \n (or \r\n); cells separated by \t. Empty trailing lines are ignored.

Result

Every tool answers {notification, data, human_action}; data carries:

  • data.rowCount / data.colCount — the size of the block written (colCount = the widest row).
  • data.written — rows written (0 for empty text).

Example

import_sheet_tsv("1ABC...", "Inventory!A1",
    "sku\tasin\tqty\nA001\tB000ABC\t14\nA002\tB000DEF\t7")

On this page

Actions

View as Markdown

Ask an assistant

Ask ChatGPTAsk Claude