Skip to main content
Glama
@cmssy/mcp-server

@cmssy/mcp-server

Official

Start record import

start_record_import
Destructive

Starts a background job to import up to 100,000 rows into a data model, validating rows before writing them in batches; use it for imports over 1,000 rows.

Instructions

Import up to 100000 rows into a data model as a background job. Use it instead of import_records for more than 1000 rows. The rows are uploaded, then validated - nothing is written while any row is still unchecked - and the valid rows are written in batches. Returns the job at once: follow it with get_record_import until status is awaitingConfirmation, completed, failed or cancelled. With onInvalid STOP (the default) a job with invalid rows stops at awaitingConfirmation: read them with list_record_import_rows (status invalid), then confirm_record_import to write the valid rows or cancel_record_import to write none. A row over 65536 bytes is staged as invalid. A model runs one import at a time: a start while another is running is refused and the uploaded rows are discarded - read the running one with get_record_import by modelIdOrSlug.

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": {
      "modelIdOrSlug": "<modelIdOrSlug>",
      "rows": "<rows>"
    },
    "name": "start_record_import"
  }
}

Input Schema

NameRequiredDescriptionDefault
rowsYesArray of plain objects keyed by the model's field keys, in the same shape import_records takes: a translatable field takes a language map ({ title: { en: '...', no: '...' } }). Row numbers in the job are positions in this array, starting at 1.
onInvalidNoWhat happens when validation refuses a row. STOP (the default) writes nothing and leaves the job awaitingConfirmation until confirm_record_import or cancel_record_import; CONTINUE writes the valid rows without asking.
upsertKeyNoA key from the model's uniqueFields, or its product skuField. A row whose value matches an existing record updates that record; any other row is created. Not allowed on member (auth) models.
modelIdOrSlugYesTarget model id or slug

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.148.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only declare that this is a destructive write; the description adds substantially more: asynchronous job semantics, validation-before-write staging, batched writes, the per-row 65536-byte rejection rule, the one-import-per-model concurrency limit with row discard on refusal, and the awaitingConfirmation gate that makes writes contingent on a later call. This is exactly the behavioral context an agent needs before a destructive call, and it is consistent with destructiveHint=true.

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 verb, scope and the sibling comparison, then ordered mechanics, follow-up protocol, failure branch, limits. It is long and densely packed into a few run-on sentences, but essentially every clause carries information (thresholds, statuses, tool names, byte limit) rather than filler.

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?

There is no output schema, so the description must explain what comes back, and it does: the job handle returned immediately plus the status values to poll for. Combined with the concurrency, size and confirmation rules, nothing an agent needs in order to call this destructive async operation correctly appears to be missing.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3; the description still adds meaning by tying onInvalid=STOP to the awaitingConfirmation workflow and the follow-up tools, and by explaining that row numbers are 1-based positions in the rows array. upsertKey and modelIdOrSlug are left to the schema, which is acceptable given full coverage.

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?

The first sentence gives a specific verb (import), resource (rows into a data model), scope cap (up to 100000 rows) and execution model (background job). The second sentence explicitly separates it from the sibling import_records with a row-count threshold, so an agent can choose without opening either schema.

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

Usage Guidelines5/5

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

It states when to prefer this over import_records ('more than 1000 rows') and specifies the exact follow-up protocol: poll get_record_import until one of four terminal statuses, then branch to list_record_import_rows / confirm_record_import / cancel_record_import under STOP, or take automatic writes under CONTINUE. It also names the exclusion case (a second concurrent start on the same model is refused and rows are discarded) and routes to get_record_import by modelIdOrSlug instead.

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