Forum Discussion

Inactive User's avatar
Inactive User
12 years ago

REST API vs Admin Metrics discrepancy

Hi,

 

We were trying to use REST API for retrieving metrics rather than using Advanced Metrics because it's too troublesome when it involves multiple forum boards metrics.

However, we notice the metrics were different when generated via REST API and Advanced Metrics. Did we miss anything?

 

For example, we were retrieving net forum topics from 1 - 28 Feb 2013 with this request URL.

http://xxxx.xxx.com/restapi/vc/metrics/name/net_threads?date_start=2013-02-01&date_end=2013-02-28

 

The response we got was for example 3344.

 

However, with the same criteria the result we got from Advanced Metrics showed 3355. We tried a few metrics such as number of solutions, pageviews,etc and we notice the same discrepancy issue.

 

Pointers?

  • JakeR's avatar
    JakeR
    Khoros Oracle

    I would hazard a guess that it is a difference in time settings between the account pulling the metrics and the default time settings for your community. 

     

    If you are making server-side calls, you may want to check the time on your machine making the calls.  If you are making client-side calls, check your time settings on your machine (or your team member's machine).

     

    You can refer to this thread for more info (it may be helpful): http://lithosphere.lithium.com/t5/developers-discussion/Difference-in-Metrics/m-p/43936/highlight/true#M1226

     

    You can also refer to a section within this TKB article that says the following: http://lithosphere.lithium.com/t5/support-knowledge-base/Using-Lithium-Metrics/ta-p/39756

     

    The metrics panel mentions that the data is based off of my profile time zone. What does this mean? - This means that the data you see will reflect what you have set in your profile. In other words, if your profile is set to use the Pacific time zone (GMT-8) then you will see different information than someone who is using the Eastern time zone (GMT-5). If you both ran a report for 3/01/2012 you may see different data. For the Eastern time user, they would see data from 12 am Eastern to 12 am Eastern, which is 9 pm to 9 pm in the Pacific time zone, while the Pacific user would see 12 am Pacific to 12 am Pacific, which is 3 am to 3 am Eastern. As you can imagine, this would lead to some discrepancies. Fortunately, you can easily update your profile to match others if needed by navigating to My Settings -> Preferences -> Preferences Options -> Update your time zone and save changes.

     

     

    • Inactive User's avatar
      Inactive User

      Hi Jake,

      Thanks for looking into this and also the links you provided.

      As the REST API server is based on UTC timezone, and my profile was based on PST, thus I've changed it to GTM UK ( which is also +0000 UTC).

      But the data I got are still differrent.

      REST API gave me 2597 net topics for 1-28 Feb.
      Advanced Metrics gave me 2682 though.

      Am i missing anything here?

      • Inactive User's avatar
        Inactive User
        Anyone can help ?