imports_create
Set up a product import. Money is integer minor units (cents). Calling this changes nothing: it returns a preview of what would change and a confirmation link. Only the merchant, on that page, can make it happen.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The file's address, or the sheet's link as copied from the browser. | |
| hour | No | Daily or weekly: the hour, on the shop's clock. | |
| name | Yes | What to call it, e.g. "Supplier stock, hourly". | |
| notify | No | When a run's report is emailed. | problems |
| record | No | XML only: the element one product row is, as imports.inspect lists them, e.g. rss/channel/item. Omitted, the outermost repeating element. | |
| runNow | No | Run it as soon as it is saved. The preview says what the run would add, update and leave out. | |
| source | Yes | url for a CSV or XML file at an http(s) address; sheets for a Google Sheet shared as "anyone with the link". | |
| cadence | No | Run on its own this often (Pro). Omitted, it runs only when asked. | |
| mapping | No | Column (exactly as imports.inspect lists it) to field. Only the columns to change: the rest keep the guess, or the task's saved mapping. | |
| weekday | No | Weekly only: 1 is Monday, 7 is Sunday. | |
| strategy | No | upsert adds new products and updates existing ones; add only adds; update only updates (the rule for a stock or price file). | upsert |
| draftMissing | No | Set products to draft when they leave the file; only products this import brought in or updated, and never more than a fifth at once. |