'How to get demographics from Google Analytics Universal via Server Side Tracking

A few months ago we switched from JavaScript to Server Side Tracking (SST), using the following information and code:

The issue at hand is How do we get demographics data in Google Analytics (Universal) when using Server Side Tracking. The current setup is to get the _ga cookie from GTAG without sending a pageview - and then use that Cookie as Client-ID.

I found the following page about where Demographic data comes from; but can't figure out what i am Missing or need to get the data into GA.

I hope that you can offer som insight or a potential solution.

Edit: The current setup initializes the _ga/_gid cookie with GTAG without triggering a pageview, and then use _ga > _gid > phpsessid as the Client-ID in the SST calls



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source