store

v0.1.0
com.yaktool/store Checked 2 days ago Published 3 months ago

Forecast a WooCommerce CSV import and migrate Shopify exports.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

validate_woocommerce_csv Forecast a WooCommerce product CSV import

Pre-flight a WooCommerce product CSV against 40 documented rules and forecast what the import will actually do. WooCommerce fails quietly in two ways this catches: (1) a row whose SKU or ID already exists is SKIPPED unless "Update existing products" is ticked — the run still reports success; (2) any column the importer does not recognise defaults to "Do not import" on the mapping screen, so its data never arrives and nothing warns. Because the outcome depends on a checkbox the user has not ticked yet, the result gives BOTH forecasts side by side (summary.addMode and summary.updateMode) rathe…

ParameterTypeDescription
csv *stringThe product CSV contents as text, header row first. Pass it raw — delimiter, encoding and quoting quirks are part of what gets checked.
existingIdsarrayProduct IDs already in the store. Same purpose as existingSkus, for files that match on ID.
existingSkusarraySKUs already in the store (Products → Export). Enables the real skipped-vs-updated forecast.

migrate_store_csv Convert a product CSV between Shopify and WooCommerce

Convert a product export between Shopify and WooCommerce, applying 21 documented rules. This is a STRUCTURAL conversion, not a column rename — renaming columns loses variants and every sale price. What it reshapes: Shopify handle groups become a WooCommerce variable product plus variation rows linked through Parent (and back again); per-image rows collapse into one comma-separated Images cell (and expand again); Option1/2/3 become Attribute N name/value(s). The critical value fix: the two platforms store sale prices in OPPOSITE columns. Shopify Variant Price is the current price and Compare…

ParameterTypeDescription
csv *stringThe product export as text, header row first — a Shopify or WooCommerce CSV.
directionstringOnly needed when the header row does not identify the platform; otherwise it is detected.