Official comment
Our client Sunil Jaiswal found a way to modify the ONTRAPORT tracking script, available in Administration > Get Tracking Code, to work in Google Tag Manager (GTM). This allows GTM to insert the tracking script into any page you are already tracking with Google.
Use this script:
<script>
(function(o,n,t,r,a){
a=o.getElementsByTagName('head')[0];
r=o.createElement('script');r.async=1;
r.onload= function() {_mri=n;_mr_domain=t;mrtracking();};
r.src='https://optassets.ontraport.com/tracking.js'
a.appendChild(r);
})(document,'99999', 'XXXXXXX.ontraport.com' );
</script>
In the next to last line replace '99999' with your account ID number and 'XXXXXXX.ontraport.com' with your subdomain. You can find these in the tracking script located at Administration > Get Tracking Code; here's an example using my account with the account ID and subdomain in bold:
<script src='https://optassets.ontraport.com/tracking.js'
type='text/javascript' async='true' onload='_mri="83383",
_mr_domain="acumensales.ontraport.com",mrtracking();'></script>