Creating custom dimension of logged in users at e-commerce site?

Have the following issue: I manage a magento 2 store, and I need to get segmented data on our logged-in e-commerce users based on their custom varible “customer group” - is this possible to set up in Piwik? (in eg targeting variable in datalayer)

Hi. You can read the value from dataLayer and store it as session-level custom dimension. More on it here: Create a custom dimension | Piwik PRO help center