kykint

Prepare for rewrite

1 -var express = require('express'); 1 +const TelegramBot = require('node-telegram-bot-api');
2 -var app = express();
3 -const line = require('@line/bot-sdk');
4 2
3 +// replace the value below with the Telegram token you receive from @BotFather
4 +const token = '825631426:AAE9tgw89kOZyLTre8DSDaObFQeVx7q41gw';
5 5
6 -//papago api 6 +// Create a bot that uses 'polling' to fetch new updates
7 -var request = require('request'); 7 +const bot = new TelegramBot(token, {polling: true});
8 8
9 -//번역 api_url 9 +// Matches "/echo [whatever]"
10 -var translate_api_url = 'https://openapi.naver.com/v1/papago/n2mt'; 10 +bot.onText(/\/echo (.+)/, (msg, match) => {
11 + // 'msg' is the received Message from Telegram
12 + // 'match' is the result of executing the regexp above on the text content
13 + // of the message
11 14
12 -//언어감지 api_url 15 + const chatId = msg.chat.id;
13 -var languagedetect_api_url = 'https://openapi.naver.com/v1/papago/detectLangs' 16 + const resp = match[1]; // the captured "whatever"
14 17
15 -// Naver Auth Key 18 + // send back the matched "whatever" to the chat
16 -//새로 발급받은 naver papago api id, pw 입력 19 + bot.sendMessage(chatId, resp);
17 -var client_id = 'xZMx34y7uru1v8lywZ2d';
18 -var client_secret = 'p6L7M7WsH9';
19 -
20 -const config = {
21 - channelAccessToken: 'mnny0MJSezgBXzR9C3Ddcc1Csdb7Y9jkvy2nqV5saOmvR2YOJ1/kj/2M0CNsLA+57B2qDpdUQ7WbCTtIKx/LAJ6Kwfop4tX3up7EM8H9EZK1td6GMbhhCb6wvUFVdb1PcTO4joCv8mspd3ubo8a+gAdB04t89/1O/w1cDnyilFU=',
22 - channelSecret: 'bde77633a16fc5bfbd532d5990c6170e',
23 -};
24 -
25 -
26 -// create LINE SDK client
27 -const client = new line.Client(config);
28 -
29 -// create Express app
30 -// about Express itself: https://expressjs.com/
31 -
32 -// register a webhook handler with middleware
33 -// about the middleware, please refer to doc
34 -app.post('/webhook', line.middleware(config), (req, res) => {
35 - Promise
36 - .all(req.body.events.map(handleEvent))
37 - .then((result) => res.json(result))
38 - .catch((err) => {
39 - console.error(err);
40 - res.status(200).end();
41 - });
42 }); 20 });
43 21
44 -// event handler 22 +// Listen for any kind of message. There are different kinds of
45 -function handleEvent(event) { 23 +// messages.
46 - if (event.type !== 'message' || event.message.type !== 'text') { 24 +bot.on('message', (msg) => {
47 - // ignore non-text-message event 25 + const chatId = msg.chat.id;
48 - return Promise.resolve(null);
49 - }
50 - return new Promise(function(resolve, reject) {
51 - //언어 감지 option
52 - var detect_options = {
53 - url : languagedetect_api_url,
54 - form : {'query': event.message.text},
55 - headers: {'X-Naver-Client-Id': client_id, 'X-Naver-Client-Secret': client_secret}
56 - };
57 -
58 - //papago 언어 감지
59 - request.post(detect_options,function(error,response,body){
60 - console.log(response.statusCode);
61 - if(!error && response.statusCode == 200){
62 - var detect_body = JSON.parse(response.body);
63 - var source = '';
64 - var target = '';
65 - var result = { type: 'text', text:''};
66 -
67 - //언어 감지가 제대로 됐는지 확인
68 - console.log(detect_body.langCode);
69 -
70 26
71 - //번역은 한국어->영어 / 영어->한국어만 지원
72 - if(detect_body.langCode == 'ko'||detect_body.langCode == 'en'){
73 - source = detect_body.langCode == 'ko' ? 'ko':'en';
74 - target = source == 'ko' ? 'en':'ko';
75 - //papago 번역 option
76 - var options = {
77 - url: translate_api_url,
78 - // 한국어(source : ko), 영어(target: en), 카톡에서 받는 메시지(text)
79 - form: {'source':source, 'target':target, 'text':event.message.text},
80 - headers: {'X-Naver-Client-Id': client_id, 'X-Naver-Client-Secret': client_secret}
81 - };
82 -
83 - // Naver Post API
84 - request.post(options, function(error, response, body){
85 - // Translate API Sucess
86 - if(!error && response.statusCode == 200){
87 - // JSON
88 - var objBody = JSON.parse(response.body);
89 - // Message 잘 찍히는지 확인
90 -
91 - result.text = objBody.message.result.translatedText;
92 - console.log(result.text);
93 - //번역된 문장 보내기
94 - client.replyMessage(event.replyToken,result).then(resolve).catch(reject);
95 - }
96 - });
97 - }
98 - // 메시지의 언어가 영어 또는 한국어가 아닐 경우
99 - else{
100 - result.text = '언어를 감지할 수 없습니다. \n 번역 언어는 한글 또는 영어만 가능합니다.';
101 - client.replyMessage(event.replyToken,result).then(resolve).catch(reject);
102 - }
103 -
104 - }
105 -
106 - });
107 -
108 - });
109 - }
110 -
111 -module.exports = app;
...\ No newline at end of file ...\ No newline at end of file
27 + // send a message to the chat acknowledging receipt of their message
28 + bot.sendMessage(chatId, 'Received your message');
29 +});
......
1 -#!/usr/bin/env node
2 -
3 -/**
4 - * Module dependencies.
5 - */
6 -
7 -var app = require('../app');
8 -var debug = require('debug')('project:server');
9 -var http = require('http');
10 -
11 -/**
12 - * Get port from environment and store in Express.
13 - */
14 -
15 -var port = normalizePort(process.env.PORT || '3000');
16 -app.set('port', port);
17 -
18 -/**
19 - * Create HTTP server.
20 - */
21 -
22 -var server = http.createServer(app);
23 -
24 -/**
25 - * Listen on provided port, on all network interfaces.
26 - */
27 -
28 -server.listen(port, function () {
29 - console.log('Linebot listening on port ' + port + '!');
30 -});
31 -server.on('error', onError);
32 -server.on('listening', onListening);
33 -
34 -/**
35 - * Normalize a port into a number, string, or false.
36 - */
37 -
38 -function normalizePort(val) {
39 - var port = parseInt(val, 10);
40 -
41 - if (isNaN(port)) {
42 - // named pipe
43 - return val;
44 - }
45 -
46 - if (port >= 0) {
47 - // port number
48 - return port;
49 - }
50 -
51 - return false;
52 -}
53 -
54 -/**
55 - * Event listener for HTTP server "error" event.
56 - */
57 -
58 -function onError(error) {
59 - if (error.syscall !== 'listen') {
60 - throw error;
61 - }
62 -
63 - var bind = typeof port === 'string'
64 - ? 'Pipe ' + port
65 - : 'Port ' + port;
66 -
67 - // handle specific listen errors with friendly messages
68 - switch (error.code) {
69 - case 'EACCES':
70 - console.error(bind + ' requires elevated privileges');
71 - process.exit(1);
72 - break;
73 - case 'EADDRINUSE':
74 - console.error(bind + ' is already in use');
75 - process.exit(1);
76 - break;
77 - default:
78 - throw error;
79 - }
80 -}
81 -
82 -/**
83 - * Event listener for HTTP server "listening" event.
84 - */
85 -
86 -function onListening() {
87 - var addr = server.address();
88 - var bind = typeof addr === 'string'
89 - ? 'pipe ' + addr
90 - : 'port ' + addr.port;
91 - debug('Listening on ' + bind);
92 -}
1 { 1 {
2 - "name": "linebot", 2 + "name": "telegrambot",
3 "version": "1.0.0", 3 "version": "1.0.0",
4 "lockfileVersion": 1, 4 "lockfileVersion": 1,
5 "requires": true, 5 "requires": true,
6 "dependencies": { 6 "dependencies": {
7 - "@line/bot-sdk": {
8 - "version": "6.7.1",
9 - "resolved": "https://registry.npmjs.org/@line/bot-sdk/-/bot-sdk-6.7.1.tgz",
10 - "integrity": "sha512-clWdgIM5pPa3J9Ov/tyquRMt/ENcOozPn1kNMuQ7lIhGklt5S+OmPbKEDXWJc7ePGXgQfU+0WtVuJRXgqXwrwA==",
11 - "requires": {
12 - "@types/body-parser": "^1.16.8",
13 - "@types/file-type": "^5.2.1",
14 - "@types/node": "^7.0.31",
15 - "axios": "^0.16.2",
16 - "body-parser": "^1.18.2",
17 - "file-type": "^7.2.0"
18 - }
19 - },
20 - "@types/body-parser": {
21 - "version": "1.17.0",
22 - "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.17.0.tgz",
23 - "integrity": "sha512-a2+YeUjPkztKJu5aIF2yArYFQQp8d51wZ7DavSHjFuY1mqVgidGyzEQ41JIVNy82fXj8yPgy2vJmfIywgESW6w==",
24 - "requires": {
25 - "@types/connect": "*",
26 - "@types/node": "*"
27 - }
28 - },
29 - "@types/connect": {
30 - "version": "3.4.32",
31 - "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.32.tgz",
32 - "integrity": "sha512-4r8qa0quOvh7lGD0pre62CAb1oni1OO6ecJLGCezTmhQ8Fz50Arx9RUszryR8KlgK6avuSXvviL6yWyViQABOg==",
33 - "requires": {
34 - "@types/node": "*"
35 - }
36 - },
37 - "@types/file-type": {
38 - "version": "5.2.2",
39 - "resolved": "https://registry.npmjs.org/@types/file-type/-/file-type-5.2.2.tgz",
40 - "integrity": "sha512-GWtM4fyqfb+bec4ocpo51/y4x0b83Je+iA6eV131LT9wL0//G+1UgwbkMg7w61ceOwR+KkZXK00z44jrrNljWg==",
41 - "requires": {
42 - "@types/node": "*"
43 - }
44 - },
45 - "@types/node": {
46 - "version": "7.10.6",
47 - "resolved": "https://registry.npmjs.org/@types/node/-/node-7.10.6.tgz",
48 - "integrity": "sha512-d0BOAicT0tEdbdVQlLGOVul1kvg6YvbaADRCThGCz5NJ0e9r00SofcR1x69hmlCyrHuB6jd4cKzL9bMLjPnpAA=="
49 - },
50 - "accepts": {
51 - "version": "1.3.7",
52 - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz",
53 - "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==",
54 - "requires": {
55 - "mime-types": "~2.1.24",
56 - "negotiator": "0.6.2"
57 - }
58 - },
59 "ajv": { 7 "ajv": {
60 "version": "6.10.0", 8 "version": "6.10.0",
61 "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.0.tgz", 9 "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.0.tgz",
...@@ -67,10 +15,14 @@ ...@@ -67,10 +15,14 @@
67 "uri-js": "^4.2.2" 15 "uri-js": "^4.2.2"
68 } 16 }
69 }, 17 },
70 - "array-flatten": { 18 + "array.prototype.findindex": {
71 - "version": "1.1.1", 19 + "version": "2.0.2",
72 - "resolved": "http://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", 20 + "resolved": "https://registry.npmjs.org/array.prototype.findindex/-/array.prototype.findindex-2.0.2.tgz",
73 - "integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=" 21 + "integrity": "sha1-WAaNJYh+9QXknckssAxE3O5VsGc=",
22 + "requires": {
23 + "define-properties": "^1.1.2",
24 + "es-abstract": "^1.5.0"
25 + }
74 }, 26 },
75 "asn1": { 27 "asn1": {
76 "version": "0.2.4", 28 "version": "0.2.4",
...@@ -100,15 +52,6 @@ ...@@ -100,15 +52,6 @@
100 "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.8.0.tgz", 52 "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.8.0.tgz",
101 "integrity": "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==" 53 "integrity": "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ=="
102 }, 54 },
103 - "axios": {
104 - "version": "0.16.2",
105 - "resolved": "https://registry.npmjs.org/axios/-/axios-0.16.2.tgz",
106 - "integrity": "sha1-uk+S8XFn37q0CYN4VFS5rBScPG0=",
107 - "requires": {
108 - "follow-redirects": "^1.2.3",
109 - "is-buffer": "^1.1.5"
110 - }
111 - },
112 "bcrypt-pbkdf": { 55 "bcrypt-pbkdf": {
113 "version": "1.0.2", 56 "version": "1.0.2",
114 "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", 57 "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz",
...@@ -117,42 +60,19 @@ ...@@ -117,42 +60,19 @@
117 "tweetnacl": "^0.14.3" 60 "tweetnacl": "^0.14.3"
118 } 61 }
119 }, 62 },
120 - "body-parser": { 63 + "bl": {
121 - "version": "1.19.0", 64 + "version": "1.2.2",
122 - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", 65 + "resolved": "https://registry.npmjs.org/bl/-/bl-1.2.2.tgz",
123 - "integrity": "sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==", 66 + "integrity": "sha512-e8tQYnZodmebYDWGH7KMRvtzKXaJHx3BbilrgZCfvyLUYdKpK1t5PSPmpkny/SgiTSCnjfLW7v5rlONXVFkQEA==",
124 - "requires": {
125 - "bytes": "3.1.0",
126 - "content-type": "~1.0.4",
127 - "debug": "2.6.9",
128 - "depd": "~1.1.2",
129 - "http-errors": "1.7.2",
130 - "iconv-lite": "0.4.24",
131 - "on-finished": "~2.3.0",
132 - "qs": "6.7.0",
133 - "raw-body": "2.4.0",
134 - "type-is": "~1.6.17"
135 - },
136 - "dependencies": {
137 - "debug": {
138 - "version": "2.6.9",
139 - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
140 - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
141 "requires": { 67 "requires": {
142 - "ms": "2.0.0" 68 + "readable-stream": "^2.3.5",
143 - } 69 + "safe-buffer": "^5.1.1"
144 - },
145 - "ms": {
146 - "version": "2.0.0",
147 - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
148 - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
149 - }
150 } 70 }
151 }, 71 },
152 - "bytes": { 72 + "bluebird": {
153 - "version": "3.1.0", 73 + "version": "3.5.5",
154 - "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz", 74 + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.5.tgz",
155 - "integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==" 75 + "integrity": "sha512-5am6HnnfN+urzt4yfg7IgTbotDjIT/u8AJpEt0sIU9FtXfVeezXAPKswrG+xKUCOYAINpSdgZVDU6QFh+cuH3w=="
156 }, 76 },
157 "caseless": { 77 "caseless": {
158 "version": "0.12.0", 78 "version": "0.12.0",
...@@ -167,29 +87,6 @@ ...@@ -167,29 +87,6 @@
167 "delayed-stream": "~1.0.0" 87 "delayed-stream": "~1.0.0"
168 } 88 }
169 }, 89 },
170 - "content-disposition": {
171 - "version": "0.5.3",
172 - "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz",
173 - "integrity": "sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==",
174 - "requires": {
175 - "safe-buffer": "5.1.2"
176 - }
177 - },
178 - "content-type": {
179 - "version": "1.0.4",
180 - "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz",
181 - "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA=="
182 - },
183 - "cookie": {
184 - "version": "0.4.0",
185 - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz",
186 - "integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg=="
187 - },
188 - "cookie-signature": {
189 - "version": "1.0.6",
190 - "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz",
191 - "integrity": "sha1-4wOogrNCzD7oylE6eZmXNNqzriw="
192 - },
193 "core-util-is": { 90 "core-util-is": {
194 "version": "1.0.2", 91 "version": "1.0.2",
195 "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", 92 "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz",
...@@ -211,6 +108,14 @@ ...@@ -211,6 +108,14 @@
211 "ms": "^2.1.1" 108 "ms": "^2.1.1"
212 } 109 }
213 }, 110 },
111 + "define-properties": {
112 + "version": "1.1.3",
113 + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz",
114 + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==",
115 + "requires": {
116 + "object-keys": "^1.0.12"
117 + }
118 + },
214 "delayed-stream": { 119 "delayed-stream": {
215 "version": "1.0.0", 120 "version": "1.0.0",
216 "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", 121 "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
...@@ -221,11 +126,6 @@ ...@@ -221,11 +126,6 @@
221 "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", 126 "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz",
222 "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=" 127 "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
223 }, 128 },
224 - "destroy": {
225 - "version": "1.0.4",
226 - "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz",
227 - "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA="
228 - },
229 "ecc-jsbn": { 129 "ecc-jsbn": {
230 "version": "0.1.2", 130 "version": "0.1.2",
231 "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", 131 "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz",
...@@ -235,78 +135,42 @@ ...@@ -235,78 +135,42 @@
235 "safer-buffer": "^2.1.0" 135 "safer-buffer": "^2.1.0"
236 } 136 }
237 }, 137 },
238 - "ee-first": { 138 + "end-of-stream": {
239 - "version": "1.1.1", 139 + "version": "1.4.1",
240 - "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", 140 + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.1.tgz",
241 - "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" 141 + "integrity": "sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q==",
242 - },
243 - "encodeurl": {
244 - "version": "1.0.2",
245 - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz",
246 - "integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k="
247 - },
248 - "escape-html": {
249 - "version": "1.0.3",
250 - "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz",
251 - "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg="
252 - },
253 - "etag": {
254 - "version": "1.8.1",
255 - "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz",
256 - "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc="
257 - },
258 - "express": {
259 - "version": "4.17.1",
260 - "resolved": "https://registry.npmjs.org/express/-/express-4.17.1.tgz",
261 - "integrity": "sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==",
262 - "requires": {
263 - "accepts": "~1.3.7",
264 - "array-flatten": "1.1.1",
265 - "body-parser": "1.19.0",
266 - "content-disposition": "0.5.3",
267 - "content-type": "~1.0.4",
268 - "cookie": "0.4.0",
269 - "cookie-signature": "1.0.6",
270 - "debug": "2.6.9",
271 - "depd": "~1.1.2",
272 - "encodeurl": "~1.0.2",
273 - "escape-html": "~1.0.3",
274 - "etag": "~1.8.1",
275 - "finalhandler": "~1.1.2",
276 - "fresh": "0.5.2",
277 - "merge-descriptors": "1.0.1",
278 - "methods": "~1.1.2",
279 - "on-finished": "~2.3.0",
280 - "parseurl": "~1.3.3",
281 - "path-to-regexp": "0.1.7",
282 - "proxy-addr": "~2.0.5",
283 - "qs": "6.7.0",
284 - "range-parser": "~1.2.1",
285 - "safe-buffer": "5.1.2",
286 - "send": "0.17.1",
287 - "serve-static": "1.14.1",
288 - "setprototypeof": "1.1.1",
289 - "statuses": "~1.5.0",
290 - "type-is": "~1.6.18",
291 - "utils-merge": "1.0.1",
292 - "vary": "~1.1.2"
293 - },
294 - "dependencies": {
295 - "debug": {
296 - "version": "2.6.9",
297 - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
298 - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
299 "requires": { 142 "requires": {
300 - "ms": "2.0.0" 143 + "once": "^1.4.0"
301 } 144 }
302 }, 145 },
303 - "ms": { 146 + "es-abstract": {
304 - "version": "2.0.0", 147 + "version": "1.13.0",
305 - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", 148 + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.13.0.tgz",
306 - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" 149 + "integrity": "sha512-vDZfg/ykNxQVwup/8E1BZhVzFfBxs9NqMzGcvIJrqg5k2/5Za2bWo40dK2J1pgLngZ7c+Shh8lwYtLGyrwPutg==",
150 + "requires": {
151 + "es-to-primitive": "^1.2.0",
152 + "function-bind": "^1.1.1",
153 + "has": "^1.0.3",
154 + "is-callable": "^1.1.4",
155 + "is-regex": "^1.0.4",
156 + "object-keys": "^1.0.12"
307 } 157 }
158 + },
159 + "es-to-primitive": {
160 + "version": "1.2.0",
161 + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.0.tgz",
162 + "integrity": "sha512-qZryBOJjV//LaxLTV6UC//WewneB3LcXOL9NP++ozKVXsIIIpm/2c13UDiD9Jp2eThsecw9m3jPqDwTyobcdbg==",
163 + "requires": {
164 + "is-callable": "^1.1.4",
165 + "is-date-object": "^1.0.1",
166 + "is-symbol": "^1.0.2"
308 } 167 }
309 }, 168 },
169 + "eventemitter3": {
170 + "version": "3.1.2",
171 + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-3.1.2.tgz",
172 + "integrity": "sha512-tvtQIeLVHjDkJYnzf2dgVMxfuSGJeM/7UCG17TT4EumTfNtF+0nebF/4zWOIkCreAbtNqhGEboB6BWrwqNaw4Q=="
173 + },
310 "extend": { 174 "extend": {
311 "version": "3.0.2", 175 "version": "3.0.2",
312 "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", 176 "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz",
...@@ -327,48 +191,6 @@ ...@@ -327,48 +191,6 @@
327 "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz", 191 "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz",
328 "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=" 192 "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I="
329 }, 193 },
330 - "file-type": {
331 - "version": "7.7.1",
332 - "resolved": "https://registry.npmjs.org/file-type/-/file-type-7.7.1.tgz",
333 - "integrity": "sha512-bTrKkzzZI6wH+NXhyD3SOXtb2zXTw2SbwI2RxUlRcXVsnN7jNL5hJzVQLYv7FOQhxFkK4XWdAflEaWFpaLLWpQ=="
334 - },
335 - "finalhandler": {
336 - "version": "1.1.2",
337 - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz",
338 - "integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==",
339 - "requires": {
340 - "debug": "2.6.9",
341 - "encodeurl": "~1.0.2",
342 - "escape-html": "~1.0.3",
343 - "on-finished": "~2.3.0",
344 - "parseurl": "~1.3.3",
345 - "statuses": "~1.5.0",
346 - "unpipe": "~1.0.0"
347 - },
348 - "dependencies": {
349 - "debug": {
350 - "version": "2.6.9",
351 - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
352 - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
353 - "requires": {
354 - "ms": "2.0.0"
355 - }
356 - },
357 - "ms": {
358 - "version": "2.0.0",
359 - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
360 - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
361 - }
362 - }
363 - },
364 - "follow-redirects": {
365 - "version": "1.7.0",
366 - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.7.0.tgz",
367 - "integrity": "sha512-m/pZQy4Gj287eNy94nivy5wchN3Kp+Q5WgUPNy5lJSZ3sgkVKSYV/ZChMAQVIgx1SqfZ2zBZtPA2YlXIWxxJOQ==",
368 - "requires": {
369 - "debug": "^3.2.6"
370 - }
371 - },
372 "forever-agent": { 194 "forever-agent": {
373 "version": "0.6.1", 195 "version": "0.6.1",
374 "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", 196 "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz",
...@@ -384,15 +206,10 @@ ...@@ -384,15 +206,10 @@
384 "mime-types": "^2.1.12" 206 "mime-types": "^2.1.12"
385 } 207 }
386 }, 208 },
387 - "forwarded": { 209 + "function-bind": {
388 - "version": "0.1.2", 210 + "version": "1.1.1",
389 - "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz", 211 + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
390 - "integrity": "sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ=" 212 + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A=="
391 - },
392 - "fresh": {
393 - "version": "0.5.2",
394 - "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz",
395 - "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac="
396 }, 213 },
397 "getpass": { 214 "getpass": {
398 "version": "0.1.7", 215 "version": "0.1.7",
...@@ -416,18 +233,19 @@ ...@@ -416,18 +233,19 @@
416 "har-schema": "^2.0.0" 233 "har-schema": "^2.0.0"
417 } 234 }
418 }, 235 },
419 - "http-errors": { 236 + "has": {
420 - "version": "1.7.2", 237 + "version": "1.0.3",
421 - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz", 238 + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
422 - "integrity": "sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==", 239 + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
423 "requires": { 240 "requires": {
424 - "depd": "~1.1.2", 241 + "function-bind": "^1.1.1"
425 - "inherits": "2.0.3",
426 - "setprototypeof": "1.1.1",
427 - "statuses": ">= 1.5.0 < 2",
428 - "toidentifier": "1.0.0"
429 } 242 }
430 }, 243 },
244 + "has-symbols": {
245 + "version": "1.0.0",
246 + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.0.tgz",
247 + "integrity": "sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q="
248 + },
431 "http-signature": { 249 "http-signature": {
432 "version": "1.2.0", 250 "version": "1.2.0",
433 "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", 251 "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz",
...@@ -438,34 +256,47 @@ ...@@ -438,34 +256,47 @@
438 "sshpk": "^1.7.0" 256 "sshpk": "^1.7.0"
439 } 257 }
440 }, 258 },
441 - "iconv-lite": {
442 - "version": "0.4.24",
443 - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz",
444 - "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==",
445 - "requires": {
446 - "safer-buffer": ">= 2.1.2 < 3"
447 - }
448 - },
449 "inherits": { 259 "inherits": {
450 "version": "2.0.3", 260 "version": "2.0.3",
451 "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", 261 "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz",
452 "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" 262 "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4="
453 }, 263 },
454 - "ipaddr.js": { 264 + "is-callable": {
455 - "version": "1.9.0", 265 + "version": "1.1.4",
456 - "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.0.tgz", 266 + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.1.4.tgz",
457 - "integrity": "sha512-M4Sjn6N/+O6/IXSJseKqHoFc+5FdGJ22sXqnjTpdZweHK64MzEPAyQZyEU3R/KRv2GLoa7nNtg/C2Ev6m7z+eA==" 267 + "integrity": "sha512-r5p9sxJjYnArLjObpjA4xu5EKI3CuKHkJXMhT7kwbpUyIFD1n5PMAsoPvWnvtZiNz7LjkYDRZhd7FlI0eMijEA=="
458 }, 268 },
459 - "is-buffer": { 269 + "is-date-object": {
460 - "version": "1.1.6", 270 + "version": "1.0.1",
461 - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", 271 + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.1.tgz",
462 - "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" 272 + "integrity": "sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY="
273 + },
274 + "is-regex": {
275 + "version": "1.0.4",
276 + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.0.4.tgz",
277 + "integrity": "sha1-VRdIm1RwkbCTDglWVM7SXul+lJE=",
278 + "requires": {
279 + "has": "^1.0.1"
280 + }
281 + },
282 + "is-symbol": {
283 + "version": "1.0.2",
284 + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.2.tgz",
285 + "integrity": "sha512-HS8bZ9ox60yCJLH9snBpIwv9pYUAkcuLhSA1oero1UB5y9aiQpRA8y2ex945AOtCZL1lJDeIk3G5LthswI46Lw==",
286 + "requires": {
287 + "has-symbols": "^1.0.0"
288 + }
463 }, 289 },
464 "is-typedarray": { 290 "is-typedarray": {
465 "version": "1.0.0", 291 "version": "1.0.0",
466 "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", 292 "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz",
467 "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=" 293 "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo="
468 }, 294 },
295 + "isarray": {
296 + "version": "1.0.0",
297 + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
298 + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
299 + },
469 "isstream": { 300 "isstream": {
470 "version": "0.1.2", 301 "version": "0.1.2",
471 "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", 302 "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz",
...@@ -502,20 +333,10 @@ ...@@ -502,20 +333,10 @@
502 "verror": "1.10.0" 333 "verror": "1.10.0"
503 } 334 }
504 }, 335 },
505 - "media-typer": { 336 + "lodash": {
506 - "version": "0.3.0", 337 + "version": "4.17.11",
507 - "resolved": "http://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", 338 + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz",
508 - "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=" 339 + "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg=="
509 - },
510 - "merge-descriptors": {
511 - "version": "1.0.1",
512 - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz",
513 - "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E="
514 - },
515 - "methods": {
516 - "version": "1.1.2",
517 - "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz",
518 - "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4="
519 }, 340 },
520 "mime": { 341 "mime": {
521 "version": "1.6.0", 342 "version": "1.6.0",
...@@ -540,77 +361,90 @@ ...@@ -540,77 +361,90 @@
540 "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", 361 "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz",
541 "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" 362 "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg=="
542 }, 363 },
543 - "negotiator": { 364 + "node-telegram-bot-api": {
544 - "version": "0.6.2", 365 + "version": "0.30.0",
545 - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz", 366 + "resolved": "https://registry.npmjs.org/node-telegram-bot-api/-/node-telegram-bot-api-0.30.0.tgz",
546 - "integrity": "sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw==" 367 + "integrity": "sha512-+EeM+fe3Xt81KIPqN3L6s6eK+FK4QaqyDcwCwkY/jqsleERXwwjGlVbf4lJCOZ0uJuF5PfqTmvVNtua7AZfBXg==",
368 + "requires": {
369 + "array.prototype.findindex": "^2.0.2",
370 + "bl": "^1.2.1",
371 + "bluebird": "^3.5.1",
372 + "debug": "^3.1.0",
373 + "depd": "^1.1.1",
374 + "eventemitter3": "^3.0.0",
375 + "file-type": "^3.9.0",
376 + "mime": "^1.6.0",
377 + "pump": "^2.0.0",
378 + "request": "^2.83.0",
379 + "request-promise": "^4.2.2"
380 + },
381 + "dependencies": {
382 + "file-type": {
383 + "version": "3.9.0",
384 + "resolved": "https://registry.npmjs.org/file-type/-/file-type-3.9.0.tgz",
385 + "integrity": "sha1-JXoHg4TR24CHvESdEH1SpSZyuek="
386 + }
387 + }
547 }, 388 },
548 "oauth-sign": { 389 "oauth-sign": {
549 "version": "0.9.0", 390 "version": "0.9.0",
550 "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", 391 "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz",
551 "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==" 392 "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ=="
552 }, 393 },
553 - "on-finished": { 394 + "object-keys": {
554 - "version": "2.3.0", 395 + "version": "1.1.1",
555 - "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", 396 + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz",
556 - "integrity": "sha1-IPEzZIGwg811M3mSoWlxqi2QaUc=", 397 + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA=="
398 + },
399 + "once": {
400 + "version": "1.4.0",
401 + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
402 + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
557 "requires": { 403 "requires": {
558 - "ee-first": "1.1.1" 404 + "wrappy": "1"
559 } 405 }
560 }, 406 },
561 - "parseurl": {
562 - "version": "1.3.3",
563 - "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz",
564 - "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ=="
565 - },
566 - "path-to-regexp": {
567 - "version": "0.1.7",
568 - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz",
569 - "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w="
570 - },
571 "performance-now": { 407 "performance-now": {
572 "version": "2.1.0", 408 "version": "2.1.0",
573 "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", 409 "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz",
574 "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=" 410 "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns="
575 }, 411 },
576 - "proxy-addr": { 412 + "process-nextick-args": {
577 - "version": "2.0.5", 413 + "version": "2.0.0",
578 - "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.5.tgz", 414 + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz",
579 - "integrity": "sha512-t/7RxHXPH6cJtP0pRG6smSr9QJidhB+3kXu0KgXnbGYMgzEnUxRQ4/LDdfOwZEMyIh3/xHb8PX3t+lfL9z+YVQ==", 415 + "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw=="
580 - "requires": {
581 - "forwarded": "~0.1.2",
582 - "ipaddr.js": "1.9.0"
583 - }
584 }, 416 },
585 "psl": { 417 "psl": {
586 "version": "1.1.32", 418 "version": "1.1.32",
587 "resolved": "https://registry.npmjs.org/psl/-/psl-1.1.32.tgz", 419 "resolved": "https://registry.npmjs.org/psl/-/psl-1.1.32.tgz",
588 "integrity": "sha512-MHACAkHpihU/REGGPLj4sEfc/XKW2bheigvHO1dUqjaKigMp1C8+WLQYRGgeKFMsw5PMfegZcaN8IDXK/cD0+g==" 420 "integrity": "sha512-MHACAkHpihU/REGGPLj4sEfc/XKW2bheigvHO1dUqjaKigMp1C8+WLQYRGgeKFMsw5PMfegZcaN8IDXK/cD0+g=="
589 }, 421 },
422 + "pump": {
423 + "version": "2.0.1",
424 + "resolved": "https://registry.npmjs.org/pump/-/pump-2.0.1.tgz",
425 + "integrity": "sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA==",
426 + "requires": {
427 + "end-of-stream": "^1.1.0",
428 + "once": "^1.3.1"
429 + }
430 + },
590 "punycode": { 431 "punycode": {
591 "version": "2.1.1", 432 "version": "2.1.1",
592 "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", 433 "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz",
593 "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==" 434 "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A=="
594 }, 435 },
595 - "qs": { 436 + "readable-stream": {
596 - "version": "6.7.0", 437 + "version": "2.3.6",
597 - "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", 438 + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
598 - "integrity": "sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==" 439 + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
599 - },
600 - "range-parser": {
601 - "version": "1.2.1",
602 - "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz",
603 - "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg=="
604 - },
605 - "raw-body": {
606 - "version": "2.4.0",
607 - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz",
608 - "integrity": "sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q==",
609 "requires": { 440 "requires": {
610 - "bytes": "3.1.0", 441 + "core-util-is": "~1.0.0",
611 - "http-errors": "1.7.2", 442 + "inherits": "~2.0.3",
612 - "iconv-lite": "0.4.24", 443 + "isarray": "~1.0.0",
613 - "unpipe": "1.0.0" 444 + "process-nextick-args": "~2.0.0",
445 + "safe-buffer": "~5.1.1",
446 + "string_decoder": "~1.1.1",
447 + "util-deprecate": "~1.0.1"
614 } 448 }
615 }, 449 },
616 "request": { 450 "request": {
...@@ -647,6 +481,25 @@ ...@@ -647,6 +481,25 @@
647 } 481 }
648 } 482 }
649 }, 483 },
484 + "request-promise": {
485 + "version": "4.2.4",
486 + "resolved": "https://registry.npmjs.org/request-promise/-/request-promise-4.2.4.tgz",
487 + "integrity": "sha512-8wgMrvE546PzbR5WbYxUQogUnUDfM0S7QIFZMID+J73vdFARkFy+HElj4T+MWYhpXwlLp0EQ8Zoj8xUA0he4Vg==",
488 + "requires": {
489 + "bluebird": "^3.5.0",
490 + "request-promise-core": "1.1.2",
491 + "stealthy-require": "^1.1.1",
492 + "tough-cookie": "^2.3.3"
493 + }
494 + },
495 + "request-promise-core": {
496 + "version": "1.1.2",
497 + "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.2.tgz",
498 + "integrity": "sha512-UHYyq1MO8GsefGEt7EprS8UrXsm1TxEvFUX1IMTuSLU2Rh7fTIdFtl8xD7JiEYiWU2dl+NYAjCTksTehQUxPag==",
499 + "requires": {
500 + "lodash": "^4.17.11"
501 + }
502 + },
650 "safe-buffer": { 503 "safe-buffer": {
651 "version": "5.1.2", 504 "version": "5.1.2",
652 "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 505 "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
...@@ -657,59 +510,6 @@ ...@@ -657,59 +510,6 @@
657 "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", 510 "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz",
658 "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" 511 "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
659 }, 512 },
660 - "send": {
661 - "version": "0.17.1",
662 - "resolved": "https://registry.npmjs.org/send/-/send-0.17.1.tgz",
663 - "integrity": "sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==",
664 - "requires": {
665 - "debug": "2.6.9",
666 - "depd": "~1.1.2",
667 - "destroy": "~1.0.4",
668 - "encodeurl": "~1.0.2",
669 - "escape-html": "~1.0.3",
670 - "etag": "~1.8.1",
671 - "fresh": "0.5.2",
672 - "http-errors": "~1.7.2",
673 - "mime": "1.6.0",
674 - "ms": "2.1.1",
675 - "on-finished": "~2.3.0",
676 - "range-parser": "~1.2.1",
677 - "statuses": "~1.5.0"
678 - },
679 - "dependencies": {
680 - "debug": {
681 - "version": "2.6.9",
682 - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
683 - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
684 - "requires": {
685 - "ms": "2.0.0"
686 - },
687 - "dependencies": {
688 - "ms": {
689 - "version": "2.0.0",
690 - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
691 - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
692 - }
693 - }
694 - }
695 - }
696 - },
697 - "serve-static": {
698 - "version": "1.14.1",
699 - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz",
700 - "integrity": "sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg==",
701 - "requires": {
702 - "encodeurl": "~1.0.2",
703 - "escape-html": "~1.0.3",
704 - "parseurl": "~1.3.3",
705 - "send": "0.17.1"
706 - }
707 - },
708 - "setprototypeof": {
709 - "version": "1.1.1",
710 - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz",
711 - "integrity": "sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw=="
712 - },
713 "sshpk": { 513 "sshpk": {
714 "version": "1.16.1", 514 "version": "1.16.1",
715 "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", 515 "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz",
...@@ -726,15 +526,18 @@ ...@@ -726,15 +526,18 @@
726 "tweetnacl": "~0.14.0" 526 "tweetnacl": "~0.14.0"
727 } 527 }
728 }, 528 },
729 - "statuses": { 529 + "stealthy-require": {
730 - "version": "1.5.0", 530 + "version": "1.1.1",
731 - "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", 531 + "resolved": "https://registry.npmjs.org/stealthy-require/-/stealthy-require-1.1.1.tgz",
732 - "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" 532 + "integrity": "sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks="
733 }, 533 },
734 - "toidentifier": { 534 + "string_decoder": {
735 - "version": "1.0.0", 535 + "version": "1.1.1",
736 - "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", 536 + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
737 - "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" 537 + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
538 + "requires": {
539 + "safe-buffer": "~5.1.0"
540 + }
738 }, 541 },
739 "tough-cookie": { 542 "tough-cookie": {
740 "version": "2.4.3", 543 "version": "2.4.3",
...@@ -765,20 +568,6 @@ ...@@ -765,20 +568,6 @@
765 "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", 568 "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz",
766 "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=" 569 "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
767 }, 570 },
768 - "type-is": {
769 - "version": "1.6.18",
770 - "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz",
771 - "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==",
772 - "requires": {
773 - "media-typer": "0.3.0",
774 - "mime-types": "~2.1.24"
775 - }
776 - },
777 - "unpipe": {
778 - "version": "1.0.0",
779 - "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz",
780 - "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw="
781 - },
782 "uri-js": { 571 "uri-js": {
783 "version": "4.2.2", 572 "version": "4.2.2",
784 "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", 573 "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz",
...@@ -787,21 +576,16 @@ ...@@ -787,21 +576,16 @@
787 "punycode": "^2.1.0" 576 "punycode": "^2.1.0"
788 } 577 }
789 }, 578 },
790 - "utils-merge": { 579 + "util-deprecate": {
791 - "version": "1.0.1", 580 + "version": "1.0.2",
792 - "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", 581 + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
793 - "integrity": "sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=" 582 + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
794 }, 583 },
795 "uuid": { 584 "uuid": {
796 "version": "3.3.2", 585 "version": "3.3.2",
797 "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz", 586 "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz",
798 "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==" 587 "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA=="
799 }, 588 },
800 - "vary": {
801 - "version": "1.1.2",
802 - "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz",
803 - "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw="
804 - },
805 "verror": { 589 "verror": {
806 "version": "1.10.0", 590 "version": "1.10.0",
807 "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", 591 "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz",
...@@ -811,6 +595,11 @@ ...@@ -811,6 +595,11 @@
811 "core-util-is": "1.0.2", 595 "core-util-is": "1.0.2",
812 "extsprintf": "^1.2.0" 596 "extsprintf": "^1.2.0"
813 } 597 }
598 + },
599 + "wrappy": {
600 + "version": "1.0.2",
601 + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
602 + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
814 } 603 }
815 } 604 }
816 } 605 }
......
1 { 1 {
2 - "name": "linebot", 2 + "name": "telegrambot",
3 "version": "1.0.0", 3 "version": "1.0.0",
4 "description": "", 4 "description": "",
5 "main": "app.js", 5 "main": "app.js",
6 "scripts": { 6 "scripts": {
7 "test": "echo \"Error: no test specified\" && exit 1", 7 "test": "echo \"Error: no test specified\" && exit 1",
8 - "start": "node ./bin/www" 8 + "start": "node ./app.js"
9 }, 9 },
10 "author": "강수인", 10 "author": "강수인",
11 "license": "MIT", 11 "license": "MIT",
12 "dependencies": { 12 "dependencies": {
13 - "@line/bot-sdk": "^6.7.1", 13 + "node-telegram-bot-api": "^0.30.0",
14 - "express": "^4.17.1",
15 "request": "^2.88.0" 14 "request": "^2.88.0"
16 } 15 }
17 } 16 }
......