Last active
December 11, 2016 10:42
-
-
Save tamanugi/e8c6dd72ee716fc80df9425efdfab461 to your computer and use it in GitHub Desktop.
[botkit × Nightmarejs] 指定されたURLのスクリーンショットをとるチャットボットを作ってみた ref: http://qiita.com/tamanugi/items/f73601365589c3e5e79d
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ npm install | |
$ token=<your bot token> node bot.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@chatbot capture http://hoge.com |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
controller.hears(['capture <(https?://.*)>'], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Nightmare(); | |
.goto(url) | |
.screenshot('path/to/image.png') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment