ClarityCafe / Clara

A general purpose Node.JS bot for Discord.
BSD 3-Clause "New" or "Revised" License
35 stars 8 forks source link

New config structure #159

Closed sr229 closed 6 years ago

sr229 commented 6 years ago

Due to the immense ammount of JSON entries in the config, I decided to group them by sub-objects to promote clarity.

Proposed Model


{
 "authMain" : {
       "discordToken": "",
       "youtubeApiToken": ""
    },
   "authAnalytics": {
         "discordBotsPWKey": "",
         "discordBotsOrgKey": "",
    },
   "appConfig": {
         "instances": 1,
         "todokete": "setsuna sani wa"
   }
}
Ovyerus commented 6 years ago

Alternative model, propsed in the Discord server

{
   "keys": {
       // Any API keys.
       "youtube": "",
       "soundcloud": "",
       "botlists": {
           "dbots": "",
           "dbl": ""
       }
   },
   "development": {
       // Various debugging/development stuff.
       "debug": true,
       "promiseWarnings": false
   },
   "options": {
       // Main bot options
       "ownerID": "",
       "token": "",
       "redisURL": "",
       "mainPrefix": "",
       "maxShards": 1
   },
   "discord": {
       // Any Discord-specific stuff like games
        "game": {
            "url": "",
            "type": 0,
            "name": "with memes"
        }
   }
}
sr229 commented 6 years ago

imstead of calling them keys we should call them tokens afaik

Ovyerus commented 6 years ago

👍

Ovyerus commented 6 years ago

Added in face80f