an example of instagram automation, either using puppeteer or using instagram-private-api. enjoy!
- Clone this project
git clone https://github.com/rashgaroth/instagram-api-automation.git
cd instagram-api-automation
- Install depedencies
yarn install
ornpm install
- Setup config
- go to
src/modules/instagram/config.js
there will be:
module.exports = {
creds: [
{
username: '<your_username>', // change this with your ig's username
password: '<your_password>', // change this with your ig's password
dms: [
{
username: 'trizal_pp', // change this with your username destination
text: 'Test ke 1' // change this with your direct message text
},
]
}
],
selectors: {
firstPerson: `x9f619 xjbqb8w x78zum5 x168nmei x13lgxp2 x5pf9jr xo71vjh x1pi30zi x1swvt13 xwib8y2 x1y1aw1k x1uhb9sk x1plvlek xryxfnj x1c4vz4f x2lah0s xdt5ytf xqjyukv x1qjc9v5 x1oa3qoh x1nhvcw1`,
nextBtn: `_acan _acao _acas _acav _aj1-`,
chatInput: `x9f619 xjbqb8w x78zum5 x168nmei x13lgxp2 x5pf9jr xo71vjh xw3qccf x1n2onr6 x1plvlek xryxfnj x1iyjqo2 x2lwn1j xeuugli xdt5ytf xqjyukv x1qjc9v5 x1oa3qoh x1nhvcw1`,
btnSend: `x1i10hfl xjqpnuy xa49m3k xqeqjp1 x2hbi6w xdl72j9 x2lah0s xe8uvvx xdj266r x11i5rnm xat24cr x1mh8g0r x2lwn1j xeuugli x1hl2dhg xggy1nq x1ja2u2z x1t137rt x1q0g3np x1lku1pv x1a2a7pz x6s0dn4 xjyslct x1ejq31n xd10rxx x1sy0etr x17r0tee x9f619 x1ypdohk x1i0vuye xwhw2v2 xl56j7k x17ydfre x1f6kntn x2b8uid xlyipyv x87ps6o x14atkfc x1d5wrs8 x972fbf xcfux6l x1qhh985 xm0m39n xm3z3ea x1x8b98j x131883w x16mih1h xt0psk2 xt7dq6l xexx8yu x4uap5 x18d9i69 xkhd6sd x1n2onr6 xjbqb8w x1n5bzlp x173jzuc x1yc6y37`
}
}
- run the project
- run
yarn start
if you want to use puppeteer - run
yarn start:api
if you want to use instagram private api