Skip to content

Shopify Integration with Marqo

This guide will help you integrate Marqo's powerful search capabilities with your Shopify store. Marqo provides a seamless integration that enhances your store's search functionality with advanced features like semantic search, filtering, and relevance tuning.

Prerequisites

Integration Steps

1. Download Required Files

Before beginning the integration, you'll need to download two key components:

  1. Webhook Handler: Download the Shopify Webhook Handler
  2. This component manages real-time updates from your Shopify store
  3. Ensures your Marqo search index stays in sync with your product catalog

  4. Indexing Script: Download the Shopify Indexing Script

  5. This script handles the initial product data import
  6. Can be used for periodic full reindexing if needed

2. Set Up Webhook Handler

The webhook handler ensures your Marqo search index stays up-to-date with your Shopify store:

  1. Deploy the webhook handler to your preferred hosting environment
  2. Configure the following environment variables:
  3. MARQO_API_KEY: Your Marqo API key
  4. MARQO_ENDPOINT: Your Marqo endpoint URL
  5. SHOPIFY_SHOP_DOMAIN: Your Shopify store domain
  6. SHOPIFY_ACCESS_TOKEN: Your Shopify admin API access token

  7. Set up the following Shopify webhooks in your store's admin panel:

  8. Product creation
  9. Product updates
  10. Product deletion
  11. Inventory updates

3. Initial Data Indexing

To populate your Marqo search index with your existing product data:

  1. Extract the downloaded indexing script to your local machine
  2. Configure the script with your credentials:

    export MARQO_API_KEY="your_api_key"
    export MARQO_ENDPOINT="your_endpoint"
    export SHOPIFY_SHOP_DOMAIN="your-store.myshopify.com"
    export SHOPIFY_ACCESS_TOKEN="your_access_token"
    

  3. Run the indexing script:

    python shopify_indexer.py
    

  4. Monitor the script's output to ensure all products are indexed successfully

4. Verify Integration

To ensure everything is working correctly:

  1. Test the search functionality on your store's frontend
  2. Verify that search results are being returned from Marqo
  3. Make a test product update in Shopify
  4. Confirm the update is reflected in Marqo search results within a few minutes

Troubleshooting

If you encounter any issues during the integration:

  1. Verify that your Marqo API key is correct
  2. Ensure the webhook handler is properly configured and running
  3. Check that your Shopify webhooks are properly set up
  4. Verify that your firewall allows connections to the Marqo endpoint
  5. Check the webhook handler logs for any error messages
  6. Contact Marqo Support if issues persist

Support

For any questions or issues with the integration, please contact our support team:

Additional Resources