Last active
September 9, 2017 13:53
-
-
Save rizky/2bc4011b44a295cb4d5675dde1f21609 to your computer and use it in GitHub Desktop.
search-sign
This file contains hidden or 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
var request = require('request'); | |
language = 'LSF' | |
search = 'right' | |
var options = { | |
url: `https://isara.search.windows.net/indexes/isara/docs?api-version=2015-02-28&searchMode=all&queryType=full&search=language:${language}%20AND%20speaker:${search}%20OR%20${search}*&api-key=F6621A479929D2E2B331E35CC3520462`, | |
headers: { | |
'Access-Token': 'request' | |
} | |
}; | |
function callback(error, response, body) { | |
if (!error && response.statusCode == 200) { | |
var info = JSON.parse(body); | |
console.log(options.url); | |
console.log(info); | |
} | |
} | |
request(options, callback); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment