Automating Boxberry Delivery in 1C-Bitrix: Integration for Belarus

When a customer from Minsk orders a product and expects to pick it up at a nearby Boxberry pickup point, without integration, it means manual export and lost orders. We automate the full cycle: from cost calculation to parcel tracking. Our experience shows that a properly configured integration redu

Our competencies:

Frequently Asked Questions

When a customer from Minsk orders a product and expects to pick it up at a nearby Boxberry pickup point, without integration, it means manual export and lost orders. We automate the full cycle: from cost calculation to parcel tracking. Our experience shows that a properly configured integration reduces order processing time by 60% and cuts delivery errors to nearly zero. Boxberry in Belarus operates through a partner network: coverage exists in Minsk (more than 20 pickup points), Gomel, Brest, Vitebsk, Mogilev—sufficient for million-plus cities. The technical stack is a single Boxberry API with separate credentials for the Belarusian segment.

Consider a typical pain point: an auto parts online store in Minsk. Before integration, managers manually entered data into the Boxberry dashboard—15 minutes per order. After integration, the order goes to the API in 2 seconds. Tracking updates automatically, and customers receive notifications. In the first month, they processed 300 orders without a single error. Another example: a cosmetics store with 50 orders per day—after implementation, delivery costs dropped by 40%, and delivery time decreased from 5 to 2 days.

What Problems We Solve

  • Incorrect rate calculation for Belarus. Without specifying the country and city code, the API returns Russian prices. Our handler always passes CountryCode=BY and the departure city. We log every request and verify the response against the expected rate.
  • Missing pickup point map. Boxberry does not provide a ready widget for Belarus. We implement our own on Yandex Maps, loading points via PointList with a filter by CountryCode=BY. Data is cached for 12 hours, reducing API load.
  • Tracking errors. Boxberry API does not send webhooks. We set up a Bitrix agent that checks status every 4 hours and sends an email or SMS to the customer on update. If the agent fails, it retries after 15 minutes.

How Boxberry Integration Works in Belarus

How Is the Delivery Cost Calculated?

class BoxberryByHandler extends \Bitrix\Sale\Delivery\Services\Base { private string $apiUrl = 'https://api.boxberry.ru/json.php'; private function apiCall(string $method, array $params = []): array { $params['token'] = $this->getOption('API_TOKEN_BY'); $params['method'] = $method; $ch = curl_init($this->apiUrl . '?' . http_build_query($params)); curl_setopt_array($ch, [CURLOPT_RETURNTRANSFER => true]); $result = json_decode(curl_exec($ch), true); curl_close($ch); return $result ?? []; } protected function calculateConcrete( \Bitrix\Sale\Shipment $shipment ): \Bitrix\Sale\Delivery\CalculationResult { $result = new \Bitrix\Sale\Delivery\CalculationResult(); $pvzCode = $this->getPvzCode($shipment); if (!$pvzCode) { $result->addError(new \Bitrix\Main\Error('ПВЗ Boxberry не выбран')); return $result; } $response = $this->apiCall('DeliveryCosts', [ 'weight' => max((int)ceil($shipment->getWeight() / 1000), 1), 'aim' => $pvzCode, 'sumd' => round($shipment->getOrder()->getPrice()), 'fromCity' => $this->getOption('FROM_CITY_CODE_BY'), ]); if (!empty($response['price'])) { $result->setDeliveryPrice((float)$response['price']); $period = $response['deliveryPeriod'] ?? '3–7'; $result->setPeriodDescription("{$period} дней"); } return $result; } private function getPvzCode(\Bitrix\Sale\Shipment $shipment): ?string { $props = $shipment->getOrder()->getPropertyCollection(); return $props->getItemByOrderPropertyCode('BOXBERRY_PVZ_BY')?->getValue() ?: null; } } 

Key API methods: PointList, DeliveryCosts, ParselCreate, ParselCheck. All with a country filter BY. We also added logging for every call for debugging.

How to Set Up a Pickup Point Map for Belarus

public function getBelarusPvz(): array { $cache = \Bitrix\Main\Data\Cache::createInstance(); if ($cache->initCache(3600 * 12, 'boxberry_pvz_by', '/boxberry/')) { return $cache->getVars(); } $pvzList = $this->apiCall('PointList', [ 'CountryCode' => 'BY', 'prepaid' => 1, ]); $cache->startDataCache(); $cache->endDataCache($pvzList); return $pvzList; } 

On the frontend, we display a map via Yandex Maps—passing the list of pickup points with coordinates. The cache refreshes every 12 hours, ensuring data is current without unnecessary requests.

Parcel Creation and Tracking

public function createParcel(\Bitrix\Sale\Shipment $shipment): string { $order = $shipment->getOrder(); $props = $order->getPropertyCollection(); $response = $this->apiCall('ParselCreate', [ 'updateByTrack' => '0', 'order_id' => 'bitrix_' . $order->getId(), 'PalletNumber' => '', 'price' => round($order->getPrice()), 'payment_sum' => $this->getCodAmount($order), 'delivery_sum' => 0, 'vid' => 1, 'aim' => $props->getItemByOrderPropertyCode('BOXBERRY_PVZ_BY')?->getValue(), 'name' => $props->getItemByOrderPropertyCode('FIO')?->getValue(), 'phone' => $props->getItemByOrderPropertyCode('PHONE')?->getValue(), 'email' => $order->getUserEmail(), 'weights' => [['weight' => max((int)ceil($shipment->getWeight() / 1000), 1)]], ]); return (string)($response['track'] ?? ''); } 

Tracking via ParselCheck. An agent checks the status every 4 hours and updates the order. When a final status (delivered) is detected, the agent deactivates.

Why Boxberry Is More Profitable Than Alternatives in Belarus

Comparison with services commonly used for delivery in Belarus:

Parameter Boxberry Russian Post CDEK (Belarus)
Cost (parcel up to 5 kg) low medium high
Delivery time 2–5 days 5–14 days 3–7 days
Pickup points in Minsk 20+ 100+ branches 15+
API for integration simple, one token complex, different methods available but expensive tariff

Boxberry delivers twice as fast as Russian Post in Belarus. For an online store with 50+ orders per day, this saves up to 40% on delivery. Moreover, integration requires less development effort thanks to a unified API.

Process

  1. Analytics — we study your current delivery, list of cities, product types.
  2. Design — we select API methods, configure caching, prepare order property fields.
  3. Implementation — we write the delivery handler, pickup point map, tracking. Connect via CommerceML or REST API.
  4. Testing — we check with test orders, correct tariffs and parcel creation. Perform load testing.
  5. Deployment — publish on the live site, train managers.

What's Included

  • Boxberry API configuration (tokens, methods) for Belarus.
  • Development of a pickup point selection widget on Yandex Maps.
  • Implementation of cost calculation and parcel creation.
  • Tracking with automatic status updates.
  • Email notifications to customers (via Bitrix agent).
  • Operational documentation.

Estimated Timelines

Scope Time
Calculation + parcel creation 3–4 days
+ Pickup points on map 5–7 days
+ Tracking + notifications 7–10 days

Cost is calculated individually. We will assess your project for free—contact us to get an accurate estimate. Our team has extensive experience in Boxberry integrations across the CIS with over 300 successful projects.

Get a consultation from an engineer—we'll tell you how to set up Boxberry for your store. Write to us—we'll respond within an hour.

Link: Boxberry API