tournament-helper-bot/commands/utility/ping.js

11 lines
374 B
JavaScript

const { SlashCommandBuilder, MessageFlags } = require('discord.js');
module.exports = {
data: new SlashCommandBuilder()
.setName('ping')
.setDescription('Проверить, жив ли бот'),
async execute(interaction) {
await interaction.reply({ content: `Pong!\nWebsocket heartbeat: ${interaction.client.ws.ping}ms.`, flags: MessageFlags.Ephemeral });
},
};