-
Notifications
You must be signed in to change notification settings - Fork 24
/
botfile.js
73 lines (64 loc) · 2.12 KB
/
botfile.js
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
module.exports = {
/**
* Postgres configuration
*/
postgres: {
enabled: process.env.DATABASE === 'postgres',
host: process.env.PG_HOST || '127.0.0.1',
port: process.env.PG_PORT || 5432,
user: process.env.PG_USER || '',
password: process.env.PG_PASSWORD || '',
database: process.env.PG_DB || ''
},
/**
* where the content is stored
* you can access this property from `bp.dataLocation`
*/
dataDir: process.env.BOTPRESS_DATA_DIR || "./data",
port: 3000,
modulesConfigDir: process.env.BOTPRESS_CONFIG_DIR || "./modules_config",
disableFileLogs: false,
notification: {
file: 'notifications.json',
maxLength: 50
},
log: {
file: 'bot.log',
maxSize: 1e6 // 1mb
},
/**
* Access control of admin pabel
*/
login: {
enabled: process.env.NODE_ENV === 'production',
tokenExpiry: "6 hours",
password: process.env.BOTPRESS_PASSWORD || "password",
maxAttempts: 3,
resetAfter: 5 * 60 * 10000 // 5 minutes
},
config: {
'botpress-messenger': {
greetingMessage: '🔥 Hey {{user_first_name}}, my name is Boost. I was born to show people how easy it is to create a basic bot with botpress, they never expected me to literally change peoples lives!\n\nAre you ready to:\n- Take charge of your life\n- Work out harder at the gym\n- Achieve more at work.\n\nDon\'t you just want to be great? 💪\n',
persistentMenu: true,
persistentMenuItems: [
{ type: 'postback',
title: '💪 Gym Motivation',
value: 'GET_VIDEO_GYM' },
{ type: 'postback',
title: '🔥 Work Motivation',
value: 'GET_VIDEO_WORK' },
{ type: 'postback',
title: '😇 Life Motivation',
value: 'GET_VIDEO_LIFE' },
{ type: 'postback',
title: '👉 Manage subscriptions',
value: 'MANAGE_SUBSCRIPTIONS' },
{ type: 'postback',
title: '⭐ This bot is Open-source',
value: 'OPEN_SOURCE' }
],
trustedDomains: [ 'https://youtube.com' ],
autoRespondGetStarted: false
}
}
}