question

Steve Kim avatar image
Steve Kim asked Samyukta Bharadwaj answered

Matching analytics api (python) to performance reports on the web

I want to get matching numbers in analytics api (python) and performance reports on the web, but they are different.

Can you take a look and tell me what I am doing wrong?

Web performance report shows 3,242 inbound calls as per below picture

1687665782862.png


And then to get API result using python, I first followed script as per this page: RingCentral Line of Business Analytics APIs Quick Start

Below is the parameters that I passed to the api call. 1687665878522.png

Regarding the "dateFrom" and "dateTo", I tried 48 different date/times:
(To try all possible time offsets that I can think of)
Here is the result of the 48 different tries. There is no inbound call count of 3,242 anywhere.

1687666316559.png

What am I doing wrong?

analytics and reporting
1687665782862.png (87.2 KiB)
1687665878522.png (27.6 KiB)
1687666316559.png (54.1 KiB)
1 comment
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Phong Vu avatar image Phong Vu ♦♦ commented ·

I notice the same issue. Let me check with the team to see how they convert and set the time. I think it's an issue in the Analytics dashboard engine. So I trust more the response from the API.

0 Likes 0 ·
Steve Kim avatar image
Steve Kim answered Steve Kim commented

Thanks for looking into this case.

In the analytics web page, I found out that there are three filters that have same name as the API - 'Queues', 'Users', and 'Company Numbers'

None of the three groupings had any matching numbers when I ran a similar test as my post.

Also, the difference for 'Users' grouping is very significant, almost three times as much total calls from API (~18,000 total calls on Jun 1) vs performance report from web (~6,000 total calls on Jun 1)

4 comments
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Phong Vu avatar image Phong Vu ♦♦ commented ·

The Performance report has some adjustments and it has some legacy. I will check with the team to see how they are going to deal with that.

Try the LOB Analytics. That will give you closer result to the API response. But it still shows discrepancy between that and the API result which is being investigated)

screen-shot-2023-06-26-at-105810-am.png

0 Likes 0 ·
Steve Kim avatar image Steve Kim commented ·

Below is the list that my account has. I don't have the LOB Analytics, but the Adoption&Usage is in BETA so I used it to compare some numbers. The result was close, but still not matching.

1687890872717.png

0 Likes 0 ·
1687890872717.png (20.3 KiB)
Phong Vu avatar image Phong Vu ♦♦ Steve Kim commented ·

Ouches! The LOB Analytics is only available for RC brand right now. The team is still working on the discrepancy between the API and the app dashboard. As for me, I trust the result from the API more as I think the app might modify the date/time range incorrectly. But I have to wait for their investigation.

0 Likes 0 ·
Steve Kim avatar image Steve Kim Phong Vu ♦♦ commented ·

Hi, just wanted to check on how the investigation is going.

0 Likes 0 ·
Phong Vu avatar image
Phong Vu answered Phong Vu commented

I found out that the API does not convert the timeFrom and timeTo from UTC to your specified time zone. So you have to convert the time accordingly.

Since you are in the US/Eastern time zone, can you try this "timeFrom" and "timeTo" format to read your analytics data for the same period of time set in the Analytics dashboard for:

Start date: 05/31/2023 / From: 12:00AM

End date: 06/01/2023 / To: 11:59PM

timeFrom: "2023-05-31T00:00:00-05:00",
timeTo: "2023-06-01T23:59:59-05:00"
8 comments
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Steve Kim avatar image Steve Kim commented ·

Hi Phong,

I have already tried all of the time differences from -12:00 to +12:00 using the analytics API (you can see in the excel table picture in original request)

None of the analytics API results matched to the analytics web.

0 Likes 0 ·
Phong Vu avatar image Phong Vu ♦♦ Steve Kim commented ·

Can you provide me with the account id and the user extension id.

Checking with the team, they say that the Analytics dashboard app uses the user regional settings/timezone, of the user who logged in the app to get the offset time and convert the selected date/time range to UTC time using that offset.

When I tried that on my own account, I got the same result. Otherwise, I also got the discrepancy.

0 Likes 0 ·
Steve Kim avatar image Steve Kim Phong Vu ♦♦ commented ·

Where can I find the information that you are asking for?

0 Likes 0 ·
Show more comments
Samyukta Bharadwaj avatar image
Samyukta Bharadwaj answered

@Steve Kim, there were some issues with the dev ticket that was opened earlier, can you please submit a new ticket below for further investigation with your most recent RC Request Id, let me know the ticket number after you are done submitting.
https://developer.ringcentral.com/support/create-case

1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Developer sandbox tools

Using the RingCentral Phone for Desktop, you can dial or receive test calls, send and receive test SMS or Fax messages in your sandbox environment.

Download RingCentral Phone for Desktop:

Tip: switch to the "sandbox mode" before logging in the app:

  • On MacOS: press "fn + command + f2" keys
  • On Windows: press "Ctrl + F2" keys