Two-Way Product Catalog Synchronization with PIM System

Our company is engaged in the development, support and maintenance of sites of any complexity. From simple one-page sites to large-scale cluster systems built on micro services. Experience of developers is confirmed by certificates from vendors.
Development and maintenance of all types of websites:
Informational websites or web applications
Business card websites, landing pages, corporate websites, online catalogs, quizzes, promo websites, blogs, news resources, informational portals, forums, aggregators
E-commerce websites or web applications
Online stores, B2B portals, marketplaces, online exchanges, cashback websites, exchanges, dropshipping platforms, product parsers
Business process management web applications
CRM systems, ERP systems, corporate portals, production management systems, information parsers
Electronic service websites or web applications
Classified ads platforms, online schools, online cinemas, website builders, portals for electronic services, video hosting platforms, thematic portals

These are just some of the technical types of websites we work with, and each of them can have its own specific features and functionality, as well as be customized to meet the specific needs and goals of the client.

Our competencies:
Development stages
Latest works
  • image_website-b2b-advance_0.png
    B2B ADVANCE company website development
    1212
  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1161
  • image_websites_belfingroup_462_0.webp
    Website development for BELFINGROUP
    852
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1041
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    822
  • image_bitrix-bitrix-24-1c_fixper_448_0.png
    Website development for FIXPER company
    815

Implementing two-way catalog synchronization with a PIM system

PIM (Product Information Management) — centralized product data repository: Akeneo, Pimcore, Plytix, Syndigo. The main value of PIM is one source of truth for all sales channels: website, marketplaces, printed catalogs. Integrating a website with PIM means the website always displays current enriched data.

Integration architecture with Akeneo

Akeneo provides REST API version 1.0+:

GET  /api/rest/v1/products           — product list
GET  /api/rest/v1/products/{code}    — specific product
GET  /api/rest/v1/product-models     — models (for variant products)
GET  /api/rest/v1/categories         — category tree
GET  /api/rest/v1/attributes         — attribute schema
GET  /api/rest/v1/families           — product families

Authentication via OAuth2 with client credentials flow.

Paginated import

class AkeneoSyncService
{
    private AkeneoClient $client;

    public function syncProducts(): void
    {
        $cursor = null;

        do {
            $response = $this->client->getProducts([
                'limit'       => 100,
                'search'      => json_encode(['enabled' => [['operator' => '=', 'value' => true]]]),
                'search_after'=> $cursor,
            ]);

            foreach ($response['_embedded']['items'] as $item) {
                $this->upsertProduct($item);
            }

            $nextLink = $response['_links']['next']['href'] ?? null;
            $cursor   = $nextLink ? $this->extractCursor($nextLink) : null;

        } while ($cursor !== null);
    }

    private function upsertProduct(array $akeneoProduct): void
    {
        // Extract localized values
        $values = $akeneoProduct['values'];
        $name   = $this->getLocaleValue($values, 'name', 'ru_RU');
        $desc   = $this->getLocaleValue($values, 'description', 'ru_RU');
        $price  = $this->getScopedValue($values, 'price', 'ecommerce');

        Product::updateOrCreate(
            ['akeneo_code' => $akeneoProduct['identifier']],
            compact('name', 'desc', 'price') + [
                'family'      => $akeneoProduct['family'],
                'categories'  => $akeneoProduct['categories'],
                'raw_values'  => $values,   // JSONB — full PIM data
                'synced_at'   => now(),
            ]
        );
    }

    private function getLocaleValue(array $values, string $attr, string $locale): ?string
    {
        return collect($values[$attr] ?? [])
            ->firstWhere('locale', $locale)['data'] ?? null;
    }
}

Webhook from Akeneo (real-time changes)

Akeneo Enterprise supports event subscriptions:

// Handler for incoming events from Akeneo
Route::post('/webhooks/akeneo', function (Request $request) {
    $signature = $request->header('X-Akeneo-Request-Signature');

    if (!hash_equals(
        hash_hmac('sha256', $request->getContent(), config('akeneo.webhook_secret')),
        $signature
    )) {
        abort(401);
    }

    foreach ($request->json('events') as $event) {
        match($event['action']) {
            'product.created', 'product.updated' =>
                SyncAkeneoProduct::dispatch($event['resource']['identifier']),
            'product.removed' =>
                Product::where('akeneo_code', $event['resource']['identifier'])
                       ->update(['active' => false]),
        };
    }

    return response('ok');
});

Reverse synchronization: site → PIM

Data generated by the site with value for PIM: ratings, view counts, conversion data. Written via Akeneo API as custom attributes.

Timeline

Integration with Akeneo PIM (one-way): 6–10 days. Two-way with webhook support: 10–16 days.