Skip to content

Latest commit

 

History

History
41 lines (34 loc) · 1.02 KB

README.md

File metadata and controls

41 lines (34 loc) · 1.02 KB
config.js

const configDB = {
    dbHost: "localhost",
    dbPort: "27017",
    dbName: "discord-checkin",
    dbPass: "123456",
};

const configDiscord = {
    tokenBot: '<TOKEN BOT HERE>',
    botName: 'YOU NAME BOT',
    botId: 'YOU BOT ID',
};

  • This case, I used cloud.mongodb.com be cluster database.
index.js

// Database
mongoose.connect(`mongodb+srv://${configDB.dbHost}:${configDB.dbPass}@cluster0-coptech-bot-discord-rsv4f.mongodb.net/${configDB.dbName}?retryWrites=true&w=majority`, { useNewUrlParser: true, useUnifiedTopology: true});
  • This case, use mongodb compass community | credit
mongoose.connect(`mongodb://${configDB.dbHost}:${configDB.dbPort}/${configDB.dbName}`, { useNewUrlParser: true, useUnifiedTopology: true })

discord-bot-features

  • Check-in
  • Check-out
  • NoSQL used MongoDB

Next update

  • store.steampowered.com
  • star wars movie infomation api
  • iss location tracker

thank & credit