explaingit

lsb11/shopify-capi-validator

Analysis updated 2026-05-18

3JavaScriptAudience · developerComplexity · 2/5LicenseSetup · easy

TLDR

A zero-dependency CLI that validates Meta Conversions API and TikTok Events API payloads for common formatting errors, like unhashed PII or wrong timestamp units, before you send them live and lose tracking data silently.

Mindmap

mindmap
  root((shopify-capi-validator))
    What it checks
      Timestamp format
      Hashed PII fields
      Required purchase fields
      Deduplication IDs
    Platforms
      Meta Conversions API
      TikTok Events API
    Usage
      npx one-liner
      CI pipeline mode
      JavaScript library
    Why it matters
      Silent failures
      No error from platforms
      Match quality score
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Validate a Meta CAPI purchase event for missing currency or unhashed email before going live

USE CASE 2

Add payload validation to a CI pipeline so builds fail when a CAPI or TikTok payload is malformed

USE CASE 3

Debug a Shopify server-side tracking setup by running webhook JSON through the validator

What is it built with?

JavaScriptNode.js

How does it compare?

lsb11/shopify-capi-validatoramarjitjim/browserpilotkitakitaaura/webgraph
Stars333
LanguageJavaScriptJavaScriptJavaScript
Setup difficultyeasymoderateeasy
Complexity2/53/51/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 5min
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.

In plain English

This is a command-line tool that checks event tracking payloads for Meta Conversions API and TikTok Events API before you send them live. Both platforms have a well-known frustration: if you send an incorrectly formatted event, they accept it silently and simply never count it, leaving you with missing conversion data and a degraded match quality score. This tool catches those formatting errors locally, so you find out before the data is lost. The most common mistakes it catches include sending timestamps in milliseconds instead of seconds (Meta expects 10-digit Unix timestamps, not 13-digit ones), sending raw unhashed email addresses and phone numbers instead of SHA-256 hashed versions, and omitting required fields like currency on purchase events. Each of these mistakes causes silent failures on both platforms, and this tool flags them with plain-English explanations and suggestions for how to fix each one. You can run it without installing anything, using npx directly against a JSON file or piping data from anywhere including curl output, log lines, or other tools. It can auto-detect which platform a payload is for, or you can specify Meta or TikTok explicitly. It also supports a machine-readable JSON output mode, which makes it suitable for use in automated CI pipelines. The exit code is non-zero when any check fails, which integrates cleanly with standard testing workflows. The tool has no external dependencies and is released under the MIT license, making it straightforward to add to any project or run on the fly during development. It can also be used as a JavaScript library directly in code if you want to validate payloads programmatically rather than from the command line. The README includes a full list of what is checked for both Meta and TikTok payloads.

Copy-paste prompts

Prompt 1
I'm setting up Meta Conversions API for a Shopify store and my Purchase events aren't matching in Events Manager. Run this payload through shopify-capi-validator and explain each error: [paste your JSON here]
Prompt 2
How do I add shopify-capi-validator to my GitHub Actions CI workflow so it fails the build when a CAPI payload is malformed?
Prompt 3
My TikTok Events API CompletePayment events show low match quality. What does shopify-capi-validator check for TikTok and which fields are most commonly wrong?
Prompt 4
Write a Node.js script that reads a Shopify webhook payload, validates it using shopify-capi-validator as a library, and logs each failure before forwarding to Meta CAPI.

Frequently asked questions

What is shopify-capi-validator?

A zero-dependency CLI that validates Meta Conversions API and TikTok Events API payloads for common formatting errors, like unhashed PII or wrong timestamp units, before you send them live and lose tracking data silently.

What language is shopify-capi-validator written in?

Mainly JavaScript. The stack also includes JavaScript, Node.js.

What license does shopify-capi-validator use?

Use freely for any purpose, including commercial use, as long as you keep the copyright notice.

How hard is shopify-capi-validator to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is shopify-capi-validator for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Scan in gitsafehub Deploy in gitdeployhub lsb11 on gitmyhub

Verify against the repo before relying on details.