How do I get an access token using UrlFetchApp with GAS
问题 I am learning how to use the REST endpoints with Google Apps Script (GAS) and want to get the access token like the example here I'm using Google Sites, here is the script function doGet(e) { var app = UiApp.createApplication().setTitle('test OAuth 2.0'); var mainPanel = app.createVerticalPanel(); app.add(mainPanel); var url = "https://accounts.google.com/o/oauth2/auth" + "?scope=https://www.googleapis.com/auth/userinfo.email https://www.googleapis.com/auth/userinfo.profile" + "&state=