Tags: Tutorial
This is the companion task for the Triggering tasks from a contact form tutorial.
- View in the task library: tasks.mechanic.dev/tutorial-trigger-a-task-from-a-contact-form-using-webhooks
- Task JSON, for direct import: task.json
- Preview task code:
{
"recipient_email_address__email_required": "[email protected]",
"email_subject__required": "Contact form submission for CRM: {{ \"now\" | date: \"%Y-%m-%d %H:%M\" }}",
"email_body__required_multiline": "Hello,\n\nPlease find the attached CSV. Thanks!\n\n-Mechanic, for {{ shop.name }}",
"csv_attachment_filename__required": "contact-form-for-crm-{{ \"now\" | date: \"%s\" }}",
"mechanic_webhook_url__required": ""
}
Learn about task options in Mechanic
user/webhook/form
Learn about event subscriptions in Mechanic
This is the companion task for the Triggering tasks from a contact form tutorial.
This task is triggered via Mechanic webhook, and includes JavaScript that calls this webhook when a contact form is submitted on your online Shopify store. This task's included JavaScript listens for a submit
event on that form, sends the form data to your Mechanic webhook, and then allows that form to continue submission normally. In this way, the task augments the contact form's original functionality, instead of replacing that functionality.
This task requires additional setup, including configuring a Mechanic webhook for your store, and adjusting the task's JavaScript to account for your contact form HTML. To use this task, make sure to start with the tutorial itself:
https://learn.mechanic.dev/resources/tutorials/triggering-tasks-from-a-contact-form
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.
Found a bug? Got an improvement to add? Start here: ../../CONTRIBUTING.md.
Submit your task requests for consideration by the Mechanic community, and they may be chosen for development and inclusion in the task library!