Thanks a lot. That resolves the error. However, I receive another error "400 Bad Request". I think it's related to this line. When I ran the URL in a browser, it returns "Not Found". Any ideas? %let oauth2=https://www.googleapis.com/oauth2/v4/token; Here's the full code: filename token "c:\temp\token.json";
%let code_given =<code-returned-from-step-1> ;
%let oauth2=https://www.googleapis.com/oauth2/v4/token;
%let client_id=<your-client-id>.apps.googleusercontent.com;
%let client_secret=<your-client-secret>;
proc http
url="&oauth2.?client_id=&client_id.%str(&)code=&code_given.%str(&)client_secret=&client_secret.%str(&)redirect_uri=urn:ietf:wg:oauth:2.0:oob%str(&)grant_type=authorization_code%str(&)response_type=token"
method="POST"
out=token
;
run;
... View more