4 Replies Latest reply on Sep 9, 2016 2:49 PM by Brendan Lee

    401 unauthenticated with WDC, works standalone

    Craig Foote

      I'm new to WDC and am following the examples at http://onlinehelp.tableau.com/v9.3/api/wdc/en-us/help.htm#WDC/wdc_tutorial_get_columns_and_data.htm%3FTocPath%3DWeb%2520Data%2520Connector%2520Tutorials|Web%2520Data%2520Connector%2520Basic%2520Tutorial|_____5.


      I've got several versions of Javascript, with and without jquery, that connect to my rest service and bring back data, cross-domain and using basic auth (digest). But none work with tableau which gives me a 401 unauthenticated error.


      I'm using this to set the credentials:


      xhr.setRequestHeader("Authorization", "Basic "+btoa(username+":"+password);


      Is this not supported in WDC? What could I be doing wrong? Any pointers greatly appreciated.