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
PythonでSlack Bot
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
anonaka
March 18, 2017
Technology
1.2k
0
Share
PythonでSlack Bot
SlackBot sample to make a phone call and read text.
anonaka
March 18, 2017
More Decks by anonaka
See All by anonaka
Introduction to the data analysis using python
anonaka
0
1.2k
Rubyで電話をかける
anonaka
0
540
Pandasによる競馬データの分析
anonaka
3
2.2k
PyCon APAC 2017へ行こう!
anonaka
0
760
Other Decks in Technology
See All in Technology
インフラが苦手でも大丈夫! 紙芝居 Kubernetes -WWGT 10周年編-
aoi1
1
310
美味しいスイスチーズを作ろう🧀🐭
taigamikami
1
190
Oracle AI Database@Google Cloud:サービス概要のご紹介
oracle4engineer
PRO
6
1.5k
A Harness for Behaviour: how to get AI to generate code that does what we intend, or "TDD in the age of AI"
xpmatteo
1
520
AI フレンドリーなエラー監視を TypeScript で実現する
shinyaigeek
2
200
Fabric-cicd によるAzure DevOps デプロイ
ryomaru0825
0
170
ポスター発表&デモと総括 / Poster Presentations & Demonstrations and Summary
ks91
PRO
0
180
ルールやカスタム機能、どう使う?理想の出力を引き出すために今知りたいIBM Bob 5つの機能
muehara
0
160
AI-DLCを活用した高品質・安全なAI駆動開発実践 / AI Driven Development
yoshidashingo
1
270
Databricks 月刊サービスアップデート 2026年05月号
tyosi1212
0
120
AI時代の私の技術インプットとアウトプット術
tonkotsuboy_com
15
8k
さきさん文庫の書籍ができるまで
sakiengineer
0
320
Featured
See All Featured
Optimising Largest Contentful Paint
csswizardry
37
3.7k
Done Done
chrislema
186
16k
The SEO Collaboration Effect
kristinabergwall1
1
470
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
The World Runs on Bad Software
bkeepers
PRO
72
12k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
130
Practical Orchestrator
shlominoach
191
11k
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
2
830
Music & Morning Musume
bryan
47
7.2k
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
2
560
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
49
10k
Building an army of robots
kneath
306
46k
Transcript
1ZUIPOͰ4MBDL#PU தɹ 909;0ΤόϯδΣϦετ
8IPBN* w ۭඈͿϓϩάϥϚ w גࣜձࣾ909;0ΤόϯδΣϦετ
None
None
"CPVU9PY[P κΫκʔʣ w ςϨϑΥχʔ"1*Λఏڙ͍ͯ͠·͢ w 909;0Ͱݕࡧͯ͠Ͷ
None
None
%&.0
#PU6TFST w 4MBDLͷ#PU6TFSΛ࡞͠ɺ"1*5PLFOΛೖख ͢Δ
४උ w QJQJOTUBMMTMBDLCPU w QJQJOTUBMMYPY[PDMPVEQZ w ʢిΛ͔͚ΔϥΠϒϥϦʣ
$ cat slack.py # -*- coding: utf-8 -*- import os
from slackbot.bot import respond_to, listen_to from xoxzo.cloudpy import XoxzoClient sid = os.environ.get("XOXZO_API_SID") auth_token = os.environ.get("XOXZO_API_AUTH_TOKEN") @listen_to('(.*)ʹʮ(.*)ʯͱిͯ͠') def hello(message, phonnum, msg): message.reply('%sʹʮ%sʯͱి͠·͢Ͷ' % (phonnum, msg)) xc = XoxzoClient(sid=sid, auth_token=auth_token) result = xc.call_tts_playback( tts_message=msg, tts_lang='ja', recipient="+81" + phonnum[1:], caller="+815012345678")
909;0ΞΧϯτ w "1*ͷར༻ʹ909;0ΞΧϯτʹαΠϯΞο ϓͯ͠ɺ4*%ͱΞΫηετʔΫϯͷೖख͕ඞཁͰ ͢ w IUUQTXXXYPY[PDPNKBBDDPVOUT TJHOVQ
909;0νʔϜ w ݱࡏ໊̔ w ΦϑΟεͳ͠ɻશһϦϞʔτϫʔΫ
None
None
͝੩ௌͲ͏ ͋Γ͕ͱ͏͍͟͝·ͨ͠ "1*Λͬͨ໘ന͍ΞΠσΞืूதͰ͢ʂ