This file contains 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
let word = 'red' | |
let endpoint = 'https://en.wiktionary.org/api/rest_v1/page/definition' | |
let url = `${endpoint}/${word}` | |
let resObj = await fetch(url, {orgin:'test'}) | |
let res = await resObj.json() | |
let output = '' | |
for (let meaning of res.en) { | |
output += meaning.partOfSpeech |
This Gist was automatically created by Carbide, a free online programming environment.
This file contains 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
"use strict"; | |
const functions = require("firebase-functions"); | |
const { WebhookClient } = require("dialogflow-fulfillment"); | |
const { Card, Suggestion } = require("dialogflow-fulfillment"); | |
const axios = require('axios'); | |
const fetch = require('node-fetch'); | |
process.env.DEBUG = "dialogflow:debug"; // enables lib debugging statements |
This Gist was automatically created by Carbide, a free online programming environment.
You can view a live, interactive version of this Gist here.(http://alpha.trycarbide.com/anonymous/fb9538f683af592c1b9e53d498a2f608).
This file contains 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 points = []; | |
for (var i = -50; i < 50; i++) { | |
points.push(Math.sin(i / 2)); | |
} | |
points |
This Gist was automatically created by Carbide, a free online programming environment.
This Gist was automatically created by Carbide, a free online programming environment.