{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-ai/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown","redocly_category":"Development","owner":"MB"},"seo":{"title":"AI - Skill: Import From File","description":"A reusable AI skill that reads a product, price, or stock file, maps it to the Norce data model, asks clarifying questions for unknown formats, and imports the data in the correct order across MCP servers. Supports saved vendor profiles for recurring imports.","keywords":"MCP, skill, import, file, product import, price import, stock import, vendor mapping, Claude Code"},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"skill-import-from-file"},"children":["Skill: Import From File"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Reads a product, price, inventory, or supplier file, maps it to the Norce data model, and imports the data in the correct sequence across the relevant MCP servers. For known vendor formats, the import runs with minimal questions. For unknown formats, the skill asks what it needs before proceeding, then offers to save the mapping for next time."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Required MCP servers:"]}," Depends on the file content — Product MCP, Pricing MCP, Inventory MCP, and/or Supplier MCP. Config MCP recommended for reference data lookup."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Who it is for:"]}," PIM managers, pricing managers, and operators importing product data, prices, or stock from external systems or vendor files."]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"the-skill"},"children":["The skill"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["This skill has two parts: a ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["vendor profiles section"]}," at the top that you fill in over time, and the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["import logic"]}," below it. Start with the vendor profiles empty — the skill will build them up as you import from new vendors."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"markdown","header":{"controls":{"copy":{}}},"source":"---\nname: import-from-file\ndescription: Reads a product, price, inventory, or supplier file and imports it into Norce in the correct order. Asks clarifying questions for unknown formats and saves mappings for recurring vendor imports.\n---\n\n## Vendor profiles\n<!-- Add a profile block here for each recurring vendor after the first import.\n     The skill will use the saved mapping and skip the setup questions. -->\n\n<!-- Example profile (remove the comment markers and fill in your values):\nVENDOR: Acme Electronics\n  File format: CSV, semicolon-delimited\n  Content type: supplier products + cost prices\n  PartNo source: use from file (column: ArticleNo)\n  Field mappings:\n    ArticleNo → PartNo\n    ProductName → Name\n    Description → Description (sv-SE)\n    CostPrice → price (price list: ACME-COST)\n    StockQty → on-hand (warehouse: ACME-STANDARD)\n  Supplier code: ACME\n  Price list code: ACME-COST\n  Warehouse code: ACME-STANDARD\n  Import order: supplier products → prices → stock\n  Notes: Always skip rows where ArticleNo is empty.\n-->\n\n---\n\n## Import logic\n\nYou are running a file import into Norce Commerce.\n\nApplication ID: Use the application ID from your session instructions. If no\napplication ID is available, ask the user which storefront to import into\nbefore proceeding.\nFile to import: $ARGUMENTS\n\n**Step 1 — Identify the vendor and format**\n\nCheck the vendor profiles section above. If the file matches a known vendor\nprofile, confirm this with the user and proceed directly to Step 3 using the\nsaved mapping.\n\nIf no matching profile exists, this is an unknown format. Proceed to Step 2.\n\n**Step 2 — Gather information (unknown formats only)**\n\nBefore touching any data, ask the user the following questions. Wait for all\nanswers before proceeding.\n\n1. What is the name of this vendor or data source? (Used to save the mapping\n   for next time.)\n\n2. What does this file contain? (Select all that apply)\n   - New or updated products (product master data)\n   - Product content (descriptions, names, images)\n   - Retail prices\n   - Cost prices (supplier)\n   - Stock / on-hand quantities\n\n3. For products: should the PartNo (product identifier) come from the file,\n   or should Norce generate a new PartNo for each product?\n   - Use PartNo from file — which column?\n   - Let Norce generate PartNo\n\n4. Show the user the column headers from the file and ask them to confirm or\n   correct the following mapping. Propose your best guess for each column\n   based on the column name and sample values, and ask the user to confirm,\n   correct, or mark as \"skip\":\n   - [column] → [proposed Norce field] — correct?\n\n5. Are there any rows in the file that should be skipped? (e.g. rows where a\n   specific column is empty, or rows flagged as inactive)\n\n6. Which Norce price list, warehouse, or supplier code should the data be\n   imported to? If unsure, offer to look them up using the Config or Pricing MCP.\n\nOnce all questions are answered, summarise the confirmed mapping and ask for\nexplicit approval before importing:\n\n\"I am about to import [N] records from [vendor name] using the following\nmapping: [summary]. Products will be created/updated in [scope]. Shall I\nproceed?\"\n\n**Step 3 — Import in the correct order**\n\nFollow this sequence exactly. Do not start a later step until all jobs in the\nprevious step have completed successfully.\n\nIf the file contains content, prices, or stock but no product master data, the\nproducts must already exist in Norce. Verify this by calling\nnorce_product_lookup_products with a filter on PartNo for a sample of the\nPartNos in the file. Do NOT use norce_product_preview_product — that tool only\nshows published products and will miss products that are in progress or not yet\nactive. If products are not found, stop and report which PartNos are missing\nbefore attempting any import.\n\n1. **Product master data** — if the file contains product master data, import\n   first using norce_product_upsert_products. Poll for job completion before\n   continuing. Products must exist in Norce before any subsequent step can run.\n\n2. **Product content and supplier data in parallel** — once product master data\n   is confirmed, run the following in parallel if present:\n   - Product content (norce_product_update_content) — requires products to exist\n   - Supplier product mappings and cost prices (norce_supplier_import_products)\n     — requires products to exist; must complete before retail prices in step 3\n   Poll both jobs for completion before continuing.\n\n3. **Retail prices and stock in parallel** — once step 2 is confirmed, run the\n   following in parallel if present:\n   - Retail prices (norce_pricing_import_sku_prices) — import after supplier\n     cost prices are in place, as retail price rules may reference supplier cost\n   - On-hand stock quantities (norce_inventory_import_onhands)\n   Poll both jobs for completion.\n\nReport the result of each job as it completes. If any job fails or returns\nerrors, pause and report the failure before continuing to the next step.\n\n**Step 4 — Verify a sample**\n\nAfter all imports are complete, verify that the data landed correctly by\nspot-checking 3–5 records from the file against what is now stored in Norce.\nUse norce_product_lookup_products to retrieve the products — not\nnorce_product_preview_product, which only returns published products.\nFlag any discrepancies between the file and the imported data.\n\n**Step 5 — Save the mapping (unknown formats only)**\n\nIf this was an unknown vendor format, first ask:\n\n\"Is this a file format you expect to import again — for example a recurring\nvendor feed? Or is this a one-off file?\"\n\nIf the user confirms it is a recurring format, generate a vendor profile block\nin the format shown in the Vendor profiles section above, using the confirmed\nmapping from this session. Then:\n\n- **Claude Code users:** Offer to add the profile block directly to this skill\n  file (`.claude/commands/import-from-file.md`) so it is available next time\n  without any manual steps.\n- **Claude Desktop users:** Display the profile block and instruct the user\n  to paste it into the Vendor profiles section of `SKILL.md` and re-upload\n  the zip file to keep the mapping for next time.\n- **Other clients:** Display the profile block and ask the user to save it\n  somewhere accessible for the next import session.\n\nIf the user says it is a one-off file, skip this step entirely.\n","lang":"markdown"},"children":[]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"how-to-install"},"children":["How to install"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Save this skill using the filename ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["import-from-file"]}," and follow the ",{"$$mdtype":"Tag","name":"a","attributes":{"href":"/ai/norce-backend-mcp-skills-customization#installing-skills"},"children":["installation instructions"]}," for your client."]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Client"},"children":["Client"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"What to do"},"children":["What to do"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Claude Desktop"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Create ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["SKILL.md"]}," inside an ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["import-from-file/"]}," folder, zip it, upload via Settings → Skills. After importing from a new vendor, update ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["SKILL.md"]}," with the saved vendor profile and re-upload."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Claude Code"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Save as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":[".claude/commands/import-from-file.md"]},", invoke with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/import-from-file filename.csv"]},". The skill can update its own vendor profiles directly after new vendor imports."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["VS Code / Cursor"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Copy the skill content, replace ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["$ARGUMENTS"]}," with a reference to the file, paste into chat and attach the file"]}]}]}]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"what-to-customise"},"children":["What to customise"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The application ID is read from your session instructions — no placeholder to fill in. If you want this skill to always target a specific storefront regardless of your default instructions, add ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Application ID: [the ID]"]}," directly after the description block."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The main customisation is filling in vendor profiles as you import from recurring sources. The skill guides you through building these profiles — you do not need to create them manually."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Pre-filling known vendor profiles."]}," If you already know the field mapping for a vendor, add a profile block to the vendor profiles section before your first import. Use the example block in the skill file as a template. This skips all the setup questions and lets the import run immediately."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Adjusting the verification sample size."]}," The skill spot-checks 3–5 records by default. For high-stakes imports, increase this: add to the skill ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Verify 10 records after import, including the first, last, and 3 random records from the middle of the file."]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"example-usage"},"children":["Example usage"]},{"$$mdtype":"Tag","name":"blockquote","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/import-from-file acme-weekly-update.csv"]}," ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["(Known vendor — imports immediately with no questions)"]}]}]},{"$$mdtype":"Tag","name":"blockquote","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/import-from-file techsupply-catalogue-june.xlsx"]}," ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["(Unknown vendor — skill asks mapping questions, then imports, then saves mapping)"]}]}]},{"$$mdtype":"Tag","name":"blockquote","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["\"Import this file. It contains products and retail prices from our Swedish distributor.\""]}]},{"$$mdtype":"Tag","name":"blockquote","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["\"Run the weekly Acme import — the file is attached.\""]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"about-recurring-imports-and-mapping-memory"},"children":["About recurring imports and mapping memory"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For vendors you import from regularly, the vendor profile is the key mechanism. Once a profile is saved, the skill recognises the vendor's file format and imports without asking questions. Over time, the skill file becomes a record of all your vendor mappings — a configuration asset that reflects exactly how your team handles each data source."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For vendors with irregular or one-off files, the skill always asks what it needs and produces a clean import without requiring any pre-configuration."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If your team uses Claude Code, the skill can maintain its own vendor profiles by editing the skill file directly after each new vendor import. For Claude Desktop users, this requires a manual update to the zip file — a small overhead that is worth it for vendors you import from frequently."]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"related"},"children":["Related"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/ai/norce-backend-mcp-skill-check-product-readiness"},"children":["Check Product Readiness"]}," — verify products after import"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/ai/norce-backend-mcp-skills-customization"},"children":["Skills customization guide"]}," — how to pre-wire environment-specific IDs across all skills"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/ai/norce-product-mcp-tool-reference"},"children":["Product MCP tool reference"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/ai/norce-pricing-mcp-tool-reference"},"children":["Pricing MCP tool reference"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/ai/norce-inventory-mcp-tool-reference"},"children":["Inventory MCP tool reference"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/ai/norce-supplier-mcp-tool-reference"},"children":["Supplier MCP tool reference"]}]}]}]},"headings":[{"value":"Skill: Import From File","id":"skill-import-from-file","depth":1},{"value":"The skill","id":"the-skill","depth":2},{"value":"How to install","id":"how-to-install","depth":2},{"value":"What to customise","id":"what-to-customise","depth":2},{"value":"Example usage","id":"example-usage","depth":2},{"value":"About recurring imports and mapping memory","id":"about-recurring-imports-and-mapping-memory","depth":2},{"value":"Related","id":"related","depth":2}],"frontmatter":{"seo":{"title":"AI - Skill: Import From File","description":"A reusable AI skill that reads a product, price, or stock file, maps it to the Norce data model, asks clarifying questions for unknown formats, and imports the data in the correct order across MCP servers. Supports saved vendor profiles for recurring imports.","keywords":"MCP, skill, import, file, product import, price import, stock import, vendor mapping, Claude Code"},"metadata":{"redocly_category":"Development","owner":"MB"}},"lastModified":"2026-09-16T06:55:22.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/ai/norce-backend-mcp-skill-import-from-file","userData":{"isAuthenticated":false,"teams":["anonymous"]}}