Skip to content

Instantly share code, notes, and snippets.

@sahava
sahava / outgoing-ip-address-logger.tpl
Last active November 20, 2023 12:40
Custom server-side Google Tag Manager client template for logging the IP address of outgoing requests
___INFO___
{
"type": "CLIENT",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Log outgoing request IP address",
"brand": {
"id": "brand_dummy",
@sahava
sahava / Amplitude Analytics.tpl
Created October 6, 2021 10:32
Server-side GTM tag template for Amplitude Analytics
___INFO___
{
"type": "TAG",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Amplitude Analytics",
"brand": {
"id": "brand_dummy",
@sahava
sahava / template.tpl
Created September 27, 2021 06:50
A server-side Google Tag Manager client template for detecting ad blockers
___INFO___
{
"type": "CLIENT",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Detect Ad Blockers",
"brand": {
"id": "brand_dummy",
@sahava
sahava / Dockerrun.aws.json
Created June 2, 2021 06:55
Sampe Dockerrun.aws.json for running a GTM tagging server in AWS Elastic Beanstalk
{
"AWSEBDockerrunVersion": "1",
"Image": {
"Name": "gcr.io/cloud-tagging-10302018/gtm-cloud-image:stable",
"Update": "true"
},
"Ports": [
{
"ContainerPort": 8080
}
@sahava
sahava / template.tpl
Created May 6, 2021 18:08
Simmer Client - Custom Client Template for Google Tag Manager Server containers. This is a "minimum viable Client" template, designed as an example for the Simmer course on server-side tagging.
___INFO___
{
"type": "CLIENT",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Simmer Client",
"brand": {
"id": "brand_dummy",
@sahava
sahava / template.tpl
Created March 4, 2021 08:56
Event Data To BigQuery - DEMO of the BigQuery API
___INFO___
{
"type": "TAG",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Event data to BigQuery",
"brand": {
"id": "brand_dummy",
@sahava
sahava / gtmContainerPolicy.js
Created February 20, 2021 21:23
Sample Server container policy file
gtag('policy', 'all', function(container, policy, data) {
switch (policy) {
// Only allow _ga cookie to be set.
case 'set_cookies':
return data.name === '_ga';
// All other permission requests are allowed.
case 'access_response':
case 'access_template_storage':
@sahava
sahava / template.tpl
Last active April 13, 2021 06:42
Facebook (updated) - Custom Template demo
___INFO___
{
"type": "TAG",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Facebook",
"brand": {
"id": "brand_dummy",
@sahava
sahava / template.tpl
Last active April 13, 2021 06:42
Facebook - Custom Template demo
___INFO___
{
"type": "TAG",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Facebook",
"brand": {
"id": "brand_dummy",
@sahava
sahava / template.tpl
Last active February 16, 2021 07:08
Advanced Universal Analytics (updated) - Custom Template demo
___INFO___
{
"type": "CLIENT",
"id": "cvt_temp_public_id",
"__wm": "VGVtcGxhdGUtQXV0aG9yX0FkdmFuY2VkVW5pdmVyc2FsQW5hbHl0aWNzLVNpbW8tQWhhdmE\u003d",
"categories": [
"ANALYTICS"
],
"version": 1,