Appearance
Setting Up a Shopify Flow with Webhook Integration
Prerequisites
- Shopify account with access to Flow feature
- NaviStone account with IQ Mail feature
Step-by-Step Instructions
Access Shopify Flow
- Log into your Shopify admin panel.
- Navigate to "Apps" in the left sidebar.
- Find and select "Shopify Flow."
- If Flow isn’t installed, search for it in "Apps" and install it before proceeding.
- Click "Create workflow" in the upper right corner.
Configure Flow Trigger
- Under the “Start Building” section, click the “Select a trigger” button.
- Choose a trigger condition, such as:
"Order created""Customer created"
- Configure any specific conditions for the trigger.
- Click "Next" to proceed.
Set Up Conditions (Optional)
- Add any conditional logic if needed.
- Configure filters based on your business rules.
- Click "Next" to proceed.
Configure Webhook Action
- On the trigger event, click the blue plus icon in the bottom right corner.
- Search for "Send HTTP request" and select it to add to your Flow.
- Set the HTTP method to
"POST". - Enter the webhook URL:
https://integrations.navistone.com/feed - Add your API key in the headers section:
- Key:
api_key - Value: (Paste the value from the IQ Mail campaign.)
- Key:
Configure Webhook Payload
- In the "Body" section, paste the following code snippet:
json{ "action": "triggerdm", "campaign_id": "[Insert Your Campaign ID Here]", "first_name": "{{customer.firstName}}", "last_name": "{{customer.lastName}}", "address_line_1": "{{customer.defaultAddress.address1}}", "address_line_2": "{{customer.defaultAddress.address2}}", "city": "{{customer.defaultAddress.city}}", "state": "{{customer.defaultAddress.province}}", "postal_code": "{{customer.defaultAddress.zip}}", "reference_id": "{{customer.id}}" }- Field Descriptions:
action: Must always be"triggerdm".first_name,last_name,address_line_1,city,state,postal_code: Dynamically mapped from Shopify’s customer data.campaign_id: Unique identifier for your campaign.
- Important Note: Replace
[Insert Your Campaign ID Here]with the actual campaign ID.
Enable and Verify the Workflow
- Review the entire workflow configuration carefully.
- Click "Turn on workflow" to activate.
- Create a test order or trigger the configured event manually.
- Monitor your webhook endpoint logs to confirm successful data transmission. Look for a
200 OKstatus and review payloads for accuracy.
Error Handling
- Verify that your API key is entered correctly.
- Ensure your trigger conditions align with the Shopify event types.
- Check webhook endpoint logs for potential errors.