This commit is contained in:
bignutty 2024-11-17 01:52:18 +01:00
parent 79b096efb4
commit fcb25fc639
7 changed files with 563 additions and 6 deletions

View file

@ -34,6 +34,8 @@ const Api = Object.freeze({
SEARCH_GOOGLE: '/search/google',
SEARCH_GOOGLE_IMAGES: '/search/google-images',
SEARCH_LYRICS: '/search/lyrics',
SEARCH_MAPS: '/search/maps',
SEARCH_MAPS_SUPPLEMENTAL: '/search/maps-supplemental',
SEARCH_QUORA: '/search/quora',
SEARCH_QUORA_RESULT: '/search/quora-result',
SEARCH_REDDIT: '/search/reddit',

View file

@ -104,12 +104,6 @@ module.exports.googleVisionWebDetection = async function(context, url){
})
}
module.exports.lyrics = async function(context, query){
return await request(Api.SEARCH_LYRICS, "GET", {}, {
q: query
})
}
module.exports.google = async function(context, query, nsfw){
return await request(Api.SEARCH_GOOGLE, "GET", {}, {
q: query,
@ -124,6 +118,24 @@ module.exports.googleImages = async function(context, query, nsfw){
})
}
module.exports.lyrics = async function(context, query){
return await request(Api.SEARCH_LYRICS, "GET", {}, {
q: query
})
}
module.exports.maps = async function(context, query){
return await request(Api.SEARCH_MAPS, "GET", {}, {
q: query
})
}
module.exports.mapsSupplemental = async function(context, supplementalKey){
return await request(Api.SEARCH_MAPS_SUPPLEMENTAL, "GET", {}, {
supplemental_key: supplementalKey
})
}
module.exports.quora = async function(context, query){
return await request(Api.SEARCH_QUORA, "GET", {}, {
q: query