Closed ZacharyFolk closed 7 months ago
https://rapidapi.com/wh-iterabb-it-wh-iterabb-it-default/api/fortune-cookie4
const axios = require('axios');
const options = { method: 'GET', url: 'https://fortune-cookie4.p.rapidapi.com/slack', headers: { 'X-RapidAPI-Key': '3ebbe997d6msh3b4919d38255054p1e80f3jsnf3bb495dc785', 'X-RapidAPI-Host': 'fortune-cookie4.p.rapidapi.com' } };
try { const response = await axios.request(options); console.log(response.data); } catch (error) { console.error(error); }
Use fortune command, could preferably use a fortune API or create an array to select one from random.