Showing
3 changed files
with
195 additions
and
71 deletions
| ... | @@ -4,22 +4,17 @@ const options = { method: 'GET', headers: { Accept: 'application/json' } }; | ... | @@ -4,22 +4,17 @@ const options = { method: 'GET', headers: { Accept: 'application/json' } }; |
| 4 | const express = require('express'); | 4 | const express = require('express'); |
| 5 | const app = express(); | 5 | const app = express(); |
| 6 | const { Coin } = require("./models/Coin"); | 6 | const { Coin } = require("./models/Coin"); |
| 7 | -const {User}=require('./models/User'); | 7 | +const { User } = require('./models/User'); |
| 8 | - | ||
| 9 | require("dotenv").config(); | 8 | require("dotenv").config(); |
| 10 | 9 | ||
| 11 | -const crypto=require('crypto'); | 10 | +const crypto = require('crypto'); |
| 12 | -const queryEncode=require('querystring').encode; | 11 | +const queryEncode = require('querystring').encode; |
| 13 | - | 12 | +const request = require('request-promise-native'); |
| 14 | - | 13 | +// const request = require('request') |
| 15 | -console.log("test"); | 14 | +const { v4 } = require("uuid") |
| 16 | -console.log("test2"); | ||
| 17 | -console.log("tesst3"); | ||
| 18 | - | ||
| 19 | -const request = require('request') | ||
| 20 | -const {v4} = require("uuid") | ||
| 21 | const sign = require('jsonwebtoken').sign | 15 | const sign = require('jsonwebtoken').sign |
| 22 | - | 16 | +var krw_balance=60000; |
| 17 | +var divided_money=krw_balance/10; | ||
| 23 | 18 | ||
| 24 | var sort_info = new Array(); | 19 | var sort_info = new Array(); |
| 25 | const mongoose = require('mongoose'); | 20 | const mongoose = require('mongoose'); |
| ... | @@ -39,7 +34,7 @@ const access_key = process.env.access_key; | ... | @@ -39,7 +34,7 @@ const access_key = process.env.access_key; |
| 39 | const secret_key = process.env.secret_key; | 34 | const secret_key = process.env.secret_key; |
| 40 | const server_url = "https://api.upbit.com" | 35 | const server_url = "https://api.upbit.com" |
| 41 | 36 | ||
| 42 | -function get_asset(){ | 37 | +function get_asset() { |
| 43 | const payload = { | 38 | const payload = { |
| 44 | access_key: access_key, | 39 | access_key: access_key, |
| 45 | nonce: v4(), | 40 | nonce: v4(), |
| ... | @@ -48,16 +43,16 @@ function get_asset(){ | ... | @@ -48,16 +43,16 @@ function get_asset(){ |
| 48 | const options = { | 43 | const options = { |
| 49 | method: "GET", | 44 | method: "GET", |
| 50 | url: server_url + "/v1/accounts", | 45 | url: server_url + "/v1/accounts", |
| 51 | - headers: {Authorization: `Bearer ${token}`}, | 46 | + headers: { Authorization: `Bearer ${token}` }, |
| 52 | } | 47 | } |
| 53 | - return new Promise(resolve=>{ | 48 | + return new Promise(resolve => { |
| 54 | - request(options,function(err,res,body){ | 49 | + request(options, function (err, res, body) { |
| 55 | if (err) throw new Error(err) | 50 | if (err) throw new Error(err) |
| 56 | // test=res.json(); | 51 | // test=res.json(); |
| 57 | - data=JSON.parse(body); | 52 | + data = JSON.parse(body); |
| 58 | // console.log(data[0].currency) | 53 | // console.log(data[0].currency) |
| 59 | - data.filter(function(item){ | 54 | + data.filter(function (item) { |
| 60 | - if(item.currency=="PLA"){ | 55 | + if (item.currency == "PLA") { |
| 61 | resolve(item); | 56 | resolve(item); |
| 62 | } | 57 | } |
| 63 | }) | 58 | }) |
| ... | @@ -78,7 +73,7 @@ async function get_marketName() { | ... | @@ -78,7 +73,7 @@ async function get_marketName() { |
| 78 | }) | 73 | }) |
| 79 | return data; | 74 | return data; |
| 80 | } | 75 | } |
| 81 | -async function transaction_coin(coin_name,side,volume,price,ord_type){ | 76 | +async function transaction_coin(coin_name, side, volume, price, ord_type) { |
| 82 | const body = { | 77 | const body = { |
| 83 | market: coin_name, | 78 | market: coin_name, |
| 84 | side: side, | 79 | side: side, |
| ... | @@ -89,29 +84,31 @@ async function transaction_coin(coin_name,side,volume,price,ord_type){ | ... | @@ -89,29 +84,31 @@ async function transaction_coin(coin_name,side,volume,price,ord_type){ |
| 89 | //시장가 매수인 경우 price를 얼마치 살건지 입력 | 84 | //시장가 매수인 경우 price를 얼마치 살건지 입력 |
| 90 | //시장가 매도인경우 volume에 몇개를 팔건지 입력 | 85 | //시장가 매도인경우 volume에 몇개를 팔건지 입력 |
| 91 | const query = queryEncode(body) | 86 | const query = queryEncode(body) |
| 92 | - | 87 | + |
| 93 | const hash = crypto.createHash('sha512') | 88 | const hash = crypto.createHash('sha512') |
| 94 | const queryHash = hash.update(query, 'utf-8').digest('hex') | 89 | const queryHash = hash.update(query, 'utf-8').digest('hex') |
| 95 | - | 90 | + |
| 96 | const payload = { | 91 | const payload = { |
| 97 | access_key: access_key, | 92 | access_key: access_key, |
| 98 | nonce: v4(), | 93 | nonce: v4(), |
| 99 | query_hash: queryHash, | 94 | query_hash: queryHash, |
| 100 | query_hash_alg: 'SHA512', | 95 | query_hash_alg: 'SHA512', |
| 101 | } | 96 | } |
| 102 | - | 97 | + |
| 103 | const token = sign(payload, secret_key) | 98 | const token = sign(payload, secret_key) |
| 104 | - | 99 | + |
| 105 | const options = { | 100 | const options = { |
| 106 | method: "POST", | 101 | method: "POST", |
| 107 | url: server_url + "/v1/orders", | 102 | url: server_url + "/v1/orders", |
| 108 | - headers: {Authorization: `Bearer ${token}`}, | 103 | + headers: { Authorization: `Bearer ${token}` }, |
| 109 | json: body | 104 | json: body |
| 110 | } | 105 | } |
| 111 | - request(options, (error, response, body) => { | 106 | + await request(options).then(async (result)=>{ |
| 112 | - if (error) throw new Error(error) | 107 | + console.log(result.body); |
| 113 | - console.log(body) | 108 | + const user = new User({ krw_balance: 100, market: "KRW-BTC", count: 1, avg_price: 100 }); |
| 114 | - }) | 109 | + await user.save().then(() => { isuser = true }) |
| 110 | + },).catch((err)=>{console.log(err.error)}) | ||
| 111 | + | ||
| 115 | } | 112 | } |
| 116 | async function get_marketInfo() { | 113 | async function get_marketInfo() { |
| 117 | //각 암호화폐 정보 조회 | 114 | //각 암호화폐 정보 조회 |
| ... | @@ -179,36 +176,47 @@ async function get_candle(minute, market) { | ... | @@ -179,36 +176,47 @@ async function get_candle(minute, market) { |
| 179 | return candle; | 176 | return candle; |
| 180 | } | 177 | } |
| 181 | async function check_coin(t1) { | 178 | async function check_coin(t1) { |
| 182 | - for (var i = 0; i < t1.length; i++) { | 179 | + User.find().then(async (user_data) => { |
| 183 | - var candle = await get_candle(5, t1[i]); | 180 | + if (user_data.length == 0) { |
| 184 | - await Coin.findOne({ name: candle[0].market }).then((result) => { | 181 | + var isuser = false; |
| 185 | - //가격이 떨어졌을때 | 182 | + for (var i = 0; i < t1.length; i++) { |
| 186 | - if (result.current_price > candle[0].trade_price) { | 183 | + if (!isuser) { |
| 187 | - Coin.findOneAndUpdate({ name: candle[0].market }, { current_price: candle[0].trade_price, $inc: { count: 1 } }, { new: true }, (err, result) => { | 184 | + var candle = await get_candle(5, t1[i]); |
| 188 | - if (err) { | 185 | + await Coin.findOne({ name: candle[0].market }).then(async (result) => { |
| 189 | - console.log(err); | 186 | + //가격이 떨어졌을때 |
| 190 | - } else { | 187 | + if (result.current_price > candle[0].trade_price) { |
| 191 | - console.log("***" + result.korean_name + "은(는)" + result.count * 5 + "분 동안 하락중"); | 188 | + Coin.findOneAndUpdate({ name: candle[0].market }, { current_price: candle[0].trade_price, $inc: { count: 1 } }, { new: true }, (err, result) => { |
| 192 | - if(count>=3){ | 189 | + if (err) { |
| 193 | - transaction_coin(result.name,"bid",null,"얼마치 살건지","price"); | 190 | + console.log(err); |
| 191 | + } else { | ||
| 192 | + console.log("***" + result.korean_name + "은(는)" + result.count * 5 + "분 동안 하락중"); | ||
| 193 | + if (result.count >= 3) { | ||
| 194 | + // transaction_coin(result.name,"bid",null,divided_money,"price"); | ||
| 195 | + } | ||
| 196 | + } | ||
| 197 | + }) | ||
| 198 | + }//그대로 이거나 올랐을때 | ||
| 199 | + else { | ||
| 200 | + await Coin.findOneAndUpdate({ name: candle[0].market }, { current_price: candle[0].trade_price, count: 0 }, { new: true }).then(async (result) => { | ||
| 201 | + //특정 조건... | ||
| 202 | + const user = new User({ krw_balance: 100, market: "KRW-BTC", count: 1, avg_price: 100 }); | ||
| 203 | + await user.save().then(() => { isuser = true }) | ||
| 204 | + // transaction_coin(result.name,"ask","몇개를 팔건지",null,"market"); | ||
| 205 | + console.log(result.korean_name + "은(는)" + result.count * 5 + "분 동안 상승 혹은 정체중"); | ||
| 206 | + }) | ||
| 194 | } | 207 | } |
| 195 | - } | 208 | + }) |
| 196 | - }) | 209 | + }else { |
| 197 | - }//그대로 이거나 올랐을때 | 210 | + console.log("메롱"); |
| 198 | - else { | 211 | + } |
| 199 | - Coin.findOneAndUpdate({ name: candle[0].market }, { current_price: candle[0].trade_price, count: 0 }, { new: true }, (err, result) => { | ||
| 200 | - if (err) { | ||
| 201 | - console.log(err); | ||
| 202 | - } else { | ||
| 203 | - //특정 조건... | ||
| 204 | - transaction_coin(result.name,"ask","몇개를 팔건지",null,"market"); | ||
| 205 | - console.log(result.korean_name + "은(는)" + result.count * 5 + "분 동안 상승 혹은 정체중"); | ||
| 206 | - } | ||
| 207 | - }) | ||
| 208 | - | ||
| 209 | } | 212 | } |
| 210 | - }) | 213 | + } else { |
| 211 | - } | 214 | + console.log(result); |
| 215 | + } | ||
| 216 | + }).catch((err) => { | ||
| 217 | + console.log(err); | ||
| 218 | + }) | ||
| 219 | + | ||
| 212 | } | 220 | } |
| 213 | async function latest_repeat(t1) { | 221 | async function latest_repeat(t1) { |
| 214 | await Coin.find().sort({ tid: 1 }).then(result => { | 222 | await Coin.find().sort({ tid: 1 }).then(result => { |
| ... | @@ -220,27 +228,27 @@ async function latest_repeat(t1) { | ... | @@ -220,27 +228,27 @@ async function latest_repeat(t1) { |
| 220 | let today = new Date(); | 228 | let today = new Date(); |
| 221 | let minutes = today.getMinutes(); | 229 | let minutes = today.getMinutes(); |
| 222 | let seconds = today.getSeconds(); | 230 | let seconds = today.getSeconds(); |
| 223 | - // if (seconds == 0) { | 231 | + if (seconds == 0) { |
| 224 | - if (minutes == 0 && seconds == 0) { | 232 | + // if (minutes == 0 && seconds == 0) { |
| 225 | clearInterval(check_time); | 233 | clearInterval(check_time); |
| 226 | sort_info = (await sort_data()); | 234 | sort_info = (await sort_data()); |
| 227 | (await refresh_db()); | 235 | (await refresh_db()); |
| 228 | console.log("현재 시간은 " + today.toLocaleTimeString()); | 236 | console.log("현재 시간은 " + today.toLocaleTimeString()); |
| 229 | - var count=0; | 237 | + var count = 0; |
| 230 | - let coin=setInterval(async () => { | 238 | + let coin = setInterval(async () => { |
| 231 | let today = new Date(); | 239 | let today = new Date(); |
| 232 | - let minutes=today.getMinutes(); | 240 | + let minutes = today.getMinutes(); |
| 233 | - let seconds=today.getSeconds(); | 241 | + let seconds = today.getSeconds(); |
| 234 | console.log("현재 시간은 " + today.toLocaleTimeString()); | 242 | console.log("현재 시간은 " + today.toLocaleTimeString()); |
| 235 | await (check_coin(t1).then(count++)); | 243 | await (check_coin(t1).then(count++)); |
| 236 | //1시간마다 db 최신화... | 244 | //1시간마다 db 최신화... |
| 237 | - if(count==12){ | 245 | + if (count == 12) { |
| 238 | - count=0; | 246 | + count = 0; |
| 239 | - sort_info=(await sort_data()); | 247 | + sort_info = (await sort_data()); |
| 240 | (await refresh_db()); | 248 | (await refresh_db()); |
| 241 | console.log("db최신화"); | 249 | console.log("db최신화"); |
| 242 | } | 250 | } |
| 243 | - }, 60000*5); | 251 | + }, 600 * 5); |
| 244 | } | 252 | } |
| 245 | }, 1000); | 253 | }, 1000); |
| 246 | } | 254 | } |
| ... | @@ -248,8 +256,9 @@ app.listen(5000, async () => { | ... | @@ -248,8 +256,9 @@ app.listen(5000, async () => { |
| 248 | console.log('server start') | 256 | console.log('server start') |
| 249 | //coin 이름,가격,거래대금 저장 , DB 최신화 1시간마다 반복 | 257 | //coin 이름,가격,거래대금 저장 , DB 최신화 1시간마다 반복 |
| 250 | //5분마다 현재 가격 가져와서 db랑 비교후 매수 매도 기준잡기 | 258 | //5분마다 현재 가격 가져와서 db랑 비교후 매수 매도 기준잡기 |
| 251 | - var t1 = new Array(); | 259 | + // var t1 = new Array(); |
| 252 | - test_data=await (latest_repeat(t1)); | 260 | + // test_data = await (latest_repeat(t1)); |
| 253 | //계좌 정보 db 최신화 | 261 | //계좌 정보 db 최신화 |
| 254 | - console.log(await get_asset()); | 262 | + // console.log(await get_asset()); |
| 263 | + await transaction_coin("KRW-BTC","bid",null,divided_money,"price"); | ||
| 255 | }) | 264 | }) |
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
| ... | @@ -17,6 +17,8 @@ | ... | @@ -17,6 +17,8 @@ |
| 17 | "node-fetch": "^3.0.0", | 17 | "node-fetch": "^3.0.0", |
| 18 | "querystring": "^0.2.1", | 18 | "querystring": "^0.2.1", |
| 19 | "request": "^2.88.2", | 19 | "request": "^2.88.2", |
| 20 | + "request-promise": "^4.2.6", | ||
| 21 | + "request-promise-native": "^1.0.9", | ||
| 20 | "requests": "^0.3.0", | 22 | "requests": "^0.3.0", |
| 21 | "uuid": "^8.3.2" | 23 | "uuid": "^8.3.2" |
| 22 | }, | 24 | }, |
| ... | @@ -229,6 +231,11 @@ | ... | @@ -229,6 +231,11 @@ |
| 229 | "node": ">=8" | 231 | "node": ">=8" |
| 230 | } | 232 | } |
| 231 | }, | 233 | }, |
| 234 | + "node_modules/bluebird": { | ||
| 235 | + "version": "3.7.2", | ||
| 236 | + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", | ||
| 237 | + "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==" | ||
| 238 | + }, | ||
| 232 | "node_modules/body-parser": { | 239 | "node_modules/body-parser": { |
| 233 | "version": "1.19.0", | 240 | "version": "1.19.0", |
| 234 | "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", | 241 | "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", |
| ... | @@ -1420,6 +1427,11 @@ | ... | @@ -1420,6 +1427,11 @@ |
| 1420 | "xhr-status": "1.0.x" | 1427 | "xhr-status": "1.0.x" |
| 1421 | } | 1428 | } |
| 1422 | }, | 1429 | }, |
| 1430 | + "node_modules/lodash": { | ||
| 1431 | + "version": "4.17.21", | ||
| 1432 | + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", | ||
| 1433 | + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" | ||
| 1434 | + }, | ||
| 1423 | "node_modules/lodash.includes": { | 1435 | "node_modules/lodash.includes": { |
| 1424 | "version": "4.3.0", | 1436 | "version": "4.3.0", |
| 1425 | "resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz", | 1437 | "resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz", |
| ... | @@ -2080,6 +2092,55 @@ | ... | @@ -2080,6 +2092,55 @@ |
| 2080 | "node": ">= 6" | 2092 | "node": ">= 6" |
| 2081 | } | 2093 | } |
| 2082 | }, | 2094 | }, |
| 2095 | + "node_modules/request-promise": { | ||
| 2096 | + "version": "4.2.6", | ||
| 2097 | + "resolved": "https://registry.npmjs.org/request-promise/-/request-promise-4.2.6.tgz", | ||
| 2098 | + "integrity": "sha512-HCHI3DJJUakkOr8fNoCc73E5nU5bqITjOYFMDrKHYOXWXrgD/SBaC7LjwuPymUprRyuF06UK7hd/lMHkmUXglQ==", | ||
| 2099 | + "deprecated": "request-promise has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142", | ||
| 2100 | + "dependencies": { | ||
| 2101 | + "bluebird": "^3.5.0", | ||
| 2102 | + "request-promise-core": "1.1.4", | ||
| 2103 | + "stealthy-require": "^1.1.1", | ||
| 2104 | + "tough-cookie": "^2.3.3" | ||
| 2105 | + }, | ||
| 2106 | + "engines": { | ||
| 2107 | + "node": ">=0.10.0" | ||
| 2108 | + }, | ||
| 2109 | + "peerDependencies": { | ||
| 2110 | + "request": "^2.34" | ||
| 2111 | + } | ||
| 2112 | + }, | ||
| 2113 | + "node_modules/request-promise-core": { | ||
| 2114 | + "version": "1.1.4", | ||
| 2115 | + "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.4.tgz", | ||
| 2116 | + "integrity": "sha512-TTbAfBBRdWD7aNNOoVOBH4pN/KigV6LyapYNNlAPA8JwbovRti1E88m3sYAwsLi5ryhPKsE9APwnjFTgdUjTpw==", | ||
| 2117 | + "dependencies": { | ||
| 2118 | + "lodash": "^4.17.19" | ||
| 2119 | + }, | ||
| 2120 | + "engines": { | ||
| 2121 | + "node": ">=0.10.0" | ||
| 2122 | + }, | ||
| 2123 | + "peerDependencies": { | ||
| 2124 | + "request": "^2.34" | ||
| 2125 | + } | ||
| 2126 | + }, | ||
| 2127 | + "node_modules/request-promise-native": { | ||
| 2128 | + "version": "1.0.9", | ||
| 2129 | + "resolved": "https://registry.npmjs.org/request-promise-native/-/request-promise-native-1.0.9.tgz", | ||
| 2130 | + "integrity": "sha512-wcW+sIUiWnKgNY0dqCpOZkUbF/I+YPi+f09JZIDa39Ec+q82CpSYniDp+ISgTTbKmnpJWASeJBPZmoxH84wt3g==", | ||
| 2131 | + "deprecated": "request-promise-native has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142", | ||
| 2132 | + "dependencies": { | ||
| 2133 | + "request-promise-core": "1.1.4", | ||
| 2134 | + "stealthy-require": "^1.1.1", | ||
| 2135 | + "tough-cookie": "^2.3.3" | ||
| 2136 | + }, | ||
| 2137 | + "engines": { | ||
| 2138 | + "node": ">=0.12.0" | ||
| 2139 | + }, | ||
| 2140 | + "peerDependencies": { | ||
| 2141 | + "request": "^2.34" | ||
| 2142 | + } | ||
| 2143 | + }, | ||
| 2083 | "node_modules/request/node_modules/qs": { | 2144 | "node_modules/request/node_modules/qs": { |
| 2084 | "version": "6.5.2", | 2145 | "version": "6.5.2", |
| 2085 | "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", | 2146 | "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", |
| ... | @@ -2275,6 +2336,14 @@ | ... | @@ -2275,6 +2336,14 @@ |
| 2275 | "node": ">= 0.6" | 2336 | "node": ">= 0.6" |
| 2276 | } | 2337 | } |
| 2277 | }, | 2338 | }, |
| 2339 | + "node_modules/stealthy-require": { | ||
| 2340 | + "version": "1.1.1", | ||
| 2341 | + "resolved": "https://registry.npmjs.org/stealthy-require/-/stealthy-require-1.1.1.tgz", | ||
| 2342 | + "integrity": "sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks=", | ||
| 2343 | + "engines": { | ||
| 2344 | + "node": ">=0.10.0" | ||
| 2345 | + } | ||
| 2346 | + }, | ||
| 2278 | "node_modules/string-width": { | 2347 | "node_modules/string-width": { |
| 2279 | "version": "4.2.3", | 2348 | "version": "4.2.3", |
| 2280 | "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", | 2349 | "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", |
| ... | @@ -2825,6 +2894,11 @@ | ... | @@ -2825,6 +2894,11 @@ |
| 2825 | "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", | 2894 | "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", |
| 2826 | "dev": true | 2895 | "dev": true |
| 2827 | }, | 2896 | }, |
| 2897 | + "bluebird": { | ||
| 2898 | + "version": "3.7.2", | ||
| 2899 | + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", | ||
| 2900 | + "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==" | ||
| 2901 | + }, | ||
| 2828 | "body-parser": { | 2902 | "body-parser": { |
| 2829 | "version": "1.19.0", | 2903 | "version": "1.19.0", |
| 2830 | "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", | 2904 | "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", |
| ... | @@ -3737,6 +3811,11 @@ | ... | @@ -3737,6 +3811,11 @@ |
| 3737 | "xhr-status": "1.0.x" | 3811 | "xhr-status": "1.0.x" |
| 3738 | } | 3812 | } |
| 3739 | }, | 3813 | }, |
| 3814 | + "lodash": { | ||
| 3815 | + "version": "4.17.21", | ||
| 3816 | + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", | ||
| 3817 | + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" | ||
| 3818 | + }, | ||
| 3740 | "lodash.includes": { | 3819 | "lodash.includes": { |
| 3741 | "version": "4.3.0", | 3820 | "version": "4.3.0", |
| 3742 | "resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz", | 3821 | "resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz", |
| ... | @@ -4258,6 +4337,35 @@ | ... | @@ -4258,6 +4337,35 @@ |
| 4258 | } | 4337 | } |
| 4259 | } | 4338 | } |
| 4260 | }, | 4339 | }, |
| 4340 | + "request-promise": { | ||
| 4341 | + "version": "4.2.6", | ||
| 4342 | + "resolved": "https://registry.npmjs.org/request-promise/-/request-promise-4.2.6.tgz", | ||
| 4343 | + "integrity": "sha512-HCHI3DJJUakkOr8fNoCc73E5nU5bqITjOYFMDrKHYOXWXrgD/SBaC7LjwuPymUprRyuF06UK7hd/lMHkmUXglQ==", | ||
| 4344 | + "requires": { | ||
| 4345 | + "bluebird": "^3.5.0", | ||
| 4346 | + "request-promise-core": "1.1.4", | ||
| 4347 | + "stealthy-require": "^1.1.1", | ||
| 4348 | + "tough-cookie": "^2.3.3" | ||
| 4349 | + } | ||
| 4350 | + }, | ||
| 4351 | + "request-promise-core": { | ||
| 4352 | + "version": "1.1.4", | ||
| 4353 | + "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.4.tgz", | ||
| 4354 | + "integrity": "sha512-TTbAfBBRdWD7aNNOoVOBH4pN/KigV6LyapYNNlAPA8JwbovRti1E88m3sYAwsLi5ryhPKsE9APwnjFTgdUjTpw==", | ||
| 4355 | + "requires": { | ||
| 4356 | + "lodash": "^4.17.19" | ||
| 4357 | + } | ||
| 4358 | + }, | ||
| 4359 | + "request-promise-native": { | ||
| 4360 | + "version": "1.0.9", | ||
| 4361 | + "resolved": "https://registry.npmjs.org/request-promise-native/-/request-promise-native-1.0.9.tgz", | ||
| 4362 | + "integrity": "sha512-wcW+sIUiWnKgNY0dqCpOZkUbF/I+YPi+f09JZIDa39Ec+q82CpSYniDp+ISgTTbKmnpJWASeJBPZmoxH84wt3g==", | ||
| 4363 | + "requires": { | ||
| 4364 | + "request-promise-core": "1.1.4", | ||
| 4365 | + "stealthy-require": "^1.1.1", | ||
| 4366 | + "tough-cookie": "^2.3.3" | ||
| 4367 | + } | ||
| 4368 | + }, | ||
| 4261 | "requests": { | 4369 | "requests": { |
| 4262 | "version": "0.3.0", | 4370 | "version": "0.3.0", |
| 4263 | "resolved": "https://registry.npmjs.org/requests/-/requests-0.3.0.tgz", | 4371 | "resolved": "https://registry.npmjs.org/requests/-/requests-0.3.0.tgz", |
| ... | @@ -4411,6 +4519,11 @@ | ... | @@ -4411,6 +4519,11 @@ |
| 4411 | "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", | 4519 | "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", |
| 4412 | "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" | 4520 | "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" |
| 4413 | }, | 4521 | }, |
| 4522 | + "stealthy-require": { | ||
| 4523 | + "version": "1.1.1", | ||
| 4524 | + "resolved": "https://registry.npmjs.org/stealthy-require/-/stealthy-require-1.1.1.tgz", | ||
| 4525 | + "integrity": "sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks=" | ||
| 4526 | + }, | ||
| 4414 | "string-width": { | 4527 | "string-width": { |
| 4415 | "version": "4.2.3", | 4528 | "version": "4.2.3", |
| 4416 | "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", | 4529 | "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", | ... | ... |
| ... | @@ -22,6 +22,8 @@ | ... | @@ -22,6 +22,8 @@ |
| 22 | "node-fetch": "^3.0.0", | 22 | "node-fetch": "^3.0.0", |
| 23 | "querystring": "^0.2.1", | 23 | "querystring": "^0.2.1", |
| 24 | "request": "^2.88.2", | 24 | "request": "^2.88.2", |
| 25 | + "request-promise": "^4.2.6", | ||
| 26 | + "request-promise-native": "^1.0.9", | ||
| 25 | "requests": "^0.3.0", | 27 | "requests": "^0.3.0", |
| 26 | "uuid": "^8.3.2" | 28 | "uuid": "^8.3.2" |
| 27 | }, | 29 | }, | ... | ... |
-
Please register or login to post a comment