Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Google Apps Script アプリを配付する
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Tiny Mouse
October 26, 2019
Programming
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Google Apps Script アプリを配付する
プログラミング生放送 2019/10/26
Tiny Mouse
October 26, 2019
More Decks by Tiny Mouse
See All by Tiny Mouse
今年がんばったこと
tinymouse
0
74
今年がんばったこと
tinymouse
0
120
【LT会】インプット・アウトプットどうしてる?
tinymouse
0
60
今年がんばったこと
tinymouse
0
180
.NET MAUI+Blazor を使ってみた
tinymouse
0
200
【LT会】この技術書がすごい
tinymouse
1
210
蔵書管理アプリを作り直した
tinymouse
1
1.1k
Windows アプリの開発手段の選択肢をまとめてみた
tinymouse
0
180
蔵書管理アプリを作りました
tinymouse
0
680
Other Decks in Programming
See All in Programming
Spec-Driven Development with AI-Agents: From High-Level Requirements to Working Software
antonarhipov
2
470
New "Type" system on PicoRuby
pocke
1
750
さぁV100、メモリをお食べ・・・
nilpe
0
130
JavaDoc 再入門
nagise
0
310
Technical Debt: Understanding it Rightly, Engaging it Rightly #LaravelLiveJP
shogogg
0
210
Contextとはなにか
chiroruxx
0
190
Signal Forms: Beyond the Basics @ngBaguette 2026 in Paris
manfredsteyer
PRO
0
230
Javaの型とAI時代に型が大事な理由 / java types and type in AI era
kishida
2
120
ECSアプリログをFireLensでコスト削減しようとしたけど諦めた話 in Fargate×Node.js
akihisaikeda
2
3.9k
Spring Security 実践 ─ GraphQL APIで実務に役立つ 認証・認可 を学ぶ
wagyu
0
210
OSもどきOS
arkw
0
470
AIチームを指揮するOSS「TAKT」活用術 / How to Use “TAKT,” an OSS Tool for Orchestrating AI Teams
nrslib
6
850
Featured
See All Featured
BBQ
matthewcrist
89
10k
Thoughts on Productivity
jonyablonski
76
5.2k
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
220
[SF Ruby Conf 2025] Rails X
palkan
2
1.1k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
840
Amusing Abliteration
ianozsvald
1
200
Rails Girls Zürich Keynote
gr2m
96
14k
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
360
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
How GitHub (no longer) Works
holman
316
150k
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
2
4k
Transcript
Tiny Mouse Google Apps Script で書いたアプリを配付する プログラミング生放送勉強会 2019/10/26
n @tinymouse_jp n SI 企業の SE n 日曜プログラマ n 二児の父
n 静岡県浜松市出身 n 東京都品川区在住。名古屋市在住。 n Windows 愛用。iPhone Android スマホ n Android の会浜松支部、よちよち Android の会、 Hamamatsu.js Tiny Mouse 自己紹介
蔵書管理アプリを作った
サーバサイドに Google Apps Script を使う 「ウェブアプリケーションとして公開」 GET メソッド、POST メソッドを受けて JSON
などでレスポンスできる スプレッドシートをデータベースとして使う
サーバサイドに Google Apps Script を使う 誰でもアクセス可能 「ウェブアプリケーションとして公開」 GET メソッド、POST メソッドを受けて
JSON などでレスポンスできる
簡易なベーシック認証する ID が違えばシートにアクセス不可 スプレッドシートのID シートのファイル ID を指定してアクセス 指定された ID のシートにアクセス
$.ajax({ url: “https://script.google.com/macros/s/◦◦◦◦◦◦◦◦/exec”, type: 'GET', data: { keywords: encodeURIComponent(“◎◎◎◎◎◎◎◎”), docid: ”••••••••” }, }) function doGet(e) { if (!e.parameter.docid || !canOpen(e.parameter.docid)) { return ContentService.createTextOutput(JSON.stringify({ result: "id not specified", })).setMimeType(ContentService.MimeType.JSON); } ....
ファイル ID を設定画面で登録する 簡易なベーシック認証する
よくあるモバイルアプリとサーバサイドアプリ クライアントアプリは配布できる
l Google Play Store で公開する l ウェブサイトで公開する スマホアプリを配付する
https://sites.google.com/view/tinymouse-zoshodaicho 蔵書管理アプリを作った
サーバサイドは開発者のリソースを使う よくあるモバイルアプリとサーバサイドアプリ
サーバサイドに Google Apps Script を使う 自分のGoogle ドライブのオブジェクトを他人に使わせるか
GAS のコードやドライブのオブジェクトはコピーできる 実は・・
GAS のコードやドライブのオブジェクトはコピーできる 実は・・ gapi.load('client', function(){ gapi.client.init({ apiKey: '◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆', clientId: '••••••-••••••••••••••••.apps.googleusercontent.com',
scope: 'https://www.googleapis.com/auth/◇◇' }) }); gapi.auth2.getAuthInstance().signIn() .... .then(function(data){ $('#status').text("蔵書データベースを設定しています (1/7) 。配付するプログラムを取得しました。"); // ①プロジェクトを作成する $('#status').text("蔵書データベースを設定しています (2/7) 。プロジェクトを作成します。"); return gapi.client.request({ path: 'https://script.googleapis.com/v1/projects', method: 'POST', body: { title: '蔵書台帳' } }); }) }) ....
GAS のコードやドライブのオブジェクトを配付する コピーできた情報をスマホアプリの設定にセットしたい
GAS のコードやドライブのオブジェクトを配付する QR コードで表示してスマホアプリで読取して貰う
実は・・ 事前に Google Apps Script API の設定を 変更して貰わないといけない
実は・・ 配付できたスクリプトを開いて 実行の承認して貰わないといけない
なかなか大変だ! ということで・・