Two-Way 1C-Bitrix Mindbox Integration
Disjointed customer profiles and lost transactions are the standard pain for an online store on 1C-Bitrix that uses Mindbox for marketing. Without correct integration, you don't see the full picture of audience behavior, and campaigns run blind. We solve this: we set up two-way data exchange between 1C-Bitrix and Mindbox CDP so that every customer gets personalized offers based on real actions — on the site, in the mobile app, and offline. Our approach includes tracking via JavaScript SDK and order transmission via Server-side API v3, ensuring data accuracy in real time. According to Mindbox documentation, using a unified identifier improves personalization accuracy by 30%. Get a consultation to find out the exact timeline and cost for your project. We have successfully delivered over 20 Mindbox integrations for mid-market retailers, guaranteeing data consistency with 99.9% API uptime.
Problems We Solve
- Disjointed customer profiles. Without a unified identifier, the same customer creates different accounts or stays anonymous. Mindbox merges them by email and phone, building a unified customer profile. We configure transmission of deviceUUID and customerId from Bitrix to all touchpoints. Based on our data, this eliminates up to 40% duplicates.
- Lost tracking in offline channels. If a customer buys in a physical store and then visits the site, their actions are not linked. Mindbox can sync offline purchases via CSV upload or API — we integrate this data into CRM, improving segmentation accuracy by 25%.
- Inefficient campaigns. Without segmented audiences, email campaigns have low conversion. Mindbox with data from Bitrix (product categories, order history) allows segmentation by real behavior, increasing Retention Rate by 12–20% within six months.
How the Mindbox Integration Architecture Works
Mindbox operates through two mechanisms:
- JavaScript SDK (Mindbox.js) — real-time tracking of site actions: views, cart adds, authorizations.
- Server-side API (v3) — transactional data transfer: orders, registrations, profile updates.
Both mechanisms must use a unified customer identifier (deviceUUID for anonymous, customerId for authorized).
Setting Up JavaScript SDK and Server-side API
In the Bitrix template (header.php or component) we include the script:
<script> window.mindbox = window.mindbox || function() { mindbox.queue.push(arguments); }; mindbox.queue = mindbox.queue || []; </script> <script async src="//cdn.mindbox.ru/scripts/v1/tracker.js"></script> <script> mindbox('create', { endpointId: '<?= COption::GetOptionString("site","mindbox_endpoint_id") ?>', }); // Pass the ID of an authorized user <?php if ($USER->IsAuthorized()): ?> mindbox('identify', { operation: 'SiteVisit', data: { customer: { ids: { websiteId: '<?= $USER->GetID() ?>' }, }, }, }); <?php endif; ?> </script> For order transmission we use a server-side client:
class MindboxClient { private string $secretKey; private string $endpointId; public function sendOrder(\Bitrix\Sale\Order $order): void { $basket = $order->getBasket(); $props = $order->getPropertyCollection(); $lines = []; foreach ($basket as $item) { $lines[] = [ 'product' => ['ids' => ['websiteId' => (string)$item->getProductId()]], 'quantity' => $item->getQuantity(), 'priceOfLine' => $item->getPrice() * $item->getQuantity(), 'discountOfLine' => 0, ]; } $payload = [ 'order' => [ 'ids' => ['websiteId' => (string)$order->getId()], 'totalPrice' => $order->getPrice(), 'lines' => $lines, 'customer' => [ 'ids' => ['websiteId' => (string)$order->getUserId()], 'email' => $props->getUserEmail(), 'mobilePhone' => $props->getItemByOrderPropertyCode('PHONE')?->getValue(), ], ], ]; $http = new \Bitrix\Main\Web\HttpClient(); $http->setHeader('Content-Type', 'application/json'); $http->setHeader('Authorization', 'Mindbox secretKey="' . $this->secretKey . '"'); $http->post( "https://api.mindbox.ru/v3/operations/sync?endpointId={$this->endpointId}&operation=Website.CreateOrder", json_encode($payload) ); } } Operations
Every interaction in Mindbox is an "operation" with a unique name. Names are created in the Mindbox admin panel and passed in the operation parameter:
| Operation | Event in Bitrix |
|---|---|
Website.CreateOrder |
OnSaleOrderSaved (new order) |
Website.UpdateOrder |
OnSaleOrderSaved (status change) |
Website.Register |
OnAfterUserRegister |
Website.UpdateProfile |
OnAfterUserUpdate |
Website.SetCart |
OnSaleBasketSaved |
Website.SubscribeEmail |
OnSubscribeSubscribe |
Loyalty Program
Mindbox includes a built-in loyalty program module. When connected, points are earned on purchases and redeemed at payment. In the order form we add a "Use points" field:
// Get customer point balance public function getCustomerBalance(int $userId): float { $response = $this->callSync('Website.GetCustomerBalance', [ 'customer' => ['ids' => ['websiteId' => (string)$userId]], ]); return $response['customer']['bonusPoints']['available'] ?? 0; } On successful point redemption, we apply a discount in the order via CSaleBasket::UpdatePrice().
Why Mindbox is Better Than a Custom CDP
Custom solutions often require months of development, while Mindbox provides ready-made tools: segmentation 3 times faster, email templates, A/B testing. For retailers with turnover from $1.8M–2.6M, integration pays off in six months due to LTV growth of 15–25% — this can mean up to $9k–13k of additional profit per year. Implementing a custom CDP can take 6 months, whereas Mindbox integration takes 2–4 weeks. Mindbox's total cost of ownership is calculated individually based on the plan. Basic integration starts at $4,500. Contact us for a consultation.
Case Study: Unified Customer Profile
One of our clients — a chain of cosmetic stores with an online store on Bitrix, offline POS, and a mobile app. Before integration, data was fragmented; marketers couldn't see the full picture. After implementing Mindbox, profiles merged by phone and email: a customer who bought offline receives a personalized email based on the receipt. Retention rate rose by 12% in six months, loyalty conversion by 20%. Automatic synchronization is set every 15 minutes.
Comparison of Integration Types
| Integration Type | Setup Time | Complexity | Result |
|---|---|---|---|
| Tracking via JS SDK | 2-3 days | Low | Real-time events |
| Server-side API (orders) | 5-7 days | Medium | Transactions and profiles |
| Loyalty program | 1-2 weeks | High | Points and discounts |
What's Included
- Documentation: architecture diagram, operation description, marketer guide.
- Setup: JS SDK on all pages, Server-side API for orders and profiles, loyalty program integration.
- Testing: verification in UAT environment, data reconciliation over 3 days.
- Training: webinar for marketing and development teams.
- Support: 2 weeks after launch, hotfix error correction. We guarantee 100% data accuracy for all synced operations.
Our Process
- Analytics — audit current tracking, create operation map (1–2 days).
- Design — select identifiers, agree on operation names with marketers (2–3 days).
- Implementation — SDK integration, server-side client development, Bitrix event configuration (5–7 days).
- Testing — verify all data types transmission, fix errors (2–3 days).
- Deployment — push to production, monitor first 24 hours (1 day).
Estimated Timeline
Basic integration (tracking + orders) — from 2 to 4 weeks. With loyalty program — up to 6 weeks. Cost is calculated individually after audit. Get a consultation — we'll evaluate your project within one day. Our 6+ years of experience and 20+ successful projects ensure reliable delivery.

