This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowA new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.
Dear community,
Recently I encoutered a bug when creating a custom connector that is .. very peculiar. Please consider the following reproduction scenario.
-Create a new custom connector, and replace the logic in the contents methods with the following ( feel free to take any API you'd like it doesn't matter for the bug ) :
let
url="https://api.publicapis.org",
path="/entries",
source = Web.Contents(url,[Headers=[#"Content-type"="application/json",
RelativePath=path]]),
responseHeaders= Value.Metadata(source)[Headers]
in
responseHeaders;
- Test the connector ( first specifying the credentials as anonymous offcourse ), and observe how several header fields are displayed.
- Paste the following method before the content method ( but after the line specifying the datasource kind and publish) :
shared aap=()=>
let
aap="noot"
in
aap;
- Please test the connector again, after specifying the credentials again please observe how the headers have been reduced to just the content type. When using an external tool like Fiddler, please note that the headers actually are still there but simply not seen ( or something like that ) by the connector. This behaviour will also happen when the connector is used in PowerBI.
I encoutered this bug with a different API, but the behaviour is odd. And it took me quite some time to figure out what exactly triggered this. I can't think of an explanation for this, so I'm eager to hear what's going on ...
kind regards,
Vincent Klijs
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.