-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.js
More file actions
39 lines (28 loc) · 1.05 KB
/
index.js
File metadata and controls
39 lines (28 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
const Insta = require('@androz2091/insta.js');
const Discord = require('discord.js');
const {
webhook_id,
webhook_token
} = require('./config.json')
const client = new Insta.Client();
const webhookClient = new Discord.WebhookClient(webhook_id, webhook_token);
client.on('connected', () =>
{
console.log(`Logged in as ${client.user.username}`);
});
client.on('messageCreate', (message) =>
{
if (message.author.id === client.user.id) return
const embed1 = new Discord.MessageEmbed()
.setDescription(`<:instagram:798775886668103680> **یک نفر برای شما پیامی جدید را در اینستاگرام ارسال کرد** <:instagram:798775886668103680>`)
.addField("> 📧 نام فرستنده", `> ${message.author.username}`)
.addField("> 🆔 ایدی فرستنده پیام", `> ${message.author.id}`)
.addField("> 📄 پیام", `> **${message.content || 'عکس'}**`)
.setColor('#833AB4')
.setTimestamp();
webhookClient.send(
{
embeds: [embed1]
});
});
client.login('Username_IG', 'Password_IG');