Created
May 14, 2026 15:24
-
-
Save evmar/f7abe8b308b508697037667cae83368b to your computer and use it in GitHub Desktop.
google apps script for logging to spreadsheet
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function doPost(e) { | |
| var sheet = SpreadsheetApp.getActiveSpreadsheet().getActiveSheet(); | |
| var mood = e.parameter.mood; | |
| var who = e.parameter.who; | |
| var notes = e.parameter.notes; | |
| var date = new Date(); | |
| if (who == null || mood == null) { | |
| return ContentService.createTextOutput("missing param").setMimeType(ContentService.MimeType.TEXT); | |
| } | |
| sheet.appendRow([date, who, mood, notes]); | |
| return ContentService.createTextOutput("success").setMimeType(ContentService.MimeType.TEXT); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment