Zudy Vinyl

Zudy Vinyl アプリケーション

アプリケーションのインストルメンテーションを開始する前に、アプリを作成し、appKey を取得していることを確認してください。

インストール

Vinyl への Pyze Analytics のインストールは簡単で、Vinyl IDE で Pyze の JavaScript をサイトウィジェットとして追加するだけです。

新しいサイトウィジェットを作成し、以下のスクリプトを図のように binder.js 内に貼り付けます。

define(function () {
    const install = function (context) {

    var pyzeAppKey= context.getParameter('AppKey');
    !function(e,t){var s=e.Pyze||{_q:[]},i=e.PyzeEvents||{_q:[]},n=e.PyzeCuratedEvents||{_q:[]},r=e.PyzeIdentity||{_q:[]};function p(t,e){function s(e){t[e]=function(){t._q.push([e].concat(Array.prototype.slice.call(arguments,0)))}}for(var i=0;i<e.length;i++)s(e[i])}p(s,["initialize","getTimerReference","getAppInstanceId","postWebAppVersion","postPageView","setUserOptOut","deleteUser"]),p(i,["postCustomEvent","startTimerForEvent","postCustomEventWithAttributes","postTimedEvent","postTimedEventWithAttributes","postExplicitActivation"]),p(n,["post"]),p(r,["setUserProfile","resetUserProfile","updateUserProfile"]);var o=t.createElement("script"),a=t.getElementsByTagName("script")[0];o.type="text/javascript",o.async=!0,o.src="https://cdn.pyze.com/pyze.js",a.parentNode.insertBefore(o,a),e.Pyze=s,e.PyzeEvents=i,e.PyzeCuratedEvents=n,e.PyzeIdentity=r}(window,document),Pyze.initialize(pyzeAppKey);
        console.log(pyzeAppKey);
    }
    return {
        callbacks: {
            install: install
        }
    };
});

初期化

Pyze SDK を初期化するには、作成したサイトウィジェットを Control Panel(コントロールパネル)から環境に追加します。

これで、Pyze SDK が多くの自動メトリクスの収集を開始します。

API リファレンス

完全な API リファレンスはこちらをご覧ください。