google-analyticse-commercemeasurement-protocolenhanced-ecommerce

GA - Is it possible to update order in Google Analytics but keep original source?


I've a question that really needs your help since I'm not finding too much information in the internet. In a development we use Google Measurement Protocol API to confirm payments or refund orders in Google Analytics. But when we do that the order source in Analytics changes... so all of our orders now have the source "direct" but that isn't true since some come from "Google" or "Facebook".

Do you have any solution to this problem?

Thanks in advance.

Here goes and example of what I'm sending to Measurement Protocol API:

var propertiesObject = {
 v: '1',
 t: 'event',
 tid: googleAnalyticsTrackingId,
 cid: '123',
 ec: 'Ecommerce',
 ea: 'Purchase',
 ni: 1,
 ti: orderId,
 pa: 'purchase',
 tr: orderRevenue,
 ts: orderShippingCost, 
 tt: orderTaxCost, 
 cos: 8 
};

Solution

  • This is most likely because your GA Client ID (cid parameter) is not matching up to the original order, causing attribution problems. It's tricky because the only way to fix this would be to pass this parameter to your back-end and keep it on hand for incidences like this.

    Have you tried using the model comparison tool as well? M