Skip to content

Latest commit

 

History

History

bulk-trigger-shopify-flow-with-historical-data

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

Bulk trigger Shopify Flow with historical data

Tags: Integration, Shopify Flow

Do you wish Shopify Flow workflows could run on historical data? Now they can! :D

Default options

{
  "start_date": "",
  "end_date": "",
  "flag_value": "mechanic-batch"
}

Learn about task options in Mechanic

Subscriptions

mechanic/user/trigger
mechanic/shopify/bulk_operation

Learn about event subscriptions in Mechanic

Documentation

Do you wish Shopify Flow workflows could run on historical data? Now they can! :D

This task queries your orders, and calls Shopify Flow for each order returned. You can optionally provide a date range to limit the orders to be processed. If provided, these dates must be in this format YYYY-MM-DD.

It includes a flag value, intended to help Flow workflows identify the Mechanic order triggers that are relevant, ignoring those that are not. The flag value only has significance if there are Flow workflows looking for its value, using workflow conditions. A Flow condition for this purpose might read like, if User string is equal to 'mechanic-import'.

This task is written to process orders, but can be modified to process products or customers. To make a change like this, open the task code, and update the bulk operation to query for the right resources. Then, update the Flow action to send product_id or customer_id as appropriate, instead of order_id.

Installing this task

Find this task in the library at tasks.mechanic.dev, and use the "Try this task" button. Or, import this task's JSON export – see Importing and exporting tasks to learn how imports work.

Contributions

Found a bug? Got an improvement to add? Start here: ../../CONTRIBUTING.md.

Task requests

Submit your task requests for consideration by the Mechanic community, and they may be chosen for development and inclusion in the task library!