user2464670
user2464670

Reputation: 1

Can you use google appscript to receive JSON and then write to a spreadsheet?

I'm currently using a web-app thats capable of sending POST messages to urls.

Is it possible to send one to a google appscript, and then from there, it writes to the spreadsheet after processing the JSON?

EDIT:

function doPost(jk){
 var ss = SpreadsheetApp.openById('id');
  var data = ss.getActiveSheet().getDataRange();
  var ending = ss.getLastRow();
 // var holder = {"Process Name": "test", "Id": "test", "Subject": "test", "Hioo": "test", "Number 1": "test", "Number 2": "test", "Binary": "test", };
  //holder['project'];

  //var jdate = JSON.stringify(holder);
  var payload = JSON.stringify(jk);

Logger.log(jk );


}

Upvotes: 0

Views: 75

Answers (1)

Zig Mandel
Zig Mandel

Reputation: 19834

Yes its possible. Se doPost. To simplify authentication, publish the webapp as anonymous access. Private is possible but harder.

Upvotes: 1

Related Questions