• Home

    Sending custom analytics from your content

    Written by Harry Phillips

    Updated at September 6th, 2024

    • Pugpig Bolt

      • Pugpig Site

        • Pugpig Archive

          • Working with Pugpig

            • Pugpig Consulting

              Table of Contents

              Using the analytics bridge service

              Pugpig Bolt features robust tracking capabilities out-of-the-box, these have been designed to help you easily understand the usage of your app. This includes popular content, commercial performance and a broad range of engagement metrics. Our analytics spec details this.

              However, if your content or timeline cards feature custom functionality that isn't already captured by our existing events we may need to implement custom event tracking specific to that functionality. 

              Pugpig Bolt includes an analytics bridge service that allows the webviews shown in your tabs or content to pass information to the analytics SDKs included in the app. These events are then tracked alongside the productised events described above. 

              As these events are custom you're free to define the naming of these events and circumstances under which they'd fire. 

              Using the analytics bridge service

              If these events are being fired from a webview that you're building yourself, you'll need to write to the aforementioned bridge call we've provided a code sample below to detail how it can be invoked.

              const payload = JSON.stringify({ category: '/ArticleView', name: 'EventName', param: 'EventParam' }) parent.pugpigBridgeService.trackAnalyticsEvent(payload)

              You're free the match the event category to existing categories in our spec, which usually map to the screen type they occur on (e.g ArticleView) or the functionality they affect (e.g Audio). This is tracked as a dimension on the event.

              EventName is what the event will appear as in the analytics tool(s) it's being sent to

              EventParam is usually used to track the specific value of the event, examples of this can be seen in our analyics spec linked above.

              Was this article helpful?

              Yes
              No
              Give feedback about this article

              Related Articles

              • Setting up Google Analytics 4
              pugpig logo white
              Navigation
              • Products
              • Customers
              • News
              • Podcast
              Contact
              • Contact us
              • LinkedIn
              • Twitter
              Technical Support
              • Status Page
              • Documentation
              • Customer Support
              Corporate
              • Company
              • Jobs
              • Privacy Policy

              © Kaldor Ltd. 2022

              Powered by Pugpig


              Knowledge Base Software powered by Helpjuice

              Expand