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

Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers. Get Fabric certified for FREE! Learn more

Reply
sa34techer
Helper II
Helper II

Adding timeout in WEB.CONTENTS to right place?

Where is the right place to add a Time Out Increase in this connection string?  The Bear Token is a parameter

 

= Json.Document(Web.Contents("https://surveys-api.avius.com/api/v1/survey/133f8356-eb51-5968-b2b6-bf200d505401/changes/117028961/5...",[Timeout=#duration(0, 0, 30, 0)], [Headers=[Authorization=#"Bearer Token", Accept="text/plain"]]))

 

 timeout.png

1 ACCEPTED SOLUTION

I figured it out. I had to remove the bracket in front of Headers. It is working now.

 

= Json.Document(Web.Contents("https://surveys-api.avius.com/api/v1/survey/133f8356-eb51-5968-b2b6-bf200d505401/Changes/0/5000",[Timeout=#duration(0, 1, 0, 0), Headers=[Authorization=#"BearerToken", Accept="text/plain"]]))

View solution in original post

3 REPLIES 3
lbendlin
Super User
Super User

= Json.Document(Web.Contents("https://surveys-api.avius.com/api/v1/survey/133f8356-eb51-5968-b2b6-bf200d505401/changes/117028961/5...",[Timeout=#duration(0, 0, 30, 0), [Headers=[Authorization=#"Bearer Token", Accept="text/plain"]]]))

Web.Contents - PowerQuery M | Microsoft Learn

Hello Sir, the code you sent gives out a Expression.SyntaxError: Invalid identifier error.   Please look into it and reply with the updated m code.

 

1.png

I figured it out. I had to remove the bracket in front of Headers. It is working now.

 

= Json.Document(Web.Contents("https://surveys-api.avius.com/api/v1/survey/133f8356-eb51-5968-b2b6-bf200d505401/Changes/0/5000",[Timeout=#duration(0, 1, 0, 0), Headers=[Authorization=#"BearerToken", Accept="text/plain"]]))

Helpful resources

Announcements
Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

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