Wait time between API calls in Power Query RRS feed

  • Question

  • I have the following function I pass many URL's to doing this #"Added Custom" = Table.AddColumn(#"First Row as Header", "Custom", each SharedCount ([URL])),

    I would like to add in a wait time between calls. I saw some posts by Chris Webb using Function.InvokeAfter but was not able to get it working with this function. Any ideas how to add in a few second wait time?

     GetCounts = (URL as text)=>
     Source = Json.Document(Web.Contents(""&URL&""))

    Thursday, June 25, 2015 3:54 PM


All replies

  • Can you tell us more about what didn't work for you with Function.InvokeAfter? I don't believe there would be another reasonsable solution for what you're looking for.
    Thursday, June 25, 2015 5:00 PM
  • I was getting a Cannot convert a value of type Table to type Function error message and was unable to find a work around for it. I was trying to put it in the function.
    Thursday, June 25, 2015 8:32 PM
  • You need to pass a function to Function.InvokeAfter and not the table returned by Web.Contents. See this blog post that explains how to use it.
    Saturday, June 27, 2015 12:29 AM