Page cover

earth-europeEmbed Variables

Custom response function created for our command handler.

const embed = Utility.embed({
  author: "Hello {name}", // Author name
  authorIcon: "url", // URL for the author icon
  title: "Hello", // Embed title
  description: "Hello World",
  variables: {
    name: "Michael"
  }
})
const embed = Utility.embed({
  author: "Hello {name}", // Author name
  authorIcon: "{url}", // URL for the author icon
  title: "Hello", // Embed title
  description: "Hello World", // Embed description
  variables: {
    name: "Michael",
    url: "example url here",
    ...Utility.userVariables(member), // Returns default user variables
    ...Utility.channelVariables(channel), // Returns default channel variables
    ...Utility.roleVariables(role), // Returns default role variables
    ...Utility.serverVariables(guild), // Returns default guild variables
    ...Utility.botVariables(client) // Returns default bot variables
  }
});

send(type, moi, { content: "", embeds: [embed] })

The send function is only used in the command section. If you need a response for an interaction or message create event, use interaction.reply() interaction.channel.send() or message.channel.send() , message.reply().

Last updated