function doGet(e) { return Authentication(e) } function doPost(e) { return Authentication(e) } function Authentication(e) { var ss = SpreadsheetApp.openById("ID"); var sh = ss.getSheetByName('標籤'); if (e.parameter.func=="Create"){ var rg = sh.getName() + "!" + sh.getDataRange().getA1Notation(); var email = e.parameter.email; var sql = '"Select B where B=\''+email+'\'"'; var qry = '=IFERROR(query(' + rg + ',' + sql + '),"")'; var ts = ss.insertSheet(); var setQuery = ts.getRange(1,1).setFormula(qry) var getResult = ts.getDataRange().getValues(); ss.deleteSheet(ts); if (getResult==""){ var data =[e.parameter.id, e.parameter.email, e.parameter.pwd]; sh.appendRow(data); return ContentService.createTextOutput("GOOD...