
- #NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU HOW TO#
- #NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU INSTALL#
- #NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU 64 BIT#
- #NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU CODE#
#NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU 64 BIT#
NOTE: I have not implemented encryption on Excel 64 bit yet. I did cover Cookies and Excel in other articles, but in this case I decided to go with Kyle’s approach and use the registry, but this time I store and encrypt all the information needed to access and refresh authentication after one initial usage. Web applications can use cookies, and have control over return URLS.
#NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU CODE#
There are a few challenges implementing this in VBA, as hiding the required refresh tokens, client secrets and even receiving the access code through a dummy redirect URL is quite complex. If this is successful the new access token can now be used, with later refreshes repeated when it expires. In this case, the app requests a new access token by sending the refresh token, along with some client secret data, to the refresh URL. Even if the access token has expired, the user consent stage can be avoided if a refresh token is available.The access token can be used in the header of any requests made within the expiry time. If successful, an access token and a refresh token, along with an expiry time is returned.A post is then made, this time to a token request endpoint, with some of the same data used in the access request, the access code, and additional client secret information – all as part of post data.In the case of a native app such as Excel, a redirect URL is not possible, so the code is returned as part of the returned URL. If successful, an access code is returned to a redirect URL associated with your app.An initial get request to a web service with which you have registered your app, passes some client identification and scope information to an authorization endpoint URL. This phase is called user consent, and usually would involve the user, through a browser, accepting that the access is allowed for the scope being requested (for example, access to google drive data).The oauth2 dance seems complicated at first, but in principle it goes like this.
#NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU HOW TO#
Here I’ll cover how to implement Google Authentication, and add others to the classes later. The implementations are not always syntactically the same, but the steps are standard. OAUTH2 is a standard dance that many have implemented for their web service authentication. I fyou have problems, let me know on our forum and I’ll explain how to create a non encrypted version that doesn’t need capicom. If you don’t know how to do that, see these instructions. However there’s not a great need to encrypt your credentials in the registry nowadays, and CAPICOM is getting harder to get hold of for modern WIndows system.

#NO OAUTH TOKEN WITH GOOGLE DRIVE SCOPE WAS FOUND TABLEAU INSTALL#
For 32 bit installation, follow the instructions to install CAPICOM, copy it to WindowsSystem32, and register it (regsrv32.exe capicom.dll). These instructions won’t exactly apply to every configuration. Here’s a Microsoft Engineer describing how to do it. It is used to store your If you get an error about being unable to create a capicom object, you’ll need to install capicom. This is a method of encryption that is often not installed by default. That way any other workbooks that you run on this machine never need your oauth2 credentials in them. There is a blank workbook with the necessary modules – oauth2credentials.xlsm – which you can download from the downloads page. You’ll need the cRest module. I recommend that you keep a single workbook for initial authorization for each scope you plan to use on this machine. All associated libraries are available in the cDataSet.xlsm library downloadable here, or through gistthat, as described here. In this post, I’ve taken this a little further, with an implementation that minimizes the need for client secrets to be passed around.

Recently, Kyle Beachill did a nice guest post on this site, showing a VBA implementation of OAUTH2. There are many different solutions, some of which are already covered on this site- for example – Basic HTTP Authentication from VBA , Digest authentication from Google Apps Script, Google Apps ScriptDB, Delegation to Google Apps Script to name but a few.


One of the things that people have a lot of trouble with is authentication to web services.
