Google跟踪代码管理器-从Rest API触发事件 [英] Google Tag Manager - firing events from rest api

查看:101
本文介绍了Google跟踪代码管理器-从Rest API触发事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的某些事件已从前端针对Google Analytics(分析)和Facebook Pixel触发,并且已通过GTM正确捕获.

但是现在我有一项功能,该功能可以从cron完成并从后端提供.捕获事件时,我需要同时在Google Analytics(分析)和Facebook Pixel中捕获事件.

我们需要触发https(基于休息)的调用来捕获它.

在此方面如何提供帮助.

解决方案

GTM没有服务器端API来触发跟踪调用(GTM API用于管理将包装到Javascript函数中的标签.没有跟踪后端可以做反对).

您需要通过测量协议将呼叫直接发送到 GA.

或分别通过离线转化 Facebook . /p>

Some of my events are getting fired from frontend for both google analytics and facebook pixel and they are getting captured properly through GTM.

but now i have a functionality which is getting done from cron and is served from backend. I need to capture a event in both google analytics and facebook pixel when this is getting captured.

We need to fire the https (rest based) calls for capturing this.

Kindly help on this how this can be achieved.

解决方案

GTM has no serverside API to trigger tracking calls (the GTM API is for managing tags that will be wrapped into a Javascript function. There is no tracking backend to do calls against).

You need to send your calls directly to GA via the measurement protocol or respectively to Facebook via offline conversions.

这篇关于Google跟踪代码管理器-从Rest API触发事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆