diff --git a/Model/ServerTracker/GtmTracker.php b/Model/ServerTracker/GtmTracker.php
index c7d01a7..cd9001e 100644
--- a/Model/ServerTracker/GtmTracker.php
+++ b/Model/ServerTracker/GtmTracker.php
@@ -290,30 +290,30 @@ class GtmTracker implements TrackerInterface
         }
 
         foreach ([
-            'dl',
-            'dt',
-            'uafvl',
-            'ul',
-            'sr',
-            'is_virtual',
-            'shipping_description',
-            'customer_is_guest',
-            'customer_identifier',
-            'customerGroup',
-            'ecomm_pagetype',
-            'dr',
-            'customer_city',
-            'customer_country_id',
-            'customer_dob',
-            'customer_email',
-            'customer_firstname',
-            'customer_lastname',
-            'customer_gender',
-            'customer_postcode',
-            'customer_region',
-            'customer_telephone',
-            '_et'
-            ] as $param) {
+                     'dl',
+                     'dt',
+                     'uafvl',
+                     'ul',
+                     'sr',
+                     'is_virtual',
+                     'shipping_description',
+                     'customer_is_guest',
+                     'customer_identifier',
+                     'customerGroup',
+                     'ecomm_pagetype',
+                     'dr',
+                     'customer_city',
+                     'customer_country_id',
+                     'customer_dob',
+                     'customer_email',
+                     'customer_firstname',
+                     'customer_lastname',
+                     'customer_gender',
+                     'customer_postcode',
+                     'customer_region',
+                     'customer_telephone',
+                     '_et'
+                 ] as $param) {
             if (isset($item[$param])) {
                 $preparedData[$param] = $item[$param];
             }
@@ -343,8 +343,10 @@ class GtmTracker implements TrackerInterface
                     $preparedData['epn.' . $epKey] = $epItem;
                 } elseif (is_array($epItem)) {
                     foreach ($epItem as $epItemData) {
-                        $preparedData['pr' . $prC] = $this->mapKeysToRight(http_build_query($epItemData));
-                        $prC++;
+                        if (is_array($epItemData)) {
+                            $preparedData['pr' . $prC] = $this->mapKeysToRight($epItemData);
+                            $prC++;
+                        }
                     }
                 }
             }
@@ -356,6 +358,7 @@ class GtmTracker implements TrackerInterface
             }
         }
 
+
         return $preparedData;
     }
 
@@ -400,28 +403,38 @@ class GtmTracker implements TrackerInterface
     }
 
     /**
-     * @param string $str
+     * @param array $item
      * @return string
      */
-    private function mapKeysToRight(string $str): string
+    private function mapKeysToRight(array $item): string
     {
-        $map = [
-            'item_id' => 'id',
-            '&' => '~',
-            'item_name' => 'nm',
-            'price' => 'pr',
-            '=' => '',
-            'item_brand' => 'br',
-            'discount' => 'ds',
-            'quantity' => 'qt',
-            'coupon_code' => 'k0coupon_code~v0'
+        $keyMap = [
+            'item_id'        => 'id',
+            'item_name'      => 'nm',
+            'price'          => 'pr',
+            'item_brand'     => 'br',
+            'discount'       => 'ds',
+            'quantity'       => 'qt',
+            'item_variant'   => 'va',
+            'item_category'  => 'ca',
+            'item_category2' => 'c2',
+            'item_category3' => 'c3',
+            'item_category4' => 'c4',
+            'item_category5' => 'c5',
+            'item_list_id'   => 'li',
+            'item_list_name' => 'ln',
+            'index'          => 'ps',
+            'affiliation'    => 'af',
+            'coupon'         => 'k0',
         ];
 
-        foreach ($map as $wrong => $right) {
-            $str = str_replace($wrong, $right, $str);
+        $parts = [];
+        foreach ($item as $key => $value) {
+            $shortKey = $keyMap[$key] ?? $key;
+            $parts[] = $shortKey . $value;
         }
 
-        return $str;
+        return implode('~', $parts);
     }
 
     /**
