A command to surf Instagram! To get started you need to create a slash command in the command builder with a string option. And you're done! Have fun!
const lib = require('lib')({token: process.env.STDLIB_SECRET_TOKEN});
let search = context.params.event.data.options[0].value;
let result = `https://www.instagram.com/${search}`
let message = context.params.event.content;
await lib.discord.channels['@0.0.6'].messages.create({
channel_id: `${context.params.event.channel_id}`,
content: ``,
embed: {
title: ` `,
description: ``,
color: 0xff0000, //red you can change that
author: {
name: `Instagram search results`,
},
fields: [
{
name: `You searched: ||${search}||`,
value: `Link: [click here](https://www.instagram.com/${search})`,
},
],
footer: {
text: `Requested by ${context.params.event.member.user.username}#${context.params.event.member.user.discriminator}`,
},
timestamp: `${new Date().toISOString()}`,
},
});