Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
threw001
Helper III
Helper III

PowerBI Service Auto Refresh Issue (Post) Using TimeAPI.io

Hi,

 

I have a PowerBI report that I have published however I am struggling to get the Service to auto-refresh.

I have no issues when I open the report in PowerBI desktop and refresh manually however when trying to refresh on PowerBI web, it is not working.

 

I have tinkered and played around with all different types of privacy settings however still no success.

 

The report takes my data and then uses the TimeAPI.io to ConvertTimeZone for a particular field.

I have checked the TimeAPI documentation and found that I am using a POST request https://timeapi.io/swagger/index.html

 

I am getting the below error message(s)

  1. Failed to update data source credentials: Web.Contents failed to get contents from 'https://timeapi.io/api/Conversion/ConvertTimeZone' (405): Method Not Allowed
  2. [Unable to combine data] Section1/Query1/Changed Type1 is accessing data sources that have privacy levels which cannot be used together. Please rebuild this data combination.. The exception was raised by the IDataReader interface. Please review the error message and provider documentation for further information and corrective action. Table: Query1.

 

I am using the below query to pull in and convert timezone (to my query that has my data)

//fnConvertTimeZone

(dt as text, fromZone as text, toZone as text) =>
let
BaseURL = "https://timeapi.io/api/Conversion/ConvertTimeZone",
headers = [#"Content-Type" = "application/json"],
Body = [dateTime = dt, fromTimeZone = fromZone, toTimeZone = toZone, dstAmbiguity=""],
Response = Web.Contents(BaseURL, [Headers = headers, Content = Json.FromValue(Body)]),
Result = Json.Document(Response)[conversionResult][dateTime]
in
Result

 

Happy to provide more info if required

 

Thank you as always!

 

 

 

2 REPLIES 2
lbendlin
Super User
Super User

Any particular reason for not using the extensive Time Zone functions in Power Query?

Thanks - I am not 100% clued up on TimeZone functions and how the PowerBI service handles timezones when the report is set up to auto refresh.

 

Perhaps I can provide more info on what I am trying to do if there is a better way...

 

I have data in Table 1 where all the Time/Dates are in Australia/Melbourne timezone

I would like to convert these times to equivalent Timezone quoted in column Time Zone and output this in column Adjusted Time Zone.

 

Currently, Australia/Perth is -2 hours behind Australia/Melbourne however due to Daylight savings, it is -2 some part of year and -3 other parts of the year. In the listed Time/Date below, Australia/Perth is -3 hours behind Australia/Melbourne. I would like the conversion to always pull in the correct time, adjusted to daylight savings

 

As mentioned before, I will be using PowerBI service to refresh the report

 

Thank you so much

 

Time/DateNameTime ZoneAdjusted Time Zone
01/01/2022 15:00LucyAustralia/Perth01/01/2022 12:00
21/06/2024 13:00TomAustralia/Brisbane21/06/2024 13:00

 

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.