은승우

delete google-api app.js

Showing 1 changed file with 0 additions and 30 deletions
......@@ -70,36 +70,6 @@ const client = new line.Client(config);
// register a webhook handler with middleware
// about the middleware, please refer to doc
// Creates a client
/* google-api
var vision = require('google-vision-api-client');
var requtil = vision.requtil;
//Prepare your service account from trust preview certificated project
var jsonfile = '/home/ubuntu/a/LINEBOT/googlevisionapikey.json';
//Initialize the api
vision.init(jsonfile);
//Build the request payloads
var d = requtil.createRequests().addRequest(
requtil.createRequest('/home/ubuntu/a/LINEBOT/photo/Fancy-TWICE.jpg')
.withFeature('TEXT_DETECTION', 3)
.build());
//Do query to the api server
vision.query(d, function(e, r, d){
if(e) console.log('ERROR:', e);
console.log(JSON.stringify(d));
});
*/
app.post('/webhook', line.middleware(config), (req, res) => {
......