ChatGPT Ads Pixel + CAPI Complete Setup
Combine the OpenAI Ads Measurement Pixel and Conversions API with event mapping, oppref capture, deduplication, testing, and implementation documentation.
Build one conversion measurement system across the browser and your server
A combined ChatGPT Ads Pixel and Conversions API setup pairs browser-side interaction tracking with direct server-to-server delivery. The browser pixel monitors visitor actions in real time and handles initial cookie state. Meanwhile, the Conversions API transmits verified transactions from your backend database, billing processor, or CRM.
Running both tools effectively requires shared architecture. Event names, currency amounts, timestamps, user tokens, and deduplication IDs must match across both pipelines so OpenAI records accurate conversions without double-counting.
Comercio Services plans and implements this dual-telemetry architecture for fast-growing ecommerce brands and SaaS platforms. We build around your specific customer journey, avoiding generic container templates. This is our most requested technical engagement: $1,600 flat, delivered in 5 to 7 business days.
Request a Complete Tracking Plan | Book a Measurement Architecture Call
A complete tracking implementation uses the browser pixel for client interactions and the Conversions API for backend transactions. When an order fires through both channels, assigning matching event IDs, identical Pixel IDs, and consistent event types allows OpenAI to deduplicate the signals into a single attributed conversion.
Why combine the Pixel and Conversions API?
The pixel and the API address different vulnerabilities in modern measurement.
The browser pixel excels at capturing early user intent. It runs client-side from bzrcdn.openai.com/sdk/oaiq.min.js, tracking landing views, product evaluations, cart updates, and initial checkout steps. It also automatically intercepts the oppref ad click reference from the URL and writes it to a first-party cookie.
The Conversions API operates where browser scripts cannot reach. It fires directly from your server to https://bzr.openai.com/v1/events, triggered by database records, webhook notifications, or payment gateway receipts.
Deploying both channels together provides clear technical advantages:
- Browser tags capture real-time navigation and visitor context.
- Server requests guarantee that paid orders and contract signups reach Ads Manager even when ad blockers intercept browser tags.
- Automatic browser cookie handling captures the
opprefclick token, which your backend then associates with the customer profile for later CAPI delivery. - Shared transaction IDs let OpenAI reconcile dual events into a single verified conversion.
- Your engineering and marketing teams gain a single, documented taxonomy covering the entire funnel.
A dual setup will not guarantee attribution on every single impression, but it creates the most resilient tracking pipe currently supported by OpenAI Ads.
What this complete service includes
1. Conversion measurement audit
We begin with an engineering audit of your advertising objectives and technical infrastructure:
- Target campaign objectives and conversion definitions in Ads Manager
- Current web framework, Single Page Application routing, and template architecture
- Web container tags in Google Tag Manager or native theme scripts
- Backend order pipelines, billing gateways like Stripe, and CRM databases like HubSpot
- Content Security Policy headers (allowing
bzrcdn.openai.comunderscript-srcandbzr.openai.comunderconnect-srcandimg-src) - Active consent banners and cookie classification rules
- Historical attribution leaks and discrepancies between bank ledgers and ad dashboards
This audit identifies exactly which events should fire from the browser, which belong on the server, and which require synchronized dual delivery.
2. Event taxonomy and measurement architecture
We build a complete event matrix across your funnel stages.
Top-of-funnel discovery runs exclusively through the browser pixel, firing page_viewed on content pages and contents_viewed on item detail views. Mid-funnel interest triggers items_added when shoppers click add to cart, followed by checkout_started as they reach payment steps.
High-value conversion events use synchronized dual delivery. Completed ecommerce purchases fire an immediate browser order_created event on confirmation pages, paired with an authenticated server-side order_created webhook dispatched the moment payment settles. Lead submissions, appointment bookings, and account registrations follow the same dual pattern, sending lead_created, appointment_scheduled, or registration_completed from both frontend forms and backend API handlers. Pure subscription billings like trial_started and subscription_created dispatch from your billing engine.
3. Browser Pixel implementation
We configure the official JavaScript library using your team's preferred deployment workflow:
- Google Tag Manager web containers with strict trigger sequencing
- Direct integration in Shopify theme code or WordPress templates
- Platform scripts in Webflow, Framer, or custom Next.js frontends
- Consent-mode integration respecting user opt-in selections
We test base script initialization, verify event payload formatting, and check browser developer tools to ensure tags never duplicate on page reloads.
4. Conversions API integration
We develop the server-side pipeline to post verified events directly to OpenAI's endpoint at https://bzr.openai.com/v1/events?pid=PIXEL-ID.
Our backend work includes:
- Setting up secure Bearer token authentication via environment variables
- Creating webhook listeners that process incoming order or lead events
- Formatting transaction values into minor currency units (such as
12999for USD 129.99) - Normalizing and SHA-256 hashing customer emails and customer IDs
- Structuring batch requests up to 1,000 events with payload isolation
- Implementing structured error logging and automatic retry routines with exponential backoff
5. Click reference capture and persistence
Attributing a server event back to a ChatGPT conversation requires passing the oppref click token.
We engineer a reliable persistence loop across your user journey:
- The visitor arrives from an ad with an
opprefparameter in their query string. - Our script reads the parameter and writes it to a first-party cookie or session storage.
- As the user moves through your store, the token attaches to their cart attributes, form session, or draft order.
- When payment clears, your backend server extracts the saved token and includes it in the CAPI payload.
This bridges the gap between client browsing and backend order execution.
6. Event deduplication logic
Deduplication prevents your ad account from recording two conversions when an order fires from both the browser and the server.
We enforce OpenAI's deduplication rules across your entire stack:
- The browser
oaiq("measure", ...)call passes a uniqueevent_idin its options argument. - The server CAPI payload uses the exact same string inside its top-level
idfield. - Both signals target the exact same Pixel ID.
- Both signals transmit the identical event taxonomy name.
- Both signals dispatch within OpenAI's 48-hour deduplication processing window.
When these parameters match, OpenAI records a single conversion and merges the attribution metadata.
7. User data normalization and security
Passing customer parameters improves match rates across devices when supported by proper user consent.
We build automated transformation pipelines that convert customer email strings to lowercase, strip trailing whitespace, and generate standard SHA-256 hex digests. We also format postal codes, cities, and country codes according to ISO standards. Plaintext customer identifiers and raw phone numbers are strictly barred from your payloads.
Your compliance counsel remains responsible for ensuring tracking disclosures satisfy regional legal requirements.
8. End-to-end sandbox verification
Before going live, we run structured test scenarios across both environments:
- Test purchases in staging with
validate_only: trueon CAPI payloads - Live browser console checks verifying clean
oaiqexecution without syntax warnings - Network tab inspections confirming HTTP 202 responses from
bzr.openai.com - Synthetic ad click simulations passing dummy
opprefvalues through to server logs - Intentional duplicate payload tests confirming Ads Manager merges matching event IDs
- Error recovery tests verifying that webhook retries handle temporary network dropouts
9. Ads Manager alignment and campaign binding
We ensure your ad account correctly digests incoming data. We confirm that your campaign goals bind to the appropriate verified conversion, that custom conversions match payload labels exactly, and that the event stream reflects both browser and server origins.
10. Complete documentation and technical handover
You receive an exhaustive documentation packet detailing:
- High-level architecture and data flow diagrams
- Complete event parameter dictionary
- Secret storage details and API key rotation procedures
- Repository commits, GTM container exports, and cloud function source code
- Operational troubleshooting runbook for engineering staff
Who should choose the complete setup?
This comprehensive service is built for:
- Ecommerce stores spending over $5,000 monthly on paid advertising
- High-growth Shopify, WooCommerce, or Magento merchants
- Headless commerce setups and custom application frontends
- Companies suffering from high ad-blocker rates or attribution loss
- Teams wanting a single, verified implementation completed by specialists
Implementation timeline
Our engagement follows a clear 6-stage roadmap completed within 5 to 7 business days:
First, we conduct discovery and gain access via team invitations. Next, we deliver the comprehensive event architecture specification for your review. In stage three, we deploy the browser pixel tags and GTM configurations. In stage four, we build and test the server-side API integration. Stage five covers end-to-end sandbox testing and Ads Manager verification. Finally, in stage six, we conduct a live handover walkthrough and begin your 14-day warranty support period.
Supported technical platforms
We routinely deploy dual-telemetry pipelines across:
- Shopify and Shopify Plus storefronts
- WooCommerce and custom WordPress setups
- Magento, BigCommerce, and custom ecommerce backends
- Modern frontend stacks including Next.js, React, Vue, and Astro
- Server-side infrastructure on AWS Lambda, Cloudflare Workers, Google Cloud, and Vercel
- Lead generation platforms like HubSpot, Webflow, and custom REST APIs
Deliverables summary
Your completed project includes:
- Production-ready browser pixel tags deployed in your CMS or GTM container
- Production-ready server-to-server CAPI pipeline with automated retry handling
- End-to-end
opprefclick token persistence mechanism - Clean deduplication wiring using shared unique transaction IDs
- SHA-256 customer data normalization functions
- Complete architecture documentation and event dictionary
- 14 days of direct technical warranty support
Pricing and investment
We work exclusively on transparent, fixed-scope pricing.
Our flagship ChatGPT Ads Pixel + CAPI Complete Setup is $1,600 flat with a 5 to 7 business day delivery turnaround. It covers the complete audit, browser pixel installation, backend API integration, token persistence, deduplication wiring, sandbox testing, and documentation. If your business only requires client-side tracking, our Pixel-only package runs $650 flat. If you already have tracking installed but suspect data discrepancies, our diagnostic Tracking Audit costs $450 with a 48-hour turnaround, and we credit that full $450 toward the complete setup if booked within 30 days.
For brands requiring ongoing operational maintenance, we offer monthly retainers. Our Tracking Care plan is $350 a month for routine endpoint monitoring, cookie freshness checks, and minor tag adjustments. Our Growth Partner plan is $950 a month, which includes monthly attribution audits, new event endpoint builds, and direct Slack support during active campaign scaling.
All figures are in USD. Book a discovery call to review your funnel before starting.
Frequently asked questions
Why do we need both the pixel and CAPI?
Browser pixels miss transactions when ad blockers, private browsing windows, or network interruptions occur. The Conversions API catches every sale directly from your server, but lacks early browser context like product views and cannot read the landing URL directly. Using both gives you complete funnel visibility with zero dropped orders.
How does deduplication prevent double-counting?
OpenAI uses the combination of event ID and event name to identify duplicate signals. When the browser sends an order_created event with ID 1001 and your server sends a CAPI event with ID 1001, OpenAI merges them into a single conversion record.
What happens if the oppref token is missing?
If a visitor converts without an oppref token (for example, if they clicked an ad weeks earlier or cleared cookies), OpenAI falls back to matching hashed customer parameters like email or IP address. Capturing oppref whenever available delivers the highest attribution accuracy.
Can this setup work on Shopify without custom apps?
Yes. We can implement standard tracking using Shopify's native Customer Events pixel sandbox paired with server webhooks. For standard stores, our free Shopify app also handles core pixel and CAPI wiring automatically.
How do you handle Content Security Policy restrictions?
We review your web server headers and provide exact directives for your engineering team. Your CSP policy must allow script execution from bzrcdn.openai.com and data transmission to bzr.openai.com.
Do you need direct access to our production server?
Not necessarily. We can provide pull requests, serverless function code, or Server-Side Google Tag Manager containers that your engineering team reviews and merges according to your internal security protocols.
Are you an official OpenAI partner?
No. Comercio Services is an independent technical consultancy. OpenAI and ChatGPT are registered trademarks of their respective owners.
Free tools
We maintain two free utilities to help store owners validate their tracking:
- Pixel OpenAI Ads & ChatGPT Ads: A free Shopify app that manages pixel and CAPI tracking directly on your storefront.
- OpenAI Ads Pixel Helper: A Chrome extension for inspecting live tracking events in your browser.
Request a complete tracking plan
Stop losing conversion attribution to browser restrictions. Tell us about your website, backend systems, and monthly ad budget. We will design a unified tracking architecture tailored to your business.
Request a Complete Tracking Plan | Email: servicescomercio@gmail.com | Take the Free Audit
Technical references
- OpenAI Ads Measurement Pixel guide: https://developers.openai.com/ads/measurement-pixel
- OpenAI Conversions API guide: https://developers.openai.com/ads/conversions-api
- Supported standard events: https://developers.openai.com/ads/supported-events
- Conversions reporting and attribution: https://help.openai.com/en/articles/20001214-measure-results
Good questions.
Straight answers.
Everything else you may want to know before getting started.
What are the OpenAI Ads Pixel and Conversions API?
The Measurement Pixel is a browser JavaScript SDK that records website events after someone clicks an ad in ChatGPT. The Conversions API (CAPI) is its server-side counterpart: your backend posts events directly to OpenAI, which makes measurement resilient to ad blockers and browser restrictions. Used together with a shared event ID, they give you deduplicated, more complete conversion data.
Why should I track ChatGPT Ads conversions server-side?
Browser-only tracking loses events to ad blockers, tracking prevention (ITP/ETP), consent declines, and multi-session journeys. Server-side CAPI events survive all four. OpenAI recommends using the Conversions API where possible; the pixel + CAPI pair with event deduplication is the reliable default.
Is customer data protected? How are emails and identifiers handled?
Personal identifiers are normalized and hashed with SHA-256 before transmission, following OpenAI documented user-data guidance. Server events carry only what attribution requires, and consent settings are strictly respected.
How long does a professional tracking setup take?
Readiness audits are delivered in 48 hours. Professional implementations are delivered as fixed-scope engagements within 5 to 7 business days, including full documentation and QA evidence.