@bx80 opened this Issue on November 23rd 2022 Contributor

Sites have their own timezone and this is used when requesting data for a single site.
When requesting data for all sites the SitesManager.getDefaultTimezone() is used.

This behavior doesn't appear to be documented:

https://developer.matomo.org/api-reference/reporting-api#standard-api-parameters
https://matomo.org/faq/how-to/faq_83/

Additionally the UI option to set the default timezone is described as 'Default time zone for new websites' which doesn't give any indication that it will also be used as the timezone when requesting all site data:

image

It would be good to update the API docs, add an FAQ and perhaps some supplemental UI text? ("You can select the time zone used as default new websites, this time zone will also be used when requesting data for multiple sites at once")

See #20042

@Faizan711 commented on November 28th 2022

is this issue still open, if so i would like to be assigned to work on it.

@justinvelluppillai commented on November 28th 2022 Member

Hi @Faizan711 - We would welcome a Pull Request on the applicable developer docs page https://developer.matomo.org/api-reference/reporting-api#standard-api-parameters

@Faizan711 commented on November 30th 2022

I am new to open source so can you please tell me which folder the page lies where i can make the changes. That would help me a lot.

@sgiehl commented on November 30th 2022 Member

@fabiocarneiro There is a edit on github link in the footer of the page justin mentioned above. That should direct you to the file, that needs to be adjusted on github

@Faizan711 commented on November 30th 2022

Thanks a lot.

@Faizan711 commented on December 2nd 2022

The issue does not clearly specifies what kind of behavior has to be documented. Can you be more specific please?

@bx80 commented on December 5th 2022 Contributor

Hi @Faizan711,

Sites have their own timezone and this is used when requesting data for a single site.
When requesting data for all sites the SitesManager.getDefaultTimezone() is used.

^^ This is the behaviour that isn't documented. The current documentation doesn't explain that the default timezone will be used when requesting data for all sites. This leads to confusion if the default timezone has not been set since it will default to UTC which may not match the expected timezone for the sites. Issue 20042 also has more useful detail. :slightly_smiling_face:

Powered by GitHub Issue Mirror