Shopify Integration
Connect your Shopify store with webhooks for server-side tracking plus unified SDK for client-side pixels.
Shopify is the most popular e-commerce platform. AdsMAA provides dual-track Shopify integration: server-side webhooks for accurate order data, plus our Unified SDK for client-side pixel tracking.
Why Connect Shopify?
What You Get
| Feature | Benefit |
|---|---|
| Order Sync | All orders imported for revenue tracking |
| Customer Profiles | Build rich customer profiles with purchase history |
| Real-Time Updates | Webhooks notify us of new orders instantly |
| Attribution | Connect ad spend to actual revenue |
| LTV Calculation | Track customer lifetime value over time |
Before vs After
| Metric | Before | After |
|---|---|---|
| Revenue tracking | Manual export | Automatic |
| Customer data | Siloed in Shopify | Unified in AdsMAA |
| Attribution | Guessing | Precise |
| Reporting | Multiple tools | One dashboard |
Setup Guide
Step 1: Create Shopify App
- Log into your Shopify Admin
- Go to Settings ā Apps and sales channels
- Click Develop apps (top right)
- Click Create an app
- Name it "AdsMAA Integration"
- Click Create app
Step 2: Configure Permissions
- Click Configure Admin API scopes
- Select these permissions:
| Scope | Why Needed |
|---|---|
| read_orders | Import order data |
| read_customers | Import customer profiles |
| read_products | Product data for analytics |
| read_inventory | Stock level tracking |
- Click Save
Step 3: Get Access Token
- Click Install app
- Go to API credentials tab
- Under Admin API access token, click Reveal token once
- Copy the token immediately - shown only once!
Step 4: Connect in AdsMAA
- Go to Integrations ā Tracking & E-commerce
- Find Shopify card
- Click Connect
- Enter your credentials:
| Field | What to Enter |
|---|---|
| Shop Domain | your-store.myshopify.com |
| Access Token | The token you copied |
- Click Connect
What Gets Synced
Orders
| Field | Description |
|---|---|
| Order ID | Unique order identifier |
| Customer | Email and customer ID |
| Products | Items purchased with quantities |
| Revenue | Order total and currency |
| Discounts | Discount codes and amounts |
| Timestamps | Created, fulfilled, updated |
Customers
| Field | Description |
|---|---|
| Customer ID | Shopify customer ID |
| Hashed for privacy | |
| Orders Count | Total orders placed |
| Total Spent | Lifetime revenue |
| Tags | Shopify customer tags |
| Created At | First order date |
Products
| Field | Description |
|---|---|
| Product ID | Shopify product ID |
| Title | Product name |
| Price | Current price |
| Inventory | Stock levels |
| Category | Product type |
Adding Tracking Code
For complete funnel tracking, add our SDK to your Shopify theme:
Step 1: Access Theme Code
- Go to Online Store ā Themes
- Click Actions ā Edit code
- Find theme.liquid
Step 2: Add SDK
Add before </head>:
****`html
<script> (function(w,d,s,o,f,js,fjs){ w['AdsMAA']=o;w[o]=w[o]||function(){(w[o].q=w[o].q||[]).push(arguments)}; w[o].l=1*new Date();js=d.createElement(s);fjs=d.getElementsByTagName(s)[0]; js.async=1;js.src=f;if(fjs&&fjs.parentNode)fjs.parentNode.insertBefore(js,fjs); }(window,document,'script','adsmai','https://cdn.adsmai.com/sdk.js')); adsmai('init', 'YOUR_API_KEY'); adsmai('pageview'); </script>****`
Step 3: Add E-commerce Events
For product pages, add ViewContent:
****`html {% if template contains 'product' %}
<script> adsmai('track', 'ViewContent', { content_id: '{{ product.id }}', content_name: '{{ product.title | escape }}', content_type: 'product', value: {{ product.price | money_without_currency | remove: ',' }}, currency: '{{ shop.currency }}' }); </script>{% endif %} ****`
Real-Time Webhooks
We automatically configure webhooks for real-time updates:
Configured Webhooks
| Event | When Fired |
|---|---|
| orders/create | New order placed |
| orders/updated | Order modified |
| orders/fulfilled | Order shipped |
| orders/cancelled | Order cancelled |
| refunds/create | Refund issued |
| customers/create | New customer |
| customers/update | Customer modified |
Webhook Benefits
- Instant updates - No waiting for sync
- Real-time attribution - See conversions immediately
- Accurate inventory - Stock updates in real-time
- Live dashboards - Watch sales as they happen
Recap
Here is what you learned:
- Connect via Admin API - Create a custom app in Shopify
- Orders and customers sync automatically - Historical and ongoing
- Add tracking code - For complete funnel visibility
- Webhooks provide real-time updates - No delay in data
Shopify integration gives you the complete picture of your e-commerce business.
Next step: Connect WooCommerce if you run multiple stores.
Key Takeaways
- 1Webhooks for server-side order tracking
- 2Unified SDK auto-loads Meta Pixel, GA4, Clarity
- 3Real-time order sync via webhooks
- 4Complete purchase funnel with dual-track
Frequently Asked Questions
How far back does historical sync go?
Will this slow down my Shopify store?
Can I connect multiple Shopify stores?
Was this article helpful?
Continue Reading
WooCommerce Integration
Connect your WooCommerce store with REST API for server-side tracking plus unified SDK for all pixels.
integrationsUnified JavaScript SDK
One SDK for all platforms. Auto-loads Meta Pixel, GA4, and Clarity based on your connected integrations.
trackingConversion Tracking Deep Dive
Understand how server-side tracking works and why it captures 2x more data than browser pixels.