discord-ghost-transcript-v13
TypeScript icon, indicating that this package has built-in type declarations

1.0.6 • Public • Published

Ghost Transcript

Introduction

😊 A easy Transcript Message collector that sends in html format.

Installation

npm i discord-ghost-transcript-v13

Options

With Options, you can customize the title, description, date format, date location and the order of messages

Working on Features

Reactions Embeds Downloads Blocks of code File preview for read/write files

Feel free to contribute to this project.

const { fetchTranscript } = require("discord-ghost-transcript-v13");
const { MessageAttachment } = require("discord.js");


//example
const Command = require("../structures/command")
const { fetchTranscript } = require('discord-ghost-transcript-v13');
const Discord = require("discord.js");
module.exports = new Command({
    name: "tscript",
    description: "Sends a message transcript",
    type: "BOTH",
    slashCommandOptions: [],
    permission: "SEND_MESSAGES",
    async run(message){

        console.log()
        fetchTranscript(message, {
            channel: message.channel ,
            numberOfMessages: 20 ,
            inverseArray: true, // order of messages, default is "false"
            dateFormat: "MM/DD/YYYY at HH:mm:ss", // moment date format, default is 'E, d MMM yyyy HH:mm:ss Z'
            dateLocale: "pt-br", // moment locale, default is "en"
            customTitle: `Channel Name: ${message.channel.name}`, // title, default is your guild name
            customDescription: `Channel Description: ${message.channel.topic}`, // description, default is `Transcripted ${numberOfMessages} messages From: ${channel.name}`
        }).then((data) => {
            const file = new Discord.MessageAttachment(data, `${message.channel.name}.html`);
            message.reply({files: [file]});
        });
        
    
    }
});
// it will fetch 5 messages in the current channel with custom options.

Package Sidebar

Install

npm i discord-ghost-transcript-v13

Weekly Downloads

22

Version

1.0.6

License

ISC

Unpacked Size

20.1 kB

Total Files

7

Last publish

Collaborators

  • ghosterzz