{
  "id": "starter-import",
  "name": "Preview a Starter CSV import",
  "risk": "mutating",
  "goal": [
    "Open Data → Import and upload data_science_salaries.csv from the allowed test fixture directory.",
    "Wait until upload status is success, use target database test and table e2e_import_preview, then continue only to the data preview.",
    "Verify the preview is visible and stop without starting the final import."
  ],
  "success": {
    "evidence": [
      { "kind": "url", "matches": "/tidbs/[^/]+/imports/create-import(?:[/?]|$)" },
      { "kind": "visibleText", "text": "Success", "timeoutMs": 60000 },
      { "kind": "visibleText", "text": "Start Import", "timeoutMs": 60000 }
    ]
  },
  "limits": { "maxDurationMs": 180000, "maxActions": 28 },
  "recovery": [
    "Use the Choose File control once. After a successful upload tool call, never invoke upload again; wait for upload status. Retry once only if the upload tool explicitly reports a failed file transfer."
  ],
  "safety": {
    "deny": [
      "Do not upload any file except data_science_salaries.csv.",
      "Do not start the final import or overwrite an existing table."
    ],
    "networkGuards": [
      {
        "id": "starter-import-upload",
        "method": "POST",
        "pathMatches": "/imports:upload$",
        "maxRequests": 2
      },
      {
        "id": "starter-import-types",
        "method": "POST",
        "pathMatches": "/imports:listSupportedDataTypes$",
        "maxRequests": 2
      },
      {
        "id": "starter-import-preview",
        "method": "POST",
        "pathMatches": "/imports:previewLocal$",
        "maxRequests": 2
      },
      {
        "id": "starter-import-columns",
        "method": "POST",
        "pathMatches": "/imports:getTableColumns$",
        "maxRequests": 2
      }
    ]
  }
}
