Aller au contenu principal

trackExperiencePageview usage

Commentaires

4 commentaires

  • Mary Hauber

    Hi Bryce, 

    Thanks for sharing your questions with the Showpad Community! 

    One of our Technical Solution Architects has shared some insights on your questions:

    Q: Should the id passed to trackExperiencePageview be unique for each button (it currently is), or is it supposed to be a single value for the entire application? Can it be any string I want, or is it supposed to be a specific id generated from a showpad API endpoint somewhere? That is, could my id be "This is my id" or does it need to be some form of specific Guid value or other hex value?

    • A: The definition of every field can be found on the Typescript type which can be found in the IDE or here https://docs.api.showpad.com/docs/apps/references/sdk/typedoc#/typedoc/interfaces/Showpad.PageViewTouchpoint.html
    • This is the id of the touchpoint. Every touchpoint should have a unique id. If it's a button it could be "button-005" or "my-shiny-purple-submitbutton"  or so. There are no hard requirements on uniqueness, but when you do reporting you will want to be able to know how often a certain button has been clicked, so if clicks on any button results in a touch event with the same id, it will not be possible to know how many clicks a specific button had.

    Q: Same question for sourceId and destinationId. Can those be any string value I want to send, or are those supposed to be generated by showpad in some fashion and I need to pass the generated values in?

    • A: Same answer here. You can use any string you want, but if you want to know how often a redirect from a certain page to another, it is in your interest to define a unique sourceId and destinationId for every page in play

    Q: Currently none of my analytics are showing up when I make calls to the https://mentor.showpad.biz/api/v3/exports/events.json endpoint

    • A: This is strange. Normally, every time trackEvent or the more specialized trackExperienceEvent and trackExperiencePageview are called a new event of the type experience-tracked-event should be created in the events table.
    • Is this called from an Experience app or a HTML Asset? Tracking events from an HTML Asset is impossible at this moment. If it's an Experience app, we can convert this into a support ticket so they can further investigate why this wouldn't be working. 

    Hope this provides some clarity for you!

    Best,
    Mary 

    0
  • Bryce Bangerter

    It does, thank you.

    I have not created a manifest.json or config.json file for my app yet, so looking back through the docs I'm guessing that is what I am missing to make it an experience app (as opposted to an HTML asset). I'm going to work on setting that up and re-test.

    0
  • Bryce Bangerter

    Well I am still stumped by this. After a day+ of working on this I am still not able to get page views showing up in the events exports.

    When running my app in the web version of showpad (without a manfiest.json or config.json file) I can see the following:

    calling 
    const { fullName } = await Showpad.getUserInfo();
    console.log(fullName);

    displays my showpad username.

    and calls to Showpad.trackExperiencePageview log a message to the console, but my page views do not show up in the events exports. (This was my original scenario).

     

    I added a manifest.json and config.json to the root of my zip file as follows:

    manifest.json
    {
      "$schema": "https://schema.showpad.com/app/manifest.v2.json",
      "schema": {
        "type": "app-manifest",
        "version": 2
      },
      "appKey": "com.showpad.app.test-app",
      "name": "Test App",
      "version": "1.0.0",
      "description": {
        "short": "Test App",
        "full": "Test App"
      },
      "images": [ "assets/images/cover.jpg" ],
      "developer": {
        "name": "Sector 5 Digital",
        "websiteUrl": "https://sector5digital.com"
      },
      "sharedStores": [ { "id": "s5d-test-app" } ]
    }

    and config.json

    {
      "version": 1,
      "labels": {
        "title": {
          "value": "Test App",
          "description": "Test App",
          "limit": 50
      },
      "contents": {}
    }

     

    With these two files added my call to await Showpad.onShowpadLibLoaded(); never returns. It also does not log any messages to the console.

    0
  • Mary Hauber

    Hi Bryce, 

    I've converted this to a ticket for our support team, who are better equipped to help you if things aren't working as they should be! 

    Best,

    Mary 

    0

Vous devez vous connecter pour laisser un commentaire.

Obtenez les dernières applications et intégrations de messagerie

iOS App Store Google Play Store Microsoft Store