은승우

Update app.js

Showing 1 changed file with 2 additions and 2 deletions
...@@ -95,7 +95,7 @@ async function handleEvent(event) { ...@@ -95,7 +95,7 @@ async function handleEvent(event) {
95 95
96 96
97 var cheerio = require('cheerio'); 97 var cheerio = require('cheerio');
98 - 98 + var imageUrl='oss.chatbot.bu.to/photo/1.png';
99 var uriBase = 'https://koreacentral.api.cognitive.microsoft.com/vision/v2.1/ocr'; 99 var uriBase = 'https://koreacentral.api.cognitive.microsoft.com/vision/v2.1/ocr';
100 var options = { 100 var options = {
101 uri: uriBase, 101 uri: uriBase,
...@@ -108,7 +108,7 @@ async function handleEvent(event) { ...@@ -108,7 +108,7 @@ async function handleEvent(event) {
108 'Content-Type': 'application/json', 108 'Content-Type': 'application/json',
109 'Ocp-Apim-Subscription-Key': '979dc5d63344438fa4701c62feebb7dc' 109 'Ocp-Apim-Subscription-Key': '979dc5d63344438fa4701c62feebb7dc'
110 }, 110 },
111 - body: '{"url":"oss.chatbot.bu.to/photo/1.png" }' 111 + body: '{"url": ' + '"' + imageUrl + '"}',
112 }; 112 };
113 console.log(body); 113 console.log(body);
114 request.post(options, function (error, response, body) { 114 request.post(options, function (error, response, body) {
......