SlideShare a Scribd company logo
1 of 33
Download to read offline
Quick Start To GAS
Gakuji Tamaki
Systems Developer
APCommunications Co., Ltd.
Twitter: @gkzvoice, Github/Medium: @gkzz
Source; sinap.jp
Table of Contents
1.About Me
2.Today’s Goal
3.Overview of Google Apps Script
4.Get Data From SpreadSheet
5.Post Data To Chat App
6.Appendix
1.About Me
Source;
Python Logo: www.python.org, CentOS’s: www.centos.org, StackStorm’s: stackstorm.com,
2.Today’s Goal
See A Demo
Source;
Demo: @gkzvoice
Code: github.com/gkzz/gas-handson
Source; giphy.com
What’s Going On!?
Source; www.azquotes.com
Does A Function Really Do just One Thing?
Function 1
postData()
Function 3
postOnly()
Function 2
getData()
Function 1
setUp()
Function 1
postData()
My Opinion:
If you feel naming is difficult,
split your functions/variables
into the smaller ones.
Table of Contents (Re:)
1.About Me
2.Today’s Goal
3.Overview of Google Apps Script
4.Get Data From SpreadSheet
5.Post Data To Chat App
6.Appendix
3.Overview of Google Apps Script
- Cloud-based Application Development Platform
- Based on JavaScript
- Integrate Easily with Google/Third-Party Apps
- Also Allows Scripts to Return HTML
Source;
Image: www.lucidchart.com
Cf. My Sample Script’s URL
Today’s BOT Workflow:
- setUp
- getData
- Boolean
(Any News?)
True
False
- send
“NoNews”
- postNews
Source;
SpreadSheet: www.iconarchive.com,
Slack: www.iosicongallery.com, Gmail: www.flaticon.com
Table of Contents (Re:)
1.About Me
2.Today’s Goal
3.Overview of Google Apps Script
4.Get Data From
SpreadSheet
5.Post Data To Chat App
6.Appendix
Function 3
postOnly()
Function 2
getData()
Function 1
setUp()
4.Get Data From SpreadSheet
See A Demo
Source;
Demo: @gkzvoice
Code: github.com/gkzz/gas-handson
Table of Contents (Re:)
1.About Me
2.Today’s Goal
3.Overview of Google Apps Script
4.Get Data From
SpreadSheet
5.Post Data To Chat App
6.Appendix
Function 3
postOnly()
Function 2
getData()
Function 1
setUp()
5.Post Data To Chat App
See A Demo
Source;
Demo: @gkzvoice
Code: github.com/gkzz/gas-handson
Source; sinap.jp
6.Appendix
1.Run Apps Script
2.Use Debugger
3.Add Libraries
4.Get Incoming Webhook URL
5.Add BOT User
6.Change Permissions
7.Get userID through Tester
8. Deploy as Web App, Enable Events
9. All Sample Codes
-mailDraft, getUserList, getChannelHistory, etc
6-1.Appendix Run Apps Script
3.Push “View” and “Logs” Button,
See the Logged Output
1.Predict Value of Variable
2.Set Logger.log(“val: %s”, val),
Run Script
Develop
& Debug
6-2.Appendix
Use Debugger
[19-03-30 21:36:23:487 JST] writeConts: 0.0
[19-03-30 21:36:23:488 JST] Successful!
[19-03-30 21:36:23:489 JST] i: 0.0
[19-03-30 21:36:23:489 JST] value: [Thu Mar 28 13:02:45 GMT+09:00
2019, gendo@example.com, Gendo, NERV, Shinji, Eva1, Mankind’s
greatest fear is Mankind itself., , , , , , , , , , Done]
[19-03-30 21:36:23:490 JST] writeConts: 1.0
[19-03-30 21:36:23:490 JST] Successful!
[19-03-30 21:36:23:491 JST] i: 1.0
[19-03-30 21:36:23:492 JST] value: [Fri Mar 29 13:02:45 GMT+09:00 2019,
gendo@example.com, Gendo, NERV, Shinji, Eva1, Mankind’s greatest fear
is Mankind itself., , , , , , , , , , Done]
[19-03-30 21:36:23:492 JST] writeConts: 2.0
[19-03-30 21:24:55:236 JST] valueRange.length: 8.0
[19-03-30 21:24:55:238 JST] Successful!
[19-03-30 21:24:55:239 JST] i: 0.0
[19-03-30 21:24:55:240 JST] value: [Thu Mar 28 13:02:45 GMT+09:00
2019, gendo@example.com, Gendo, NERV, Shinji, Eva1, Mankind’s
greatest fear is Mankind itself., , , , , , , , , , Done]
Source;
1st Code: devel-old/sendRichMsg.js, 2nd:
topic-getValueRange/sendRichMsg.js
6-3.Appendix Add Libraries
See A Demo
Source;
Demo: @gkzvoice
Code: https://github.com/gkzz/gas-handson
Moment.js library key;
MHMchiX6c1bwSqGM1PZiW_PxhMjh3Sh48
6-4.Appendix Get Incoming Webhook URL
https://api.slack.com/apps
6-5.Appendix Add BOT User
6-6.Appendix Change Permissions
6-7.Appendix Get userID through Tester
https://api.slack.com/methods/users.list/test
<Your WorkSpace Name>
xoxb-aaaaaaaaaa
6-8. Deploy as Web App,
Enable Events --Work in Progress---
6-9. All Sample Codes
Go to the Following Github Page
https://github.com/gkzz/gas-handson
Fin.Twitter: @gkzvoice, Github/Medium: @gkzz

More Related Content

Similar to QuickStartToGAS

Openstack contribution process
Openstack contribution processOpenstack contribution process
Openstack contribution process
Syed Armani
 
OpenStack Contribution Process
OpenStack Contribution ProcessOpenStack Contribution Process
OpenStack Contribution Process
openstackindia
 

Similar to QuickStartToGAS (20)

Shipping to Learn and Accelerate Growth with GitHub
Shipping to Learn and Accelerate Growth with GitHubShipping to Learn and Accelerate Growth with GitHub
Shipping to Learn and Accelerate Growth with GitHub
 
Openstack contribution process
Openstack contribution processOpenstack contribution process
Openstack contribution process
 
OpenStack Contribution Process
OpenStack Contribution ProcessOpenStack Contribution Process
OpenStack Contribution Process
 
Real_World_0days.pdf
Real_World_0days.pdfReal_World_0days.pdf
Real_World_0days.pdf
 
Dynamics 365 self hosting bots
Dynamics 365 self hosting botsDynamics 365 self hosting bots
Dynamics 365 self hosting bots
 
Harnessing the cloud to create social mobile apps that scale
Harnessing the cloud to create social mobile apps that scaleHarnessing the cloud to create social mobile apps that scale
Harnessing the cloud to create social mobile apps that scale
 
[T3 ext day] all in one chat – real time chat
[T3 ext day] all in one chat – real time chat[T3 ext day] all in one chat – real time chat
[T3 ext day] all in one chat – real time chat
 
Budapest Spark Meetup - Apache Spark @enbrite.ly
Budapest Spark Meetup - Apache Spark @enbrite.lyBudapest Spark Meetup - Apache Spark @enbrite.ly
Budapest Spark Meetup - Apache Spark @enbrite.ly
 
Going open source with small teams
Going open source with small teamsGoing open source with small teams
Going open source with small teams
 
Git ongithub
Git ongithubGit ongithub
Git ongithub
 
Bitrise: Make iOS Builds Faster - Tokyo 2019 March - Cookpad meetup
Bitrise: Make iOS Builds Faster - Tokyo 2019 March - Cookpad meetupBitrise: Make iOS Builds Faster - Tokyo 2019 March - Cookpad meetup
Bitrise: Make iOS Builds Faster - Tokyo 2019 March - Cookpad meetup
 
GigaSpaces Cloud Computing Framework 4 XAP - Quick Tour - v2
GigaSpaces Cloud Computing Framework 4 XAP - Quick Tour - v2GigaSpaces Cloud Computing Framework 4 XAP - Quick Tour - v2
GigaSpaces Cloud Computing Framework 4 XAP - Quick Tour - v2
 
Big query - Command line tools and Tips - (MOSG)
Big query - Command line tools and Tips - (MOSG)Big query - Command line tools and Tips - (MOSG)
Big query - Command line tools and Tips - (MOSG)
 
Gutmacher javascript-bookmarklets-sosuv-july2020
Gutmacher javascript-bookmarklets-sosuv-july2020Gutmacher javascript-bookmarklets-sosuv-july2020
Gutmacher javascript-bookmarklets-sosuv-july2020
 
Bronx study jam 2
Bronx study jam 2Bronx study jam 2
Bronx study jam 2
 
Hyperkitty: Updating Mailman's UI
Hyperkitty: Updating Mailman's UIHyperkitty: Updating Mailman's UI
Hyperkitty: Updating Mailman's UI
 
Getting Started in Custom Programming for Talent Sourcing
Getting Started in Custom Programming for Talent SourcingGetting Started in Custom Programming for Talent Sourcing
Getting Started in Custom Programming for Talent Sourcing
 
CrashCourse: Python with DataCamp and Jupyter for Beginners
CrashCourse: Python with DataCamp and Jupyter for BeginnersCrashCourse: Python with DataCamp and Jupyter for Beginners
CrashCourse: Python with DataCamp and Jupyter for Beginners
 
Hacking the Kinect with GAFFTA Day 1
Hacking the Kinect with GAFFTA Day 1Hacking the Kinect with GAFFTA Day 1
Hacking the Kinect with GAFFTA Day 1
 
Lessons Learned from Migrating Legacy Enterprise Applications to Microservices
Lessons Learned from Migrating Legacy Enterprise Applications to MicroservicesLessons Learned from Migrating Legacy Enterprise Applications to Microservices
Lessons Learned from Migrating Legacy Enterprise Applications to Microservices
 

Recently uploaded

Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider  Progress from Awareness to Implementation.pptxTales from a Passkey Provider  Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
FIDO Alliance
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
panagenda
 
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
FIDO Alliance
 

Recently uploaded (20)

Design Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptxDesign Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptx
 
Design and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data ScienceDesign and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data Science
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 
Introduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptxIntroduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptx
 
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider  Progress from Awareness to Implementation.pptxTales from a Passkey Provider  Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
 
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
 
Top 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development CompaniesTop 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development Companies
 
AI mind or machine power point presentation
AI mind or machine power point presentationAI mind or machine power point presentation
AI mind or machine power point presentation
 
WebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM PerformanceWebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM Performance
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage Intacct
 
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
 
Intro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptxIntro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptx
 
Working together SRE & Platform Engineering
Working together SRE & Platform EngineeringWorking together SRE & Platform Engineering
Working together SRE & Platform Engineering
 
TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...
TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...
TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdf
 
ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps Productivity
 
ADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptxADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptx
 
Syngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdfSyngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdf
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024
 

QuickStartToGAS

  • 1. Quick Start To GAS Gakuji Tamaki Systems Developer APCommunications Co., Ltd. Twitter: @gkzvoice, Github/Medium: @gkzz
  • 3. Table of Contents 1.About Me 2.Today’s Goal 3.Overview of Google Apps Script 4.Get Data From SpreadSheet 5.Post Data To Chat App 6.Appendix
  • 4. 1.About Me Source; Python Logo: www.python.org, CentOS’s: www.centos.org, StackStorm’s: stackstorm.com,
  • 5. 2.Today’s Goal See A Demo Source; Demo: @gkzvoice Code: github.com/gkzz/gas-handson
  • 8. Does A Function Really Do just One Thing? Function 1 postData()
  • 9. Function 3 postOnly() Function 2 getData() Function 1 setUp() Function 1 postData()
  • 10. My Opinion: If you feel naming is difficult, split your functions/variables into the smaller ones.
  • 11. Table of Contents (Re:) 1.About Me 2.Today’s Goal 3.Overview of Google Apps Script 4.Get Data From SpreadSheet 5.Post Data To Chat App 6.Appendix
  • 12. 3.Overview of Google Apps Script - Cloud-based Application Development Platform - Based on JavaScript - Integrate Easily with Google/Third-Party Apps - Also Allows Scripts to Return HTML Source; Image: www.lucidchart.com Cf. My Sample Script’s URL
  • 13. Today’s BOT Workflow: - setUp - getData - Boolean (Any News?) True False - send “NoNews” - postNews Source; SpreadSheet: www.iconarchive.com, Slack: www.iosicongallery.com, Gmail: www.flaticon.com
  • 14. Table of Contents (Re:) 1.About Me 2.Today’s Goal 3.Overview of Google Apps Script 4.Get Data From SpreadSheet 5.Post Data To Chat App 6.Appendix Function 3 postOnly() Function 2 getData() Function 1 setUp()
  • 15. 4.Get Data From SpreadSheet See A Demo Source; Demo: @gkzvoice Code: github.com/gkzz/gas-handson
  • 16. Table of Contents (Re:) 1.About Me 2.Today’s Goal 3.Overview of Google Apps Script 4.Get Data From SpreadSheet 5.Post Data To Chat App 6.Appendix Function 3 postOnly() Function 2 getData() Function 1 setUp()
  • 17. 5.Post Data To Chat App See A Demo Source; Demo: @gkzvoice Code: github.com/gkzz/gas-handson
  • 18. Source; sinap.jp 6.Appendix 1.Run Apps Script 2.Use Debugger 3.Add Libraries 4.Get Incoming Webhook URL 5.Add BOT User 6.Change Permissions 7.Get userID through Tester 8. Deploy as Web App, Enable Events 9. All Sample Codes -mailDraft, getUserList, getChannelHistory, etc
  • 20.
  • 21. 3.Push “View” and “Logs” Button, See the Logged Output 1.Predict Value of Variable 2.Set Logger.log(“val: %s”, val), Run Script Develop & Debug 6-2.Appendix Use Debugger
  • 22. [19-03-30 21:36:23:487 JST] writeConts: 0.0 [19-03-30 21:36:23:488 JST] Successful! [19-03-30 21:36:23:489 JST] i: 0.0 [19-03-30 21:36:23:489 JST] value: [Thu Mar 28 13:02:45 GMT+09:00 2019, gendo@example.com, Gendo, NERV, Shinji, Eva1, Mankind’s greatest fear is Mankind itself., , , , , , , , , , Done] [19-03-30 21:36:23:490 JST] writeConts: 1.0 [19-03-30 21:36:23:490 JST] Successful! [19-03-30 21:36:23:491 JST] i: 1.0 [19-03-30 21:36:23:492 JST] value: [Fri Mar 29 13:02:45 GMT+09:00 2019, gendo@example.com, Gendo, NERV, Shinji, Eva1, Mankind’s greatest fear is Mankind itself., , , , , , , , , , Done] [19-03-30 21:36:23:492 JST] writeConts: 2.0 [19-03-30 21:24:55:236 JST] valueRange.length: 8.0 [19-03-30 21:24:55:238 JST] Successful! [19-03-30 21:24:55:239 JST] i: 0.0 [19-03-30 21:24:55:240 JST] value: [Thu Mar 28 13:02:45 GMT+09:00 2019, gendo@example.com, Gendo, NERV, Shinji, Eva1, Mankind’s greatest fear is Mankind itself., , , , , , , , , , Done] Source; 1st Code: devel-old/sendRichMsg.js, 2nd: topic-getValueRange/sendRichMsg.js
  • 23. 6-3.Appendix Add Libraries See A Demo Source; Demo: @gkzvoice Code: https://github.com/gkzz/gas-handson Moment.js library key; MHMchiX6c1bwSqGM1PZiW_PxhMjh3Sh48
  • 24. 6-4.Appendix Get Incoming Webhook URL https://api.slack.com/apps
  • 25.
  • 26.
  • 28.
  • 30. 6-7.Appendix Get userID through Tester https://api.slack.com/methods/users.list/test <Your WorkSpace Name> xoxb-aaaaaaaaaa
  • 31. 6-8. Deploy as Web App, Enable Events --Work in Progress---
  • 32. 6-9. All Sample Codes Go to the Following Github Page https://github.com/gkzz/gas-handson