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
Chatting with Japanese using Firebase Extensions
Search
Firebase Thailand
November 09, 2019
Technology
0
290
Chatting with Japanese using Firebase Extensions
Get to know how to build Translator Chatbot in LINE using Firebase Extensions
Firebase Thailand
November 09, 2019
Tweet
Share
More Decks by Firebase Thailand
See All by Firebase Thailand
What's New in Firebase 2024
firebasethailand
1
200
Adding New Capabilities to Your Apps with Firebase and Gemini API
firebasethailand
1
180
Say Hello to Cloud Functions for Firebase 2nd Gen
firebasethailand
1
360
What's New in Firebase 2023
firebasethailand
3
570
Building a more Efficient Firestore Web App
firebasethailand
1
170
Developing with Firebase - Best Practices
firebasethailand
0
170
Analyze your production issue on Firebase Crashlytics more efficient with BigQuery
firebasethailand
0
360
What I learn from Firebase when build Saifah
firebasethailand
0
130
Security Rules Unit Testing Pipeline Integration for Firestore
firebasethailand
0
120
Other Decks in Technology
See All in Technology
Raycast AI APIを使ってちょっと便利な拡張機能を作ってみた / created-a-handy-extension-using-the-raycast-ai-api
kawamataryo
0
210
4th place solution Eedi - Mining Misconceptions in Mathematics
rist
0
140
Potential EM 制度を始めた理由、そして2年後にやめた理由 - EMConf JP 2025
hoyo
2
2.5k
EMConf JP 2025 懇親会LT / EMConf JP 2025 social gathering
sugamasao
2
190
スキルだけでは満たせない、 “組織全体に”なじむオンボーディング/Onboarding that fits “throughout the organization” and cannot be satisfied by skills alone
bitkey
0
170
Exadata Database Service on Cloud@Customer セキュリティ、ネットワーク、および管理について
oracle4engineer
PRO
2
1.5k
php-conference-nagoya-2025
fuwasegu
0
150
AWS Well-Architected Frameworkで学ぶAmazon ECSのセキュリティ対策
umekou
2
140
IAMのマニアックな話2025
nrinetcom
PRO
1
190
Two Blades, One Journey: Engineering While Managing
ohbarye
4
1.9k
OPENLOGI Company Profile
hr01
0
60k
サイト信頼性エンジニアリングとAmazon Web Services / SRE and AWS
ymotongpoo
7
1.4k
Featured
See All Featured
Side Projects
sachag
452
42k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
27
1.9k
Unsuck your backbone
ammeep
669
57k
Bash Introduction
62gerente
611
210k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
49
2.3k
Docker and Python
trallard
44
3.3k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
Six Lessons from altMBA
skipperchong
27
3.6k
How GitHub (no longer) Works
holman
314
140k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
30
2.2k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
3.7k
Transcript
GDG Thailand Firebase Thailand Organized by Chatting with Japanese using
Firebase Extensions Firebase Extensionsを使用して日本人とチャットする Warit Wanwithu LINE Thailand
#FirebaseDevDay DEVELOPERS นักพัฒนา デベロッパーズ
#FirebaseDevDay “How’s it Going” “Hello!”
None
#FirebaseDevDay Sending Email Resize Images Deleted User Data
https://github.com/firebase/functions-samples
#FirebaseDevDay ファイアーベース エクステンションズ
None
#FirebaseDevDay Install Functions Firestore Send email
None
#FirebaseDevDay DEMO デモ
#FirebaseDevDay CHATTING チャッティング
#FirebaseDevDay Functions Extensions Firestore 1.Webhook 2.Save 3.Translated 5.Push 4.Trigger
#FirebaseDevDay ❤ 0. Install Translation extension 1. Create LINE Chatbot
2. Handle LINE Webhook using Cloud Functions and save to Firestore 3. Listen to Firestore trigger and push message back to LINE group
1. Create LINE Chatbot https://developers.line.biz/
#FirebaseDevDay { "destination": "xxxxxxxxxx", "events": [{ "replyToken": "0f3779fba3b349968c5d07db31eab56f", "type": "message",
"timestamp": 1462629479859, "source": { "type": "user", "userId": "U4af4980629..." }, "message": { "id": "325708", "type": "text", "text": "Hello" } }]} 2. Handle LINE Webhook
#FirebaseDevDay exports.LineWebhook = functions.region(region).runWith(runtimeOpts) .https.onRequest(async (req, res) => { let
event = req.body.events[0]; if (event.message.type === 'text') { let input = event.message.text; await admin.firestore().collection('translations').doc('inputText') .set({ input: input }); } return res.status(200).send(req.method);; });
#FirebaseDevDay Functions Extensions Firestore Webhook Save Translated Push Trigger 3.
Listen to Firestore trigger
#FirebaseDevDay exports.LineBotPush = functions.region(region).runWith(runtimeOpts) .firestore.document('translations/inputText').onWrite(async (change, context) => { let
latest = change.after.data(); let input = latest.input; let containsJapanese = input.match(/[\u3000-\u303f\u3040-...]/); if (containsJapanese) { push(GROUP_ID, latest.translated.th); } else { push(GROUP_ID, latest.translated.ja); } });
None
#FirebaseDevDay MISSION ミッション
#FirebaseDevDay INSTALL CLOUD FUNCTIONS OPEN SOURCE CONFIG BETA
Thank You! #FirebaseDevDay Helpful resources fb.com/LINEDevTH fb.com/groups/LINEDevTH medium.com/LINEDevTH Warit Wanwithu
ありがとうございます