mirror of
https://gitlab.com/bignutty/labscore.git
synced 2025-06-09 06:33:05 -04:00
[nextgen/cardstack] add BUTTON_GENERATOR
- support dynamic button resolving - update all commands using dynstack to latest api - add supplemental to wolfram
This commit is contained in:
parent
3a016dde3d
commit
ecaaba9d3c
10 changed files with 356 additions and 176 deletions
|
@ -54,6 +54,7 @@ const Api = Object.freeze({
|
|||
SEARCH_WEATHER: '/search/weather',
|
||||
SEARCH_WIKIHOW: '/search/wikihow',
|
||||
SEARCH_WOLFRAM_ALPHA: '/search/wolfram-alpha',
|
||||
SEARCH_WOLFRAM_SUPPLEMENTAL: '/search/wolfram-supplemental',
|
||||
SEARCH_YOUTUBE: '/search/youtube',
|
||||
|
||||
TTS_IMTRANSLATOR: '/tts/imtranslator',
|
||||
|
|
|
@ -126,7 +126,7 @@ module.exports.googleImages = async function(context, query, nsfw){
|
|||
})
|
||||
}
|
||||
|
||||
module.exports.googleNews = async function(context, query, nsfw){
|
||||
module.exports.googleNews = async function(context, query){
|
||||
return await request(Api.SEARCH_GOOGLE_NEWS, "GET", {}, {
|
||||
q: query
|
||||
})
|
||||
|
@ -232,6 +232,12 @@ module.exports.wolframAlpha = async function(context, query){
|
|||
})
|
||||
}
|
||||
|
||||
module.exports.wolframSupplemental = async function(context, supplementalKey){
|
||||
return await request(Api.SEARCH_WOLFRAM_SUPPLEMENTAL, "GET", {}, {
|
||||
supplemental_key: supplementalKey
|
||||
})
|
||||
}
|
||||
|
||||
module.exports.youtube = async function(context, query, category){
|
||||
return await request(Api.SEARCH_YOUTUBE, "GET", {}, {
|
||||
q: query,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue