Skip to content

Instantly share code, notes, and snippets.

Avatar
🍸
learning

Alan Berman thealanberman

🍸
learning
  • SF Bay Area
View GitHub Profile
View BingoCardGenerator.gs
// the ID for the spreadsheet of quotes
var sheet_id = SpreadsheetApp.getActiveSpreadsheet().getId();
var sheet = SpreadsheetApp.openById(sheet_id);
var range = sheet.getDataRange();
var values = range.getValues();
var rows = range.getNumRows();
// Log some things for sanity check
Logger.log("sheet ID: " + sheet_id)
Logger.log("sheet: " + sheet)
View slack-slash-echo.js
module['exports'] = function echo(hook) {
// hook.io has a range of node modules available - see
// https://hook.io/modules.
// We use request (https://www.npmjs.com/package/request) for an easy way to
// make the HTTP request.
var request = require('request');
// The parameters passed in via the slash command POST request.
var params = hook.params;