// e-commerce and billing
Via APIShopify email verification with pingutil
Shopify accepts any address that looks like an email at checkout, so typos and temp-mail inboxes turn into orders whose confirmations and shipping updates never arrive. A small webhook handler sends each new customer or order email to pingutil and tags the Shopify record with the result, so your team and your flows can act on it without ever touching payment.
Where it connects: Shopify webhooks (customers/create, orders/create) plus the Admin GraphQL tagsAdd mutation
What goes wrong without it
- A customer typed gmial.com at checkout, never got the shipping confirmation and opened a "where is my order" ticket.
- The same person keeps creating new accounts with throwaway inboxes to reuse the first-order discount code.
- Our Shopify Email and marketing flows keep sending to addresses that bounce, and we have no way to see which customers are fake.
What you can do with Shopify and pingutil
Tag customers with a verification result
On customers/create, verify the address and add a tag like email-invalid, email-risky or email-disposable. Tags show up in the admin, can filter customer segments and can be read by Shopify Flow.
Flag orders placed with an unreachable address
On orders/create, check the order email and tag the order so fulfilment or support knows to confirm the address by phone or SMS before the parcel ships.
Spot first-order discount abuse
Disposable and randomized addresses come back with category "disposable" or verdict.is_spam. Tag those orders so you can review discount use before the next sale.
Keep bad addresses out of marketing segments
Exclude customers tagged email-invalid from email campaigns, so dead mailboxes stop counting against your sender reputation.
Set it up
- 1
Create an API key in the pingutil dashboard and store it as PINGUTIL_KEY on the server that will receive webhooks.
- 2
In your Shopify app (custom app or Partner app), request the write_customers and write_orders access scopes and copy the client secret.
- 3
Subscribe to the customers/create and orders/create webhook topics, pointing them at your HTTPS endpoint.
- 4
In the handler, verify the X-Shopify-Hmac-SHA256 header against the raw body, respond 200 right away, then call pingutil in the background.
- 5
Write the result back with the tagsAdd mutation on the customer or order admin_graphql_api_id.
- 6
Use the tags in customer segments, Shopify Flow conditions or your support tooling.
import express from 'express';
import crypto from 'node:crypto';
const app = express();
const SHOP = process.env.SHOPIFY_SHOP; // your-store.myshopify.com
const ADMIN_TOKEN = process.env.SHOPIFY_ADMIN_TOKEN;
const CLIENT_SECRET = process.env.SHOPIFY_CLIENT_SECRET;
app.post('/webhooks/shopify', express.raw({ type: 'application/json' }), (req, res) => {
const hmac = req.get('X-Shopify-Hmac-SHA256') || '';
const digest = crypto.createHmac('sha256', CLIENT_SECRET).update(req.body).digest('base64');
if (hmac.length !== digest.length || !crypto.timingSafeEqual(Buffer.from(hmac), Buffer.from(digest))) {
return res.sendStatus(401);
}
res.sendStatus(200); // Shopify waits 5 seconds at most, so answer first
const customer = JSON.parse(req.body.toString('utf8'));
if (customer.email) tagCustomer(customer.admin_graphql_api_id, customer.email).catch(console.error);
});
async function tagCustomer(gid, email) {
let result;
try {
const res = await fetch('https://pingutil.com/v1/verify', {
method: 'POST',
headers: {
authorization: 'Bearer ' + process.env.PINGUTIL_KEY,
'content-type': 'application/json',
},
body: JSON.stringify({ email }),
signal: AbortSignal.timeout(30000),
});
if (!res.ok) return; // quota or rate limit: leave the customer untagged
result = await res.json();
} catch {
return; // fail open
}
const tags = ['email-' + result.status];
if (result.checks.disposable) tags.push('email-disposable');
if (result.did_you_mean) tags.push('email-typo');
// Use an Admin API version that is currently supported for your app.
await fetch('https://' + SHOP + '/admin/api/' + process.env.SHOPIFY_API_VERSION + '/graphql.json', {
method: 'POST',
headers: { 'X-Shopify-Access-Token': ADMIN_TOKEN, 'content-type': 'application/json' },
body: JSON.stringify({
query: 'mutation tag($id: ID!, $tags: [String!]!) { tagsAdd(id: $id, tags: $tags) { userErrors { message } } }',
variables: { id: gid, tags },
}),
});
}
app.listen(3000);What to do with each result
| pingutil result | Action in Shopify |
|---|---|
| status: "valid" | Tag email-valid. Nothing else to do. |
| status: "invalid" | Tag email-invalid on the customer and order, exclude from marketing, and contact the buyer another way about delivery. |
| did_you_mean is set | Tag email-typo and have support confirm the suggested address before changing the customer email. |
| checks.disposable: true | Tag email-disposable and review first-order discount use for that customer. |
| status: "risky" or "unknown" | Tag only. Catch-all domains and slow mail servers are common for real buyers, so do not cancel orders on these. |
Limits to plan for
- Shopify gives a webhook request five seconds and retries failed deliveries, while a mailbox check can take several seconds or more on slow mail servers. Respond 200 first and verify in the background or a queue.
- A webhook fires after the customer or order exists, so this flags rather than prevents. For typo suggestions during checkout you need your own frontend and backend call, which Shopify checkout customization may not allow on every plan.
- pingutil verifies up to 300 addresses a day (3,000 a month) per account. On a busy store, verify orders and use /v1/lookup with skip_enrichment for the rest. Those are Free plan limits; Enterprise has custom limits.
Shopify documentation
- shopify.dev/docs/apps/build/webhooks/subscribe/https
- shopify.dev/docs/api/admin-graphql/latest/mutations/tagsAdd
Shopify is a trademark of its owner. This integration uses Shopify's documented extension points; it is not an official Shopify app.
Common questions
- Can pingutil block a Shopify checkout with a bad email?
- Not from a webhook, because webhooks fire after the order is created. We recommend tagging and following up, since blocking a paying customer over an email check costs more than it saves.
- Should I verify customers or orders?
- Orders if you care about delivery emails, customers if you care about account and discount abuse. Results are cached, so verifying the same address twice is cheap.
- Is there a pingutil Shopify app?
- No. You connect pingutil through webhooks and the Admin API as shown here, or through an automation tool like Zapier, Make or n8n.
Stop bad addresses in Shopify today
Sign in with your email, create an API key and paste it into the step above. Test on a few real addresses first: the live demo shows exactly what your Shopify setup will receive.