Added API key authentication.
This commit is contained in:
@@ -23,7 +23,6 @@ module.exports = {
|
||||
maxQueryTime: 10000,
|
||||
},
|
||||
timeout: 5000,
|
||||
graphiql: false,
|
||||
pool: {
|
||||
min: 0,
|
||||
max: 20,
|
||||
@@ -64,6 +63,12 @@ module.exports = {
|
||||
usernameLength: [2, 24],
|
||||
usernamePattern: /^[a-zA-Z0-9_-]+$/,
|
||||
},
|
||||
apiAccess: {
|
||||
graphqlEnabled: true,
|
||||
keySize: 24, // bytes
|
||||
keyLimit: 5, // max keys per user
|
||||
keyCooldown: 1, // minutes between key generation
|
||||
},
|
||||
psa: {
|
||||
text: 'Welcome to traxxx!', // html enabled
|
||||
type: 'notice', // notice, alert
|
||||
|
||||
Reference in New Issue
Block a user