Compare commits

..

407 commits

Author SHA1 Message Date
greenkeeper[bot]
2cc1642960 chore(package): update lockfile packages/default.gbui/package-lock.json 2018-12-20 01:56:24 +00:00
greenkeeper[bot]
0589de3c7c fix(package): update react-dom to version 16.7.0 2018-12-20 01:56:17 +00:00
greenkeeper[bot]
6c903e6663 fix(package): update react to version 16.7.0 2018-12-20 01:56:13 +00:00
Rodrigo
4263cd7629 chore(release): 1.2.1 [skip ci]
## [1.2.1](https://github.com/pragmatismo-io/BotServer/compare/1.2.0...1.2.1) (2018-12-18)

### Bug Fixes

* **kb:** Fix in Faq and Menu dialogs. ([6ba8c09](https://github.com/pragmatismo-io/BotServer/commit/6ba8c09))
* **startup:** Startup improved and more checks added. ([5d6c60e](https://github.com/pragmatismo-io/BotServer/commit/5d6c60e))
* **webchat:** Sync versions and MSFT strategy. ([238c0bf](https://github.com/pragmatismo-io/BotServer/commit/238c0bf))
2018-12-18 16:36:57 +00:00
40e48cd9a4
Merge pull request #51 from rodrigorodriguez/master
Update webchat to v4.
2018-12-18 14:31:42 -02:00
6ba8c0993f fix(kb): Fix in Faq and Menu dialogs. 2018-12-18 14:24:02 -02:00
238c0bfb8c fix(webchat): Sync versions and MSFT strategy. 2018-12-18 14:12:38 -02:00
5d6c60ed6d fix(startup): Startup improved and more checks added. 2018-12-18 13:50:35 -02:00
Rodrigo
4501ddaf94 chore(release): 1.2.0 [skip ci]
# [1.2.0](https://github.com/pragmatismo-io/BotServer/compare/1.1.1...1.2.0) (2018-12-13)

### Features

* **webchat:** Update of webchat to the newer version 4. ([0270a8e](https://github.com/pragmatismo-io/BotServer/commit/0270a8e))
2018-12-13 18:53:01 +00:00
9cdb0259af
Merge pull request #44 from rodrigorodriguez/master
feat(webchat): Update of webchat to the newer version 4.
2018-12-13 16:48:21 -02:00
47f28e3d08
Update SAMPLES.md
[ci skip]
2018-12-13 12:52:31 -02:00
0270a8ef40 feat(webchat): Update of webchat to the newer version 4. 2018-12-12 20:40:33 -02:00
Rodrigo Rodriguez
8490f5ed06
Update README.md
[skip ci]
2018-12-09 11:32:34 -02:00
Rodrigo Rodriguez
487089da7d
Update README.md
[ci-skip]
2018-12-09 11:29:18 -02:00
Rodrigo
ce3b105066 chore(release): 1.1.1 [skip ci]
## [1.1.1](https://github.com/pragmatismo-io/BotServer/compare/1.1.0...1.1.1) (2018-12-08)

### Bug Fixes

* **package:** update csv-parse to version 4.1.0 ([a606ef1](https://github.com/pragmatismo-io/BotServer/commit/a606ef1))
2018-12-08 09:57:47 +00:00
6aedca38fe
Merge pull request #40 from pragmatismo-io/greenkeeper/csv-parse-4.1.0
Update csv-parse to the latest version 🚀
2018-12-08 07:53:16 -02:00
greenkeeper[bot]
769b3772c3 chore(package): update lockfile package-lock.json 2018-12-06 21:50:38 +00:00
greenkeeper[bot]
a606ef1869 fix(package): update csv-parse to version 4.1.0 2018-12-06 21:50:34 +00:00
Rodrigo
4e52349588 chore(release): 1.1.0 [skip ci]
# [1.1.0](https://github.com/pragmatismo-io/BotServer/compare/1.0.8...1.1.0) (2018-12-06)

### Bug Fixes

* **CI:** default.gbui compilation issues. ([7a11919](https://github.com/pragmatismo-io/BotServer/commit/7a11919))
* **CI:** Migrating CI logic to package.json. ([8ee048f](https://github.com/pragmatismo-io/BotServer/commit/8ee048f))
* **core:** Bot boot logic being fixed. ([1761e06](https://github.com/pragmatismo-io/BotServer/commit/1761e06))
* **core:** Bot Server is runnable again after refactory. ([9379dec](https://github.com/pragmatismo-io/BotServer/commit/9379dec))
* **core:** Loaded dynamically a .js file containing converted VBA dialogs. ([3f32e48](https://github.com/pragmatismo-io/BotServer/commit/3f32e48))
* **core:** Moved logic from app to core. ([c1db8be](https://github.com/pragmatismo-io/BotServer/commit/c1db8be))
* **default.gbui:** Removing warnings. ([02ed085](https://github.com/pragmatismo-io/BotServer/commit/02ed085))
* **gbdialog:** Renamed alpha command to alpha-VBA added documentation files. ([9cd66b8](https://github.com/pragmatismo-io/BotServer/commit/9cd66b8))
* **gbdialog:** Support for multiples hear blocks. ([3bb9d65](https://github.com/pragmatismo-io/BotServer/commit/3bb9d65))
* **gbdialog:** Trying to save context. ([ce04290](https://github.com/pragmatismo-io/BotServer/commit/ce04290))
* **gbdialog:** Updating packages to latest versions and sync *-lock file. ([dcafb7a](https://github.com/pragmatismo-io/BotServer/commit/dcafb7a))
* **gbdialog:** VBA hear must be a wrapper call. ([6915d58](https://github.com/pragmatismo-io/BotServer/commit/6915d58))
* **gbdialog:** VBA is running financial simulations. ([9fb431c](https://github.com/pragmatismo-io/BotServer/commit/9fb431c))
* **gbdialog:** VBA is running. ([2dd359a](https://github.com/pragmatismo-io/BotServer/commit/2dd359a))
* **gbdialog:** VBA loop done - one thing left to automate: Hear wrapper. ([776fe03](https://github.com/pragmatismo-io/BotServer/commit/776fe03))
* **package:** update azure-arm-resource to version 7.2.1 ([4e72507](https://github.com/pragmatismo-io/BotServer/commit/4e72507))
* **package:** update botlib to version 0.1.7 ([8205599](https://github.com/pragmatismo-io/BotServer/commit/8205599))
* **package:** update csv-parse to version 4.0.0 ([3fb5a9a](https://github.com/pragmatismo-io/BotServer/commit/3fb5a9a))
* **package:** update marked to version 0.5.2 ([405fc96](https://github.com/pragmatismo-io/BotServer/commit/405fc96))
* **package:** update pragmatismo-io-framework to version 1.0.19 ([67c2ce7](https://github.com/pragmatismo-io/BotServer/commit/67c2ce7))
* **tests:** Disabling VM tests tentative for now. ([9d5a9c6](https://github.com/pragmatismo-io/BotServer/commit/9d5a9c6))

### Features

* **gbdialog:** The first VBA code is run. ([f0a0cd3](https://github.com/pragmatismo-io/BotServer/commit/f0a0cd3))
* **scripting:** First code changes to VBA implementation. ([09715bc](https://github.com/pragmatismo-io/BotServer/commit/09715bc))
2018-12-06 13:23:34 +00:00
Rodrigo Rodriguez (pragmatismo.io)
9d5a9c694a fix(tests): Disabling VM tests tentative for now. 2018-12-06 11:20:05 -02:00
17ac3681b8
Update GBLoginPlayer.js 2018-12-06 11:07:15 -02:00
0349caaf79
Update GBLoginPlayer.js 2018-12-06 11:02:08 -02:00
415bcf3097
Update GBMarkdownPlayer.js 2018-12-06 11:01:31 -02:00
bd77b1c3ac
Update GBUIApp.js 2018-12-06 10:55:22 -02:00
9ea490a5db
Merge pull request #39 from rodrigorodriguez/vba-alpha
Vba alpha
2018-12-06 10:48:05 -02:00
bebe7e8761
Merge branch 'master' into vba-alpha 2018-12-06 10:47:53 -02:00
Rodrigo Rodriguez (pragmatismo.io)
02ed08508d fix(default.gbui): Removing warnings. 2018-12-06 10:45:16 -02:00
Rodrigo Rodriguez (pragmatismo.io)
dcafb7acf9 fix(gbdialog): Updating packages to latest versions and sync *-lock file. 2018-12-06 10:32:31 -02:00
8ff69b73e2
Merge branch 'master' into vba-alpha 2018-12-06 10:24:49 -02:00
Rodrigo Rodriguez (pragmatismo.io)
9cd66b8fac fix(gbdialog): Renamed alpha command to alpha-VBA added documentation files. 2018-12-06 10:16:28 -02:00
cde174fb19
Merge pull request #32 from pragmatismo-io/greenkeeper/@types/sequelize-4.27.31
Update @types/sequelize to the latest version 🚀
2018-12-05 18:17:39 -02:00
a755371181
Merge pull request #33 from pragmatismo-io/greenkeeper/azure-arm-resource-7.2.1
Update azure-arm-resource to the latest version 🚀
2018-12-05 18:17:29 -02:00
6b68812246
Merge pull request #34 from pragmatismo-io/greenkeeper/tslint-microsoft-contrib-6.0.0
Update tslint-microsoft-contrib to the latest version 🚀
2018-12-05 18:17:20 -02:00
e24c45715a
Merge pull request #35 from pragmatismo-io/greenkeeper/botlib-0.1.7
Update botlib to the latest version 🚀
2018-12-05 18:17:08 -02:00
d326031437
Merge pull request #37 from pragmatismo-io/greenkeeper/pragmatismo-io-framework-1.0.19
Update pragmatismo-io-framework to the latest version 🚀
2018-12-05 18:16:54 -02:00
greenkeeper[bot]
35638b5ab9 chore(package): update lockfile package-lock.json 2018-12-05 15:16:07 +00:00
greenkeeper[bot]
67c2ce78c2 fix(package): update pragmatismo-io-framework to version 1.0.19 2018-12-05 15:16:03 +00:00
98fd3d2adf
Update README.md 2018-12-03 15:16:42 -02:00
239394a8dc
Update README.md 2018-12-03 15:15:43 -02:00
4ebd04a660
Add files via upload 2018-12-03 14:54:35 -02:00
f7a6aae0a6
Add files via upload 2018-12-03 14:50:33 -02:00
dfa30f882c
Add files via upload 2018-12-03 14:49:46 -02:00
ef81f6d098
Add files via upload 2018-12-03 14:48:20 -02:00
cf2454c74f
Add files via upload 2018-12-03 14:47:31 -02:00
2b871000e6
Update README.md 2018-12-03 14:43:57 -02:00
Rodrigo Rodriguez (pragmatismo.io)
9fb431ce2f fix(gbdialog): VBA is running financial simulations. 2018-12-02 21:39:36 -02:00
Rodrigo Rodriguez (pragmatismo.io)
2dd359a344 fix(gbdialog): VBA is running. 2018-12-02 19:59:27 -02:00
Rodrigo Rodriguez (pragmatismo.io)
3bb9d652fd fix(gbdialog): Support for multiples hear blocks. 2018-12-01 23:01:42 -02:00
Rodrigo Rodriguez (pragmatismo.io)
6915d58db1 fix(gbdialog): VBA hear must be a wrapper call. 2018-12-01 20:48:08 -02:00
Rodrigo Rodriguez (pragmatismo.io)
776fe03503 fix(gbdialog): VBA loop done - one thing left to automate: Hear wrapper. 2018-12-01 17:31:57 -02:00
Rodrigo Rodriguez (pragmatismo.io)
ce04290fcd fix(gbdialog): Trying to save context. 2018-12-01 14:38:08 -02:00
greenkeeper[bot]
82055992bb fix(package): update botlib to version 0.1.7 2018-12-01 14:43:05 +00:00
greenkeeper[bot]
52ba0543da chore(package): update tslint-microsoft-contrib to version 6.0.0 2018-12-01 07:45:32 +00:00
Rodrigo Rodriguez (pragmatismo.io)
f0a0cd36be feat(gbdialog): The first VBA code is run. 2018-11-30 17:30:48 -02:00
Rodrigo Rodriguez (pragmatismo.io)
9379dec1b0 fix(core): Bot Server is runnable again after refactory. 2018-11-30 11:55:44 -02:00
Rodrigo Rodriguez (pragmatismo.io)
3f32e48fad fix(core): Loaded dynamically a .js file containing converted VBA dialogs. 2018-11-28 17:08:06 -02:00
Rodrigo Rodriguez (pragmatismo.io)
1761e06061 fix(core): Bot boot logic being fixed. 2018-11-27 22:56:11 -02:00
Rodrigo Rodriguez (pragmatismo.io)
c1db8be0c0 fix(core): Moved logic from app to core. 2018-11-26 15:54:34 -02:00
Rodrigo Rodriguez (pragmatismo.io)
09715bcfc0 feat(scripting): First code changes to VBA implementation. 2018-11-26 14:09:09 -02:00
8804928cf2
Update README.md 2018-11-23 09:57:52 -02:00
01391a0a0c
Update README.md 2018-11-23 09:37:31 -02:00
22ef759cdc
Update README.md 2018-11-22 14:23:11 -02:00
6ea9826947
Update README.md 2018-11-21 09:55:47 -02:00
greenkeeper[bot]
0d6b7dae83 chore(package): update lockfile package-lock.json 2018-11-20 22:18:35 +00:00
greenkeeper[bot]
4e7250788d fix(package): update azure-arm-resource to version 7.2.1 2018-11-20 22:18:31 +00:00
greenkeeper[bot]
c90e4eb301 chore(package): update lockfile package-lock.json 2018-11-20 18:36:07 +00:00
greenkeeper[bot]
641f003d9f chore(package): update @types/sequelize to version 4.27.31 2018-11-20 18:36:04 +00:00
70fa0f6150
Merge pull request #31 from pragmatismo-io/greenkeeper/marked-0.5.2
Update marked to the latest version 🚀
2018-11-20 14:05:51 -02:00
c8edae4d8a
Merge pull request #30 from pragmatismo-io/greenkeeper/csv-parse-4.0.0
Update csv-parse to the latest version 🚀
2018-11-20 14:02:39 -02:00
greenkeeper[bot]
0e229bed9a chore(package): update lockfile package-lock.json 2018-11-20 00:09:19 +00:00
greenkeeper[bot]
405fc96eae fix(package): update marked to version 0.5.2 2018-11-20 00:09:16 +00:00
0788bc8d96
Merge pull request #1 from pragmatismo-io/master
Migrating to fork instead of main
2018-11-19 12:26:35 -02:00
Rodrigo Rodriguez
75fef24b7e
Update README.md 2018-11-19 10:04:28 -02:00
Rodrigo Rodriguez
fe14fc6508
Update README.md 2018-11-19 10:02:33 -02:00
greenkeeper[bot]
a0e8eced51 chore(package): update lockfile package-lock.json 2018-11-19 10:57:12 +00:00
greenkeeper[bot]
3fb5a9adc8 fix(package): update csv-parse to version 4.0.0 2018-11-19 10:57:08 +00:00
Rodrigo Rodriguez (pragmatismo.io)
7a119198f8 fix(CI): default.gbui compilation issues. 2018-11-18 22:03:46 -02:00
Rodrigo Rodriguez (pragmatismo.io)
aeb43b9ed5 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-18 21:29:09 -02:00
Rodrigo Rodriguez (pragmatismo.io)
8ee048f68e fix(CI): Migrating CI logic to package.json. 2018-11-18 21:28:26 -02:00
Rodrigo
aba0ff7fcf chore(release): 1.0.8 [skip ci]
## [1.0.8](https://github.com/pragmatismo-io/BotServer/compare/1.0.7...1.0.8) (2018-11-18)

### Bug Fixes

* **docs:** Video thumbnail update to raw picture URL. ([564b394](https://github.com/pragmatismo-io/BotServer/commit/564b394))
2018-11-18 22:01:34 +00:00
Rodrigo Rodriguez (pragmatismo.io)
0884c63bc8 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-18 20:00:03 -02:00
Rodrigo Rodriguez (pragmatismo.io)
564b39411e fix(docs): Video thumbnail update to raw picture URL. 2018-11-18 19:59:24 -02:00
Rodrigo Rodriguez
f230b82eef
Update CHANGELOG.md 2018-11-18 19:37:15 -02:00
Rodrigo
f8e3fda796 chore(release): 1.0.7 [skip ci]
## [1.0.7](https://github.com/pragmatismo-io/BotServer/compare/1.0.6...1.0.7) (2018-11-18)

### Bug Fixes

* **config:** CHANGELOG generator fixing. ([ac18782](https://github.com/pragmatismo-io/BotServer/commit/ac18782))
2018-11-18 21:35:47 +00:00
Rodrigo Rodriguez (pragmatismo.io)
2f593d0335 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-18 19:34:12 -02:00
Rodrigo Rodriguez (pragmatismo.io)
ac18782480 fix(config): CHANGELOG generator fixing. 2018-11-18 19:33:15 -02:00
Rodrigo
128b28905c chore(release): 1.0.6 [skip ci]
## [1.0.6](https://github.com/pragmatismo-io/BotServer/compare/1.0.5...1.0.6) (2018-11-18)

### Bug Fixes

* **config:** CI fixed, now improving. ([46daec8](https://github.com/pragmatismo-io/BotServer/commit/46daec8))
2018-11-18 21:24:50 +00:00
Rodrigo Rodriguez (pragmatismo.io)
2fd9e9b24a Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-18 19:23:26 -02:00
Rodrigo Rodriguez (pragmatismo.io)
46daec8ca5 fix(config): CI fixed, now improving. 2018-11-18 19:23:09 -02:00
Rodrigo
d4d0036c72 chore(release): 1.0.5 [skip ci]
## [1.0.5](https://github.com/pragmatismo-io/BotServer/compare/1.0.4...1.0.5) (2018-11-18)

### Bug Fixes

* **config:** Try to fix CI. ([780a177](https://github.com/pragmatismo-io/BotServer/commit/780a177))
* **config:** Try to fix CI. ([240e905](https://github.com/pragmatismo-io/BotServer/commit/240e905))
* **config:** Try to fix CI. ([ae8e2bc](https://github.com/pragmatismo-io/BotServer/commit/ae8e2bc))
2018-11-18 20:47:19 +00:00
Rodrigo Rodriguez (pragmatismo.io)
780a177979 fix(config): Try to fix CI. 2018-11-18 18:46:23 -02:00
Rodrigo Rodriguez (pragmatismo.io)
240e90502f fix(config): Try to fix CI. 2018-11-18 17:03:24 -02:00
Rodrigo Rodriguez (pragmatismo.io)
ae8e2bc161 fix(config): Try to fix CI. 2018-11-18 16:26:11 -02:00
Rodrigo Rodriguez (pragmatismo.io)
684ca40e1d fix(config): Try to fix CI. 2018-11-18 14:45:54 -02:00
Rodrigo Rodriguez (pragmatismo.io)
06955b3cc3 fix(config): Try to fix CI. 2018-11-18 14:37:43 -02:00
Rodrigo Rodriguez (pragmatismo.io)
e8d3603679 fix(config): Try to fix CI. 2018-11-18 14:30:12 -02:00
Rodrigo Rodriguez (pragmatismo.io)
6b4ac4dde2 fix(config): Try to fix CI. 2018-11-18 14:19:21 -02:00
Rodrigo Rodriguez (pragmatismo.io)
1a0e9697bc Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-18 14:04:20 -02:00
Rodrigo Rodriguez (pragmatismo.io)
d415e0fc1c fix(config): Try to fix CI. 2018-11-18 14:03:33 -02:00
Rodrigo Rodriguez
8a315a20a9
Update README.md 2018-11-18 13:57:59 -02:00
Rodrigo Rodriguez (pragmatismo.io)
d8e9e6b531 fix(config): Try to fix CI. 2018-11-18 12:41:45 -02:00
Rodrigo Rodriguez (pragmatismo.io)
700f5ed9ac fix(config): always load config first. 2018-11-17 09:33:39 -02:00
Rodrigo Rodriguez (pragmatismo.io)
0ce86fce2c Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-17 08:53:04 -02:00
Rodrigo Rodriguez (pragmatismo.io)
e430532e66 fix(code): Improvements on CODE_OF_CONDUCT and prettify. 2018-11-17 08:52:16 -02:00
ed7f870151
Merge pull request #26 from pragmatismo-io/greenkeeper/semantic-release-15.12.0
Update semantic-release to the latest version 🚀
2018-11-16 10:45:21 -02:00
268b7f7069
Merge pull request #27 from pragmatismo-io/greenkeeper/azure-arm-website-5.7.0
Update azure-arm-website to the latest version 🚀
2018-11-16 10:45:12 -02:00
242427f4f5
Merge pull request #28 from pragmatismo-io/greenkeeper/azure-arm-resource-7.2.0
Update azure-arm-resource to the latest version 🚀
2018-11-16 10:44:46 -02:00
greenkeeper[bot]
2a9777897d chore(package): update lockfile package-lock.json 2018-11-15 17:36:19 +00:00
greenkeeper[bot]
ec0da6bed3 fix(package): update azure-arm-resource to version 7.2.0 2018-11-15 17:36:16 +00:00
greenkeeper[bot]
b06d5ec063 chore(package): update lockfile package-lock.json 2018-11-14 21:56:55 +00:00
greenkeeper[bot]
601add3a0f fix(package): update azure-arm-website to version 5.7.0 2018-11-14 21:56:50 +00:00
greenkeeper[bot]
b8b5b3f059 chore(package): update lockfile package-lock.json 2018-11-14 20:35:52 +00:00
greenkeeper[bot]
769c15b9b4 chore(package): update semantic-release to version 15.12.0 2018-11-14 20:35:48 +00:00
Rodrigo Rodriguez
d60cbe7cc8
Update README.md 2018-11-13 11:49:48 -02:00
Rodrigo Rodriguez
65b6589433
Update README.md 2018-11-12 20:51:05 -02:00
Rodrigo Rodriguez
a1c2ad6a78
Update README.md 2018-11-12 20:45:40 -02:00
Rodrigo Rodriguez (pragmatismo.io)
518aa5c6b3 fix(config): Updating semantic versioning settings. 2018-11-12 20:34:37 -02:00
Rodrigo Rodriguez (pragmatismo.io)
f19a946b9e fix(config): Updating semantic versioning settings. 2018-11-12 20:28:47 -02:00
Rodrigo Rodriguez
ca3947b0a8
Update README.md 2018-11-12 20:23:59 -02:00
2da1c06739
Merge pull request #23 from pragmatismo-io/greenkeeper/semantic-release-15.11.0
Update semantic-release to the latest version 🚀
2018-11-12 20:07:36 -02:00
Rodrigo Rodriguez
4820e2abf8
Update README.md 2018-11-12 20:05:08 -02:00
Rodrigo Rodriguez (pragmatismo.io)
b17c5c0360 fix(doc): contributing and security information. 2018-11-12 20:01:09 -02:00
Rodrigo Rodriguez (pragmatismo.io)
65255a43b0 fix(ci): semantic release plugins. 2018-11-12 18:55:50 -02:00
Rodrigo Rodriguez (pragmatismo.io)
35aec11fda fix(ci): semantic release plugins. 2018-11-12 18:51:13 -02:00
Rodrigo Rodriguez (pragmatismo.io)
09b19159f8 fix(ci): semantic release plugins. 2018-11-12 18:46:05 -02:00
greenkeeper[bot]
8500b3c2c4 chore(package): update lockfile package-lock.json 2018-11-12 20:32:59 +00:00
greenkeeper[bot]
b6075a7ab3 chore(package): update semantic-release to version 15.11.0 2018-11-12 20:32:54 +00:00
Rodrigo Rodriguez (pragmatismo.io)
898f16a65a fix(ci): semantic release plugins. 2018-11-12 18:05:38 -02:00
Rodrigo Rodriguez (pragmatismo.io)
d4999fb2d9 fix(ci): semantic release plugins. 2018-11-12 17:58:02 -02:00
Rodrigo Rodriguez (pragmatismo.io)
b15fda5025 fix(ci): semantic release plugins. 2018-11-12 17:47:24 -02:00
Rodrigo Rodriguez (pragmatismo.io)
38f47b0cfa fix(ci): semantic release plugins. 2018-11-12 17:21:32 -02:00
Rodrigo Rodriguez (pragmatismo.io)
08fccb79cb fix(ci): semantic release plugins. 2018-11-12 17:11:21 -02:00
Rodrigo Rodriguez (pragmatismo.io)
44d8a3a4d6 fix(ci): semantic release plugins. 2018-11-12 17:08:12 -02:00
Rodrigo Rodriguez (pragmatismo.io)
bfaceb871a fix(ci): semantic release plugins. 2018-11-12 17:06:15 -02:00
Rodrigo Rodriguez (pragmatismo.io)
5588e1b64a fix(ci): semantic release plugins. 2018-11-12 17:02:11 -02:00
Rodrigo Rodriguez (pragmatismo.io)
554ffd9743 fix(ci): semantic release plugins. 2018-11-12 16:51:27 -02:00
Rodrigo Rodriguez (pragmatismo.io)
f1a2fba92d fix(ci): semantic release plugins. 2018-11-12 16:31:08 -02:00
Rodrigo Rodriguez (pragmatismo.io)
ea2dc29692 fix(ci): semantic release plugins. 2018-11-12 16:15:54 -02:00
Rodrigo Rodriguez (pragmatismo.io)
77c8ce2101 fix(ci): semantic release plugins. 2018-11-12 16:10:47 -02:00
Rodrigo Rodriguez (pragmatismo.io)
0088b28d41 fix(ci): semantic release plugins. 2018-11-12 16:01:16 -02:00
Rodrigo Rodriguez (pragmatismo.io)
6c4bf7b434 fix(ci): semantic release plugins. 2018-11-12 15:43:25 -02:00
Rodrigo Rodriguez (pragmatismo.io)
eea9ed7ef0 fix(ci): semantic release plugins. 2018-11-12 15:32:36 -02:00
Rodrigo Rodriguez (pragmatismo.io)
3b960916cc fix(ci): add new logging feature 2018-11-12 14:48:38 -02:00
Rodrigo Rodriguez (pragmatismo.io)
0d643be817 chore(ci): semantic commit 2018-11-12 14:02:26 -02:00
Rodrigo Rodriguez (pragmatismo.io)
4b81c6cf1c chore(ci): semantic commit 2018-11-12 14:00:53 -02:00
Rodrigo Rodriguez (pragmatismo.io)
8fcc3cc78a chore(ci): semantic commit 2018-11-12 13:57:23 -02:00
Rodrigo Rodriguez (pragmatismo.io)
6a08f084e7 chore(ci): semantic commit 2018-11-12 13:53:21 -02:00
Rodrigo Rodriguez (pragmatismo.io)
8d5ddf7e14 chore(ci): semantic commit 2018-11-12 13:23:23 -02:00
Rodrigo Rodriguez (pragmatismo.io)
bf48d12f76 fix(btfmw): new dialog pattern fixing. 2018-11-12 13:00:30 -02:00
Rodrigo Rodriguez (pragmatismo.io)
54b816b3ca chore(ci): semantic commit 2018-11-12 12:54:14 -02:00
Rodrigo Rodriguez (pragmatismo.io)
3be05b8e2d fix: Fixing auto-commit. 2018-11-12 12:40:35 -02:00
Rodrigo Rodriguez (pragmatismo.io)
51bdf02915 fix: More CI.
Travis and auto-semantic.
2018-11-12 12:36:59 -02:00
Rodrigo Rodriguez (pragmatismo.io)
ea978f7d65 fix(config): TSLint parsed on all files.
new(config): Several CI integrations.
2018-11-12 12:20:44 -02:00
Rodrigo Rodriguez
7a1948e1aa
Update .travis.yml 2018-11-12 11:40:36 -02:00
323fa9dd63
Update README.md 2018-11-12 11:32:34 -02:00
e0a346d768
Merge pull request #21 from pragmatismo-io/greenkeeper/initial
Update dependencies to enable Greenkeeper 🌴
2018-11-12 11:30:28 -02:00
greenkeeper[bot]
36bf16091f chore(package): update lockfile packages/default.gbui/package-lock.json 2018-11-12 13:03:13 +00:00
greenkeeper[bot]
4171dfef51 chore(package): update lockfile package-lock.json 2018-11-12 13:03:09 +00:00
greenkeeper[bot]
c131e836d1 docs(readme): add Greenkeeper badge 2018-11-12 13:03:06 +00:00
greenkeeper[bot]
e27519ce8a chore(travis): whitelist greenkeeper branches 2018-11-12 13:03:03 +00:00
greenkeeper[bot]
1198a7ccfe chore(package): update dependencies 2018-11-12 13:02:59 +00:00
greenkeeper[bot]
98c6349427 chore(package): update dependencies 2018-11-12 13:02:57 +00:00
greenkeeper[bot]
4c5f853d26 chore: add Greenkeeper config file 2018-11-12 13:02:53 +00:00
Rodrigo Rodriguez
e8aa235398
Update README.md 2018-11-12 10:12:29 -02:00
Rodrigo Rodriguez (pragmatismo.io)
6f868c5178 0.1.11 2018-11-11 21:30:05 -02:00
Rodrigo Rodriguez (pragmatismo.io)
b71881c9dd 0.1.10 2018-11-11 21:29:55 -02:00
Rodrigo Rodriguez (pragmatismo.io)
8aac578b3f CI in progress. 2018-11-11 21:29:48 -02:00
Rodrigo Rodriguez (pragmatismo.io)
5cdf458173 CI. 2018-11-11 20:16:40 -02:00
Rodrigo Rodriguez (pragmatismo.io)
3b1bbfe6a0 CI. 2018-11-11 20:08:56 -02:00
Rodrigo Rodriguez (pragmatismo.io)
d40a5333f2 CI. 2018-11-11 20:05:08 -02:00
Rodrigo Rodriguez (pragmatismo.io)
4cc0b76003 CI. 2018-11-11 20:02:21 -02:00
Rodrigo Rodriguez (pragmatismo.io)
c9aeaab59b CI in course. 2018-11-11 20:00:11 -02:00
Rodrigo Rodriguez (pragmatismo.io)
e649517fa2 CI in progress. 2018-11-11 19:57:58 -02:00
Rodrigo Rodriguez (pragmatismo.io)
2b0604a7d8 CI in course. 2018-11-11 19:56:00 -02:00
Rodrigo Rodriguez (pragmatismo.io)
7f18407e15 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-11 19:38:53 -02:00
Rodrigo Rodriguez (pragmatismo.io)
657bb7f180 CI in progress with releases. 2018-11-11 19:38:43 -02:00
Rodrigo Rodriguez
3ed71c3bf0
Update README.md 2018-11-11 19:21:48 -02:00
Rodrigo Rodriguez (pragmatismo.io)
3feac0c4e3 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-11 19:20:14 -02:00
Rodrigo Rodriguez (pragmatismo.io)
73dcae201d TSLint in progress. 2018-11-11 19:20:04 -02:00
Rodrigo Rodriguez
321e92b7a5
Update README.md 2018-11-11 19:16:20 -02:00
Rodrigo Rodriguez
bd42362f84
Update README.md 2018-11-11 19:15:36 -02:00
Rodrigo Rodriguez (pragmatismo.io)
ca565b890a TSLint fixing. 2018-11-11 19:09:18 -02:00
Rodrigo Rodriguez (pragmatismo.io)
60b935189f CI in progress. 2018-11-11 18:14:25 -02:00
Rodrigo Rodriguez (pragmatismo.io)
b841a5cd77 CI in progress. 2018-11-11 18:11:22 -02:00
Rodrigo Rodriguez (pragmatismo.io)
d067b37ced Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-11 18:09:48 -02:00
Rodrigo Rodriguez (pragmatismo.io)
dcc2dde8d5 CI in progress. 2018-11-11 18:09:21 -02:00
Rodrigo Rodriguez (pragmatismo.io)
4698611711 CI in progress. 2018-11-11 18:06:22 -02:00
Rodrigo Rodriguez (pragmatismo.io)
a6ff182aa8 CI in progress. 2018-11-11 18:03:35 -02:00
Rodrigo Rodriguez (pragmatismo.io)
bce11b9cce Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-11 18:01:21 -02:00
Rodrigo Rodriguez (pragmatismo.io)
6a0e993833 CI in progress. 2018-11-11 18:00:37 -02:00
Rodrigo Rodriguez
6c47dd87d7
Rename .travis.yaml to .travis.yml 2018-11-11 17:41:48 -02:00
Rodrigo Rodriguez (pragmatismo.io)
bc46284de5 Fixing CI configuration. 2018-11-11 17:41:36 -02:00
Rodrigo Rodriguez (pragmatismo.io)
cab4f2b62f Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-11 17:31:27 -02:00
Rodrigo Rodriguez (pragmatismo.io)
2c631ca8bd Added CI and unit test infrastructure; updated packages. 2018-11-11 17:31:17 -02:00
Rodrigo Rodriguez
3248d2ec39
Update README.md 2018-11-11 16:15:50 -02:00
Rodrigo Rodriguez
0c8e2c7160
Update README.md 2018-11-11 15:11:39 -02:00
Rodrigo Rodriguez
881bfba5b4
Update README.md 2018-11-11 15:08:48 -02:00
Rodrigo Rodriguez
1dc9289c09
Update README.md 2018-11-11 15:08:33 -02:00
Rodrigo Rodriguez
b3bc4d9625
Update README.md 2018-11-11 15:08:20 -02:00
Rodrigo Rodriguez
0416d83bba
Update README.md 2018-11-11 14:58:50 -02:00
d7181b250e
Add files via upload 2018-11-11 14:58:21 -02:00
Rodrigo Rodriguez
42e4ff6012
Update README.md 2018-11-11 14:55:26 -02:00
Rodrigo Rodriguez (pragmatismo.io)
517e20ddbb Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-11 10:51:11 -02:00
Rodrigo Rodriguez (pragmatismo.io)
47406ac487 Adding CI. 2018-11-11 10:50:58 -02:00
Rodrigo Rodriguez
da9e96a6cb
Update README.md 2018-11-11 10:08:33 -02:00
Rodrigo Rodriguez
a808525b7f
Update README.md 2018-11-11 10:06:42 -02:00
Rodrigo Rodriguez (pragmatismo.io)
0f00acb32e Republishing. 2018-11-05 14:46:48 -02:00
Rodrigo Rodriguez (pragmatismo.io)
139517decf Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-11-05 14:27:19 -02:00
Rodrigo Rodriguez (pragmatismo.io)
07039e2b7c Publishing and cleaning. 2018-11-05 14:27:05 -02:00
Rodrigo Rodriguez (pragmatismo.io)
8306fddb76 Cleaning and redeploy. 2018-11-05 14:23:36 -02:00
Rodrigo Rodriguez (pragmatismo.io)
ecf2ba35ef ARM process is done. 2018-11-04 17:26:29 -02:00
Rodrigo Rodriguez (pragmatismo.io)
5ecf922999 Removing bugs after updating to BOT Framework latest dialog pattern. 2018-11-04 09:19:03 -02:00
Rodrigo Rodriguez (pragmatismo.io)
fbdae843cf Text Replacement error due to generalization initiative, changed 'directLine' to 'line'. Solved by @compulim - MSFT. 2018-11-03 11:47:46 -03:00
Rodrigo Rodriguez (pragmatismo.io)
5ab6824635 Trying to get the UI to work https://github.com/Microsoft/BotFramework-WebChat/issues/970 2018-11-02 22:41:55 -03:00
Rodrigo Rodriguez (pragmatismo.io)
ef492836a6 Obtaining help from MSFT on https://github.com/Microsoft/BotFramework-WebChat/issues/1146. 2018-11-02 18:04:41 -03:00
Rodrigo Rodriguez (pragmatismo.io)
d3337bd221 Trying to get the bot running again; added default theme in case of recent born bots. 2018-11-02 14:19:41 -03:00
Rodrigo Rodriguez (pragmatismo.io)
8a3c41db1c More MS adaptations. 2018-11-01 21:39:37 -03:00
Rodrigo Rodriguez (pragmatismo.io)
677057c282 Microsoft updated everything again, so we need to update it too. 2018-11-01 21:06:11 -03:00
Rodrigo Rodriguez (pragmatismo.io)
820d4f612e Updating to latest architectural changes from BotBuilder-js v4. 2018-11-01 18:00:09 -03:00
Rodrigo Rodriguez (pragmatismo.io)
4315449a91 PUT in BotService was replaced by GET - the bot was unusable. 2018-11-01 15:11:23 -03:00
Rodrigo Rodriguez (pragmatismo.io)
fa8e310a2e Try to create the app from scratch on Microsoft App domain. 2018-10-30 19:52:40 -03:00
Rodrigo Rodriguez (pragmatismo.io)
028a4455ea Ngrok initialization and other startup stuff. 2018-10-28 21:56:51 -03:00
Rodrigo Rodriguez (pragmatismo.io)
d3e82b5806 More testing and adjustments on automation. 2018-10-25 21:57:28 -03:00
Rodrigo Rodriguez (pragmatismo.io)
b7f256b01f ARM automation done. 2018-10-25 18:13:51 -03:00
Rodrigo Rodriguez (pragmatismo.io)
d030ed8278 Bot deployment and key getting done. 2018-10-24 12:06:47 -03:00
76de18fa02 Set theme jekyll-theme-minimal 2018-10-24 09:21:34 -03:00
Rodrigo Rodriguez (pragmatismo.io)
c3d49e3288 Plug and play dev. environment in progress. 2018-10-22 15:33:23 -03:00
Rodrigo Rodriguez
c7ff6679cf
Update README.md 2018-10-21 15:16:43 -03:00
Rodrigo Rodriguez (pragmatismo.io)
4011edfb19 Generating a valid account for MSSQL. 2018-10-17 19:57:22 -03:00
38d399ee1b
Add files via upload 2018-10-17 19:50:52 -03:00
608910cffd
Add files via upload 2018-10-17 19:40:59 -03:00
PH-Nascimento
76fd3aa1ab
Update README.md 2018-10-16 20:32:43 -03:00
Rodrigo Rodriguez
9f8bab3a6b
Update WhatsappDirectLine.ts 2018-10-16 10:19:34 -03:00
Rodrigo Rodriguez (pragmatismo.io)
533787372f Call orchestration. 2018-10-15 21:03:17 -03:00
Rodrigo Rodriguez (pragmatismo.io)
a7142c5cfe Advancements in ARM and other repeatable stuff automation. 2018-10-15 19:05:43 -03:00
4d9ba23fdd
Add files via upload 2018-10-15 14:11:20 -03:00
Rodrigo Rodriguez (pragmatismo.io)
7ef4e22764 New tasks on Azure Deployer and start of Bot Farm deployer. 2018-10-14 19:58:54 -03:00
Rodrigo Rodriguez (pragmatismo.io)
7991dced80 First version of azure-arm automation. 2018-10-14 11:38:40 -03:00
Rodrigo Rodriguez (pragmatismo.io)
633cab410d Independent line for BotServer. 2018-10-12 12:28:51 -03:00
Rodrigo Rodriguez (pragmatismo.io)
eee48ee520 Storage sync logic and some refactoring. 2018-10-11 10:53:22 -03:00
37f9fced09 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-10-06 21:26:05 -03:00
1d3518ce66 Adjustment in homepage attribute. 2018-10-06 21:25:37 -03:00
2c3e6f6f34
Update README.md 2018-09-30 11:20:56 -03:00
207e2a1e4f Updated packages references. 2018-09-27 12:16:48 -03:00
d4c1094588 Fixing replacing error in package.json. 2018-09-27 11:38:34 -03:00
72cba3fcd8 Updating licensing and fixing BotBuilder version. 2018-09-27 11:35:35 -03:00
3f1ac29da8 Updated packages versions. 2018-09-27 09:27:39 -03:00
da9bfd3e4c Now tsc outputs the version. 2018-09-27 09:12:51 -03:00
31aaaec9d6 RegExp for authentication fixed. 2018-09-26 21:56:17 -03:00
ab1f1feb12 Bringing TypeScript. 2018-09-25 22:41:50 -03:00
1d676d7c19 powerbi-client added. 2018-09-25 21:04:37 -03:00
a9b738515f Trying to fix npm run build on default.gbui. 2018-09-25 20:26:33 -03:00
a8368988df Trying to fix npm run build on default.gbui. 2018-09-24 22:03:09 -03:00
34b7bb4572 Trying to fix npm run build on default.gbui. 2018-09-24 21:51:48 -03:00
6b12bdca27 Trying to fix npm run build on default.gbui. 2018-09-24 21:42:04 -03:00
29b85a7835 Command file improvement. 2018-09-24 20:08:35 -03:00
b94b9952aa Trying to deploy to WebApp with some improvements. 2018-09-24 19:56:11 -03:00
5b869c7313 Fixed node version. 2018-09-24 19:32:11 -03:00
d1d57dcdd8 Version updated. 2018-09-24 15:28:35 -03:00
b922a5b413 * Error handling improved and logging enriched as well.
* Setting DATABASE_ is now STORAGE_.
2018-09-24 15:27:26 -03:00
c2d0ef3f2e Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-09-24 11:04:47 -03:00
3832f27451 * FIX: Admin now is internationalized.
* FIX: Webchat now receives a private token.
* FIX: OAuth2 now has got revised and included state to avoid CSRF attacks.
* FIX: Now server will only start with a secure administration password.
2018-09-24 11:04:36 -03:00
fabf7a0a6c
Create README.md 2018-09-21 11:56:10 -03:00
ee4b554577
Create README.md 2018-09-21 08:16:38 -03:00
7375f179b2 * NEW: kb.gbapp now has a complete browser of excel articles.
* FIX: Some security improved.
* NEW: Protocol changes for exchanging questions between UI and Bot Server.
2018-09-20 12:37:33 -03:00
b028f2fccf Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-09-20 12:35:58 -03:00
379ade60fb * NEW: kb.gbapp now has a complete browser of excel articles.
* FIX: Some security improved.
* NEW: Protocol changes for exchanging questions between UI and Bot Server.
2018-09-20 12:35:47 -03:00
efc9ebfcc0
Update README.md 2018-09-18 10:57:52 -03:00
708a27e419 * gbot tested command on Windows machines.
* Bot lib reference updated.
2018-09-17 21:08:09 -03:00
cedd086eae
Update README.md 2018-09-17 20:40:15 -03:00
5330f3ff0e Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-09-16 20:27:46 -03:00
b2ddc95d3d Updated docs and published on NPM. 2018-09-16 20:26:07 -03:00
2f26873cba SMS sending is now done. 2018-09-16 20:15:42 -03:00
7e6ab65a37 Now the AD password can be reset. 2018-09-16 18:17:28 -03:00
c03228dbbe Added Azure AD administration routines. 2018-09-16 17:00:17 -03:00
e7a7fcedbf Testing and rebase to en-us as default language. 2018-09-14 14:29:44 -03:00
7a33f6942e General Bots in now almost globalized. 2018-09-14 12:56:54 -03:00
c573e33754 Multi language support changed to a custom. 2018-09-13 19:58:18 -03:00
d3487387d6 Adding multi language support. 2018-09-13 18:21:22 -03:00
18200e8ea1 Now context is correctly reset when coming from menu. 2018-09-12 05:18:37 -03:00
81dafca36e Removal of semicolon. 2018-09-12 04:47:11 -03:00
911aa77b11 Menu is back again in BtFmwV4. 2018-09-12 04:42:29 -03:00
3a3a1e2546 Adding some semicolon back. 2018-09-11 19:58:33 -03:00
576b9581ab Removal of semicolon. 2018-09-11 19:40:53 -03:00
d07b6350a0 Adding tslint.json and working on Cognitive Services NPM package upgrade. 2018-09-11 19:33:58 -03:00
bd03cfbc6c react downgraded to 15.5.0 due to https://github.com/Microsoft/BotFramework-WebChat/issues/970.
Promises revised.
2018-09-11 12:04:50 -03:00
c31671f3b4 KB FAQ click working now. 2018-09-10 19:27:56 -03:00
ea39f80707 KB is almost working in V4. 2018-09-10 16:24:32 -03:00
3fdceda57c MinService Demonolithization. 2018-09-10 12:09:48 -03:00
8ca77a4a63 Promise has sequenced import tasks in .gbkb. 2018-09-09 20:09:07 -03:00
88c190254d KB has now all the way Promised. 2018-09-09 18:11:41 -03:00
0fc1cddda5 Bot UI is running again. 2018-09-09 16:40:04 -03:00
f62399c912 More logging on web-service calls and Promise replacement for forEach. 2018-09-09 16:18:26 -03:00
0ce8d48f09 New promises and compiling. 2018-09-09 14:39:37 -03:00
96f78956b6 Migrating Bot Boot logic to BotFmwV4. 2018-09-04 15:09:52 -03:00
f6bf1068bb Debugging V4 and adding some security logic. 2018-09-03 13:43:09 -03:00
1eaaf8458a
Update README.md 2018-09-02 19:09:26 -03:00
78255b7009 New logo. 2018-09-02 19:09:35 -03:00
6acd0d4464
Add files via upload 2018-09-02 19:06:08 -03:00
11519e970d
Delete logo.png 2018-09-02 19:05:58 -03:00
eedf4d7ca6
Add files via upload 2018-09-02 19:05:39 -03:00
afa103d768
Add files via upload 2018-09-02 19:05:00 -03:00
3511907eb7
Add files via upload 2018-09-02 19:04:20 -03:00
a05fd39b57
Update README.md 2018-09-02 18:24:49 -03:00
11aea1d0f2
Update README.md 2018-09-02 18:24:08 -03:00
348652746d
Add files via upload 2018-09-01 21:07:03 -03:00
b0aacd3e26
Add files via upload 2018-09-01 21:04:50 -03:00
a6798afd37
Update README.md 2018-09-01 20:55:49 -03:00
8f80cbc002
Update README.md 2018-09-01 20:46:45 -03:00
ebc5f64a1c
Add files via upload 2018-09-01 20:45:25 -03:00
9efb1e1555
Update README.md 2018-09-01 18:52:56 -03:00
0f2eebe246
Update README.md 2018-09-01 18:46:24 -03:00
9b5f612c42
Update README.md 2018-09-01 18:45:46 -03:00
7eb889e137
Add files via upload 2018-09-01 18:44:28 -03:00
2584717ae8 Finishing merge on v4 branch. 2018-09-01 13:51:58 -03:00
3f9b289499 Merge remote-tracking branch 'remotes/origin/master' into MigrationToBotFmwV4 2018-09-01 12:49:38 -03:00
c419b292de Latest adjustments trying to fix BotFramework-WebChat control bug as documented in https://github.com/Microsoft/BotFramework-WebChat/issues/970. 2018-09-01 12:36:04 -03:00
17129785f3
Update README.md 2018-08-30 17:27:32 -03:00
5106a13a23
Update README.md 2018-08-30 11:54:07 -03:00
a6e890e9b2
Add files via upload 2018-08-30 11:41:28 -03:00
b936e20cb2
Add files via upload 2018-08-30 11:40:08 -03:00
173a89ee54
Update README.md 2018-08-30 11:39:33 -03:00
fcf32f4f0d
Update README.md 2018-08-30 11:38:29 -03:00
0a09c882d9
Add files via upload 2018-08-30 11:33:48 -03:00
3a8594bb7b
Delete Use Visual Studio Code To Keep All Packages in a .gbai workspace.png 2018-08-30 11:32:47 -03:00
2e8dd6b97f
Add files via upload 2018-08-30 11:31:20 -03:00
8b1f87de8b
Update README.md 2018-08-30 11:12:39 -03:00
a034ef8789
Key packages table added. 2018-08-30 11:12:19 -03:00
9bd5995115 Dialog being called again. 2018-08-28 19:16:29 -03:00
3118b45543 Migration to V4 is in progress. The Bot now can be loaded again. 2018-08-28 17:50:19 -03:00
f6fa24c7df Adding some images to documentation and segmenting documentation main folder. 2018-08-25 16:25:37 -03:00
Jorge Ramos
03e6fc47a2 FIX: Updated dependencies versions. 2018-08-22 05:43:36 -03:00
Jorge Ramos
14daf8612d Add skipLibCheck in tsconfig 2018-08-19 15:34:21 -03:00
Jorge Ramos
527f83c631 Merge branch 'master' of https://github.com/pragmatismo-io/BotServer
# Resolved:
#	tsconfig.json
2018-08-19 13:02:21 -03:00
Jorge Ramos
e26e15e2ae Add keyofStringsOnly in tsconfig 2018-08-19 12:58:35 -03:00
Rafael Arenario Pereira da Silva
3f1487c5d1 Now compiling. 2018-08-19 12:42:50 -03:00
Rafael Arenario Pereira da Silva
086697c042 Merge branch 'master' of https://github.com/pragmatismo-io/BotServer
# Conflicts:
#	deploy/whatsapp.gblib/services/WhatsappDirectLine.ts
2018-08-19 12:37:01 -03:00
Rafael Arenario Pereira da Silva
0dbe506681 Adjustments in Hackathon. 2018-08-19 12:34:37 -03:00
Jorge Ramos
bc41a8c18c Whatsapp test changed to all netshoes bots 2018-08-19 05:56:38 -03:00
Jorge Ramos
6b254e1aad Compilation fixes 2018-08-19 05:37:13 -03:00
Jorge Ramos
d8080f9696 Merge branch 'master' of https://github.com/pragmatismo-io/BotServer
# Resolved:
#	deploy/default.gbui/public/index.html
2018-08-18 23:51:26 -03:00
Jorge Ramos
f1af1ee1bd Opacity commented in class "loader" and todoincluded 2018-08-18 23:46:51 -03:00
Rafael Arenario Pereira da Silva
2577f47504 Ajustes para corrigir o problema de inicialização do class, além de preparar a aplicação para funcionar com o Whatsapp. 2018-08-18 23:10:33 -03:00
Jorge Ramos
91e03a1a39 Merge branch 'master' of https://github.com/pragmatismo-io/BotServer 2018-08-01 02:08:58 -03:00
Jorge Ramos
b599cb4608 Change STS API endpoint (temporary solution) 2018-08-01 02:08:45 -03:00
5251689da0
Updated documentation about running tests. 2018-07-26 10:51:46 -03:00
d24d357fdd
Updated test search path so mocha can find test.ts files. 2018-07-26 10:43:35 -03:00
ae3a5e7b34
Create requirement 2018-07-15 09:07:04 -03:00
Rafael Arenario Pereira da Silva
a2ffa65425 Ajustes para abertura do sistema sem a necessidade da pasta de gbapp. 2018-06-18 09:41:55 -03:00
4cc4e7236a LUIS is called again with no context revoke. 2018-06-04 20:27:21 -03:00
Jorge Ramos
e4e331730d - FIX: Packages updated.
- NEW: DATABASE_SYNC_ALTER environment parameter.
- NEW: DATABASE_SYNC_FORCE environment parameter.
- NEW: Define constraint names in MSSQL.
2018-06-04 08:03:23 -03:00
d2a4855702 The application is now compiling with "sequelize-typescript": "^0.6.3". 2018-06-04 06:42:47 -03:00
b30eb5d1b9 Code migrated and compiling, now the bot needs to work again. 2018-06-04 05:33:37 -03:00
0955599855 NEW: Added STT and TTS capabilities to default.gbui. 2018-06-01 16:11:52 -03:00
Jorge Ramos
c4f767156b gbui packages updated. 2018-05-29 06:20:09 -03:00
Jorge Ramos
e4176b9f0d Packages updated. 2018-05-29 05:27:52 -03:00
Jorge Ramos
d019ebaef1 Package dependencies updated. 2018-05-28 21:58:14 -03:00
Jorge Ramos
1e523c16b9 Minor change (blank line) in package.json 2018-05-28 07:03:26 -03:00
Jorge Ramos
ea89351f7d Update of dependencies versions (package.json).
If a bot package's name begins with '.', then it is ignored.
Created DATABASE_LOGGING environment parameter.
2018-05-28 06:51:06 -03:00
Jorge Ramos
582b176d49 Atualização do package-lok.json 2018-05-27 21:10:50 -03:00
81a1445a09 - FIX: Whastapp line now can be turned off;
- FIX: More error logging on BuildMin.
2018-05-27 18:15:33 -03:00
Jorge Ramos
70a9862d01 Update package.json and package-lock.json 2018-05-18 22:21:23 -03:00
b49d5aafd6 - FIX: AskDialog compilation error.
- FIX: More Whatsapp line adjustments: Duplicated 'Hi!' & log enrichment.
2018-05-18 11:39:17 -03:00
Jorge Ramos
3cc0b5e7b4 Fixed missing variable declaration 2018-05-16 23:21:17 -03:00
db59f29a72 Update issue templates 2018-05-16 12:13:31 -03:00
4afa561775
Create CODE_OF_CONDUCT.md 2018-05-16 12:12:08 -03:00
040977076f - FIX: Duplicated asking on main loop removed.
- FIX: Whatsapp log phrase correction.
- FIX: Directline can now receive messages sent in not-in-conversation, projector-only fashion.
2018-05-16 12:06:37 -03:00
Jorge Ramos
b7b62c0642 Auto-dispatch to dialog based on intent name. 2018-05-14 04:12:09 -03:00
Jorge Ramos
3b6edd4f3a Parameter whatsappServiceWebhookUrl added. 2018-05-14 01:48:39 -03:00
1bc4b37827 Improvements on Whatsapp directline. 2018-05-13 18:28:24 -03:00
72433236b0 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-05-13 16:36:06 -03:00
a55c677833 Minor fixes in imports and exact match question processing. 2018-05-13 16:35:57 -03:00
Jorge Ramos
af7db2246d Rename _this and update package.json 2018-05-12 22:41:54 -03:00
f899029963 Updated package.json to include git repository and homepage. 2018-05-12 16:14:59 -03:00
b122882aac - NEW: Whatsapp directline client is now working in preview. 2018-05-12 16:08:24 -03:00
1d0dc4cf25 Building 3rd party service webhook for Whatsapp.gblib.
Signed-off-by: Rodrigo Rodriguez <me@rodrigorodriguez.com>
2018-05-12 13:40:34 -03:00
ba85db06dd Whatsapp channel improvements. 2018-05-11 23:27:00 -03:00
51e9b9c3bf Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-05-11 22:18:47 -03:00
2a142e3afc - NEW: Now each .gbapp has it own set of syspackages loaded.
- NEW: Added support for Whatsapp external service key on bot instance model.
2018-05-11 22:18:38 -03:00
ad92560a7e
Update README.md 2018-05-09 16:36:46 -03:00
262a2c8cc1
Update README.md 2018-05-09 16:35:09 -03:00
1d36f3d95e Started Whatsapp interface, updated packages and cleaned up. 2018-05-07 20:45:11 -03:00
9208648734 New version file and numbering update. 2018-05-06 19:26:45 -03:00
51d244ce44 - FIX: .gbapp files now correctly loaded before other package types so custom models can be used to sync DB.
- NEW: Removed Boot Package feature. Now every .gbot found on deploy folders are deployed on startup.
2018-05-06 19:25:47 -03:00
3bb0b316a9 Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-05-05 08:26:13 -03:00
0d87345849 Contained .js files into the final package. 2018-05-05 08:26:00 -03:00
David Lerner
d21a046aa7
Novo logo 2018-04-27 15:08:17 -03:00
a6fa06159d English grammar correction. 2018-04-26 23:03:41 -03:00
7bcb6d9f85 Cleaning and improvements on setup development environment on Windows and source-code sharing with direct download links. 2018-04-26 22:40:51 -03:00
9027c9c39e web.config path updated. 2018-04-25 03:10:14 -03:00
b42aeb7d5a README.md updated. 2018-04-25 03:03:00 -03:00
76291122b8 Fix in README.md. 2018-04-25 02:41:57 -03:00
c547888697 Azure deploy in progress. 2018-04-25 02:17:02 -03:00
b30639b5cd package.json updated with dev. references. 2018-04-25 02:11:14 -03:00
413a354299 Adding missing packages on prod. 2018-04-25 02:03:45 -03:00
c4177b11b7 README.md updated. 2018-04-25 01:32:21 -03:00
aecb8d0226 Updated version in package.json. 2018-04-25 01:17:04 -03:00
c173fa8a8e Azure Search call fix for managing KB indexes. 2018-04-25 00:58:34 -03:00
1f1d63c2ff Cleaning. 2018-04-24 05:37:34 -03:00
fcbbcf1965 Cleaning and KB improvements. 2018-04-24 05:36:48 -03:00
538996abfb Merge branch 'master' of https://github.com/pragmatismo-io/botserver 2018-04-23 13:52:14 -03:00
4cbbc3268f Added docs and fixed package references. 2018-04-23 13:52:03 -03:00
eb9d95e46e
Update README.md 2018-04-21 11:26:14 -03:00
f3f64e5775
Update README.md 2018-04-21 11:25:03 -03:00
8a8df3b992 Added logo to README.md. 2018-04-21 11:19:43 -03:00
0a1dfeb9a5
Update README.md 2018-04-21 04:33:34 -03:00
fa66162409
Update README.md 2018-04-21 03:37:32 -03:00
992 changed files with 49097 additions and 325905 deletions

View file

@ -1,5 +0,0 @@
[build]
rustc-wrapper = "sccache"
[target.x86_64-unknown-linux-gnu]
linker = "clang"

2
.deployment Normal file
View file

@ -0,0 +1,2 @@
[config]
command = deploy.cmd

View file

@ -1,52 +0,0 @@
# BotServer Embedded Configuration
# For Orange Pi, Raspberry Pi, and other ARM SBCs
# Server
HOST=0.0.0.0
PORT=9000
RUST_LOG=info
# Database (SQLite for embedded, no PostgreSQL needed)
DATABASE_URL=sqlite:///opt/botserver/data/botserver.db
# LLM Configuration - Local llama.cpp
LLM_PROVIDER=llamacpp
LLM_API_URL=http://127.0.0.1:8080
LLM_MODEL=tinyllama
# Alternative: Use remote API
# LLM_PROVIDER=openai
# LLM_API_URL=https://api.openai.com/v1
# LLM_API_KEY=sk-...
# Alternative: Ollama (if installed)
# LLM_PROVIDER=ollama
# LLM_API_URL=http://127.0.0.1:11434
# LLM_MODEL=tinyllama
# Memory limits for embedded
MAX_CONTEXT_TOKENS=2048
MAX_RESPONSE_TOKENS=512
STREAMING_ENABLED=true
# Embedded UI
STATIC_FILES_PATH=/opt/botserver/ui
DEFAULT_UI=embedded
# WebSocket
WS_PING_INTERVAL=30
WS_TIMEOUT=300
# Security (change in production!)
JWT_SECRET=embedded-change-me-in-production
CORS_ORIGINS=*
# Logging
LOG_FILE=/opt/botserver/data/botserver.log
LOG_MAX_SIZE=10M
LOG_RETENTION=7
# Performance tuning for low-memory devices
# Uncomment for <2GB RAM devices
# RUST_BACKTRACE=0
# MALLOC_ARENA_MAX=2

View file

@ -1,36 +0,0 @@
# BotServer Environment Configuration
# =====================================
#
# ONLY VAULT VARIABLES ARE ALLOWED IN THIS FILE!
# All secrets (DATABASE_URL, API keys, etc.) MUST be stored in Vault.
# NO LEGACY FALLBACK - Vault is mandatory.
#
# Vault paths for secrets:
# - gbo/tables - PostgreSQL credentials (host, port, database, username, password)
# - gbo/drive - MinIO/S3 credentials (accesskey, secret)
# - gbo/cache - Redis credentials (password)
# - gbo/directory - Zitadel credentials (url, project_id, client_id, client_secret)
# - gbo/email - Email credentials (username, password)
# - gbo/llm - LLM API keys (openai_key, anthropic_key, groq_key)
# - gbo/encryption - Encryption keys (master_key)
# - gbo/meet - LiveKit credentials (api_key, api_secret)
# - gbo/alm - Forgejo credentials (url, admin_password, runner_token)
# - gbo/vectordb - Qdrant credentials (url, api_key)
# - gbo/observability - InfluxDB credentials (url, org, bucket, token)
# =====================
# VAULT CONFIGURATION - ONLY THESE VARS ARE ALLOWED
# =====================
# Vault server address
VAULT_ADDR=https://localhost:8200
# Vault authentication token (generated during vault init)
# This will be populated automatically after first bootstrap
VAULT_TOKEN=
# Skip TLS verification for development (set to false in production)
VAULT_SKIP_VERIFY=true
# Cache TTL for secrets in seconds (default: 300 = 5 minutes)
VAULT_CACHE_TTL=300

View file

@ -1,89 +0,0 @@
name: BotServer CI
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
env:
CARGO_BUILD_JOBS: 8
CARGO_NET_RETRY: 10
jobs:
build:
runs-on: gbo
steps:
- name: Disable SSL verification
run: git config --global http.sslVerify false
- name: Setup Workspace
run: |
# Clone the main gb repository
git clone --depth 1 --branch main https://alm.pragmatismo.com.br/GeneralBots/gb.git workspace
cd workspace
git submodule update --init --depth 1 botlib
# Clone botserver separately
git clone --depth 1 --branch main https://alm.pragmatismo.com.br/GeneralBots/BotServer.git botserver
# Remove all members except botserver and botlib from workspace
sed -i '/"botapp",/d' Cargo.toml
sed -i '/"botdevice",/d' Cargo.toml
sed -i '/"bottest",/d' Cargo.toml
sed -i '/"botui",/d' Cargo.toml
sed -i '/"botbook",/d' Cargo.toml
sed -i '/"botmodels",/d' Cargo.toml
sed -i '/"botplugin",/d' Cargo.toml
sed -i '/"bottemplates",/d' Cargo.toml
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y libpq-dev libssl-dev liblzma-dev pkg-config
- name: Install Rust
run: |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain stable --profile minimal
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Install sccache
run: |
wget https://github.com/mozilla/sccache/releases/download/v0.8.2/sccache-v0.8.2-x86_64-unknown-linux-musl.tar.gz
tar xzf sccache-v0.8.2-x86_64-unknown-linux-musl.tar.gz
mv sccache-v0.8.2-x86_64-unknown-linux-musl/sccache $HOME/.cargo/bin/sccache
chmod +x $HOME/.cargo/bin/sccache
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
$HOME/.cargo/bin/sccache --start-server || true
- name: Setup environment
run: sudo cp /opt/gbo/bin/system/.env . 2>/dev/null || true
- name: Build BotServer
working-directory: workspace
run: |
cargo build -p botserver -j 8 2>&1 | tee /tmp/build.log
ls -lh target/debug/botserver
sccache --show-stats || true
- name: Save build log
if: always()
run: |
sudo mkdir -p /opt/gbo/logs
sudo cp /tmp/build.log /opt/gbo/logs/botserver-$(date +%Y%m%d-%H%M%S).log || true
- name: Deploy
working-directory: workspace
run: |
lxc exec bot:pragmatismo-system -- systemctl stop system || true
sudo cp target/debug/botserver /opt/gbo/bin/system/
sudo chmod +x /opt/gbo/bin/system/botserver
lxc exec bot:pragmatismo-system -- systemctl start system || true

3
.gitattributes vendored Normal file
View file

@ -0,0 +1,3 @@
* text=auto
*.js eol=lf
*.ts eol=lf

9
.github/ISSUE_TEMPLATE.md vendored Normal file
View file

@ -0,0 +1,9 @@
<!-- File a GitHub issue only for bugs or feature requests related to the code **in this repository**. For other topics you can get more information in the README file. -->
### Observed Results:
<!-- This could be a description, error output, steps to reproduce, a feature missed, etc. -->
### Expected behavior:
<!-- What did you expect to happen? -->

35
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file
View file

@ -0,0 +1,35 @@
---
name: Bug report
about: Create a report to help us improve
---
**Describe the bug**
A clear and concise description of what the bug is.
**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots**
If applicable, add screenshots to help explain your problem.
**Desktop (please complete the following information):**
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]
**Smartphone (please complete the following information):**
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]
**Additional context**
Add any other context about the problem here.

7
.github/ISSUE_TEMPLATE/custom.md vendored Normal file
View file

@ -0,0 +1,7 @@
---
name: Custom issue template
about: Describe this issue template's purpose here.
---

View file

@ -0,0 +1,17 @@
---
name: Feature request
about: Suggest an idea for this project
---
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
**Describe the solution you'd like**
A clear and concise description of what you want to happen.
**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.
**Additional context**
Add any other context or screenshots about the feature request here.

2
.github/ISSUE_TEMPLATE/requirement vendored Normal file
View file

@ -0,0 +1,2 @@
**Description**
A clear and concise description of what the requirement is.

16
.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View file

@ -0,0 +1,16 @@
### Changes description
<!-- Describe results, user mentions, screenshots, screencast (gif) -->
### Checklist
Please check if your PR fulfills the following specifications:
- [ ] Tests for the changes have been added
- [ ] Docs have been added/updated
### References
<!-- issues related (for reference or to be closed) and/or links of discuss -->
Closes #N/A

3
.github/invite-contributors.yml vendored Normal file
View file

@ -0,0 +1,3 @@
isOutside: true
# Team Name
team: contributors

44
.github/settings.yml vendored Normal file
View file

@ -0,0 +1,44 @@
repository:
name: botserver
description: botserver
homepage: http://pragmatismo.io/general-bots
topics: node-module
private: false
has_issues: true
has_wiki: false
has_downloads: true
default_branch: develop
allow_squash_merge: true
allow_merge_commit: false
allow_rebase_merge: true
labels:
- name: bug
color: f44336
- name: build
color: 795548
- name: ci
color: fbca04
- name: documentation
color: 607d8b
- name: duplicate
color: 9e9e9e
- name: feature
color: 3f51b5
- name: invalid
color: cddc39
- name: performance
color: 009688
- name: question
color: ff5722
- name: refactor
color: 9c27b0
- name: style
color: 2196f3
- name: test
color: 8bc34a
- name: wontfix
color: ffffff
- name: help wanted
color: 33aa3f
- name: good first issue
color: 7057ff

33
.gitignore vendored
View file

@ -1,16 +1,17 @@
.tmp*
.tmp/*
*.log
target*
.env
*.env
work
*.out
bin
botserver-stack
*logfile*
*-log*
docs/book
*.rdb
botserver-installers
.git-rewrite
/.coveralls.yml
/.env
/.npmrc
/.nyc_output
/coverage
/dist
/docs
/guaribas.log
/guaribas.sqlite
/node_modules
/packages/default.gbui/build
/packages/default.gbui/.env
/packages/default.gbui/node_modules
/tmp
/work
/packages/default.gbdialog/bot.js
/packages/default.gbdialog/bot.ts

15
.npmignore Normal file
View file

@ -0,0 +1,15 @@
# This file must be a copy of .gitignore except for the WILLSHIP commented lines below.
/.coveralls.yml
/.env
/.npmrc
# WILLSHIP /.nyc_output
/coverage
# WILLSHIP /dist
/guaribas.log
/guaribas.sqlite
/node_modules
# WILLSHIP /packages/default.gbui/build
/packages/default.gbui/.env
/packages/default.gbui/node_modules
/tmp
/work

30
.nycrc Normal file
View file

@ -0,0 +1,30 @@
{
"check-coverage": true,
"statements": 0,
"lines": 0,
"functions": 0,
"branches": 0,
"watermarks": {
"statements": [0, 0],
"lines": [0, 0],
"functions": [0, 0],
"branches": [0, 0]
},
"cache": true,
"extension": [
".ts"
],
"include": [
"packages/**"
],
"exclude": [
"**/node_modules/**/*",
"**/tests/**/*",
"**/default.gbui/**/*",
"**/line.gbui/**/*"
],
"reporter": [
"html"
],
"all": true
}

8
.prettierrc Normal file
View file

@ -0,0 +1,8 @@
{
"trailingComma": "none",
"tabWidth": 2,
"printWidth": 120,
"arrowParens": "avoid",
"semi": true,
"singleQuote": true
}

View file

@ -1,53 +0,0 @@
# Product Configuration File
# This file defines white-label settings for the application.
#
# All occurrences of "General Bots" will be replaced by the 'name' value.
# Only apps listed in 'apps' will be active in the suite (and their APIs enabled).
# The 'theme' value sets the default theme for the UI.
# Product name (replaces "General Bots" throughout the application)
name=General Bots
# Active apps (comma-separated list)
# Available apps: chat, mail, calendar, drive, tasks, docs, paper, sheet, slides,
# meet, research, sources, analytics, admin, monitoring, settings
# Only listed apps will be visible in the UI and have their APIs enabled.
apps=chat,drive,tasks,sources,settings
# Search mechanism enabled
# Controls whether the omnibox/search toolbar is displayed in the suite
# Set to false to disable the search mechanism
search_enabled=false
# Menu launcher enabled
# Controls whether the apps menu launcher is displayed in the suite
# Set to false to hide the menu launcher button
# When the menu is empty (no apps to show), it will be automatically hidden
menu_launcher_enabled=false
# Default theme
# Available themes: dark, light, blue, purple, green, orange, sentient, cyberpunk,
# retrowave, vapordream, y2kglow, arcadeflash, discofever, grungeera,
# jazzage, mellowgold, midcenturymod, polaroidmemories, saturdaycartoons,
# seasidepostcard, typewriter, 3dbevel, xeroxui, xtreegold
theme=sentient
# Logo URL (optional - leave empty to use default)
# Can be a relative path or absolute URL
logo=
# Favicon URL (optional - leave empty to use default)
favicon=
# Primary color override (optional - hex color code)
# Example: #d4f505
primary_color=
# Support email (optional)
support_email=
# Documentation URL (optional)
docs_url=https://docs.pragmatismo.com.br
# Copyright text (optional - {year} will be replaced with current year)
copyright=© {year} {name}. All rights reserved.

34
.travis.yml Normal file
View file

@ -0,0 +1,34 @@
language: node_js
node_js:
- lts/*
notifications:
email: false
before_script:
- npm run build
script:
- npm run coveralls
branches:
only:
- master
- /^greenkeeper/.*$/
except:
- /^v\d+\.\d+\.\d+$/
after_success:
- npm run travis-deploy-once "npm run semantic-release"
- npm pack
deploy:
- provider: pages
skip_cleanup: true
local_dir: docs/reference
github_token: $GITHUB_TOKEN
on:
tags: false
branch: master

41
.vscode/launch.json vendored
View file

@ -1,41 +1,20 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "lldb",
"type": "node",
"request": "launch",
"name": "Debug executable 'botserver'",
"cargo": {
"args": ["build", "--bin=botserver", "--package=botserver"],
"filter": {
"name": "botserver",
"kind": "bin"
}
},
"args": ["--desktop"],
"name": "Debug Program",
"program": "${workspaceRoot}/dist/src/app.js",
"cwd": "${workspaceRoot}",
"env": {
"RUST_LOG": "trace,aws_sigv4=off,aws_smithy_checksums=off,mio=off,reqwest=off,aws_runtime=off,aws_smithy_http_client=off,rustls=off,hyper_util=off,aws_smithy_runtime=off,aws_smithy_runtime_api=off,tracing=off,aws_sdk_s3=off"
"NODE_ENV": "development"
},
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'botserver'",
"cargo": {
"args": ["test", "--no-run", "--bin=botserver", "--package=botserver"],
"filter": {
"name": "botserver",
"kind": "bin"
}
},
"args": [],
"env": {
"RUST_LOG": "trace"
},
"cwd": "${workspaceFolder}"
"args":["--no-deprecation"],
"skipFiles": ["node_modules/**/*.js"],
"outFiles": ["${workspaceRoot}/dist/*.js"],
"stopOnEntry": false,
"console": "integratedTerminal"
}
]
}

View file

@ -1,16 +0,0 @@
[
{
"label": "Debug BotServer",
"build": {
"command": "cargo",
"args": ["build"],
},
"program": "$ZED_WORKTREE_ROOT/target/debug/botserver",
"env": {
"RUST_LOG": "trace",
},
"sourceLanguages": ["rust"],
"request": "launch",
"adapter": "CodeLLDB",
},
]

View file

@ -1,222 +0,0 @@
# Third-Party Dependencies Configuration
# ======================================
# This file lists all external downloads required by botserver.
#
# Caching Behavior:
# - On first run, files are downloaded from the URLs below
# - Downloaded files are cached in ./botserver-installers/
# - On subsequent runs, cached files are used instead of downloading
# - To force re-download, delete the cached file
#
# Offline Installation:
# - Pre-download all files to ./botserver-installers/
# - The installer will use cached files automatically
# - You can safely delete ./botserver-stack/ without losing downloads
[cache_settings]
# Directory where downloaded files are cached (relative to botserver root)
cache_dir = "botserver-installers"
# Components
# ==========
# Each component has:
# - url: Download URL
# - filename: Local filename in cache
# - sha256: Optional checksum for verification (empty = skip verification)
[components.drive]
name = "MinIO Object Storage"
url = "https://dl.min.io/server/minio/release/linux-amd64/minio"
filename = "minio"
sha256 = ""
[components.tables]
name = "PostgreSQL Database"
url = "https://github.com/theseus-rs/postgresql-binaries/releases/download/17.2.0/postgresql-17.2.0-x86_64-unknown-linux-gnu.tar.gz"
filename = "postgresql-17.2.0-x86_64-unknown-linux-gnu.tar.gz"
sha256 = ""
[components.cache]
name = "Valkey Cache (Redis-compatible)"
# Precompiled binary from download.valkey.io (jammy for GLIBC 2.36 compatibility)
url = "https://download.valkey.io/releases/valkey-8.1.5-jammy-x86_64.tar.gz"
filename = "valkey-8.1.5-jammy-x86_64.tar.gz"
sha256 = ""
[components.llm]
name = "Llama.cpp Server"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-ubuntu-x64.zip"
filename = "llama-b7345-bin-ubuntu-x64.zip"
sha256 = "91b066ecc53c20693a2d39703c12bc7a69c804b0768fee064d47df702f616e52"
[components.email]
name = "Stalwart Mail Server"
url = "https://github.com/stalwartlabs/mail-server/releases/download/v0.10.7/stalwart-mail-x86_64-linux.tar.gz"
filename = "stalwart-mail-x86_64-linux.tar.gz"
sha256 = ""
[components.proxy]
name = "Caddy Web Server"
url = "https://github.com/caddyserver/caddy/releases/download/v2.9.1/caddy_2.9.1_linux_amd64.tar.gz"
filename = "caddy_2.9.1_linux_amd64.tar.gz"
sha256 = ""
[components.directory]
name = "Zitadel Identity Provider"
url = "https://github.com/zitadel/zitadel/releases/download/v4.11.1/zitadel-linux-amd64.tar.gz"
filename = "zitadel-linux-amd64.tar.gz"
sha256 = ""
[components.alm]
name = "Forgejo Git Server"
url = "https://codeberg.org/forgejo/forgejo/releases/download/v14.0.2/forgejo-14.0.2-linux-amd64"
filename = "forgejo-14.0.2-linux-amd64"
sha256 = ""
[components.alm_ci]
name = "Forgejo Actions Runner"
url = "https://code.forgejo.org/forgejo/runner/releases/download/v6.3.1/forgejo-runner-6.3.1-linux-amd64"
filename = "forgejo-runner-6.3.1-linux-amd64"
sha256 = ""
[components.dns]
name = "CoreDNS Server"
url = "https://github.com/coredns/coredns/releases/download/v1.11.1/coredns_1.11.1_linux_amd64.tgz"
filename = "coredns_1.11.1_linux_amd64.tgz"
sha256 = ""
[components.webmail]
name = "Roundcube Webmail"
url = "https://github.com/roundcube/roundcubemail/releases/download/1.6.6/roundcubemail-1.6.6-complete.tar.gz"
filename = "roundcubemail-1.6.6-complete.tar.gz"
sha256 = ""
[components.meet]
name = "LiveKit Media Server"
url = "https://github.com/livekit/livekit/releases/download/v2.8.2/livekit_2.8.2_linux_amd64.tar.gz"
filename = "livekit_2.8.2_linux_amd64.tar.gz"
sha256 = ""
[components.table_editor]
name = "NocoDB"
url = "http://get.nocodb.com/linux-x64"
filename = "nocodb-linux-x64"
sha256 = ""
[components.vector_db]
name = "Qdrant Vector Database"
url = "https://github.com/qdrant/qdrant/releases/latest/download/qdrant-x86_64-unknown-linux-gnu.tar.gz"
filename = "qdrant-x86_64-unknown-linux-gnu.tar.gz"
sha256 = ""
[components.timeseries_db]
name = "InfluxDB Time Series Database"
url = "https://download.influxdata.com/influxdb/releases/influxdb2-2.7.5-linux-amd64.tar.gz"
filename = "influxdb2-2.7.5-linux-amd64.tar.gz"
sha256 = ""
[components.vault]
name = "HashiCorp Vault"
url = "https://releases.hashicorp.com/vault/1.15.4/vault_1.15.4_linux_amd64.zip"
filename = "vault_1.15.4_linux_amd64.zip"
sha256 = ""
[components.observability]
name = "Vector Log Aggregator"
url = "https://packages.timber.io/vector/0.35.0/vector-0.35.0-x86_64-unknown-linux-gnu.tar.gz"
filename = "vector-0.35.0-x86_64-unknown-linux-gnu.tar.gz"
sha256 = ""
# LLM Models
# ==========
# Large model files for AI/ML functionality
[models.deepseek_small]
name = "DeepSeek R1 Distill Qwen 1.5B (Q3_K_M)"
url = "https://huggingface.co/bartowski/DeepSeek-R1-Distill-Qwen-1.5B-GGUF/resolve/main/DeepSeek-R1-Distill-Qwen-1.5B-Q3_K_M.gguf"
filename = "DeepSeek-R1-Distill-Qwen-1.5B-Q3_K_M.gguf"
sha256 = ""
[models.bge_embedding]
name = "BGE Small EN v1.5 Embedding Model"
url = "https://huggingface.co/CompendiumLabs/bge-small-en-v1.5-gguf/resolve/main/bge-small-en-v1.5-f32.gguf"
filename = "bge-small-en-v1.5-f32.gguf"
sha256 = ""
# Platform-specific llama.cpp variants
# =====================================
# These are alternative builds for different platforms/GPU support
[components.llm_linux_vulkan]
name = "Llama.cpp Server (Linux Vulkan)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-ubuntu-vulkan-x64.zip"
filename = "llama-b7345-bin-ubuntu-vulkan-x64.zip"
sha256 = "03f0b3acbead2ddc23267073a8f8e0207937c849d3704c46c61cf167c1001442"
[components.llm_linux_s390x]
name = "Llama.cpp Server (Linux s390x)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-ubuntu-s390x.zip"
filename = "llama-b7345-bin-ubuntu-s390x.zip"
sha256 = "688ddad6996b1166eaaa76d5025e304c684116efe655e6e881d877505ecffccb"
[components.llm_macos_arm64]
name = "Llama.cpp Server (macOS ARM64)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-macos-arm64.zip"
filename = "llama-b7345-bin-macos-arm64.zip"
sha256 = "72ae9b4a4605aa1223d7aabaa5326c66c268b12d13a449fcc06f61099cd02a52"
[components.llm_macos_x64]
name = "Llama.cpp Server (macOS x64)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-macos-x64.zip"
filename = "llama-b7345-bin-macos-x64.zip"
sha256 = "bec6b805cf7533f66b38f29305429f521dcb2be6b25dbce73a18df448ec55cc5"
[components.llm_win_cpu_x64]
name = "Llama.cpp Server (Windows x64 CPU)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-win-cpu-x64.zip"
filename = "llama-b7345-bin-win-cpu-x64.zip"
sha256 = "ea449082c8e808a289d9a1e8331f90a0379ead4dd288a1b9a2d2c0a7151836cd"
[components.llm_win_cpu_arm64]
name = "Llama.cpp Server (Windows ARM64 CPU)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-win-cpu-arm64.zip"
filename = "llama-b7345-bin-win-cpu-arm64.zip"
sha256 = "91e3ff43c123c7c30decfe5a44c291827c1e47359abaa2fbad1eb5392b3a0d85"
[components.llm_win_cuda12]
name = "Llama.cpp Server (Windows CUDA 12.4)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-win-cuda-12.4-x64.zip"
filename = "llama-b7345-bin-win-cuda-12.4-x64.zip"
sha256 = "7a82aba2662fa7d4477a7a40894de002854bae1ab8b0039888577c9a2ca24cae"
[components.llm_win_cuda13]
name = "Llama.cpp Server (Windows CUDA 13.1)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-win-cuda-13.1-x64.zip"
filename = "llama-b7345-bin-win-cuda-13.1-x64.zip"
sha256 = "06ea715cefb07e9862394e6d1ffa066f4c33add536b1f1aa058723f86ae05572"
[components.llm_win_vulkan]
name = "Llama.cpp Server (Windows Vulkan)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/llama-b7345-bin-win-vulkan-x64.zip"
filename = "llama-b7345-bin-win-vulkan-x64.zip"
sha256 = "3e948bee438f46c8ea0a3faf0416549391ee945ffa624b25bc1f73d60d668679"
# CUDA runtime libraries (required for CUDA builds on Windows)
[components.cudart_win_cuda12]
name = "CUDA Runtime (Windows CUDA 12.4)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/cudart-llama-bin-win-cuda-12.4-x64.zip"
filename = "cudart-llama-bin-win-cuda-12.4-x64.zip"
sha256 = "8c79a9b226de4b3cacfd1f83d24f962d0773be79f1e7b75c6af4ded7e32ae1d6"
[components.cudart_win_cuda13]
name = "CUDA Runtime (Windows CUDA 13.1)"
url = "https://github.com/ggml-org/llama.cpp/releases/download/b7345/cudart-llama-bin-win-cuda-13.1-x64.zip"
filename = "cudart-llama-bin-win-cuda-13.1-x64.zip"
sha256 = "f96935e7e385e3b2d0189239077c10fe8fd7e95690fea4afec455b1b6c7e3f18"
# Optional larger models (uncomment to include)
# [models.gpt_oss_20b]
# name = "GPT-OSS 20B F16 (requires 16GB+ VRAM or MoE)"
# url = "https://huggingface.co/unsloth/gpt-oss-20b-GGUF/resolve/main/gpt-oss-20b-F16.gguf"
# filename = "gpt-oss-20b-F16.gguf"
# sha256 = ""

View file

@ -1,101 +0,0 @@
{
"llama_cpp": {
"version": "b7345",
"base_url": "https://github.com/ggml-org/llama.cpp/releases/download",
"binaries": {
"linux": {
"x64": {
"cpu": "llama-{version}-bin-ubuntu-x64.zip",
"cpu_tar": "llama-{version}-bin-ubuntu-x64.tar.gz",
"vulkan": "llama-{version}-bin-ubuntu-vulkan-x64.zip",
"vulkan_tar": "llama-{version}-bin-ubuntu-vulkan-x64.tar.gz"
},
"s390x": {
"cpu": "llama-{version}-bin-ubuntu-s390x.zip",
"cpu_tar": "llama-{version}-bin-ubuntu-s390x.tar.gz"
}
},
"macos": {
"arm64": {
"cpu": "llama-{version}-bin-macos-arm64.zip",
"cpu_tar": "llama-{version}-bin-macos-arm64.tar.gz"
},
"x64": {
"cpu": "llama-{version}-bin-macos-x64.zip",
"cpu_tar": "llama-{version}-bin-macos-x64.tar.gz"
}
},
"windows": {
"x64": {
"cpu": "llama-{version}-bin-win-cpu-x64.zip",
"cuda_12": "llama-{version}-bin-win-cuda-12.4-x64.zip",
"cuda_13": "llama-{version}-bin-win-cuda-13.1-x64.zip",
"vulkan": "llama-{version}-bin-win-vulkan-x64.zip",
"sycl": "llama-{version}-bin-win-sycl-x64.zip",
"hip": "llama-{version}-bin-win-hip-radeon-x64.zip"
},
"arm64": {
"cpu": "llama-{version}-bin-win-cpu-arm64.zip",
"opencl_adreno": "llama-{version}-bin-win-opencl-adreno-arm64.zip"
}
},
"ios": {
"xcframework": "llama-{version}-xcframework.zip",
"xcframework_tar": "llama-{version}-xcframework.tar.gz"
}
},
"cuda_runtime": {
"windows": {
"cuda_12": "cudart-llama-bin-win-cuda-12.4-x64.zip",
"cuda_13": "cudart-llama-bin-win-cuda-13.1-x64.zip"
}
},
"checksums": {
"llama-b7345-bin-ubuntu-x64.zip": "sha256:91b066ecc53c20693a2d39703c12bc7a69c804b0768fee064d47df702f616e52",
"llama-b7345-bin-ubuntu-x64.tar.gz": "sha256:c5f4c8111887072a5687b42e0700116e93eddf14c5401fa7eba3ab0b8481ff4e",
"llama-b7345-bin-ubuntu-vulkan-x64.zip": "sha256:03f0b3acbead2ddc23267073a8f8e0207937c849d3704c46c61cf167c1001442",
"llama-b7345-bin-ubuntu-vulkan-x64.tar.gz": "sha256:9b02b406106cd20ea0568c43c28c587d7e4908b5b649e943adebb0e1ae726076",
"llama-b7345-bin-ubuntu-s390x.zip": "sha256:688ddad6996b1166eaaa76d5025e304c684116efe655e6e881d877505ecffccb",
"llama-b7345-bin-ubuntu-s390x.tar.gz": "sha256:118011b38b02fee21596ab5b1c40b56369da514645394b6528a466e18f4336f5",
"llama-b7345-bin-macos-arm64.zip": "sha256:72ae9b4a4605aa1223d7aabaa5326c66c268b12d13a449fcc06f61099cd02a52",
"llama-b7345-bin-macos-arm64.tar.gz": "sha256:dc7c6b64848180259db19eb5d8ee8424cffcbb053960e5c45d79db6b9ac4f40d",
"llama-b7345-bin-macos-x64.zip": "sha256:bec6b805cf7533f66b38f29305429f521dcb2be6b25dbce73a18df448ec55cc5",
"llama-b7345-bin-macos-x64.tar.gz": "sha256:9267a292f39a86b2ee5eaa553a06f4a2fda2aee35142cde40a9099432b304313",
"llama-b7345-bin-win-cpu-x64.zip": "sha256:ea449082c8e808a289d9a1e8331f90a0379ead4dd288a1b9a2d2c0a7151836cd",
"llama-b7345-bin-win-cpu-arm64.zip": "sha256:91e3ff43c123c7c30decfe5a44c291827c1e47359abaa2fbad1eb5392b3a0d85",
"llama-b7345-bin-win-cuda-12.4-x64.zip": "sha256:7a82aba2662fa7d4477a7a40894de002854bae1ab8b0039888577c9a2ca24cae",
"llama-b7345-bin-win-cuda-13.1-x64.zip": "sha256:06ea715cefb07e9862394e6d1ffa066f4c33add536b1f1aa058723f86ae05572",
"llama-b7345-bin-win-vulkan-x64.zip": "sha256:3e948bee438f46c8ea0a3faf0416549391ee945ffa624b25bc1f73d60d668679",
"llama-b7345-bin-win-sycl-x64.zip": "sha256:708ddb786cdeb43ceadaa57c0ca669ce05b86753bf859f5a95012c2ea481f9da",
"llama-b7345-bin-win-hip-radeon-x64.zip": "sha256:ba1fe643e27bae8dcdf6d7be459a6dc5d8385f179e71e749c53f52083c68e107",
"llama-b7345-bin-win-opencl-adreno-arm64.zip": "sha256:59d625d21fb64294b075c61ec1a5f01d394baf826bee2df847d0ea3ed21fa3f3",
"llama-b7345-xcframework.zip": "sha256:c94e870ba844e4938d6fccf0bfd64c9fe57884a14a3e2a4966e56e35a6cbaef4",
"llama-b7345-xcframework.tar.gz": "sha256:a542ceace2621d9d860f2ec64c1b2294ac71f292106b95dcaf239aec0a06dd55",
"cudart-llama-bin-win-cuda-12.4-x64.zip": "sha256:8c79a9b226de4b3cacfd1f83d24f962d0773be79f1e7b75c6af4ded7e32ae1d6",
"cudart-llama-bin-win-cuda-13.1-x64.zip": "sha256:f96935e7e385e3b2d0189239077c10fe8fd7e95690fea4afec455b1b6c7e3f18"
}
},
"models": {
"default_llm": {
"name": "DeepSeek-R1-Distill-Qwen-1.5B",
"url": "https://huggingface.co/bartowski/DeepSeek-R1-Distill-Qwen-1.5B-GGUF/resolve/main/DeepSeek-R1-Distill-Qwen-1.5B-Q3_K_M.gguf",
"filename": "DeepSeek-R1-Distill-Qwen-1.5B-Q3_K_M.gguf",
"size_mb": 1100,
"description": "Small reasoning model, good for CPU or minimal GPU (4GB VRAM)"
},
"default_embedding": {
"name": "BGE Small EN v1.5",
"url": "https://huggingface.co/CompendiumLabs/bge-small-en-v1.5-gguf/resolve/main/bge-small-en-v1.5-f32.gguf",
"filename": "bge-small-en-v1.5-f32.gguf",
"size_mb": 130,
"description": "Embedding model for vector search"
},
"large_llm": {
"name": "GPT-OSS 20B",
"url": "https://huggingface.co/unsloth/gpt-oss-20b-GGUF/resolve/main/gpt-oss-20b-F16.gguf",
"filename": "gpt-oss-20b-F16.gguf",
"size_mb": 40000,
"description": "Large model for GPU with 16GB+ VRAM"
}
}
}

View file

@ -1,466 +0,0 @@
{
"mcp_servers": [
{
"id": "azure-cosmos-db",
"name": "Azure Cosmos DB",
"description": "Enables Agents to interact with and retrieve data from Azure Cosmos DB accounts.",
"icon": "azure-cosmos-db",
"type": "Local",
"category": "Database",
"provider": "Microsoft"
},
{
"id": "azure-database-postgresql",
"name": "Azure Database for PostgreSQL",
"description": "Enables Agents to interact with and retrieve data from Azure Database for PostgreSQL resources using natural language prompts.",
"icon": "azure-database-postgresql",
"type": "Local",
"category": "Database",
"provider": "Microsoft"
},
{
"id": "azure-databricks-genie",
"name": "Azure Databricks Genie",
"description": "Azure Databricks Genie MCP server lets AI agents connect to Genie spaces so users can ask natural language questions and get specialized answers from their data easily.",
"icon": "azure-databricks-genie",
"type": "Remote",
"category": "Analytics",
"provider": "Microsoft"
},
{
"id": "azure-managed-redis",
"name": "Azure Managed Redis",
"description": "Azure Managed Redis MCP Server provides a natural language interface for agentic apps to interact with Azure Managed Redis—a high-speed, in-memory datastore that is ideal for low-latency use cases like agent memory, vector data store and semantic caching.",
"icon": "azure-managed-redis",
"type": "Local",
"category": "Database",
"provider": "Microsoft"
},
{
"id": "azure-sql",
"name": "Azure SQL MCP Server",
"description": "A secure, self-hosted MCP for interacting with SQL data (Azure SQL, SQL MI, SQL DW, SQL Server).",
"icon": "azure-sql",
"type": "Local",
"category": "Database",
"provider": "Microsoft"
},
{
"id": "elasticsearch",
"name": "Elasticsearch",
"description": "Search, retrieve, and analyze Elasticsearch data in developer and agentic workflows.",
"icon": "elasticsearch",
"type": "Remote",
"category": "Search",
"provider": "Elastic"
},
{
"id": "mongodb",
"name": "MongoDB MCP Server",
"description": "MongoDB MCP Server allows any MCP-aware LLM to connect to MongoDB Atlas for admin tasks and to MongoDB databases for data operations, all through natural language.",
"icon": "mongodb",
"type": "Local",
"category": "Database",
"provider": "MongoDB"
},
{
"id": "pinecone-assistant",
"name": "Pinecone Assistant MCP Server",
"description": "Pinecone Assistant MCP server helps prototype and deploy assistants that retrieve context-aware answers grounded in proprietary data.",
"icon": "pinecone",
"type": "Remote",
"category": "Vector Database",
"provider": "Pinecone"
},
{
"id": "vercel",
"name": "Vercel",
"description": "With Vercel MCP, you can explore projects, inspect failed deployments, fetch logs, and more right from your AI client.",
"icon": "vercel",
"type": "Remote",
"category": "Deployment",
"provider": "Vercel"
},
{
"id": "amplitude",
"name": "Amplitude MCP Server",
"description": "Search, access, and get insights on your Amplitude product analytics data.",
"icon": "amplitude",
"type": "Remote",
"category": "Analytics",
"provider": "Amplitude"
},
{
"id": "atlan",
"name": "Atlan",
"description": "The Atlan MCP server provides a set of tools that enable AI agents to work directly with Atlan metadata. These tools supply real-time context to AI environments, making it easier to search, explore, and update metadata without leaving your workflow.",
"icon": "atlan",
"type": "Remote",
"category": "Data Catalog",
"provider": "Atlan"
},
{
"id": "atlassian",
"name": "Atlassian",
"description": "Connect to Jira and Confluence for issue tracking and documentation.",
"icon": "atlassian",
"type": "Remote",
"category": "Productivity",
"provider": "Atlassian"
},
{
"id": "azure-language-foundry",
"name": "Azure Language in Foundry Tools",
"description": "The MCP server enables AI agents to access Azure Language in Foundry Tools for accurate, explainable and compliant NLP capabilities.",
"icon": "azure-language",
"type": "Remote",
"category": "AI/ML",
"provider": "Microsoft"
},
{
"id": "azure-speech",
"name": "Azure Speech MCP Server",
"description": "A hosted MCP server that exposes Azure Speech capabilities (speech-to-text, text-to-speech and streaming speech I/O) to agents and LLM workflows.",
"icon": "azure-speech",
"type": "Remote",
"category": "AI/ML",
"provider": "Microsoft"
},
{
"id": "box",
"name": "Box MCP Server",
"description": "Access and manage your Box content with AI-powered tools for file operations, collaboration, and metadata extraction.",
"icon": "box",
"type": "Remote",
"category": "Storage",
"provider": "Box"
},
{
"id": "cast-imaging",
"name": "CAST Imaging MCP Server",
"description": "Deterministic mapping of application architecture and code objects to support discovery, impact analysis, and technical debt remediation.",
"icon": "cast-imaging",
"type": "Remote",
"category": "DevOps",
"provider": "CAST"
},
{
"id": "celonis",
"name": "Celonis PI Graph MCP Server",
"description": "Agent toolkit that provides process intelligence context, action triggering, and write-back capabilities into Celonis.",
"icon": "celonis",
"type": "Remote",
"category": "Process Mining",
"provider": "Celonis"
},
{
"id": "exa",
"name": "Exa Web Search",
"description": "Exa MCP is a powerful web search and web crawling MCP. It lets you do real-time web searches, extract content from any URL, and even run deep research for detailed reports.",
"icon": "exa",
"type": "Remote",
"category": "Search",
"provider": "Exa"
},
{
"id": "factory-rca",
"name": "Factory RCA MCP",
"description": "Toolset for manufacturing root-cause analysis, anomaly detection, and telemetry-driven recommendations.",
"icon": "factory",
"type": "Remote",
"category": "Manufacturing",
"provider": "Factory"
},
{
"id": "github",
"name": "GitHub",
"description": "Access GitHub repositories, issues, and pull requests through secure API integration. If you need the GitHub MCP server to access your private repo, make sure you have installed the GitHub app.",
"icon": "github",
"type": "Remote",
"category": "Development",
"provider": "GitHub"
},
{
"id": "huggingface",
"name": "Hugging Face MCP Server",
"description": "Search through millions of Hugging Face models, datasets, applications and research papers, and use the Spaces applications you've selected.",
"icon": "huggingface",
"type": "Remote",
"category": "AI/ML",
"provider": "Hugging Face"
},
{
"id": "infobip-rcs",
"name": "Infobip RCS MCP server",
"description": "Infobip RCS MCP server enables seamless integration with our communication platform that allows you to reach your customers globally through RCS.",
"icon": "infobip",
"type": "Remote",
"category": "Communication",
"provider": "Infobip"
},
{
"id": "infobip-sms",
"name": "Infobip SMS MCP server",
"description": "The Infobip SMS MCP server enables agentic and developer workflows to send and manage SMS messages through Infobip's platform.",
"icon": "infobip",
"type": "Remote",
"category": "Communication",
"provider": "Infobip"
},
{
"id": "infobip-whatsapp",
"name": "Infobip WhatsApp MCP server",
"description": "Infobip WhatsApp MCP server enables seamless integration with our communication platform that allows you to reach your customers globally through WhatsApp.",
"icon": "infobip",
"type": "Remote",
"category": "Communication",
"provider": "Infobip"
},
{
"id": "intercom",
"name": "Intercom MCP Server",
"description": "Secure, read-only access to Intercom conversations and contacts for MCP-compatible AI tools.",
"icon": "intercom",
"type": "Remote",
"category": "Customer Support",
"provider": "Intercom"
},
{
"id": "marketnode",
"name": "Marketnode MCP Server",
"description": "AI-powered document data extraction, workflow automation, transaction management and tokenization for financial institutions and enterprises.",
"icon": "marketnode",
"type": "Remote",
"category": "Finance",
"provider": "Marketnode"
},
{
"id": "foundry",
"name": "Foundry MCP Server (preview)",
"description": "Foundry MCP Server (preview) offers instant access to model exploration, deployment of models and agents, and performance evaluation. This fully cloud-native MCP server is integrated with Visual Studio Code and Foundry agents, and secured by Microsoft Entra ID, RBAC, and tenant-level conditional access with Azure Policy for enterprise control.",
"icon": "foundry",
"type": "Remote",
"category": "AI/ML",
"provider": "Microsoft"
},
{
"id": "microsoft-enterprise",
"name": "Microsoft MCP Server for Enterprise",
"description": "Official Microsoft MCP Server to query Microsoft Entra data using natural language.",
"icon": "microsoft",
"type": "Remote",
"category": "Enterprise",
"provider": "Microsoft"
},
{
"id": "mihcm",
"name": "MiHCM MCP Server",
"description": "Provides secure access to employee and leave management data from the MiHCM HR platform through standardized MCP server.",
"icon": "mihcm",
"type": "Remote",
"category": "HR",
"provider": "MiHCM"
},
{
"id": "morningstar",
"name": "Morningstar MCP Server",
"description": "Access Morningstar data, research, and capabilities through specialized MCP tools for global securities.",
"icon": "morningstar",
"type": "Remote",
"category": "Finance",
"provider": "Morningstar"
},
{
"id": "microsoft-sentinel",
"name": "Microsoft Sentinel Data Exploration",
"description": "The data exploration tool collection in the Microsoft Sentinel MCP server lets you search for relevant tables and retrieve data from Microsoft Sentinel's data lake using natural language.",
"icon": "microsoft-sentinel",
"type": "Remote",
"category": "Security",
"provider": "Microsoft"
},
{
"id": "microsoft-learn",
"name": "Microsoft Learn",
"description": "AI assistant with real-time access to official Microsoft documentation.",
"icon": "microsoft-learn",
"type": "Remote",
"category": "Documentation",
"provider": "Microsoft"
},
{
"id": "neon",
"name": "Neon",
"description": "Manage and query Neon Postgres databases with natural language.",
"icon": "neon",
"type": "Remote",
"category": "Database",
"provider": "Neon"
},
{
"id": "netlify",
"name": "Netlify",
"description": "Deploy, secure, and manage websites with Netlify.",
"icon": "netlify",
"type": "Remote",
"category": "Deployment",
"provider": "Netlify"
},
{
"id": "pipedream",
"name": "Pipedream",
"description": "Securely connect to 10,000+ tools from 3,000+ APIs with Pipedream MCP.",
"icon": "pipedream",
"type": "Remote",
"category": "Integration",
"provider": "Pipedream"
},
{
"id": "postman",
"name": "Postman",
"description": "Postman's remote MCP server connects AI agents, assistants, and chatbots directly to your APIs on Postman.",
"icon": "postman",
"type": "Remote",
"category": "API",
"provider": "Postman"
},
{
"id": "sophos-intelix",
"name": "Sophos Intelix MCP Server",
"description": "Sophos Intelix delivers threat intelligence into analyst workflows, enabling agents to access file, URL, and IP reputation and threat analysis.",
"icon": "sophos",
"type": "Remote",
"category": "Security",
"provider": "Sophos"
},
{
"id": "stripe",
"name": "Stripe",
"description": "Payment processing and financial infrastructure tools.",
"icon": "stripe",
"type": "Remote",
"category": "Payments",
"provider": "Stripe"
},
{
"id": "supabase",
"name": "Supabase",
"description": "Connect your Supabase projects to AI agents: design tables and migrations; create database branches; build custom APIs with Edge Functions; retrieve logs and more.",
"icon": "supabase",
"type": "Remote",
"category": "Database",
"provider": "Supabase"
},
{
"id": "tavily",
"name": "Tavily MCP",
"description": "Real-time web search, extraction, crawling and mapping tools for agentic workflows with source citations.",
"icon": "tavily",
"type": "Remote",
"category": "Search",
"provider": "Tavily"
},
{
"id": "tomtom",
"name": "TomTom Maps",
"description": "Give your application real-time geospatial context from TomTom — including maps, routing, search, geocoding and traffic.",
"icon": "tomtom",
"type": "Remote",
"category": "Maps",
"provider": "TomTom"
},
{
"id": "wix",
"name": "Wix MCP",
"description": "Unified access to Wix's development ecosystem for documentation, implementation, and site management.",
"icon": "wix",
"type": "Remote",
"category": "Web Development",
"provider": "Wix"
},
{
"id": "10to8",
"name": "10to8 Appointment Scheduling",
"description": "10to8 is a powerful appointment management, communications & online booking system.",
"icon": "10to8",
"type": "Custom",
"category": "Scheduling",
"provider": "10to8"
},
{
"id": "1docstop",
"name": "1DocStop",
"description": "The best document management system for your web & mobile apps. Store, Manage, and Access all your documents whenever and wherever you are.",
"icon": "1docstop",
"type": "Custom",
"category": "Document Management",
"provider": "1DocStop"
},
{
"id": "1me-corporate",
"name": "1Me Corporate",
"description": "1Me is the easiest and fastest way to share your contact information. With 1Me, you can have an unlimited number of contact cards.",
"icon": "1me",
"type": "Custom",
"category": "Contact Management",
"provider": "1Me"
},
{
"id": "1pt",
"name": "1pt (Independent Publisher)",
"description": "1pt is a URL shortening service and hosts over 15,000+ redirects with 200,000+ visits.",
"icon": "1pt",
"type": "Custom",
"category": "URL Shortener",
"provider": "1pt"
}
],
"categories": [
"Database",
"Analytics",
"Search",
"Vector Database",
"Deployment",
"Data Catalog",
"Productivity",
"AI/ML",
"Storage",
"DevOps",
"Process Mining",
"Development",
"Communication",
"Customer Support",
"Finance",
"Enterprise",
"HR",
"Security",
"Documentation",
"Integration",
"API",
"Payments",
"Maps",
"Web Development",
"Scheduling",
"Document Management",
"Contact Management",
"URL Shortener",
"Manufacturing"
],
"types": [
{
"id": "Local",
"name": "MCP: Local",
"description": "Runs locally on your machine"
},
{
"id": "Remote",
"name": "MCP: Remote",
"description": "Hosted remote MCP server"
},
{
"id": "Custom",
"name": "Custom",
"description": "Custom integration"
}
]
}

184
CHANGELOG.md Normal file
View file

@ -0,0 +1,184 @@
## [1.2.1](https://github.com/pragmatismo-io/BotServer/compare/1.2.0...1.2.1) (2018-12-18)
### Bug Fixes
* **kb:** Fix in Faq and Menu dialogs. ([6ba8c09](https://github.com/pragmatismo-io/BotServer/commit/6ba8c09))
* **startup:** Startup improved and more checks added. ([5d6c60e](https://github.com/pragmatismo-io/BotServer/commit/5d6c60e))
* **webchat:** Sync versions and MSFT strategy. ([238c0bf](https://github.com/pragmatismo-io/BotServer/commit/238c0bf))
# [1.2.0](https://github.com/pragmatismo-io/BotServer/compare/1.1.1...1.2.0) (2018-12-13)
### Features
* **webchat:** Update of webchat to the newer version 4. ([0270a8e](https://github.com/pragmatismo-io/BotServer/commit/0270a8e))
## [1.1.1](https://github.com/pragmatismo-io/BotServer/compare/1.1.0...1.1.1) (2018-12-08)
### Bug Fixes
* **package:** update csv-parse to version 4.1.0 ([a606ef1](https://github.com/pragmatismo-io/BotServer/commit/a606ef1))
# [1.1.0](https://github.com/pragmatismo-io/BotServer/compare/1.0.8...1.1.0) (2018-12-06)
### Bug Fixes
* **CI:** default.gbui compilation issues. ([7a11919](https://github.com/pragmatismo-io/BotServer/commit/7a11919))
* **CI:** Migrating CI logic to package.json. ([8ee048f](https://github.com/pragmatismo-io/BotServer/commit/8ee048f))
* **core:** Bot boot logic being fixed. ([1761e06](https://github.com/pragmatismo-io/BotServer/commit/1761e06))
* **core:** Bot Server is runnable again after refactory. ([9379dec](https://github.com/pragmatismo-io/BotServer/commit/9379dec))
* **core:** Loaded dynamically a .js file containing converted VBA dialogs. ([3f32e48](https://github.com/pragmatismo-io/BotServer/commit/3f32e48))
* **core:** Moved logic from app to core. ([c1db8be](https://github.com/pragmatismo-io/BotServer/commit/c1db8be))
* **default.gbui:** Removing warnings. ([02ed085](https://github.com/pragmatismo-io/BotServer/commit/02ed085))
* **gbdialog:** Renamed alpha command to alpha-VBA added documentation files. ([9cd66b8](https://github.com/pragmatismo-io/BotServer/commit/9cd66b8))
* **gbdialog:** Support for multiples hear blocks. ([3bb9d65](https://github.com/pragmatismo-io/BotServer/commit/3bb9d65))
* **gbdialog:** Trying to save context. ([ce04290](https://github.com/pragmatismo-io/BotServer/commit/ce04290))
* **gbdialog:** Updating packages to latest versions and sync *-lock file. ([dcafb7a](https://github.com/pragmatismo-io/BotServer/commit/dcafb7a))
* **gbdialog:** VBA hear must be a wrapper call. ([6915d58](https://github.com/pragmatismo-io/BotServer/commit/6915d58))
* **gbdialog:** VBA is running financial simulations. ([9fb431c](https://github.com/pragmatismo-io/BotServer/commit/9fb431c))
* **gbdialog:** VBA is running. ([2dd359a](https://github.com/pragmatismo-io/BotServer/commit/2dd359a))
* **gbdialog:** VBA loop done - one thing left to automate: Hear wrapper. ([776fe03](https://github.com/pragmatismo-io/BotServer/commit/776fe03))
* **package:** update azure-arm-resource to version 7.2.1 ([4e72507](https://github.com/pragmatismo-io/BotServer/commit/4e72507))
* **package:** update botlib to version 0.1.7 ([8205599](https://github.com/pragmatismo-io/BotServer/commit/8205599))
* **package:** update csv-parse to version 4.0.0 ([3fb5a9a](https://github.com/pragmatismo-io/BotServer/commit/3fb5a9a))
* **package:** update marked to version 0.5.2 ([405fc96](https://github.com/pragmatismo-io/BotServer/commit/405fc96))
* **package:** update pragmatismo-io-framework to version 1.0.19 ([67c2ce7](https://github.com/pragmatismo-io/BotServer/commit/67c2ce7))
* **tests:** Disabling VM tests tentative for now. ([9d5a9c6](https://github.com/pragmatismo-io/BotServer/commit/9d5a9c6))
### Features
* **gbdialog:** The first VBA code is run. ([f0a0cd3](https://github.com/pragmatismo-io/BotServer/commit/f0a0cd3))
* **scripting:** First code changes to VBA implementation. ([09715bc](https://github.com/pragmatismo-io/BotServer/commit/09715bc))
## [1.0.8](https://github.com/pragmatismo-io/BotServer/compare/1.0.7...1.0.8) (2018-11-18)
### Bug Fixes
* **docs:** Video thumbnail update to raw picture URL. ([564b394](https://github.com/pragmatismo-io/BotServer/commit/564b394))
## [1.0.7](https://github.com/pragmatismo-io/BotServer/compare/1.0.6...1.0.7) (2018-11-18)
### Bug Fixes
* **config:** CHANGELOG generator fixing. ([ac18782](https://github.com/pragmatismo-io/BotServer/commit/ac18782))
## Version 0.1.9 (Before CI with Semantic Release)
* Republishing.
## Version 0.1.8
* Republishing.
## Version 0.1.7
* 100% automated development environement setup.
* Azure Deployer based on ARM done - setup is easy as F5 in Visual Studio.
* Auto-ngrok - No more reverse proxy manual configuration.
* Strategy to replicate itself in several subscriptions done.
## Version 0.1.6
* Updated packages references.
## Version 0.1.5
* Updated packages references.
## Version 0.1.4
* Error handling improved and logging enriched as well.
* Setting DATABASE_ is now STORAGE_.
## Version 0.1.3
* FIX: Admin now is internationalized.
* FIX: Webchat now receives a private token.
* FIX: OAuth2 now has got revised and included state to avoid CSRF attacks.
* FIX: Now server will only start with a secure administration password.
## Version 0.1.2
* NEW: kb.gbapp now has a complete browser of excel articles.
* FIX: Some security improved.
* NEW: Protocol changes for exchanging questions between UI and Bot Server.
## Version 0.1.0
- NEW: Migration to Bot Framework v4.
## Version 0.0.31
- FIX: Updated dependencies versions.
## Version 0.0.30
- FIX: Packages updated.
- NEW: DATABASE_SYNC_ALTER environment parameter.
- NEW: DATABASE_SYNC_FORCE environment parameter.
- NEW: Define constraint names in MSSQL.
## Version 0.0.29
- NEW: Added STT and TTS capabilities to default.gbui.
## Version 0.0.28
- FIX: gbui packages updated.
## Version 0.0.27
- FIX: Packages updated.
## Version 0.0.26
- FIX: Packages updated.
- NEW: If a bot package's name begins with '.', then it is ignored.
- NEW: Created DATABASE_LOGGING environment parameter.
## Version 0.0.25
- FIX: Whastapp line now can be turned off;
- FIX: More error logging on BuildMin.
## Version 0.0.24
- FIX: AskDialog compilation error.
- FIX: More Whatsapp line adjustments: Duplicated 'Hi!' & log enrichment.
## Version 0.0.23
- FIX: Duplicated asking on main loop removed.
- FIX: Whatsapp log phrase correction.
- FIX: Directline can now receive messages sent in not-in-conversation, projector-only fashion.
## Version 0.0.22
- NEW: Auto-dispatch to dialog based on intent name.
## Version 0.0.21
- FIX: Whatsapp directline client improved.
## Version 0.0.20
- NEW: Whatsapp directline client is now working in preview.
## Version 0.0.19
- NEW: Whatsapp directline client started.
- NEW: Console directline client.
- NEW: Now each .gbapp has it own set of syspackages loaded.
- NEW: Added support for Whatsapp external service key on bot instance model.
## Version 0.0.18
- FIX: .gbapp files now correctly loaded before other package types so custom models can be used to sync DB.
- NEW: Removed Boot Package feature. Now every .gbot found on deploy folders are deployed on startup.

48
CODE_OF_CONDUCT.md Normal file
View file

@ -0,0 +1,48 @@
# Contributor Covenant Code of Conduct
## Our Pledge
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
## Our Standards
Examples of behavior that contributes to creating a positive environment include:
* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
* Writing general pieces of code so it can be widely used.
Examples of unacceptable behavior by participants include:
* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting
* Call a person other name than that declared by the person
## Our Responsibilities
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
## Scope
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the Pragmatismo.io security team at security@pragmatismo.io. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/

57
CONTRIBUTING.md Normal file
View file

@ -0,0 +1,57 @@
# Instructions for Logging Issues
## 1. Search for Duplicates
[Search the existing issues](https://github.com/pragmatismo-io/BotServer/issues) before logging a new one.
## 2. Do you have a question?
Please use the issue tracker for bugs and suggestions.
If you have a *question*, please use [Stack Overflow](https://stackoverflow.com/questions/tagged/botserver)
## 3. Did you find a bug?
We are not surprised, we're still in early preview so there are plenty of them right now.
When logging a bug, please be sure to include the following:
* The platform you were using
* If at all possible, an *isolated* way to reproduce the behavior
* The behavior you expect to see, and the actual behavior
## 4. Do you have a suggestion?
We also accept suggestions in the issue tracker.
In general, things we find useful when reviewing suggestions are:
* A description of the problem you're trying to solve
* An overview of the suggested solution
* Examples of how the suggestion would work in various places
# Instructions for Contributing Code
## Contributing bug fixes
General Bots is current in early preview. We're still accepting contributions in the form of bug fixes.
A bug must have an issue tracking it in the issue tracker that has been approved by the Pragmatismo.io team. Your pull request should include a link to the bug that you are fixing. If you've submitted a PR for a bug, please post a comment in the bug to avoid duplication of effort.
## Contributing features
Please open an issue with the `Schema` label to get a discussion started.
## Legal
We appreciate community contributions to code repositories open sourced by Pragmatismo.io. By signing a contributor license agreement, we ensure that the community is free to use your contributions.
## Housekeeping
Your pull request should:
* Include a description of what your change intends to do
* Be a child commit of a reasonably recent commit in the **master** branch
* Requests need not be a single commit, but should be a linear sequence of commits (i.e. no merge commits in your PR)
* Have clear commit messages
* e.g. "Refactor feature", "Fix issue", "Add tests for issue"
## Running (and adding) the Tests
*Coming soon*

View file

@ -1,235 +0,0 @@
[package]
name = "botserver"
version = "6.2.0"
edition = "2021"
resolver = "2"
[dependencies.botlib]
workspace = true
features = ["database", "i18n"]
[features]
# ===== DEFAULT =====
default = ["chat", "automation", "drive", "tasks", "cache", "directory", "llm", "crawler", "browser", "terminal", "editor", "mail", "whatsapp"]
browser = ["automation", "drive", "cache"]
terminal = ["automation", "drive", "cache"]
# ===== CORE INFRASTRUCTURE (Can be used standalone) =====
scripting = ["dep:rhai"]
automation = ["scripting", "dep:cron"]
drive = ["dep:aws-config", "dep:aws-sdk-s3", "dep:aws-smithy-async", "dep:pdf-extract", "dep:notify"]
cache = ["dep:redis"]
directory = []
crawler = ["drive", "cache"]
# ===== APPS (Each includes what it needs from core) =====
# Communication
chat = ["automation", "drive", "cache"]
people = ["automation", "drive", "cache"]
mail = ["automation", "drive", "cache", "dep:lettre", "dep:mailparse", "dep:imap"]
meet = ["automation", "drive", "cache"]
social = ["automation", "drive", "cache"]
# Productivity
calendar = ["automation", "drive", "cache"]
tasks = ["automation", "drive", "cache", "dep:cron"]
project = ["automation", "drive", "cache", "quick-xml"]
goals = ["automation", "drive", "cache"]
workspaces = ["automation", "drive", "cache"]
tickets = ["automation", "drive", "cache"]
billing = ["automation", "drive", "cache"]
# Documents
docs = ["automation", "drive", "cache", "docx-rs", "ooxmlsdk"]
sheet = ["automation", "drive", "cache", "calamine", "dep:rust_xlsxwriter", "dep:umya-spreadsheet"]
slides = ["automation", "drive", "cache", "ooxmlsdk"]
paper = ["automation", "drive", "cache"]
# Media
video = ["automation", "drive", "cache"]
player = ["automation", "drive", "cache"]
canvas = ["automation", "drive", "cache"]
# Learning
learn = ["automation", "drive", "cache", "crawler"]
research = ["automation", "drive", "cache", "llm", "vectordb"]
sources = ["automation", "drive", "cache"]
# Analytics
analytics = ["automation", "drive", "cache"]
dashboards = ["automation", "drive", "cache"]
monitoring = ["automation", "drive", "cache", "dep:sysinfo"]
# Development
designer = ["automation", "drive", "cache"]
editor = ["automation", "drive", "cache"]
# Admin
attendant = ["automation", "drive", "cache"]
security = ["automation", "drive", "cache"]
settings = ["automation", "drive", "cache"]
whatsapp = ["automation", "drive", "cache"]
telegram = ["automation", "drive", "cache"]
instagram = ["automation", "drive", "cache"]
msteams = ["automation", "drive", "cache"]
# Core Tech
llm = ["automation", "drive", "cache"]
vectordb = ["automation", "drive", "cache", "dep:qdrant-client"]
nvidia = ["automation", "drive", "cache"]
compliance = ["automation", "drive", "cache", "dep:csv"]
timeseries = ["automation", "drive", "cache"]
weba = ["automation", "drive", "cache"]
progress-bars = ["automation", "drive", "cache", "dep:indicatif"]
grpc = ["automation", "drive", "cache"]
jemalloc = ["automation", "drive", "cache", "dep:tikv-jemallocator", "dep:tikv-jemalloc-ctl"]
console = ["automation", "drive", "cache", "dep:crossterm", "dep:ratatui"]
# ===== BUNDLES (Optional - for convenience) =====
minimal = ["chat"]
lightweight = ["chat", "tasks", "people"]
full = ["chat", "people", "mail", "tasks", "calendar", "drive", "docs", "llm", "cache", "compliance"]
embed-ui = ["dep:rust-embed"]
[dependencies]
diesel_migrations = { workspace = true }
bigdecimal = { workspace = true }
# === CORE RUNTIME ===
aes-gcm = { workspace = true }
anyhow = { workspace = true }
argon2 = { workspace = true }
async-trait = { workspace = true }
axum = { workspace = true }
axum-server = { workspace = true }
base64 = { workspace = true }
chrono = { workspace = true, features = ["clock", "std"] }
color-eyre = { workspace = true }
diesel = { workspace = true, features = ["postgres", "uuid", "chrono", "serde_json", "r2d2", "numeric", "32-column-tables"] }
dirs = { workspace = true }
dotenvy = { workspace = true }
futures = { workspace = true }
futures-util = { workspace = true }
git2 = "0.19"
hex = { workspace = true }
hmac = { workspace = true }
log = { workspace = true }
num-format = { workspace = true }
once_cell = { workspace = true }
rand = { workspace = true }
regex = { workspace = true }
reqwest = { workspace = true, features = ["rustls-tls", "multipart", "stream", "json"] }
serde = { workspace = true, features = ["derive", "std"] }
serde_json = { workspace = true }
toml = { workspace = true }
sha2 = { workspace = true }
sha1 = { workspace = true }
tokio = { workspace = true, features = ["full", "process"] }
tower-http = { workspace = true, features = ["cors", "fs", "trace"] }
tracing = { workspace = true }
url = { workspace = true }
urlencoding = { workspace = true }
uuid = { workspace = true, features = ["v4", "v5"] }
# === TLS/SECURITY DEPENDENCIES ===
rustls = { workspace = true, features = ["ring", "std", "tls12"] }
tokio-rustls = { workspace = true }
rcgen = { workspace = true, features = ["crypto", "ring", "pem"] }
x509-parser = { workspace = true }
ring = { workspace = true }
ciborium = { workspace = true }
time = { workspace = true, features = ["formatting"] }
jsonwebtoken = { workspace = true }
# === APP-SPECIFIC DEPENDENCIES ===
# mail Integration (mail feature)
imap = { workspace = true, optional = true }
lettre = { workspace = true, optional = true }
mailparse = { workspace = true, optional = true }
# Vector Database (vectordb feature)
qdrant-client = { workspace = true, optional = true }
# Document Processing
docx-rs = { workspace = true, optional = true }
ooxmlsdk = { workspace = true, optional = true, features = ["parts"] }
calamine = { workspace = true, optional = true }
rust_xlsxwriter = { workspace = true, optional = true }
umya-spreadsheet = { workspace = true, optional = true }
# File Storage & Drive (drive feature)
aws-config = { workspace = true, features = ["behavior-version-latest", "rt-tokio", "rustls"], optional = true }
aws-sdk-s3 = { workspace = true, features = ["rt-tokio", "rustls"], optional = true }
aws-smithy-async = { workspace = true, optional = true }
pdf-extract = { workspace = true, optional = true }
quick-xml = { workspace = true, optional = true }
flate2 = { workspace = true }
zip = { workspace = true }
tar = { workspace = true }
# Task Management (tasks feature)
cron = { workspace = true, optional = true }
# Automation & Scripting (automation feature)
rhai = { workspace = true, optional = true }
# Compliance & Reporting (compliance feature)
csv = { workspace = true, optional = true }
# Console/TUI (console feature)
crossterm = { workspace = true, optional = true }
ratatui = { workspace = true, optional = true }
# QR Code Generation
png = { workspace = true }
qrcode = { workspace = true }
# Error handling
thiserror = { workspace = true }
# Caching/Sessions (cache feature)
redis = { workspace = true, features = ["tokio-comp"], optional = true }
# System Monitoring (monitoring feature)
sysinfo = { workspace = true, optional = true }
# UI Enhancement (progress-bars feature)
indicatif = { workspace = true, optional = true }
smartstring = { workspace = true }
# Memory allocator (jemalloc feature)
tikv-jemallocator = { workspace = true, optional = true }
tikv-jemalloc-ctl = { workspace = true, optional = true }
scopeguard = { workspace = true }
# Vault secrets management
vaultrs = { workspace = true }
# Calendar standards (RFC 5545)
icalendar = { workspace = true }
# Rate limiting
governor = { workspace = true }
# RSS feed parsing
rss = { workspace = true }
# HTML parsing/web scraping
scraper = { workspace = true }
walkdir = { workspace = true }
# File system monitoring (for local .gbai monitoring)
notify = { workspace = true, optional = true }
# Embedded static files
rust-embed = { workspace = true, optional = true }
[dev-dependencies]
mockito = { workspace = true }
tempfile = { workspace = true }
bigdecimal = { workspace = true }
[lints]
workspace = true

View file

@ -1,5 +1,5 @@
General Bots is licensed under a dual license. To check which license
edition of General bots you have installed, please ask info@pragmatismo.com.br
edition of General bots you have installed, please ask info@pragmatismo.io
informing your Customer ID.
If you modify this Program, or any covered work, by combining it

7
LOCALIZATION.md Normal file
View file

@ -0,0 +1,7 @@
# Localization in General Bots
## .gbapp
The localization is done by adding a strings.ts file to the root of the .gbapp package.

View file

@ -1,594 +0,0 @@
# BotServer Cinema Viewer Logging Plan
## 🎬 The Cinema Viewer Philosophy
Think of your logs as a movie with different viewing modes:
- **INFO** = **The Movie** - Watch the main story unfold (production-ready)
- **DEBUG** = **Director's Commentary** - Behind-the-scenes details (troubleshooting)
- **TRACE** = **Raw Footage** - Every single take and detail (deep debugging)
- **WARN** = **Plot Holes** - Things that shouldn't happen but are recoverable
- **ERROR** = **Scene Failures** - Critical issues that break the narrative
---
## 📊 Log Level Definitions
### ERROR - Critical Failures
**When to use:** System cannot proceed, requires immediate attention
```rust
// ✅ GOOD - Actionable, clear context
error!("Database connection failed - retrying in 5s: {}", e);
error!("Authentication failed for user {}: invalid credentials", user_id);
error!("Stage 2 BUILD failed: {}", e);
// ❌ BAD - Vague, no context
error!("Error!");
error!("Failed");
error!("Something went wrong: {}", e);
```
### WARN - Recoverable Issues
**When to use:** Unexpected state but system can continue
```rust
// ✅ GOOD - Explains the issue and impact
warn!("Failed to create data directory: {}. Using fallback.", e);
warn!("LLM server not ready - deferring embedding generation");
warn!("Rate limit approaching for API key {}", key_id);
// ❌ BAD - Not actionable
warn!("Warning");
warn!("Something happened");
```
### INFO - The Main Story
**When to use:** Key events, state changes, business milestones
```rust
// ✅ GOOD - Tells a story, shows progress
info!("Pipeline starting - task: {}, intent: {}", task_id, intent);
info!("Stage 1 PLAN complete - {} nodes planned", node_count);
info!("User {} logged in from {}", user_id, ip_address);
info!("Server started on port {}", port);
// ❌ BAD - Too verbose, implementation details
info!("Entering function process_request");
info!("Variable x = {}", x);
info!("Loop iteration {}", i);
```
### DEBUG - Behind the Scenes
**When to use:** Troubleshooting information, decision points, state inspections
```rust
// ✅ GOOD - Helps diagnose issues
debug!("Request payload: {:?}", payload);
debug!("Using cache key: {}", cache_key);
debug!("Retry attempt {} of {}", attempt, max_retries);
debug!("Selected LLM model: {} for task type: {}", model, task_type);
// ❌ BAD - Too trivial
debug!("Variable assigned");
debug!("Function called");
```
### TRACE - Raw Footage
**When to use:** Step-by-step execution, loop iterations, detailed flow
```rust
// ✅ GOOD - Detailed execution path
trace!("Starting monitoring loop");
trace!("Processing file: {:?}", path);
trace!("Checking bot directory: {}", dir);
trace!("WebSocket message received: {} bytes", len);
// ❌ BAD - Noise without value
trace!("Line 100");
trace!("Got here");
trace!("...");
```
---
## 🎭 Logging Patterns by Module Type
### 1. Orchestration & Pipeline Modules
**Examples:** `auto_task/orchestrator.rs`, `auto_task/agent_executor.rs`
**INFO Level:** Show the story arc
```rust
info!("Pipeline starting - task: {}, intent: {}", task_id, intent);
info!("Stage 1 PLAN starting - Agent #1 analyzing request");
info!("Stage 1 PLAN complete - {} nodes planned", node_count);
info!("Stage 2 BUILD complete - {} resources, url: {}", count, url);
info!("Pipeline complete - task: {}, nodes: {}, resources: {}", task_id, nodes, resources);
```
**DEBUG Level:** Show decision points
```rust
debug!("Classified intent as: {:?}", classification);
debug!("Selected app template: {}", template_name);
debug!("Skipping stage 3 - no resources to review");
```
**TRACE Level:** Show execution flow
```rust
trace!("Broadcasting thought to UI: {}", thought);
trace!("Updating agent {} status: {} -> {}", id, old, new);
trace!("Sub-task generated: {}", task_name);
```
### 2. File Monitoring & Compilation
**Examples:** `drive/local_file_monitor.rs`, `drive/drive_monitor/mod.rs`
**INFO Level:** Key file operations
```rust
info!("Local file monitor started - watching /opt/gbo/data/*.gbai");
info!("Compiling bot: {} ({} files)", bot_name, file_count);
info!("Bot {} compiled successfully - {} tools generated", bot_name, tool_count);
```
**DEBUG Level:** File processing details
```rust
debug!("Detected change in: {:?}", path);
debug!("Recompiling {} - modification detected", bot_name);
debug!("Skipping {} - no changes detected", bot_name);
```
**TRACE Level:** File system operations
```rust
trace!("Scanning directory: {:?}", dir);
trace!("File modified: {:?} at {:?}", path, time);
trace!("Watching directory: {:?}", path);
```
### 3. Security & Authentication
**Examples:** `security/jwt.rs`, `security/api_keys.rs`, `security/sql_guard.rs`
**INFO Level:** Security events (always log these!)
```rust
info!("User {} logged in from {}", user_id, ip);
info!("API key {} created for user {}", key_id, user_id);
info!("Failed login attempt for user {} from {}", username, ip);
info!("Rate limit exceeded for IP: {}", ip);
```
**DEBUG Level:** Security checks
```rust
debug!("Validating JWT for user {}", user_id);
debug!("Checking API key permissions: {:?}", permissions);
debug!("SQL query sanitized: {}", safe_query);
```
**TRACE Level:** Security internals
```rust
trace!("Token expiry check: {} seconds remaining", remaining);
trace!("Permission check: {} -> {}", resource, allowed);
trace!("Hashing password with cost factor: {}", cost);
```
### 4. API Handlers
**Examples:** HTTP endpoint handlers in `core/`, `drive/`, etc.
**INFO Level:** Request lifecycle
```rust
info!("Request started: {} {} from {}", method, path, ip);
info!("Request completed: {} {} -> {} ({}ms)", method, path, status, duration);
info!("User {} created resource: {}", user_id, resource_id);
```
**DEBUG Level:** Request details
```rust
debug!("Request headers: {:?}", headers);
debug!("Request body: {:?}", body);
debug!("Response payload: {} bytes", size);
```
**TRACE Level:** Request processing
```rust
trace!("Parsing JSON body");
trace!("Validating request parameters");
trace!("Serializing response");
```
### 5. Database Operations
**Examples:** `core/shared/models/`, Diesel queries
**INFO Level:** Database lifecycle
```rust
info!("Database connection pool initialized ({} connections)", pool_size);
info!("Migration completed - {} tables updated", count);
info!("Database backup created: {}", backup_path);
```
**DEBUG Level:** Query information
```rust
debug!("Executing query: {}", query);
debug!("Query returned {} rows in {}ms", count, duration);
debug!("Cache miss for key: {}", key);
```
**TRACE Level:** Query details
```rust
trace!("Preparing statement: {}", sql);
trace!("Binding parameter {}: {:?}", index, value);
trace!("Fetching next row");
```
### 6. LLM & AI Operations
**Examples:** `llm/`, `core/kb/`
**INFO Level:** LLM operations
```rust
info!("LLM request started - model: {}, tokens: {}", model, estimated_tokens);
info!("LLM response received - {} tokens, {}ms", tokens, duration);
info!("Embedding generated - {} dimensions", dimensions);
info!("Knowledge base indexed - {} documents", doc_count);
```
**DEBUG Level:** LLM details
```rust
debug!("LLM prompt: {}", prompt_preview);
debug!("Using temperature: {}, max_tokens: {}", temp, max);
debug!("Selected model variant: {}", variant);
```
**TRACE Level:** LLM internals
```rust
trace!("Sending request to LLM API: {}", url);
trace!("Streaming token: {}", token);
trace!("Parsing LLM response chunk");
```
### 7. Startup & Initialization
**Examples:** `main.rs`, `main_module/bootstrap.rs`
**INFO Level:** Startup milestones
```rust
info!("Server starting on port {}", port);
info!("Database initialized - PostgreSQL connected");
info!("Cache initialized - Valkey connected");
info!("Secrets loaded from Vault");
info!("BotServer ready - {} bots loaded", bot_count);
```
**DEBUG Level:** Configuration details
```rust
debug!("Using config: {:?}", config);
debug!("Environment: {}", env);
debug!("Feature flags: {:?}", features);
```
**TRACE Level:** Initialization steps
```rust
trace!("Loading .env file");
trace!("Setting up signal handlers");
trace!("Initializing thread registry");
```
---
## 🎯 The Cinema Viewer Experience
### Level 1: Watching the Movie (INFO)
```bash
RUST_LOG=botserver=info
```
**What you see:**
```
INFO botserver: Server starting on port 8080
INFO botserver: Database initialized - PostgreSQL connected
INFO botserver: User alice@example.com logged in from 192.168.1.100
INFO botserver::auto_task::orchestrator: Pipeline starting - task: abc123, intent: Create CRM
INFO botserver::auto_task::orchestrator: Stage 1 PLAN complete - 5 nodes planned
INFO botserver::auto_task::orchestrator: Stage 2 BUILD complete - 12 resources, url: /apps/crm
INFO botserver::auto_task::orchestrator: Pipeline complete - task: abc123, nodes: 5, resources: 12
INFO botserver: User alice@example.com logged out
```
**Perfect for:** Production monitoring, understanding system flow
### Level 2: Director's Commentary (DEBUG)
```bash
RUST_LOG=botserver=debug
```
**What you see:** Everything from INFO plus:
```
DEBUG botserver::auto_task::orchestrator: Classified intent as: AppGeneration
DEBUG botserver::auto_task::orchestrator: Selected app template: crm
DEBUG botserver::security::jwt: Validating JWT for user alice@example.com
DEBUG botserver::drive::local_file_monitor: Detected change in: /opt/gbo/data/crm.gbai
DEBUG botserver::llm: Using temperature: 0.7, max_tokens: 2000
```
**Perfect for:** Troubleshooting issues, understanding decisions
### Level 3: Raw Footage (TRACE)
```bash
RUST_LOG=botserver=trace
```
**What you see:** Everything from DEBUG plus:
```
TRACE botserver::drive::local_file_monitor: Scanning directory: /opt/gbo/data
TRACE botserver::auto_task::orchestrator: Broadcasting thought to UI: Analyzing...
TRACE botserver::llm: Streaming token: Create
TRACE botserver::llm: Streaming token: a
TRACE botserver::llm: Streaming token: CRM
TRACE botserver::core::db: Preparing statement: SELECT * FROM bots
```
**Perfect for:** Deep debugging, performance analysis, finding bugs
---
## ✨ Best Practices
### 1. Tell a Story
```rust
// ✅ GOOD - Shows the narrative
info!("Pipeline starting - task: {}", task_id);
info!("Stage 1 PLAN complete - {} nodes planned", nodes);
info!("Stage 2 BUILD complete - {} resources", resources);
info!("Pipeline complete - app deployed at {}", url);
// ❌ BAD - Just data points
info!("Task started");
info!("Nodes: {}", nodes);
info!("Resources: {}", resources);
info!("Done");
```
### 2. Use Structured Data
```rust
// ✅ GOOD - Easy to parse and filter
info!("User {} logged in from {}", user_id, ip);
info!("Request completed: {} {} -> {} ({}ms)", method, path, status, duration);
// ❌ BAD - Hard to parse
info!("User login happened");
info!("Request finished successfully");
```
### 3. Include Context
```rust
// ✅ GOOD - Provides context
error!("Database connection failed for bot {}: {}", bot_id, e);
warn!("Rate limit approaching for user {}: {}/{} requests", user_id, count, limit);
// ❌ BAD - No context
error!("Connection failed: {}", e);
warn!("Rate limit warning");
```
### 4. Use Appropriate Levels
```rust
// ✅ GOOD - Right level for right information
info!("Server started on port {}", port); // Key event
debug!("Using config: {:?}", config); // Troubleshooting
trace!("Listening on socket {:?}", socket); // Deep detail
// ❌ BAD - Wrong levels
trace!("Server started"); // Too important for trace
info!("Loop iteration {}", i); // Too verbose for info
error!("Variable is null"); // Not an error
```
### 5. Avoid Noise
```rust
// ✅ GOOD - Meaningful information
debug!("Retry attempt {} of {} for API call", attempt, max);
// ❌ BAD - Just noise
debug!("Entering function");
debug!("Exiting function");
debug!("Variable assigned");
```
### 6. Log State Changes
```rust
// ✅ GOOD - Shows what changed
info!("User {} role changed: {} -> {}", user_id, old_role, new_role);
info!("Bot {} status: {} -> {}", bot_id, old_status, new_status);
// ❌ BAD - No before/after
info!("User role updated");
info!("Bot status changed");
```
### 7. Include Timings for Operations
```rust
// ✅ GOOD - Performance visibility
info!("Database migration completed in {}ms", duration);
info!("LLM response received - {} tokens, {}ms", tokens, duration);
debug!("Query executed in {}ms", duration);
// ❌ BAD - No performance data
info!("Migration completed");
info!("LLM response received");
```
---
## 🔧 Implementation Guide
### Step 1: Audit Current Logging
```bash
# Find all logging statements
find botserver/src -name "*.rs" -exec grep -n "info!\|debug!\|trace!\|warn!\|error!" {} +
# Count by level
grep -r "info!" botserver/src | wc -l
grep -r "debug!" botserver/src | wc -l
grep -r "trace!" botserver/src | wc -l
```
### Step 2: Categorize by Module
Create a spreadsheet or document listing:
- Module name
- Current log levels used
- Purpose of the module
- What story should it tell
### Step 3: Refactor Module by Module
Start with critical path modules:
1. **auto_task/orchestrator.rs** - Already done! ✅
2. **drive/local_file_monitor.rs** - File operations
3. **security/jwt.rs** - Authentication events
4. **main.rs** - Startup sequence
5. **core/bot/** - Bot lifecycle
### Step 4: Test Different Verbosity Levels
```bash
# Test INFO level (production)
RUST_LOG=botserver=info cargo run
# Test DEBUG level (troubleshooting)
RUST_LOG=botserver=debug cargo run
# Test TRACE level (development)
RUST_LOG=botserver=trace cargo run
```
### Step 5: Document Module-Specific Patterns
For each module, document:
- What story does it tell at INFO level?
- What troubleshooting info at DEBUG level?
- What raw details at TRACE level?
---
## 📋 Quick Reference Card
### Log Level Decision Tree
```
Is this a failure that stops execution?
└─ YES → ERROR
└─ NO → Is this unexpected but recoverable?
└─ YES → WARN
└─ NO → Is this a key business event?
└─ YES → INFO
└─ NO → Is this useful for troubleshooting?
└─ YES → DEBUG
└─ NO → Is this step-by-step execution detail?
└─ YES → TRACE
└─ NO → Don't log it!
```
### Module-Specific Cheat Sheet
| Module Type | INFO | DEBUG | TRACE |
|-------------|------|-------|-------|
| **Orchestration** | Stage start/complete, pipeline milestones | Decision points, classifications | UI broadcasts, state changes |
| **File Monitoring** | Monitor start, bot compiled | Changes detected, recompiles | File scans, timestamps |
| **Security** | Logins, key events, failures | Validations, permission checks | Token details, hash operations |
| **API Handlers** | Request start/end, resource changes | Headers, payloads | JSON parsing, serialization |
| **Database** | Connections, migrations | Queries, row counts | Statement prep, row fetching |
| **LLM** | Requests, responses, indexing | Prompts, parameters | Token streaming, chunking |
| **Startup** | Service ready, milestones | Config, environment | Init steps, signal handlers |
---
## 🎬 Example: Complete Pipeline Logging
Here's how a complete auto-task pipeline looks at different levels:
### INFO Level (The Movie)
```
INFO Pipeline starting - task: task-123, intent: Create a CRM system
INFO Stage 1 PLAN starting - Agent #1 analyzing request
INFO Stage 1 PLAN complete - 5 nodes planned
INFO Stage 2 BUILD starting - Agent #2 generating code
INFO Stage 2 BUILD complete - 12 resources, url: /apps/crm-system
INFO Stage 3 REVIEW starting - Agent #3 checking code quality
INFO Stage 3 REVIEW complete - all checks passed
INFO Stage 4 DEPLOY starting - Agent #4 deploying to /apps/crm-system
INFO Stage 4 DEPLOY complete - app live at /apps/crm-system
INFO Stage 5 MONITOR starting - Agent #1 setting up monitoring
INFO Stage 5 MONITOR complete - monitoring active
INFO Pipeline complete - task: task-123, nodes: 5, resources: 12, url: /apps/crm-system
```
### DEBUG Level (Director's Commentary)
```
INFO Pipeline starting - task: task-123, intent: Create a CRM system
DEBUG Classified intent as: AppGeneration
DEBUG Selected app template: crm_standard
INFO Stage 1 PLAN starting - Agent #1 analyzing request
DEBUG Generated 5 sub-tasks from intent
INFO Stage 1 PLAN complete - 5 nodes planned
INFO Stage 2 BUILD starting - Agent #2 generating code
DEBUG Using database schema: contacts, deals, activities
DEBUG Generated 3 tables, 8 pages, 1 tool
INFO Stage 2 BUILD complete - 12 resources, url: /apps/crm-system
...
```
### TRACE Level (Raw Footage)
```
INFO Pipeline starting - task: task-123, intent: Create a CRM system
DEBUG Classified intent as: AppGeneration
TRACE Extracting entities from: "Create a CRM system"
TRACE Found entity: CRM
TRACE Found entity: system
DEBUG Selected app template: crm_standard
INFO Stage 1 PLAN starting - Agent #1 analyzing request
TRACE Broadcasting thought to UI: Analyzing request...
TRACE Deriving plan sub-tasks
TRACE Sub-task 1: Create database schema
TRACE Sub-task 2: Generate list page
TRACE Sub-task 3: Generate form pages
TRACE Sub-task 4: Create BASIC tools
TRACE Sub-task 5: Setup navigation
DEBUG Generated 5 sub-tasks from intent
...
```
---
## 🎯 Goals & Metrics
### Success Criteria
1. **INFO logs tell a complete story** - Can understand system flow without DEBUG/TRACE
2. **DEBUG logs enable troubleshooting** - Can diagnose issues with context
3. **TRACE logs show execution details** - Can see step-by-step for deep debugging
4. **No log spam** - Production logs are concise and meaningful
5. **Consistent patterns** - Similar modules log similarly
### Metrics to Track
- Lines of logs per request at INFO level: < 20
- Lines of logs per request at DEBUG level: < 100
- Lines of logs per request at TRACE level: unlimited
- Error logs include context: 100%
- WARN logs explain impact: 100%
---
## 🚀 Next Steps
1. **Audit** current logging in all 341 files
2. **Prioritize** modules by criticality
3. **Refactor** module by module following this plan
4. **Test** at each log level
5. **Document** module-specific patterns
6. **Train** team on logging standards
7. **Monitor** log volume and usefulness
8. **Iterate** based on feedback
---
## 📚 References
- [Rust log crate documentation](https://docs.rs/log/)
- [env_logger documentation](https://docs.rs/env_logger/)
- [Structured logging best practices](https://www.honeycomb.io/blog/structured-logging/)
- [The Log: What every software engineer should know](https://blog.codinghorror.com/the-log-everything-manifesto/)
---
**Remember:** Good logging is like good cinematography - it should be invisible when done right, but tell a compelling story when you pay attention to it. 🎬

575
README.md
View file

@ -1,495 +1,306 @@
# General Bots - Enterprise-Grade LLM Orchestrator
| Area | Status |
|------------------------------|----------------------------------------------------------------------------------------------------|
| Community | [![StackExchange](https://img.shields.io/stackexchange/stackoverflow/t/generalbots.svg)](https://stackoverflow.com/questions/tagged/generalbots) [![Gitter](https://img.shields.io/gitter/room/pragmatismo-io/GeneralBots.svg)](https://gitter.im/GeneralBots) [![Open-source](https://badges.frapsoft.com/os/v2/open-source.svg)](https://badges.frapsoft.com) [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com) [![License](https://img.shields.io/badge/license-AGPL-blue.svg)](https://github.com/pragmatismo-io/BotServer/blob/master/LICENSE.txt)|
| Management | [![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://gitHub.com/pragmatismo-io/BotServer/graphs/commit-activity) [![Waffle.io - Columns and their card count](https://badge.waffle.io/pragmatismo-io/BotServer.svg?columns=all)](https://waffle.io/pragmatismo-io/BotServer) |
| Security | [![Known Vulnerabilities](https://snyk.io/test/github/pragmatismo-io/BotServer/badge.svg)](https://snyk.io/test/github/pragmatismo-io/BotServer) |
| Building & Quality | [![Build Status](https://travis-ci.com/pragmatismo-io/BotServer.svg?branch=master)](https://travis-ci.com/pragmatismo-io/BotServer) [![Coverage Status](https://coveralls.io/repos/github/pragmatismo-io/BotServer/badge.svg)](https://coveralls.io/github/pragmatismo-io/BotServer) [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier) |
| Packaging | [![forthebadge](https://badge.fury.io/js/botserver.svg)](https://badge.fury.io) [![Dependencies](https://david-dm.org/pragmatismo-io/botserver.svg)](https://david-dm.org) [![Greenkeeper badge](https://badges.greenkeeper.io/pragmatismo-io/BotServer.svg)](https://greenkeeper.io/) [![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/) |
| Releases | [![General Bots](https://img.shields.io/npm/dt/botserver.svg?logo=npm&label=botserver)](https://www.npmjs.com/package/botserver/) [![.gbapp lib](https://img.shields.io/npm/dt/botlib.svg?logo=npm&label=botlib)](https://www.npmjs.com/package/botlib/) [![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)|
| [Docker Image](https://github.com/lpicanco/docker-botserver) | ![Docker Automated build](https://img.shields.io/docker/automated/lpicanco/botserver.svg) ![Docker Build Status](https://img.shields.io/docker/build/lpicanco/botserver.svg) ![MicroBadger Size](https://img.shields.io/microbadger/image-size/lpicanco/botserver.svg) ![MicroBadger Layers](https://img.shields.io/microbadger/layers/lpicanco/botserver.svg) ![Docker Pulls](https://img.shields.io/docker/pulls/lpicanco/botserver.svg) <br/> *Provided by [@lpicanco](https://github.com/lpicanco/docker-botserver)* |
**Version:** 6.2.0
**Purpose:** Main API server for General Bots (Axum + Diesel + Rhai BASIC)
#### Watch a video about easeness authoring of bot packages, development environment and self-deployment
---
* Now with General Bots you can press F5 on Visual Studio to get a bot factory on your environment* published on November 10th, 2018.
![General Bot Logo](https://github.com/GeneralBots/botserver/blob/main/logo.png?raw=true)
[![General Bot Video](https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/video-01-thumb.jpg)](https://www.youtube.com/watch?v=AfKTwljoMOs)
## Overview
General Bots is a **self-hosted AI automation platform** and strongly-typed LLM conversational platform focused on convention over configuration and code-less approaches. It serves as the core API server handling LLM orchestration, business logic, database operations, and multi-channel communication.
Welcome to General Bot Community Edition
----------------------------------------
For comprehensive documentation, see **[docs.pragmatismo.com.br](https://docs.pragmatismo.com.br)** or the **[BotBook](../botbook)** for detailed guides, API references, and tutorials.
![General Bot Logo](https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/logo.png)
---
General Bot is a package based chat bot server focused in convention over configuration and code-less approaches, which brings software packages and application server concepts to help parallel bot development.
## 🚀 Quick Start
### Prerequisites
## Sample Package #1: [default.gbdialog (VBA)](https://github.com/pragmatismo-io/BotServer/tree/master/packages/default.gbdialog)
- **Rust** (1.75+) - [Install from rustup.rs](https://rustup.rs/)
- **Git** - [Download from git-scm.com](https://git-scm.com/downloads)
- **Mold** - `sudo apt-get install mold`
### Installation
* See how easy is to use 'hear' and 'talk' to build Microsoft BOT Framework v4 logic with plain BASIC * published on December 3rd, 2018.
```bash
git clone https://github.com/GeneralBots/botserver
cd botserver
cargo install sccache
sudo apt-get install mold # or build from source
cargo run
```
[![See how easy is to use 'hear' and 'talk' to build Microsoft BOT Framework v4 logic with plain BASIC](https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/video-02-thumb.jpg)](https://www.youtube.com/watch?v=yX1sF9n9628)
On first run, botserver automatically:
- Installs required components (PostgreSQL, S3 storage, Redis cache, LLM)
- Sets up database with migrations
- Downloads AI models
- Starts HTTP server at `http://localhost:9000`
### Command-Line Options
## Sample Package #2: [AzureADPasswordReset.gbapp (TypeScript)](https://github.com/pragmatismo-io/AzureADPasswordReset.gbapp)
```bash
cargo run # Default: console UI + web server
cargo run -- --noconsole # Background service mode
cargo run -- --desktop # Desktop application (Tauri)
cargo run -- --tenant <name> # Specify tenant
cargo run -- --container # LXC container mode
```
---
Custom dialogs for reseting user password in Azure Active Directory, Office 365, Dynamics 365 or any app published through Azure AD. See also [IntranetBotQuickStart.gbai](https://github.com/pragmatismo-io/IntranetBotQuickStart.gbai) and related MSDN article **[Applied AI Using a Bot for Password Reset](https://blogs.msdn.microsoft.com/buckwoody/2018/09/25/applied-ai-using-a-bot-for-password-reset)** by *Rodrigo Souza*.
## ✨ Key Features
### Multi-Vendor LLM API
Unified interface for OpenAI, Groq, Claude, Anthropic, and local models.
### Bot Administrator - Setup Security
### MCP + LLM Tools Generation
Instant tool creation from code and functions - no complex configurations.
So the Bot provides an **admin** mode allowing the user having the Directory.AccessAsUser.All permission to be logged on Administrative interface to obtain and save its token into the database.
### Semantic Caching
Intelligent response caching achieving **70% cost reduction** on LLM calls.
![General Bot Logo](https://raw.githubusercontent.com/pragmatismo-io/AzureADPasswordReset.gbapp/master/docs/general-bots-reset-ad-password-admin.gif)
### Web Automation Engine
Browser automation combined with AI intelligence for complex workflows.
### Bot User - Reset Password
### Enterprise Data Connectors
Native integrations with CRM, ERP, databases, and external services.
### Git-like Version Control
Full history with rollback capabilities for all configurations and data.
With the access token stored in the database, any user can access anonymously the
bot and through a combination of e-mail and mobile received code, the user will be able to reset her or his password.
---
#### Reset password via Web
## 🎯 4 Essential Keywords
Any user can use a web address to talk to a reset password bot. Just provide credentials that are confronted with Microsoft Graph to ensure security.
```basic
USE KB "kb-name" ' Load knowledge base into vector database
CLEAR KB "kb-name" ' Remove KB from session
USE TOOL "tool-name" ' Make tool available to LLM
CLEAR TOOLS ' Remove all tools from session
```
![General Bot Logo](https://raw.githubusercontent.com/pragmatismo-io/AzureADPasswordReset.gbapp/master/docs/password.gif)
### Example Bot
general-bots-reset-ad-password.gif
```basic
' customer-support.bas
USE KB "support-docs"
USE TOOL "create-ticket"
USE TOOL "check-order"
#### Reset password via Skype
SET CONTEXT "support" AS "You are a helpful customer support agent."
This is the case when user does not have the password to login on Skype for Business or Teams, and they need to reset their password, so the right tool is Skype.
TALK "Welcome! How can I help you today?"
```
![General Bot Logo](https://raw.githubusercontent.com/pragmatismo-io/AzureADPasswordReset.gbapp/master/docs/general-bots-reset-ad-password.gif)
---
## 📁 Project Structure
## What is a Bot Server?
```
src/
├── core/ # Bootstrap, config, routes
├── basic/ # Rhai BASIC interpreter
│ └── keywords/ # BASIC keyword implementations
├── security/ # Security modules
│ ├── command_guard.rs # Safe command execution
│ ├── error_sanitizer.rs # Error message sanitization
│ └── sql_guard.rs # SQL injection prevention
├── shared/ # Shared types, models
├── tasks/ # AutoTask system (2651 lines - NEEDS REFACTORING)
├── auto_task/ # App generator (2981 lines - NEEDS REFACTORING)
├── drive/ # File operations (1522 lines - NEEDS REFACTORING)
├── learn/ # Learning system (2306 lines - NEEDS REFACTORING)
└── attendance/ # LLM assistance (2053 lines - NEEDS REFACTORING)
![General Bots Starting From Scrach](https://github.com/pragmatismo-io/BotServer/blob/master/docs/images/generalbots-open-core-starting-from-scratch.gif)
migrations/ # Database migrations
botserver-stack/ # Stack deployment files
```
---
## ✅ ZERO TOLERANCE POLICY
**EVERY SINGLE WARNING MUST BE FIXED. NO EXCEPTIONS.**
### Absolute Prohibitions
```
❌ NEVER use #![allow()] or #[allow()] in source code
❌ NEVER use .unwrap() - use ? or proper error handling
❌ NEVER use .expect() - use ? or proper error handling
❌ NEVER use panic!() or unreachable!()
❌ NEVER use todo!() or unimplemented!()
❌ NEVER leave unused imports or dead code
❌ NEVER add comments - code must be self-documenting
❌ NEVER use CDN links - all assets must be local
❌ NEVER build SQL queries with format! - use parameterized queries
❌ NEVER pass user input to Command::new() without validation
❌ NEVER log passwords, tokens, API keys, or PII
```
Bot Server accelerates the process of developing a bot. It provisions all code
base, resources and deployment to the cloud, and gives you templates you can
choose from whenever you need a new bot. The server has a database and service
backend allowing you to further modify your bot package directly by downloading
a zip file, editing and uploading it back to the server (deploying process) with
no code. The Bot Server also provides a framework to develop bot packages in a more
advanced fashion writing custom code in editors like Visual Studio Code, Atom or Brackets.
---
Everyone can create bots by just copying and pasting some files and using their
favorite tools like Excel (or any text editor) or Photoshop (or any image
editor).
## 🔐 Security Requirements
Package Quick Reference
------------
|Whatsapp|Web|Core|KB|
|----|-----|----|----|
|[whatsapp.gblib](https://github.com/pragmatismo-io/BotServer/tree/master/packages/whatsapp.gblib)|[default.gbui](https://github.com/pragmatismo-io/BotServer/tree/master/packages/default.gbui)|[core.gbapp](https://github.com/pragmatismo-io/BotServer/tree/master/packages/core.gbapp)|[kb.gbapp](https://github.com/pragmatismo-io/BotServer/tree/master/packages/kb.gbapp)|
### Error Handling - CRITICAL DEBT
### The bot development stack
**Current Status**: 955 instances of `unwrap()`/`expect()` found in codebase
**Target**: 0 instances in production code (tests excluded)
![General Bot Logo](https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/general-bots-stack.png)
```rust
// ❌ WRONG - Found 955 times in codebase
let value = something.unwrap();
let value = something.expect("msg");
// ✅ CORRECT - Required replacements
let value = something?;
let value = something.ok_or_else(|| Error::NotFound)?;
let value = something.unwrap_or_default();
let value = something.unwrap_or_else(|e| {
log::error!("Operation failed: {e}");
default_value
});
```
### Performance Issues - CRITICAL DEBT
**Current Status**: 12,973 excessive `clone()`/`to_string()` calls
**Target**: Minimize allocations, use references where possible
```rust
// ❌ WRONG - Excessive allocations
let name = user.name.clone();
let msg = format!("Hello {}", name.to_string());
// ✅ CORRECT - Minimize allocations
let name = &user.name;
let msg = format!("Hello {name}");
// ✅ CORRECT - Use Cow for conditional ownership
use std::borrow::Cow;
fn process_name(name: Cow<str>) -> String {
match name {
Cow::Borrowed(s) => s.to_uppercase(),
Cow::Owned(s) => s.to_uppercase(),
}
}
```
### SQL Injection Prevention
```rust
// ❌ WRONG
let query = format!("SELECT * FROM {}", table_name);
### The Bot Factory
// ✅ CORRECT - whitelist validation
const ALLOWED_TABLES: &[&str] = &["users", "sessions"];
if !ALLOWED_TABLES.contains(&table_name) {
return Err(Error::InvalidTable);
}
```
### Command Injection Prevention
```rust
// ❌ WRONG
Command::new("tool").arg(user_input).output()?;
// ✅ CORRECT - Use SafeCommand
use crate::security::command_guard::SafeCommand;
SafeCommand::new("allowed_command")?
.arg("safe_arg")?
.execute()
```
![General Bots Block Architecture](https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/general-bots-block-architecture.png)
### Error Responses - Use ErrorSanitizer
```rust
// ❌ WRONG
Json(json!({ "error": e.to_string() }))
format!("Database error: {}", e)
GeneralBots aims to delivery bots in azure in a very easy and fast fashion. Use Office tools like Word or Excel to edit your Bot - using code (JavaScript or TypeScript) just to empower custom requirements.
// ✅ CORRECT
use crate::security::error_sanitizer::log_and_sanitize;
let sanitized = log_and_sanitize(&e, "context", None);
(StatusCode::INTERNAL_SERVER_ERROR, sanitized)
```
---
## ✅ Mandatory Code Patterns
#### Use Excel for (Hierarchical) Knowledge Base Editing
### Format Strings - Inline Variables
![General Bots Inside Excel can enable bot production the masses](https://github.com/pragmatismo-io/BotServer/blob/master/docs/images/general-bots-composing-subjects-json-and-excel.gif)
```rust
// ❌ WRONG
format!("Hello {}", name)
#### Use Visual Studio for a complete .gbai package building system
// ✅ CORRECT
format!("Hello {name}")
```
![General Bots Inside Visual Studio Code provides a complete artificial intelligence based conversational platform](https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/general-bots-inside-visual-studio-code-provides-a-complete-artificial-intelligence-based-conversational-platform.png)
### Self Usage in Impl Blocks
```rust
// ❌ WRONG
impl MyStruct {
fn new() -> MyStruct { MyStruct { } }
}
How To
------
// ✅ CORRECT
impl MyStruct {
fn new() -> Self { Self { } }
}
```
### Run the server locally
### Derive Eq with PartialEq
1. Install [Node.js](https://www.npmjs.com/get-npm) the current generation General Bot code execution platform;
2. Open a **Terminal** on Linux and Mac or a **Command Prompt** window on Windows;
3. Type `npm install -g botserver` and press *ENTER*;
4. Type `gbot` to run the server core.
```rust
// ❌ WRONG
#[derive(PartialEq)]
struct MyStruct { }
Notes:
// ✅ CORRECT
#[derive(PartialEq, Eq)]
struct MyStruct { }
```
* [*nodejs.install* Chocolatey Package](https://chocolatey.org/packages/nodejs.install) is also available.
* The zip source code of General Bot is also available for [Download](https://codeload.github.com/pragmatismo-io/BotServer/zip/master);
### Option Handling
### Configure the server to deploy specific directory
```rust
// ✅ CORRECT
opt.unwrap_or(default)
opt.unwrap_or_else(|| compute_default())
opt.map_or(default, |x| transform(x))
```
1. Create/Edit the .env file and add the ADDITIONAL_DEPLOY_PATH key pointing to the .gbai local parent folder of .gbapp, .gbot, .gbtheme, .gbkb package directories.
2. Specify STORAGE_SYNC to TRUE so database sync is run when the server is run.
3. In case of Microsoft SQL Server add the following keys: STORAGE_SERVER, STORAGE_NAME, STORAGE_USERNAME, STORAGE_PASSWORD, STORAGE_DIALECT to `mssql`.
### Chrono DateTime
Note:
```rust
// ❌ WRONG
date.with_hour(9).unwrap().with_minute(0).unwrap()
* You can specify several bots separated by semicolon, the BotServer will serve all of them at once.
// ✅ CORRECT
date.with_hour(9).and_then(|d| d.with_minute(0)).unwrap_or(date)
```
## Setup development environment (Windows)
---
1. [Optional] Install [Chocolatey](https://chocolatey.org/install), a Windows Package Manager;
2. Install [git](`https://git-scm.com/`), a Software Configuration Management (SCM).;
3. Install [Node.js](npmjs.com/get-npm), a [Runtime system](https://en.wikipedia.org/wiki/Runtime_system).
(https://www.npmjs.com/get-npm) (suggested: LTS 8.x.x);
4. Install [Visual Studio Code](https://chocolatey.org/packages/nodejs.install), Brackets or Atom as an editor of your choice;
5. [Fork](https://en.wikipedia.org/wiki/Fork_(software_development)) by visiting https://github.com/pragmatismo-io/BotServer/fork
6. Clone the just forked repository by running `git clone <your-forked-repository-url>/BotServer.git` ;
7. Run `npm install -g typescript`;
8. Run `npm install` on Command Prompt or PowerShell on the General Bot source-code folder;
9. Enter './packages/default.gbui' folder;
10. Run `npm install` folled by `npm run build` (To build default Bot UI);
11. Enter the On the downloaded folder (../..);
12. Compile the bot server by `tsc`.
13. Run the bot server by `npm start`.
## 📏 File Size Limits - MANDATORY
Note:
### Maximum 450 Lines Per File
* Whenever you are ready to turn your open-source bot ideas in form of .gbapp (source-code) and artifacts like .gbkb, .gbtheme, .gbot or the .gbai full package read [CONTRIBUTING.md](https://github.com/pragmatismo-io/BotServer/blob/master/CONTRIBUTING.md) about performing Pull Requests (PR) and creating other public custom packages repositories of your own personal or organization General Bot Community Edition powered packages.
When a file grows beyond this limit:
### Running unit tests
1. **Identify logical groups** - Find related functions
2. **Create subdirectory module** - e.g., `handlers/`
3. **Split by responsibility:**
- `types.rs` - Structs, enums, type definitions
- `handlers.rs` - HTTP handlers and routes
- `operations.rs` - Core business logic
- `utils.rs` - Helper functions
- `mod.rs` - Re-exports and configuration
4. **Keep files focused** - Single responsibility
5. **Update mod.rs** - Re-export all public items
1. Enter the BotServer root folder.
2. Run tests by `npm test`.
**NEVER let a single file exceed 450 lines - split proactively at 350 lines**
### Just copy the source code to your machine
### Files Requiring Immediate Refactoring
1. [Download] the Zip file of (https://codeload.github.com/pragmatismo-io/BotServer/zip/master)
| File | Lines | Target Split |
|------|-------|--------------|
| `auto_task/app_generator.rs` | 2981 | → 7 files |
| `tasks/mod.rs` | 2651 | → 6 files |
| `learn/mod.rs` | 2306 | → 5 files |
| `attendance/llm_assist.rs` | 2053 | → 5 files |
| `drive/mod.rs` | 1522 | → 4 files |
### Updating the Bot Knoledge Base (.gbkb folder)
The subjects.json file contains all information related to the subject tree and can be used to build the menu carrousel as well give a set of words to be used as subject catcher in the conversation. A hierarchy can be specified.
### Creating a new Theme folder (.gbtheme folder)
---
A theme is composed of some CSS files and images. That set of files can change
everything in the General Bot UI. Use them extensively before going to change
the UI application itself (HTML & JS).
## 🗄️ Database Standards
Package Types
-------------
- **TABLES AND INDEXES ONLY** (no stored procedures, nothing, no views, no triggers, no functions)
- **JSON columns:** use TEXT with `_json` suffix
- **ORM:** Use diesel - no sqlx
- **Migrations:** Located in `botserver/migrations/`
### .gbai
---
Embraces all packages types (content, logic & conversation) into a pluggable bot
directory. [A sample .gbai is available](https://github.com/pragmatismo-io/IntranetBotQuickStart.gbai).
## 🎨 Frontend Rules
### .gbapp
- **Use HTMX** - minimize JavaScript
- **NO external CDN** - all assets local
- **Server-side rendering** with Askama templates
The artificial intelligence extensions in form of pluggable apps. Dialogs,
Services and all model related to data. A set of interactions, use cases,
integrations in form of conversationals dialogs.
The .gbapp adds the General Bot base library (botlib) for building Node.js TypeScript Apps packages.
---
## 📦 Key Dependencies
Four components builds up a General Bot App:
| Library | Version | Purpose |
|---------|---------|---------|
| axum | 0.7.5 | Web framework |
| diesel | 2.1 | PostgreSQL ORM |
| tokio | 1.41 | Async runtime |
| rhai | git | BASIC scripting |
| reqwest | 0.12 | HTTP client |
| serde | 1.0 | Serialization |
| askama | 0.12 | HTML Templates |
* dialogs
* models
* services
* tests
---
#### Dialogs
## 🚀 CI/CD Workflow
All code contained in a dialog builds the flow to custom conversations in
built-in and additional packages .
When configuring CI/CD pipelines (e.g., Forgejo Actions):
- **Minimal Checkout**: Clone only the root `gb` and the `botlib` submodule. Do NOT recursively clone everything.
- **BotServer Context**: Replace the empty `botserver` directory with the current set of files being tested.
#### Models
**Example Step:**
```yaml
- name: Setup Workspace
run: |
# 1. Clone only the root workspace configuration
git clone --depth 1 <your-git-repo-url> workspace
# 2. Setup only the necessary dependencies (botlib)
cd workspace
git submodule update --init --depth 1 botlib
cd ..
Models builds the foundation of data relationships in form of entities.
# 3. Inject current BotServer code
rm -rf workspace/botserver
mv botserver workspace/botserver
```
---
#### Services
## 📚 Documentation
Services are a façade for bot back-end logic and other custom processing.
### Documentation Structure
#### Tests
```
docs/
├── api/ # API documentation
│ ├── README.md # API overview
│ ├── rest-endpoints.md # HTTP endpoints
│ └── websocket.md # Real-time communication
├── guides/ # How-to guides
│ ├── getting-started.md # Quick start
│ ├── deployment.md # Production setup
│ └── templates.md # Using templates
└── reference/ # Technical reference
├── basic-language.md # BASIC keywords
├── configuration.md # Config options
└── architecture.md # System design
```
Tests try to automate code execution validation before crashing in production.
### Additional Resources
- **[docs.pragmatismo.com.br](https://docs.pragmatismo.com.br)** - Full online documentation
- **[BotBook](../botbook)** - Local comprehensive guide with tutorials and examples
- **[API Reference](docs/api/README.md)** - REST and WebSocket endpoints
- **[BASIC Language](docs/reference/basic-language.md)** - Dialog scripting reference
### .gbot
---
An expression of an artificial inteligence entity. A .gbot file defines
all bots dependencies related to services and other resources.
## 🔗 Related Projects
### .gbtheme
| Project | Description |
|---------|-------------|
| [botui](https://github.com/GeneralBots/botui) | Pure web UI (HTMX-based) |
| [botapp](https://github.com/GeneralBots/botapp) | Tauri desktop wrapper |
| [botlib](https://github.com/GeneralBots/botlib) | Shared Rust library |
| [botbook](https://github.com/GeneralBots/botbook) | Documentation |
| [bottemplates](https://github.com/GeneralBots/bottemplates) | Templates and examples |
A theme of a bot at a given time. CSS files & images that can compose all UI
presentation and using it a branding can be done. [A sample .gbtheme is available](https://github.com/pragmatismo-io/Office365.gbtheme)
---
### .gbkb
## 🛡️ Security
A set of subjects that bot knows in a form of hierarchical menu-based QnA. [A sample .gbkb is available](https://github.com/pragmatismo-io/ProjectOnline.gbkb).
- **AGPL-3.0 License** - True open source with contribution requirements
- **Self-hosted** - Your data stays on your infrastructure
- **Enterprise-grade** - 5+ years of stability
- **No vendor lock-in** - Open protocols and standards
### .gblib
Report security issues to: **security@pragmatismo.com.br**
Shared code that can be used across bot apps.
---
Reference
---------
## 🤝 Contributing
### GeneralBots admin commands
We welcome contributions! Please read our contributing guidelines before submitting PRs.
General Bot can be controlled by the same chat window people talk to, so
here is a list of admin commands related to deploying .gb* files.
### Contributors
| Command | Description |
|-----------------|-----------------------------------------------------------------------------------------------------------------|
| deployPackage | Deploy a KB package. Usage **deployPackage** [package-name]. Then, you need to run rebuildIndex. |
| undeployPackage | Undeploy a KB. Usage **undeployPackage** [package-name]. |
| redeployPackage | Undeploy and then deploys the KB. Usage **redeployPackage** [package-name]. Then, you need to run rebuildIndex. |
| setupSecurity | Setup connection to user directories. |
<a href="https://github.com/generalbots/botserver/graphs/contributors">
<img src="https://contrib.rocks/image?repo=generalbots/botserver" />
</a>
Discontinued commands:
---
| Command | Description |Reason |
|-----------------| -----------------------------------------------------------------------------------------------------------------|------|
| rebuildIndex | Rebuild Azure Search indexes, must be run after **deployPackage** or **redeployPackage**. | Now it is called automatically |
## 🔑 Remember
### Credits & Inspiration
- **ZERO WARNINGS** - Fix every clippy warning
- **ZERO COMMENTS** - No comments, no doc comments
- **NO ALLOW IN CODE** - Configure exceptions in Cargo.toml only
- **NO DEAD CODE** - Delete unused code
- **NO UNWRAP/EXPECT** - Use ? or combinators (955 instances to fix)
- **MINIMIZE CLONES** - Avoid excessive allocations (12,973 instances to optimize)
- **PARAMETERIZED SQL** - Never format! for queries
- **VALIDATE COMMANDS** - Never pass raw user input
- **INLINE FORMAT ARGS** - `format!("{name}")` not `format!("{}", name)`
- **USE SELF** - In impl blocks, use Self not type name
- **FILE SIZE LIMIT** - Max 450 lines per file, refactor at 350 lines
- **Version 6.2.0** - Do not change without approval
- **GIT WORKFLOW** - ALWAYS push to ALL repositories (github, pragmatismo)
* Rodrigo Rodriguez (me@rodrigorodriguez.com) - Coding, Docs & Architecture.
* David Lerner (david.lerner@hotmail.com) - UI, UX & Theming.
* Eduardo Romeiro (eromeirosp@outlook.com) - Content & UX.
* Jorge Ramos (jramos@pobox.com) - Coding, Docs & Architecture.
* PH Nascimento (ph.an@outlook.com) - Product Manager
---
Powered by Microsoft [BOT Framework](https://dev.botframework.com/) and [Azure](http://www.azure.com).
## 🚨 Immediate Action Required
General Bot Code Name is [Guaribas](https://en.wikipedia.org/wiki/Guaribas), the name of a city in Brasil, state of Piaui.
[Roberto Mangabeira Unger](http://www.robertounger.com/en/): "No one should have to do work that can be done by a machine".
1. **Replace 955 unwrap()/expect() calls** with proper error handling
2. **Optimize 12,973 clone()/to_string() calls** for performance
3. **Refactor 5 large files** following refactoring plan
4. **Add missing error handling** in critical paths
5. **Implement proper logging** instead of panicking
## Contributing
---
This project welcomes contributions and suggestions.
See our [Contribution Guidelines](https://github.com/pragmatismo-io/BotServer/blob/master/CONTRIBUTING.md) for more details.
## 📄 License
## Reporting Security Issues
General Bot Copyright (c) pragmatismo.com.br. All rights reserved.
Licensed under the **AGPL-3.0**.
Security issues and bugs should be reported privately, via email, to the Pragmatismo.io Security
team at [security@pragmatismo.io](mailto:security@pragmatismo.io). You should
receive a response within 24 hours. If for some reason you do not, please follow up via
email to ensure we received your original message.
According to our dual licensing model, this program can be used either under the terms of the GNU Affero General Public License, version 3, or under a proprietary license.
## License & Warranty
---
General Bot Copyright (c) Pragmatismo.io. All rights reserved.
Licensed under the AGPL-3.0.
According to our dual licensing model, this program can be used either
under the terms of the GNU Affero General Public License, version 3,
or under a proprietary license.
The texts of the GNU Affero General Public License with an additional
permission and of our proprietary license can be found at and
in the LICENSE file you have received along with this program.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
"General Bot" is a registered trademark of Pragmatismo.io.
The licensing of the program under the AGPLv3 does not imply a
trademark license. Therefore any rights, title and interest in
our trademarks remain entirely with us.
## 🔗 Links
- **Website:** [pragmatismo.com.br](https://pragmatismo.com.br)
- **Documentation:** [docs.pragmatismo.com.br](https://docs.pragmatismo.com.br)
- **GitHub:** [github.com/GeneralBots/botserver](https://github.com/GeneralBots/botserver)
- **Stack Overflow:** Tag questions with `generalbots`
- **Video Tutorial:** [7 AI General Bots LLM Templates](https://www.youtube.com/watch?v=KJgvUPXi3Fw)
---
**General Bots Code Name:** [Guaribas](https://en.wikipedia.org/wiki/Guaribas)
> "No one should have to do work that can be done by a machine." - Roberto Mangabeira Unger
<a href="https://stackoverflow.com/questions/ask?tags=generalbots">:speech_balloon: Ask a question</a> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <a href="/docs">:book: Read the Docs</a>
</h2>

7
SAMPLES.md Normal file
View file

@ -0,0 +1,7 @@
# General Bots Server Samples
| Sample | Description |
|--------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------|
| [IntranetBotQuickStart-gbai](https://github.com/pragmatismo-io/IntranetBotQuickStart.gbai) | Free modules from General Bots Intranet based bot. |
| [AzureADPasswordReset-gbapp](https://github.com/pragmatismo-io/AzureADPasswordReset.gbapp) | Custom General Bot App (gbapp) for resetting an user password in Azure Active Directory, Office 365, Dynamics 365 or any app published through Azure AD. |
| [ProjectOnline.gbkb](https://github.com/pragmatismo-io/ProjectOnline.gbkb) | The .gbkb file demonstring a Knowledge Base for Pragmatismo.io KBot for Microsoft Project. |

View file

@ -1,89 +0,0 @@
#!/bin/bash
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PROJECT_ROOT="$SCRIPT_DIR"
OUTPUT_FILE="/tmp/prompt.out"
echo "Consolidated LLM Context" > "$OUTPUT_FILE"
prompts=(
"./prompts/dev/platform/shared.md"
"./prompts/dev/platform/cli.md"
"./prompts/dev/platform/ide.md"
"./Cargo.toml"
)
for file in "${prompts[@]}"; do
if [ -f "$file" ]; then
cat "$file" >> "$OUTPUT_FILE"
echo "" >> "$OUTPUT_FILE"
fi
done
dirs=(
"auth"
#"automation"
#"basic"
#"bootstrap"
"bot"
#"channels"
#"config"
#"context"
#"drive_monitor"
"email"
"file"
#"kb"
"llm"
#"llm_models"
"meet"
#"org"
#"package_manager"
#"riot_compiler"
"session"
"shared"
#"tests"
#"tools"
#"ui"
#"ui_tree"
#"web_server"
#"web_automation"
)
for dir in "${dirs[@]}"; do
find "$PROJECT_ROOT/src/$dir" -name "*.rs" | while read -r file; do
echo "$file" >> "$OUTPUT_FILE"
cat "$file" >> "$OUTPUT_FILE"
done
done
# Additional specific files
files=(
"$PROJECT_ROOT/src/main.rs"
#"$PROJECT_ROOT/src/basic/keywords/mod.rs"
)
for file in "${files[@]}"; do
echo "$file" >> "$OUTPUT_FILE"
cat "$file" >> "$OUTPUT_FILE"
done
# Remove all blank lines and reduce whitespace greater than 1 space
sed -i 's/[[:space:]]*$//' "$OUTPUT_FILE"
sed -i '/^$/d' "$OUTPUT_FILE"
sed -i 's/ \+/ /g' "$OUTPUT_FILE"
# Calculate and display token count (approximation: words * 1.3)
WORD_COUNT=$(wc -w < "$OUTPUT_FILE")
TOKEN_COUNT=$(echo "$WORD_COUNT * 1.3 / 1" | bc)
FILE_SIZE=$(wc -c < "$OUTPUT_FILE")
echo "" >> "$OUTPUT_FILE"
echo "Approximate token count: $TOKEN_COUNT"
echo "Context size: $FILE_SIZE bytes"
cat "$OUTPUT_FILE" | xclip -selection clipboard
echo "Content copied to clipboard (xclip)"
rm -f "$OUTPUT_FILE"

View file

@ -1,7 +0,0 @@
fn main() {
if std::path::Path::new("../botui/ui/suite/").exists() {
println!("cargo:rerun-if-changed=../botui/ui/suite/");
}
println!("cargo:rerun-if-changed=3rdparty.toml");
println!("cargo:rerun-if-changed=.env.embedded");
}

148
deploy.cmd Normal file
View file

@ -0,0 +1,148 @@
@if "%SCM_TRACE_LEVEL%" NEQ "4" @echo off
:: ----------------------
:: General Bots deployment.
:: -------------
:: Verify node.js installed
where node 2>nul >nul
IF %ERRORLEVEL% NEQ 0 (
echo Missing node.js executable, please install node.js, if already installed make sure it can be reached from current environment.
goto error
)
:: Setup
:: -----
setlocal enabledelayedexpansion
SET ARTIFACTS=%~dp0%..\artifacts
IF NOT DEFINED DEPLOYMENT_SOURCE (
SET DEPLOYMENT_SOURCE=%~dp0%.
)
IF NOT DEFINED DEPLOYMENT_TARGET (
SET DEPLOYMENT_TARGET=%ARTIFACTS%\wwwroot
)
IF NOT DEFINED NEXT_MANIFEST_PATH (
SET NEXT_MANIFEST_PATH=%ARTIFACTS%\manifest
IF NOT DEFINED PREVIOUS_MANIFEST_PATH (
SET PREVIOUS_MANIFEST_PATH=%ARTIFACTS%\manifest
)
)
IF NOT DEFINED KUDU_SYNC_CMD (
:: Install kudu sync
echo Installing Kudu Sync
call npm install kudusync -g --silent
IF !ERRORLEVEL! NEQ 0 goto error
:: Locally just running "kuduSync" would also work
SET KUDU_SYNC_CMD=%appdata%\npm\kuduSync.cmd
)
goto Deployment
:: Utility Functions
:: -----------------
:SelectNodeVersion
IF DEFINED KUDU_SELECT_NODE_VERSION_CMD (
:: The following are done only on Windows Azure Websites environment
call %KUDU_SELECT_NODE_VERSION_CMD% "%DEPLOYMENT_SOURCE%" "%DEPLOYMENT_TARGET%" "%DEPLOYMENT_TEMP%"
IF !ERRORLEVEL! NEQ 0 goto error
IF EXIST "%DEPLOYMENT_TEMP%\__nodeVersion.tmp" (
SET /p NODE_EXE=<"%DEPLOYMENT_TEMP%\__nodeVersion.tmp"
IF !ERRORLEVEL! NEQ 0 goto error
)
IF EXIST "%DEPLOYMENT_TEMP%\__npmVersion.tmp" (
SET /p NPM_JS_PATH=<"%DEPLOYMENT_TEMP%\__npmVersion.tmp"
IF !ERRORLEVEL! NEQ 0 goto error
)
IF NOT DEFINED NODE_EXE (
SET NODE_EXE=node
)
SET NPM_CMD="!NODE_EXE!" "!NPM_JS_PATH!"
) ELSE (
SET NPM_CMD=npm
SET NODE_EXE=node
)
goto :EOF
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: Deployment
:: ----------
:Deployment
echo Handling node.js deployment.
:: 1. KuduSync
IF /I "%IN_PLACE_DEPLOYMENT%" NEQ "1" (
call :ExecuteCmd "%KUDU_SYNC_CMD%" -v 50 -f "%DEPLOYMENT_SOURCE%" -t "%DEPLOYMENT_TARGET%" -n "%NEXT_MANIFEST_PATH%" -p "%PREVIOUS_MANIFEST_PATH%" -i ".git;.hg;.deployment;deploy.cmd"
IF !ERRORLEVEL! NEQ 0 goto error
)
:: 2. Select node version
call :SelectNodeVersion
:: 3. Install npm packages
IF EXIST "%DEPLOYMENT_TARGET%\package.json" (
pushd "%DEPLOYMENT_TARGET%"
echo [GUARIBASDEPLOYER] Installing packages for server.
call :ExecuteCmd !NPM_CMD! install --production
IF !ERRORLEVEL! NEQ 0 goto error
popd
)
:: 3.1 Install npm packages on UI
IF EXIST "%DEPLOYMENT_TARGET%\deploy\default.gbui\package.json" (
call :ExecuteCmd !NPM_CMD! config set scripts-prepend-node-path true
pushd "%DEPLOYMENT_TARGET%\deploy\default.gbui"
echo [GUARIBASDEPLOYER] Installing packages for default.gbui.
call :ExecuteCmd !NPM_CMD! install
echo [GUARIBASDEPLOYER] Building default.gbui.
call :ExecuteCmd !NPM_CMD! run build
IF !ERRORLEVEL! NEQ 0 goto error
popd
)
:: 4. Install typescript
echo [GUARIBASDEPLOYER] Transpiling...
call :ExecuteCmd node %DEPLOYMENT_TARGET%\node_modules\typescript\bin\tsc -v
call :ExecuteCmd node %DEPLOYMENT_TARGET%\node_modules\typescript\bin\tsc -p "%DEPLOYMENT_TARGET%"
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
goto end
:: Execute command routine that will echo out when error
:ExecuteCmd
setlocal
set _CMD_=%*
call %_CMD_%
if "%ERRORLEVEL%" NEQ "0" echo Failed exitCode=%ERRORLEVEL%, command=%_CMD_%
exit /b %ERRORLEVEL%
:error
endlocal
echo An error has occurred during web site deployment.
call :exitSetErrorLevel
call :exitFromFunction 2>nul
:exitSetErrorLevel
exit /b 1
:exitFromFunction
()
:end
endlocal
echo Finished successfully.

View file

@ -1,5 +0,0 @@
[migrations_directory]
dir = "migrations"
[print_schema]
file = "src/shared/schema.rs"

1
docs/_config.yml Normal file
View file

@ -0,0 +1 @@
theme: jekyll-theme-minimal

View file

@ -1,57 +0,0 @@
# Multi-Agent Workflows Guide
## Creating Workflows
### Basic Workflow Structure
```basic
ORCHESTRATE WORKFLOW "workflow-name"
STEP 1: BOT "analyzer" "process input"
STEP 2: BOT "validator" "check results"
END WORKFLOW
```
### Human Approval Integration
```basic
STEP 3: HUMAN APPROVAL FROM "manager@company.com"
TIMEOUT 1800 ' 30 minutes
ON TIMEOUT: ESCALATE TO "director@company.com"
```
### Parallel Processing
```basic
STEP 4: PARALLEL
BRANCH A: BOT "processor-1" "handle batch-a"
BRANCH B: BOT "processor-2" "handle batch-b"
END PARALLEL
```
### Event-Driven Coordination
```basic
ON EVENT "data-ready" DO
CONTINUE WORKFLOW AT STEP 5
END ON
PUBLISH EVENT "processing-complete"
```
### Cross-Bot Memory Sharing
```basic
BOT SHARE MEMORY "successful-patterns" WITH "learning-bot"
BOT SYNC MEMORY FROM "master-knowledge-bot"
```
## Best Practices
1. **Keep workflows focused** - Max 10 steps per workflow
2. **Use meaningful names** - Clear bot and step names
3. **Add timeouts** - Always set timeouts for human approvals
4. **Share knowledge** - Use memory sharing for bot learning
5. **Handle events** - Use event system for loose coupling
## Workflow Persistence
Workflows automatically survive server restarts. State is stored in PostgreSQL and recovered on startup.
## Visual Designer
Use the drag-and-drop designer at `/designer/workflow` to create workflows visually. The designer generates BASIC code automatically.

View file

@ -1,308 +0,0 @@
# Tools vs Bots: When to Use Each
**Chapter 4: Understanding the Difference Between Function Calls and AI Agents**
---
## Overview
General Bots provides two ways to extend your bot's capabilities:
- **TOOLs** - Simple functions with input/output
- **BOTs** - Intelligent AI agents that can reason and remember
Understanding when to use each is crucial for building efficient, cost-effective automation.
## Quick Comparison
| Feature | TOOL | BOT |
|---------|------|-----|
| **Purpose** | Data operations | Decision making |
| **Intelligence** | None (function) | Full LLM reasoning |
| **Speed** | Fast (10-100ms) | Slower (1-5 seconds) |
| **Cost** | Free | LLM tokens ($0.001-0.01) |
| **Input** | Structured data | Natural language |
| **Output** | Structured data | Conversational response |
| **Memory** | Stateless | Remembers context |
## Tools: The Function Approach
### What Are Tools?
Tools are **stateless functions** that perform specific operations:
```basic
' Tool usage - direct function call
USE TOOL "check-order"
result = CALL TOOL "check-order" WITH order_id="12345"
' Returns: {"status": "delivered", "amount": 899}
```
### When to Use Tools
✅ **Perfect for:**
- Database queries
- API calls
- Calculations
- Data transformations
- Real-time operations
```basic
' Examples of good tool usage
USE TOOL "get-weather"
weather = CALL TOOL "get-weather" WITH city="São Paulo"
USE TOOL "calculate-tax"
tax = CALL TOOL "calculate-tax" WITH amount=100, region="BR"
USE TOOL "send-email"
CALL TOOL "send-email" WITH to="user@example.com", subject="Order Confirmed"
```
### Tool Limitations
❌ **Cannot:**
- Make decisions
- Understand context
- Remember previous calls
- Handle ambiguous input
- Provide explanations
## Bots: The AI Agent Approach
### What Are Bots?
Bots are **intelligent agents** that can reason, remember, and make decisions:
```basic
' Bot usage - conversational interaction
ADD BOT "order-specialist"
response = ASK BOT "order-specialist" ABOUT "Customer says order 12345 arrived damaged. What should we do?"
' Returns: Detailed analysis with reasoning and recommendation
```
### When to Use Bots
✅ **Perfect for:**
- Complex decision making
- Natural language understanding
- Multi-step reasoning
- Context-aware responses
- Customer service scenarios
```basic
' Examples of good bot usage
ADD BOT "financial-advisor"
advice = ASK BOT "financial-advisor" ABOUT "Customer wants refund after 60 days but threatens legal action"
ADD BOT "technical-support"
solution = ASK BOT "technical-support" ABOUT "User can't login, tried password reset twice"
ADD BOT "content-moderator"
decision = ASK BOT "content-moderator" ABOUT "Review this user comment for policy violations"
```
### Bot Capabilities
✅ **Can:**
- Analyze complex situations
- Remember conversation history
- Use multiple tools internally
- Provide detailed explanations
- Handle edge cases
## Real-World Example: Order Processing
### Scenario
Customer contacts support: *"My laptop order #12345 arrived broken. I need this fixed immediately as I have a presentation tomorrow."*
### Tool-Only Approach (Limited)
```basic
' Simple but inflexible
USE TOOL "check-order"
order = CALL TOOL "check-order" WITH order_id="12345"
USE TOOL "check-warranty"
warranty = CALL TOOL "check-warranty" WITH order_id="12345"
IF order.status = "delivered" AND warranty.valid = true THEN
TALK "You're eligible for replacement"
ELSE
TALK "Please contact manager"
END IF
```
**Problems:**
- No understanding of urgency ("presentation tomorrow")
- No consideration of customer history
- Rigid, rule-based responses
- Cannot handle edge cases
### Bot Approach (Intelligent)
```basic
' Intelligent and flexible
ADD BOT "support-specialist"
response = ASK BOT "support-specialist" ABOUT "Customer says laptop order #12345 arrived broken. They have presentation tomorrow and need immediate help."
```
**Bot's internal reasoning:**
1. Uses `check-order` tool → Order delivered 2 days ago, $1,299 laptop
2. Uses `check-warranty` tool → Premium warranty valid
3. Uses `customer-history` tool → VIP customer, 8 previous orders
4. **Analyzes urgency** → Presentation tomorrow = time-sensitive
5. **Considers options** → Replacement (2-day shipping) vs immediate refund for local purchase
6. **Makes recommendation** → "Given urgency and VIP status, authorize immediate refund so customer can buy locally, plus expedited replacement as backup"
## Hybrid Approach: Best of Both Worlds
**Recommended pattern: Bots use Tools internally**
```basic
' support-specialist.bas - Bot implementation
USE TOOL "check-order"
USE TOOL "check-warranty"
USE TOOL "customer-history"
USE TOOL "inventory-check"
USE KB "support-policies"
WHEN ASKED ABOUT order_issue DO
' Gather data using tools (fast, cheap)
order = CALL TOOL "check-order" WITH order_id
warranty = CALL TOOL "check-warranty" WITH order_id
customer = CALL TOOL "customer-history" WITH customer_id
' Apply AI reasoning (intelligent, contextual)
urgency = ANALYZE urgency FROM user_message
customer_value = CALCULATE value FROM customer.total_orders
IF urgency = "high" AND customer_value = "vip" THEN
recommendation = "Expedited resolution with manager approval"
ELSE IF warranty.type = "premium" THEN
recommendation = "Standard replacement process"
ELSE
recommendation = "Store credit or repair option"
END IF
RETURN detailed_response WITH reasoning AND next_steps
END WHEN
```
## Performance Guidelines
### Tool Performance
- **Latency:** 10-100ms
- **Cost:** $0 (no LLM calls)
- **Throughput:** 1000+ operations/second
- **Use for:** High-frequency, simple operations
### Bot Performance
- **Latency:** 1-5 seconds
- **Cost:** $0.001-0.01 per interaction
- **Throughput:** 10-100 interactions/second
- **Use for:** Complex, high-value decisions
## Decision Framework
### Use TOOL when:
1. **Operation is deterministic** - Same input always produces same output
2. **Speed is critical** - Real-time responses needed
3. **Cost matters** - High-frequency operations
4. **Data is structured** - Clear input/output format
### Use BOT when:
1. **Context matters** - Previous conversation affects response
2. **Reasoning required** - Multiple factors to consider
3. **Natural language input** - Ambiguous or conversational requests
4. **Edge cases exist** - Situations requiring judgment
### Use HYBRID when:
1. **Complex workflows** - Multiple steps with decision points
2. **Data + Intelligence** - Need both fast data access and smart reasoning
3. **Scalability important** - Balance cost and capability
## Common Patterns
### Pattern 1: Data Retrieval
```basic
' TOOL: Simple lookup
price = CALL TOOL "get-price" WITH product_id="laptop-123"
' BOT: Contextual pricing
ADD BOT "pricing-advisor"
quote = ASK BOT "pricing-advisor" ABOUT "Customer wants bulk discount for 50 laptops, they're a returning enterprise client"
```
### Pattern 2: Validation
```basic
' TOOL: Rule-based validation
valid = CALL TOOL "validate-email" WITH email="user@domain.com"
' BOT: Contextual validation
ADD BOT "content-reviewer"
assessment = ASK BOT "content-reviewer" ABOUT "Is this product review appropriate for our family-friendly site?"
```
### Pattern 3: Workflow Orchestration
```basic
' Hybrid: Bot coordinates, tools execute
ORCHESTRATE WORKFLOW "order-processing"
STEP 1: CALL TOOL "validate-payment" WITH payment_info
STEP 2: BOT "fraud-detector" ANALYZES transaction_pattern
STEP 3: CALL TOOL "reserve-inventory" WITH product_id
STEP 4: BOT "shipping-optimizer" SELECTS best_carrier
STEP 5: CALL TOOL "send-confirmation" WITH order_details
END WORKFLOW
```
## Best Practices
### 1. Start Simple, Add Intelligence
```basic
' Phase 1: Tool-based (fast to implement)
result = CALL TOOL "process-refund" WITH order_id, amount
' Phase 2: Add bot intelligence (when complexity grows)
ADD BOT "refund-specialist"
decision = ASK BOT "refund-specialist" ABOUT "Customer wants refund but policy expired, they're threatening bad review"
```
### 2. Cache Bot Responses
```basic
' Expensive bot call
ADD BOT "product-recommender"
recommendations = ASK BOT "product-recommender" ABOUT "Best laptop for gaming under $1000"
' Cache result for similar queries
REMEMBER "gaming-laptop-under-1000" AS recommendations
```
### 3. Fallback Patterns
```basic
' Try bot first, fallback to tool
TRY
response = ASK BOT "smart-assistant" ABOUT user_query
CATCH bot_error
' Fallback to simple tool
response = CALL TOOL "keyword-search" WITH query=user_query
END TRY
```
## Summary
**Tools** are your **workhorses** - fast, reliable, cost-effective for data operations.
**Bots** are your **brain trust** - intelligent, contextual, perfect for complex decisions.
**Hybrid approach** gives you the best of both: use tools for speed and bots for intelligence.
Choose based on your specific needs:
- Need speed? → Tool
- Need intelligence? → Bot
- Need both? → Bot that uses tools
The key is understanding that **tools and bots complement each other** - they're not competing solutions, but different tools for different jobs in your AI automation toolkit.
---
**Next:** [Chapter 5: Building Multi-Agent Workflows](workflows.md)

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 280 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 163 KiB

View file

@ -0,0 +1,865 @@
/*! normalize.css v1.1.3 | MIT License | git.io/normalize */
/* ========================================================================== HTML5 display definitions ========================================================================== */
/** Correct `block` display not defined in IE 6/7/8/9 and Firefox 3. */
article, aside, details, figcaption, figure, footer, header, hgroup, main, nav, section, summary { display: block; }
/** Correct `inline-block` display not defined in IE 6/7/8/9 and Firefox 3. */
audio, canvas, video { display: inline-block; *display: inline; *zoom: 1; }
/** Prevent modern browsers from displaying `audio` without controls. Remove excess height in iOS 5 devices. */
audio:not([controls]) { display: none; height: 0; }
/** Address styling not present in IE 7/8/9, Firefox 3, and Safari 4. Known issue: no IE 6 support. */
[hidden] { display: none; }
/* ========================================================================== Base ========================================================================== */
/** 1. Correct text resizing oddly in IE 6/7 when body `font-size` is set using `em` units. 2. Prevent iOS text size adjust after orientation change, without disabling user zoom. */
html { font-size: 100%; /* 1 */ -ms-text-size-adjust: 100%; /* 2 */ -webkit-text-size-adjust: 100%; /* 2 */ font-family: sans-serif; }
/** Address `font-family` inconsistency between `textarea` and other form elements. */
button, input, select, textarea { font-family: sans-serif; }
/** Address margins handled incorrectly in IE 6/7. */
body { margin: 0; }
/* ========================================================================== Links ========================================================================== */
/** Address `outline` inconsistency between Chrome and other browsers. */
a:focus { outline: thin dotted; }
a:active, a:hover { outline: 0; }
/** Improve readability when focused and also mouse hovered in all browsers. */
/* ========================================================================== Typography ========================================================================== */
/** Address font sizes and margins set differently in IE 6/7. Address font sizes within `section` and `article` in Firefox 4+, Safari 5, and Chrome. */
h1 { font-size: 2em; margin: 0.67em 0; }
h2 { font-size: 1.5em; margin: 0.83em 0; }
h3 { font-size: 1.17em; margin: 1em 0; }
h4, .tsd-index-panel h3 { font-size: 1em; margin: 1.33em 0; }
h5 { font-size: 0.83em; margin: 1.67em 0; }
h6 { font-size: 0.67em; margin: 2.33em 0; }
/** Address styling not present in IE 7/8/9, Safari 5, and Chrome. */
abbr[title] { border-bottom: 1px dotted; }
/** Address style set to `bolder` in Firefox 3+, Safari 4/5, and Chrome. */
b, strong { font-weight: bold; }
blockquote { margin: 1em 40px; }
/** Address styling not present in Safari 5 and Chrome. */
dfn { font-style: italic; }
/** Address differences between Firefox and other browsers. Known issue: no IE 6/7 normalization. */
hr { box-sizing: content-box; height: 0; }
/** Address styling not present in IE 6/7/8/9. */
mark { background: #ff0; color: #000; }
/** Address margins set differently in IE 6/7. */
p, pre { margin: 1em 0; }
/** Correct font family set oddly in IE 6, Safari 4/5, and Chrome. */
code, kbd, pre, samp { font-family: monospace, serif; _font-family: "courier new", monospace; font-size: 1em; }
/** Improve readability of pre-formatted text in all browsers. */
pre { white-space: pre; white-space: pre-wrap; word-wrap: break-word; }
/** Address CSS quotes not supported in IE 6/7. */
q { quotes: none; }
q:before, q:after { content: ""; content: none; }
/** Address `quotes` property not supported in Safari 4. */
/** Address inconsistent and variable font size in all browsers. */
small { font-size: 80%; }
/** Prevent `sub` and `sup` affecting `line-height` in all browsers. */
sub { font-size: 75%; line-height: 0; position: relative; vertical-align: baseline; }
sup { font-size: 75%; line-height: 0; position: relative; vertical-align: baseline; top: -0.5em; }
sub { bottom: -0.25em; }
/* ========================================================================== Lists ========================================================================== */
/** Address margins set differently in IE 6/7. */
dl, menu, ol, ul { margin: 1em 0; }
dd { margin: 0 0 0 40px; }
/** Address paddings set differently in IE 6/7. */
menu, ol, ul { padding: 0 0 0 40px; }
/** Correct list images handled incorrectly in IE 7. */
nav ul, nav ol { list-style: none; list-style-image: none; }
/* ========================================================================== Embedded content ========================================================================== */
/** 1. Remove border when inside `a` element in IE 6/7/8/9 and Firefox 3. 2. Improve image quality when scaled in IE 7. */
img { border: 0; /* 1 */ -ms-interpolation-mode: bicubic; }
/* 2 */
/** Correct overflow displayed oddly in IE 9. */
svg:not(:root) { overflow: hidden; }
/* ========================================================================== Figures ========================================================================== */
/** Address margin not present in IE 6/7/8/9, Safari 5, and Opera 11. */
figure, form { margin: 0; }
/* ========================================================================== Forms ========================================================================== */
/** Correct margin displayed oddly in IE 6/7. */
/** Define consistent border, margin, and padding. */
fieldset { border: 1px solid #c0c0c0; margin: 0 2px; padding: 0.35em 0.625em 0.75em; }
/** 1. Correct color not being inherited in IE 6/7/8/9. 2. Correct text not wrapping in Firefox 3. 3. Correct alignment displayed oddly in IE 6/7. */
legend { border: 0; /* 1 */ padding: 0; white-space: normal; /* 2 */ *margin-left: -7px; }
/* 3 */
/** 1. Correct font size not being inherited in all browsers. 2. Address margins set differently in IE 6/7, Firefox 3+, Safari 5, and Chrome. 3. Improve appearance and consistency in all browsers. */
button, input, select, textarea { font-size: 100%; /* 1 */ margin: 0; /* 2 */ vertical-align: baseline; /* 3 */ *vertical-align: middle; }
/* 3 */
/** Address Firefox 3+ setting `line-height` on `input` using `!important` in the UA stylesheet. */
button, input { line-height: normal; }
/** Address inconsistent `text-transform` inheritance for `button` and `select`. All other form control elements do not inherit `text-transform` values. Correct `button` style inheritance in Chrome, Safari 5+, and IE 6+. Correct `select` style inheritance in Firefox 4+ and Opera. */
button, select { text-transform: none; }
/** 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio` and `video` controls. 2. Correct inability to style clickable `input` types in iOS. 3. Improve usability and consistency of cursor style between image-type `input` and others. 4. Remove inner spacing in IE 7 without affecting normal text inputs. Known issue: inner spacing remains in IE 6. */
button, html input[type="button"] { -webkit-appearance: button; /* 2 */ cursor: pointer; /* 3 */ *overflow: visible; }
/* 4 */
input[type="reset"], input[type="submit"] { -webkit-appearance: button; /* 2 */ cursor: pointer; /* 3 */ *overflow: visible; }
/* 4 */
/** Re-set default cursor for disabled elements. */
button[disabled], html input[disabled] { cursor: default; }
/** 1. Address box sizing set to content-box in IE 8/9. 2. Remove excess padding in IE 8/9. 3. Remove excess padding in IE 7. Known issue: excess padding remains in IE 6. */
input { /* 3 */ }
input[type="checkbox"], input[type="radio"] { box-sizing: border-box; /* 1 */ padding: 0; /* 2 */ *height: 13px; /* 3 */ *width: 13px; }
input[type="search"] { -webkit-appearance: textfield; /* 1 */ /* 2 */ box-sizing: content-box; }
input[type="search"]::-webkit-search-cancel-button, input[type="search"]::-webkit-search-decoration { -webkit-appearance: none; }
/** 1. Address `appearance` set to `searchfield` in Safari 5 and Chrome. 2. Address `box-sizing` set to `border-box` in Safari 5 and Chrome (include `-moz` to future-proof). */
/** Remove inner padding and search cancel button in Safari 5 and Chrome on OS X. */
/** Remove inner padding and border in Firefox 3+. */
button::-moz-focus-inner, input::-moz-focus-inner { border: 0; padding: 0; }
/** 1. Remove default vertical scrollbar in IE 6/7/8/9. 2. Improve readability and alignment in all browsers. */
textarea { overflow: auto; /* 1 */ vertical-align: top; }
/* 2 */
/* ========================================================================== Tables ========================================================================== */
/** Remove most spacing between table cells. */
table { border-collapse: collapse; border-spacing: 0; }
/* Visual Studio-like style based on original C# coloring by Jason Diamond <jason@diamond.name> */
.hljs { display: inline-block; padding: 0.5em; background: white; color: black; }
.hljs-comment, .hljs-annotation, .hljs-template_comment, .diff .hljs-header, .hljs-chunk, .apache .hljs-cbracket { color: #008000; }
.hljs-keyword, .hljs-id, .hljs-built_in, .css .smalltalk .hljs-class, .hljs-winutils, .bash .hljs-variable, .tex .hljs-command, .hljs-request, .hljs-status, .nginx .hljs-title { color: #00f; }
.xml .hljs-tag { color: #00f; }
.xml .hljs-tag .hljs-value { color: #00f; }
.hljs-string, .hljs-title, .hljs-parent, .hljs-tag .hljs-value, .hljs-rules .hljs-value { color: #a31515; }
.ruby .hljs-symbol { color: #a31515; }
.ruby .hljs-symbol .hljs-string { color: #a31515; }
.hljs-template_tag, .django .hljs-variable, .hljs-addition, .hljs-flow, .hljs-stream, .apache .hljs-tag, .hljs-date, .tex .hljs-formula, .coffeescript .hljs-attribute { color: #a31515; }
.ruby .hljs-string, .hljs-decorator, .hljs-filter .hljs-argument, .hljs-localvars, .hljs-array, .hljs-attr_selector, .hljs-pseudo, .hljs-pi, .hljs-doctype, .hljs-deletion, .hljs-envvar, .hljs-shebang, .hljs-preprocessor, .hljs-pragma, .userType, .apache .hljs-sqbracket, .nginx .hljs-built_in, .tex .hljs-special, .hljs-prompt { color: #2b91af; }
.hljs-phpdoc, .hljs-javadoc, .hljs-xmlDocTag { color: #808080; }
.vhdl .hljs-typename { font-weight: bold; }
.vhdl .hljs-string { color: #666666; }
.vhdl .hljs-literal { color: #a31515; }
.vhdl .hljs-attribute { color: #00b0e8; }
.xml .hljs-attribute { color: #f00; }
.col > :first-child, .col-1 > :first-child, .col-2 > :first-child, .col-3 > :first-child, .col-4 > :first-child, .col-5 > :first-child, .col-6 > :first-child, .col-7 > :first-child, .col-8 > :first-child, .col-9 > :first-child, .col-10 > :first-child, .col-11 > :first-child, .tsd-panel > :first-child, ul.tsd-descriptions > li > :first-child, .col > :first-child > :first-child, .col-1 > :first-child > :first-child, .col-2 > :first-child > :first-child, .col-3 > :first-child > :first-child, .col-4 > :first-child > :first-child, .col-5 > :first-child > :first-child, .col-6 > :first-child > :first-child, .col-7 > :first-child > :first-child, .col-8 > :first-child > :first-child, .col-9 > :first-child > :first-child, .col-10 > :first-child > :first-child, .col-11 > :first-child > :first-child, .tsd-panel > :first-child > :first-child, ul.tsd-descriptions > li > :first-child > :first-child, .col > :first-child > :first-child > :first-child, .col-1 > :first-child > :first-child > :first-child, .col-2 > :first-child > :first-child > :first-child, .col-3 > :first-child > :first-child > :first-child, .col-4 > :first-child > :first-child > :first-child, .col-5 > :first-child > :first-child > :first-child, .col-6 > :first-child > :first-child > :first-child, .col-7 > :first-child > :first-child > :first-child, .col-8 > :first-child > :first-child > :first-child, .col-9 > :first-child > :first-child > :first-child, .col-10 > :first-child > :first-child > :first-child, .col-11 > :first-child > :first-child > :first-child, .tsd-panel > :first-child > :first-child > :first-child, ul.tsd-descriptions > li > :first-child > :first-child > :first-child { margin-top: 0; }
.col > :last-child, .col-1 > :last-child, .col-2 > :last-child, .col-3 > :last-child, .col-4 > :last-child, .col-5 > :last-child, .col-6 > :last-child, .col-7 > :last-child, .col-8 > :last-child, .col-9 > :last-child, .col-10 > :last-child, .col-11 > :last-child, .tsd-panel > :last-child, ul.tsd-descriptions > li > :last-child, .col > :last-child > :last-child, .col-1 > :last-child > :last-child, .col-2 > :last-child > :last-child, .col-3 > :last-child > :last-child, .col-4 > :last-child > :last-child, .col-5 > :last-child > :last-child, .col-6 > :last-child > :last-child, .col-7 > :last-child > :last-child, .col-8 > :last-child > :last-child, .col-9 > :last-child > :last-child, .col-10 > :last-child > :last-child, .col-11 > :last-child > :last-child, .tsd-panel > :last-child > :last-child, ul.tsd-descriptions > li > :last-child > :last-child, .col > :last-child > :last-child > :last-child, .col-1 > :last-child > :last-child > :last-child, .col-2 > :last-child > :last-child > :last-child, .col-3 > :last-child > :last-child > :last-child, .col-4 > :last-child > :last-child > :last-child, .col-5 > :last-child > :last-child > :last-child, .col-6 > :last-child > :last-child > :last-child, .col-7 > :last-child > :last-child > :last-child, .col-8 > :last-child > :last-child > :last-child, .col-9 > :last-child > :last-child > :last-child, .col-10 > :last-child > :last-child > :last-child, .col-11 > :last-child > :last-child > :last-child, .tsd-panel > :last-child > :last-child > :last-child, ul.tsd-descriptions > li > :last-child > :last-child > :last-child { margin-bottom: 0; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 40px; }
@media (max-width: 640px) { .container { padding: 0 20px; } }
.container-main { padding-bottom: 200px; }
.row { position: relative; margin: 0 -10px; }
.row:after { visibility: hidden; display: block; content: ""; clear: both; height: 0; }
.col, .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11 { box-sizing: border-box; float: left; padding: 0 10px; }
.col-1 { width: 8.33333%; }
.offset-1 { margin-left: 8.33333%; }
.col-2 { width: 16.66667%; }
.offset-2 { margin-left: 16.66667%; }
.col-3 { width: 25%; }
.offset-3 { margin-left: 25%; }
.col-4 { width: 33.33333%; }
.offset-4 { margin-left: 33.33333%; }
.col-5 { width: 41.66667%; }
.offset-5 { margin-left: 41.66667%; }
.col-6 { width: 50%; }
.offset-6 { margin-left: 50%; }
.col-7 { width: 58.33333%; }
.offset-7 { margin-left: 58.33333%; }
.col-8 { width: 66.66667%; }
.offset-8 { margin-left: 66.66667%; }
.col-9 { width: 75%; }
.offset-9 { margin-left: 75%; }
.col-10 { width: 83.33333%; }
.offset-10 { margin-left: 83.33333%; }
.col-11 { width: 91.66667%; }
.offset-11 { margin-left: 91.66667%; }
.tsd-kind-icon { display: block; position: relative; padding-left: 20px; text-indent: -20px; }
.tsd-kind-icon:before { content: ''; display: inline-block; vertical-align: middle; width: 17px; height: 17px; margin: 0 3px 2px 0; background-image: url(../images/icons.png); }
@media (-webkit-min-device-pixel-ratio: 1.5), (min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) { .tsd-kind-icon:before { background-image: url(../images/icons@2x.png); background-size: 238px 204px; } }
.tsd-signature.tsd-kind-icon:before { background-position: 0 -153px; }
.tsd-kind-object-literal > .tsd-kind-icon:before { background-position: 0px -17px; }
.tsd-kind-object-literal.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -17px; }
.tsd-kind-object-literal.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -17px; }
.tsd-kind-class > .tsd-kind-icon:before { background-position: 0px -34px; }
.tsd-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -34px; }
.tsd-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -34px; }
.tsd-kind-class.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: 0px -51px; }
.tsd-kind-class.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -51px; }
.tsd-kind-class.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -51px; }
.tsd-kind-interface > .tsd-kind-icon:before { background-position: 0px -68px; }
.tsd-kind-interface.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -68px; }
.tsd-kind-interface.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -68px; }
.tsd-kind-interface.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: 0px -85px; }
.tsd-kind-interface.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -85px; }
.tsd-kind-interface.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -85px; }
.tsd-kind-module > .tsd-kind-icon:before { background-position: 0px -102px; }
.tsd-kind-module.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -102px; }
.tsd-kind-module.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -102px; }
.tsd-kind-external-module > .tsd-kind-icon:before { background-position: 0px -102px; }
.tsd-kind-external-module.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -102px; }
.tsd-kind-external-module.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -102px; }
.tsd-kind-enum > .tsd-kind-icon:before { background-position: 0px -119px; }
.tsd-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -119px; }
.tsd-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -119px; }
.tsd-kind-enum-member > .tsd-kind-icon:before { background-position: 0px -136px; }
.tsd-kind-enum-member.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -136px; }
.tsd-kind-enum-member.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -136px; }
.tsd-kind-signature > .tsd-kind-icon:before { background-position: 0px -153px; }
.tsd-kind-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -153px; }
.tsd-kind-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -153px; }
.tsd-kind-type-alias > .tsd-kind-icon:before { background-position: 0px -170px; }
.tsd-kind-type-alias.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -170px; }
.tsd-kind-type-alias.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -170px; }
.tsd-kind-variable > .tsd-kind-icon:before { background-position: -136px -0px; }
.tsd-kind-variable.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -0px; }
.tsd-kind-variable.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; }
.tsd-kind-variable.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -0px; }
.tsd-kind-variable.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -0px; }
.tsd-kind-variable.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -0px; }
.tsd-kind-variable.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -0px; }
.tsd-kind-variable.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; }
.tsd-kind-variable.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -0px; }
.tsd-kind-variable.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -0px; }
.tsd-kind-variable.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; }
.tsd-kind-variable.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -0px; }
.tsd-kind-variable.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -0px; }
.tsd-kind-property > .tsd-kind-icon:before { background-position: -136px -0px; }
.tsd-kind-property.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -0px; }
.tsd-kind-property.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; }
.tsd-kind-property.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -0px; }
.tsd-kind-property.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -0px; }
.tsd-kind-property.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -0px; }
.tsd-kind-property.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -0px; }
.tsd-kind-property.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; }
.tsd-kind-property.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -0px; }
.tsd-kind-property.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -0px; }
.tsd-kind-property.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; }
.tsd-kind-property.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -0px; }
.tsd-kind-property.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -0px; }
.tsd-kind-get-signature > .tsd-kind-icon:before { background-position: -136px -17px; }
.tsd-kind-get-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -17px; }
.tsd-kind-get-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -17px; }
.tsd-kind-get-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -17px; }
.tsd-kind-set-signature > .tsd-kind-icon:before { background-position: -136px -34px; }
.tsd-kind-set-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -34px; }
.tsd-kind-set-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -34px; }
.tsd-kind-set-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -34px; }
.tsd-kind-accessor > .tsd-kind-icon:before { background-position: -136px -51px; }
.tsd-kind-accessor.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -51px; }
.tsd-kind-accessor.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -51px; }
.tsd-kind-accessor.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -51px; }
.tsd-kind-accessor.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -51px; }
.tsd-kind-accessor.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -51px; }
.tsd-kind-accessor.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -51px; }
.tsd-kind-accessor.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -51px; }
.tsd-kind-accessor.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -51px; }
.tsd-kind-accessor.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -51px; }
.tsd-kind-accessor.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -51px; }
.tsd-kind-accessor.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -51px; }
.tsd-kind-accessor.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -51px; }
.tsd-kind-function > .tsd-kind-icon:before { background-position: -136px -68px; }
.tsd-kind-function.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -68px; }
.tsd-kind-function.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-function.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -68px; }
.tsd-kind-function.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -68px; }
.tsd-kind-function.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -68px; }
.tsd-kind-function.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -68px; }
.tsd-kind-function.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-function.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -68px; }
.tsd-kind-function.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -68px; }
.tsd-kind-function.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-function.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -68px; }
.tsd-kind-function.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -68px; }
.tsd-kind-method > .tsd-kind-icon:before { background-position: -136px -68px; }
.tsd-kind-method.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -68px; }
.tsd-kind-method.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-method.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -68px; }
.tsd-kind-method.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -68px; }
.tsd-kind-method.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -68px; }
.tsd-kind-method.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -68px; }
.tsd-kind-method.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-method.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -68px; }
.tsd-kind-method.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -68px; }
.tsd-kind-method.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-method.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -68px; }
.tsd-kind-method.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -68px; }
.tsd-kind-call-signature > .tsd-kind-icon:before { background-position: -136px -68px; }
.tsd-kind-call-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -68px; }
.tsd-kind-call-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -68px; }
.tsd-kind-call-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -68px; }
.tsd-kind-function.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: -136px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -85px; }
.tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -85px; }
.tsd-kind-method.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: -136px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -85px; }
.tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -85px; }
.tsd-kind-constructor > .tsd-kind-icon:before { background-position: -136px -102px; }
.tsd-kind-constructor.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -102px; }
.tsd-kind-constructor.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; }
.tsd-kind-constructor.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -102px; }
.tsd-kind-constructor.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -102px; }
.tsd-kind-constructor.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -102px; }
.tsd-kind-constructor.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -102px; }
.tsd-kind-constructor.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; }
.tsd-kind-constructor.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -102px; }
.tsd-kind-constructor.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -102px; }
.tsd-kind-constructor.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; }
.tsd-kind-constructor.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -102px; }
.tsd-kind-constructor.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -102px; }
.tsd-kind-constructor-signature > .tsd-kind-icon:before { background-position: -136px -102px; }
.tsd-kind-constructor-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -102px; }
.tsd-kind-constructor-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -102px; }
.tsd-kind-constructor-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -102px; }
.tsd-kind-index-signature > .tsd-kind-icon:before { background-position: -136px -119px; }
.tsd-kind-index-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -119px; }
.tsd-kind-index-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -119px; }
.tsd-kind-index-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -119px; }
.tsd-kind-event > .tsd-kind-icon:before { background-position: -136px -136px; }
.tsd-kind-event.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -136px; }
.tsd-kind-event.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -136px; }
.tsd-kind-event.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -136px; }
.tsd-kind-event.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -136px; }
.tsd-kind-event.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -136px; }
.tsd-kind-event.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -136px; }
.tsd-kind-event.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -136px; }
.tsd-kind-event.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -136px; }
.tsd-kind-event.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -136px; }
.tsd-kind-event.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -136px; }
.tsd-kind-event.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -136px; }
.tsd-kind-event.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -136px; }
.tsd-is-static > .tsd-kind-icon:before { background-position: -136px -153px; }
.tsd-is-static.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -153px; }
.tsd-is-static.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -153px; }
.tsd-is-static.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -153px; }
.tsd-is-static.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -153px; }
.tsd-is-static.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -153px; }
.tsd-is-static.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -153px; }
.tsd-is-static.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -153px; }
.tsd-is-static.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -153px; }
.tsd-is-static.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -153px; }
.tsd-is-static.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -153px; }
.tsd-is-static.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -153px; }
.tsd-is-static.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -153px; }
.tsd-is-static.tsd-kind-function > .tsd-kind-icon:before { background-position: -136px -170px; }
.tsd-is-static.tsd-kind-function.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -170px; }
.tsd-is-static.tsd-kind-function.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -170px; }
.tsd-is-static.tsd-kind-function.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -170px; }
.tsd-is-static.tsd-kind-method > .tsd-kind-icon:before { background-position: -136px -170px; }
.tsd-is-static.tsd-kind-method.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -170px; }
.tsd-is-static.tsd-kind-method.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -170px; }
.tsd-is-static.tsd-kind-method.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -170px; }
.tsd-is-static.tsd-kind-call-signature > .tsd-kind-icon:before { background-position: -136px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -170px; }
.tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -170px; }
.tsd-is-static.tsd-kind-event > .tsd-kind-icon:before { background-position: -136px -187px; }
.tsd-is-static.tsd-kind-event.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -187px; }
.tsd-is-static.tsd-kind-event.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -187px; }
.tsd-is-static.tsd-kind-event.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -187px; }
.no-transition { transition: none !important; }
@-webkit-keyframes fade-in { from { opacity: 0; }
to { opacity: 1; } }
@keyframes fade-in { from { opacity: 0; }
to { opacity: 1; } }
@-webkit-keyframes fade-out { from { opacity: 1; visibility: visible; }
to { opacity: 0; } }
@keyframes fade-out { from { opacity: 1; visibility: visible; }
to { opacity: 0; } }
@-webkit-keyframes fade-in-delayed { 0% { opacity: 0; }
33% { opacity: 0; }
100% { opacity: 1; } }
@keyframes fade-in-delayed { 0% { opacity: 0; }
33% { opacity: 0; }
100% { opacity: 1; } }
@-webkit-keyframes fade-out-delayed { 0% { opacity: 1; visibility: visible; }
66% { opacity: 0; }
100% { opacity: 0; } }
@keyframes fade-out-delayed { 0% { opacity: 1; visibility: visible; }
66% { opacity: 0; }
100% { opacity: 0; } }
@-webkit-keyframes shift-to-left { from { -webkit-transform: translate(0, 0); transform: translate(0, 0); }
to { -webkit-transform: translate(-25%, 0); transform: translate(-25%, 0); } }
@keyframes shift-to-left { from { -webkit-transform: translate(0, 0); transform: translate(0, 0); }
to { -webkit-transform: translate(-25%, 0); transform: translate(-25%, 0); } }
@-webkit-keyframes unshift-to-left { from { -webkit-transform: translate(-25%, 0); transform: translate(-25%, 0); }
to { -webkit-transform: translate(0, 0); transform: translate(0, 0); } }
@keyframes unshift-to-left { from { -webkit-transform: translate(-25%, 0); transform: translate(-25%, 0); }
to { -webkit-transform: translate(0, 0); transform: translate(0, 0); } }
@-webkit-keyframes pop-in-from-right { from { -webkit-transform: translate(100%, 0); transform: translate(100%, 0); }
to { -webkit-transform: translate(0, 0); transform: translate(0, 0); } }
@keyframes pop-in-from-right { from { -webkit-transform: translate(100%, 0); transform: translate(100%, 0); }
to { -webkit-transform: translate(0, 0); transform: translate(0, 0); } }
@-webkit-keyframes pop-out-to-right { from { -webkit-transform: translate(0, 0); transform: translate(0, 0); visibility: visible; }
to { -webkit-transform: translate(100%, 0); transform: translate(100%, 0); } }
@keyframes pop-out-to-right { from { -webkit-transform: translate(0, 0); transform: translate(0, 0); visibility: visible; }
to { -webkit-transform: translate(100%, 0); transform: translate(100%, 0); } }
body { background: #fdfdfd; font-family: "Segoe UI", sans-serif; font-size: 16px; color: #222; }
a { color: #4da6ff; text-decoration: none; }
a:hover { text-decoration: underline; }
code, pre { font-family: Menlo, Monaco, Consolas, "Courier New", monospace; padding: 0.2em; margin: 0; font-size: 14px; background-color: rgba(0, 0, 0, 0.04); }
pre { padding: 10px; }
pre code { padding: 0; font-size: 100%; background-color: transparent; }
.tsd-typography { line-height: 1.333em; }
.tsd-typography ul { list-style: square; padding: 0 0 0 20px; margin: 0; }
.tsd-typography h4, .tsd-typography .tsd-index-panel h3, .tsd-index-panel .tsd-typography h3, .tsd-typography h5, .tsd-typography h6 { font-size: 1em; margin: 0; }
.tsd-typography h5, .tsd-typography h6 { font-weight: normal; }
.tsd-typography p, .tsd-typography ul, .tsd-typography ol { margin: 1em 0; }
@media (min-width: 901px) and (max-width: 1024px) { html.default .col-content { width: 72%; }
html.default .col-menu { width: 28%; }
html.default .tsd-navigation { padding-left: 10px; } }
@media (max-width: 900px) { html.default .col-content { float: none; width: 100%; }
html.default .col-menu { position: fixed !important; overflow: auto; -webkit-overflow-scrolling: touch; overflow-scrolling: touch; z-index: 1024; top: 0 !important; bottom: 0 !important; left: auto !important; right: 0 !important; width: 100%; padding: 20px 20px 0 0; max-width: 450px; visibility: hidden; background-color: #fff; -webkit-transform: translate(100%, 0); transform: translate(100%, 0); }
html.default .col-menu > *:last-child { padding-bottom: 20px; }
html.default .overlay { content: ""; display: block; position: fixed; z-index: 1023; top: 0; left: 0; right: 0; bottom: 0; background-color: rgba(0, 0, 0, 0.75); visibility: hidden; }
html.default.to-has-menu .overlay { -webkit-animation: fade-in 0.4s; animation: fade-in 0.4s; }
html.default.to-has-menu header, html.default.to-has-menu footer, html.default.to-has-menu .col-content { -webkit-animation: shift-to-left 0.4s; animation: shift-to-left 0.4s; }
html.default.to-has-menu .col-menu { -webkit-animation: pop-in-from-right 0.4s; animation: pop-in-from-right 0.4s; }
html.default.from-has-menu .overlay { -webkit-animation: fade-out 0.4s; animation: fade-out 0.4s; }
html.default.from-has-menu header, html.default.from-has-menu footer, html.default.from-has-menu .col-content { -webkit-animation: unshift-to-left 0.4s; animation: unshift-to-left 0.4s; }
html.default.from-has-menu .col-menu { -webkit-animation: pop-out-to-right 0.4s; animation: pop-out-to-right 0.4s; }
html.default.has-menu body { overflow: hidden; }
html.default.has-menu .overlay { visibility: visible; }
html.default.has-menu header, html.default.has-menu footer, html.default.has-menu .col-content { -webkit-transform: translate(-25%, 0); transform: translate(-25%, 0); }
html.default.has-menu .col-menu { visibility: visible; -webkit-transform: translate(0, 0); transform: translate(0, 0); } }
.tsd-page-title { padding: 70px 0 20px 0; margin: 0 0 40px 0; background: #fff; box-shadow: 0 0 5px rgba(0, 0, 0, 0.35); }
.tsd-page-title h1 { margin: 0; }
.tsd-breadcrumb { margin: 0; padding: 0; color: #808080; }
.tsd-breadcrumb a { color: #808080; text-decoration: none; }
.tsd-breadcrumb a:hover { text-decoration: underline; }
.tsd-breadcrumb li { display: inline; }
.tsd-breadcrumb li:after { content: " / "; }
html.minimal .container { margin: 0; }
html.minimal .container-main { padding-top: 50px; padding-bottom: 0; }
html.minimal .content-wrap { padding-left: 300px; }
html.minimal .tsd-navigation { position: fixed !important; overflow: auto; -webkit-overflow-scrolling: touch; overflow-scrolling: touch; box-sizing: border-box; z-index: 1; left: 0; top: 40px; bottom: 0; width: 300px; padding: 20px; margin: 0; }
html.minimal .tsd-member .tsd-member { margin-left: 0; }
html.minimal .tsd-page-toolbar { position: fixed; z-index: 2; }
html.minimal #tsd-filter .tsd-filter-group { right: 0; -webkit-transform: none; transform: none; }
html.minimal footer { background-color: transparent; }
html.minimal footer .container { padding: 0; }
html.minimal .tsd-generator { padding: 0; }
@media (max-width: 900px) { html.minimal .tsd-navigation { display: none; }
html.minimal .content-wrap { padding-left: 0; } }
dl.tsd-comment-tags { overflow: hidden; }
dl.tsd-comment-tags dt { clear: both; float: left; padding: 1px 5px; margin: 0 10px 0 0; border-radius: 4px; border: 1px solid #808080; color: #808080; font-size: 0.8em; font-weight: normal; }
dl.tsd-comment-tags dd { margin: 0 0 10px 0; }
dl.tsd-comment-tags p { margin: 0; }
.tsd-panel.tsd-comment .lead { font-size: 1.1em; line-height: 1.333em; margin-bottom: 2em; }
.tsd-panel.tsd-comment .lead:last-child { margin-bottom: 0; }
.toggle-protected .tsd-is-private { display: none; }
.toggle-public .tsd-is-private, .toggle-public .tsd-is-protected, .toggle-public .tsd-is-private-protected { display: none; }
.toggle-inherited .tsd-is-inherited { display: none; }
.toggle-only-exported .tsd-is-not-exported { display: none; }
.toggle-externals .tsd-is-external { display: none; }
#tsd-filter { position: relative; display: inline-block; height: 40px; vertical-align: bottom; }
.no-filter #tsd-filter { display: none; }
#tsd-filter .tsd-filter-group { display: inline-block; height: 40px; vertical-align: bottom; white-space: nowrap; }
#tsd-filter input { display: none; }
@media (max-width: 900px) { #tsd-filter .tsd-filter-group { display: block; position: absolute; top: 40px; right: 20px; height: auto; background-color: #fff; visibility: hidden; -webkit-transform: translate(50%, 0); transform: translate(50%, 0); box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); }
.has-options #tsd-filter .tsd-filter-group { visibility: visible; }
.to-has-options #tsd-filter .tsd-filter-group { -webkit-animation: fade-in 0.2s; animation: fade-in 0.2s; }
.from-has-options #tsd-filter .tsd-filter-group { -webkit-animation: fade-out 0.2s; animation: fade-out 0.2s; }
#tsd-filter label, #tsd-filter .tsd-select { display: block; padding-right: 20px; } }
footer { border-top: 1px solid #eee; background-color: #fff; }
footer.with-border-bottom { border-bottom: 1px solid #eee; }
footer .tsd-legend-group { font-size: 0; }
footer .tsd-legend { display: inline-block; width: 25%; padding: 0; font-size: 16px; list-style: none; line-height: 1.333em; vertical-align: top; }
@media (max-width: 900px) { footer .tsd-legend { width: 50%; } }
.tsd-hierarchy { list-style: square; padding: 0 0 0 20px; margin: 0; }
.tsd-hierarchy .target { font-weight: bold; }
.tsd-index-panel .tsd-index-content { margin-bottom: -30px !important; }
.tsd-index-panel .tsd-index-section { margin-bottom: 30px !important; }
.tsd-index-panel h3 { margin: 0 -20px 10px -20px; padding: 0 20px 10px 20px; border-bottom: 1px solid #eee; }
.tsd-index-panel ul.tsd-index-list { -webkit-column-count: 3; -moz-column-count: 3; -ms-column-count: 3; -o-column-count: 3; column-count: 3; -webkit-column-gap: 20px; -moz-column-gap: 20px; -ms-column-gap: 20px; -o-column-gap: 20px; column-gap: 20px; padding: 0; list-style: none; line-height: 1.333em; }
@media (max-width: 900px) { .tsd-index-panel ul.tsd-index-list { -webkit-column-count: 1; -moz-column-count: 1; -ms-column-count: 1; -o-column-count: 1; column-count: 1; } }
@media (min-width: 901px) and (max-width: 1024px) { .tsd-index-panel ul.tsd-index-list { -webkit-column-count: 2; -moz-column-count: 2; -ms-column-count: 2; -o-column-count: 2; column-count: 2; } }
.tsd-index-panel ul.tsd-index-list li { -webkit-column-break-inside: avoid; -moz-column-break-inside: avoid; -ms-column-break-inside: avoid; -o-column-break-inside: avoid; column-break-inside: avoid; -webkit-page-break-inside: avoid; -moz-page-break-inside: avoid; -ms-page-break-inside: avoid; -o-page-break-inside: avoid; page-break-inside: avoid; }
.tsd-index-panel a, .tsd-index-panel .tsd-parent-kind-module a { color: #9600ff; }
.tsd-index-panel .tsd-parent-kind-interface a { color: #7da01f; }
.tsd-index-panel .tsd-parent-kind-enum a { color: #cc9900; }
.tsd-index-panel .tsd-parent-kind-class a { color: #4da6ff; }
.tsd-index-panel .tsd-kind-module a { color: #9600ff; }
.tsd-index-panel .tsd-kind-interface a { color: #7da01f; }
.tsd-index-panel .tsd-kind-enum a { color: #cc9900; }
.tsd-index-panel .tsd-kind-class a { color: #4da6ff; }
.tsd-index-panel .tsd-is-private a { color: #808080; }
.tsd-flag { display: inline-block; padding: 1px 5px; border-radius: 4px; color: #fff; background-color: #808080; text-indent: 0; font-size: 14px; font-weight: normal; }
.tsd-anchor { position: absolute; top: -100px; }
.tsd-member { position: relative; }
.tsd-member .tsd-anchor + h3 { margin-top: 0; margin-bottom: 0; border-bottom: none; }
.tsd-navigation { padding: 0 0 0 40px; }
.tsd-navigation a { display: block; padding-top: 2px; padding-bottom: 2px; border-left: 2px solid transparent; color: #222; text-decoration: none; transition: border-left-color 0.1s; }
.tsd-navigation a:hover { text-decoration: underline; }
.tsd-navigation ul { margin: 0; padding: 0; list-style: none; }
.tsd-navigation li { padding: 0; }
.tsd-navigation.primary { padding-bottom: 40px; }
.tsd-navigation.primary a { display: block; padding-top: 6px; padding-bottom: 6px; }
.tsd-navigation.primary ul li a { padding-left: 5px; }
.tsd-navigation.primary ul li li a { padding-left: 25px; }
.tsd-navigation.primary ul li li li a { padding-left: 45px; }
.tsd-navigation.primary ul li li li li a { padding-left: 65px; }
.tsd-navigation.primary ul li li li li li a { padding-left: 85px; }
.tsd-navigation.primary ul li li li li li li a { padding-left: 105px; }
.tsd-navigation.primary > ul { border-bottom: 1px solid #eee; }
.tsd-navigation.primary li { border-top: 1px solid #eee; }
.tsd-navigation.primary li.current > a { font-weight: bold; }
.tsd-navigation.primary li.label span { display: block; padding: 20px 0 6px 5px; color: #808080; }
.tsd-navigation.primary li.globals + li > span, .tsd-navigation.primary li.globals + li > a { padding-top: 20px; }
.tsd-navigation.secondary ul { transition: opacity 0.2s; }
.tsd-navigation.secondary ul li a { padding-left: 25px; }
.tsd-navigation.secondary ul li li a { padding-left: 45px; }
.tsd-navigation.secondary ul li li li a { padding-left: 65px; }
.tsd-navigation.secondary ul li li li li a { padding-left: 85px; }
.tsd-navigation.secondary ul li li li li li a { padding-left: 105px; }
.tsd-navigation.secondary ul li li li li li li a { padding-left: 125px; }
.tsd-navigation.secondary ul.current a { border-left-color: #eee; }
.tsd-navigation.secondary li.focus > a, .tsd-navigation.secondary ul.current li.focus > a { border-left-color: #000; }
.tsd-navigation.secondary li.current { margin-top: 20px; margin-bottom: 20px; border-left-color: #eee; }
.tsd-navigation.secondary li.current > a { font-weight: bold; }
@media (min-width: 901px) { .menu-sticky-wrap { position: static; }
.no-csspositionsticky .menu-sticky-wrap.sticky { position: fixed; }
.no-csspositionsticky .menu-sticky-wrap.sticky-current { position: fixed; }
.no-csspositionsticky .menu-sticky-wrap.sticky-current ul.before-current, .no-csspositionsticky .menu-sticky-wrap.sticky-current ul.after-current { opacity: 0; }
.no-csspositionsticky .menu-sticky-wrap.sticky-bottom { position: absolute; top: auto !important; left: auto !important; bottom: 0; right: 0; }
.csspositionsticky .menu-sticky-wrap.sticky { position: -webkit-sticky; position: sticky; }
.csspositionsticky .menu-sticky-wrap.sticky-current { position: -webkit-sticky; position: sticky; } }
.tsd-panel { margin: 20px 0; padding: 20px; background-color: #fff; box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); }
.tsd-panel:empty { display: none; }
.tsd-panel > h1, .tsd-panel > h2, .tsd-panel > h3 { margin: 1.5em -20px 10px -20px; padding: 0 20px 10px 20px; border-bottom: 1px solid #eee; }
.tsd-panel > h1.tsd-before-signature, .tsd-panel > h2.tsd-before-signature, .tsd-panel > h3.tsd-before-signature { margin-bottom: 0; border-bottom: 0; }
.tsd-panel table { display: block; width: 100%; overflow: auto; margin-top: 10px; word-break: normal; word-break: keep-all; }
.tsd-panel table th { font-weight: bold; }
.tsd-panel table th, .tsd-panel table td { padding: 6px 13px; border: 1px solid #ddd; }
.tsd-panel table tr { background-color: #fff; border-top: 1px solid #ccc; }
.tsd-panel table tr:nth-child(2n) { background-color: #f8f8f8; }
.tsd-panel-group { margin: 60px 0; }
.tsd-panel-group > h1, .tsd-panel-group > h2, .tsd-panel-group > h3 { padding-left: 20px; padding-right: 20px; }
#tsd-search { transition: background-color 0.2s; }
#tsd-search .title { position: relative; z-index: 2; }
#tsd-search .field { position: absolute; left: 0; top: 0; right: 40px; height: 40px; }
#tsd-search .field input { box-sizing: border-box; position: relative; top: -50px; z-index: 1; width: 100%; padding: 0 10px; opacity: 0; outline: 0; border: 0; background: transparent; color: #222; }
#tsd-search .field label { position: absolute; overflow: hidden; right: -40px; }
#tsd-search .field input, #tsd-search .title { transition: opacity 0.2s; }
#tsd-search .results { position: absolute; visibility: hidden; top: 40px; width: 100%; margin: 0; padding: 0; list-style: none; box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); }
#tsd-search .results li { padding: 0 10px; background-color: #fdfdfd; }
#tsd-search .results li:nth-child(even) { background-color: #fff; }
#tsd-search .results li.state { display: none; }
#tsd-search .results li.current, #tsd-search .results li:hover { background-color: #eee; }
#tsd-search .results a { display: block; }
#tsd-search .results a:before { top: 10px; }
#tsd-search .results span.parent { color: #808080; font-weight: normal; }
#tsd-search.has-focus { background-color: #eee; }
#tsd-search.has-focus .field input { top: 0; opacity: 1; }
#tsd-search.has-focus .title { z-index: 0; opacity: 0; }
#tsd-search.has-focus .results { visibility: visible; }
#tsd-search.loading .results li.state.loading { display: block; }
#tsd-search.failure .results li.state.failure { display: block; }
.tsd-signature { margin: 0 0 1em 0; padding: 10px; border: 1px solid #eee; font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px; }
.tsd-signature.tsd-kind-icon { padding-left: 30px; }
.tsd-signature.tsd-kind-icon:before { top: 10px; left: 10px; }
.tsd-panel > .tsd-signature { margin-left: -20px; margin-right: -20px; border-width: 1px 0; }
.tsd-panel > .tsd-signature.tsd-kind-icon { padding-left: 40px; }
.tsd-panel > .tsd-signature.tsd-kind-icon:before { left: 20px; }
.tsd-signature-symbol { color: #808080; font-weight: normal; }
.tsd-signature-type { font-style: italic; font-weight: normal; }
.tsd-signatures { padding: 0; margin: 0 0 1em 0; border: 1px solid #eee; }
.tsd-signatures .tsd-signature { margin: 0; border-width: 1px 0 0 0; transition: background-color 0.1s; }
.tsd-signatures .tsd-signature:first-child { border-top-width: 0; }
.tsd-signatures .tsd-signature.current { background-color: #eee; }
.tsd-signatures.active > .tsd-signature { cursor: pointer; }
.tsd-panel > .tsd-signatures { margin-left: -20px; margin-right: -20px; border-width: 1px 0; }
.tsd-panel > .tsd-signatures .tsd-signature.tsd-kind-icon { padding-left: 40px; }
.tsd-panel > .tsd-signatures .tsd-signature.tsd-kind-icon:before { left: 20px; }
.tsd-panel > a.anchor + .tsd-signatures { border-top-width: 0; margin-top: -20px; }
ul.tsd-descriptions { position: relative; overflow: hidden; transition: height 0.3s; padding: 0; list-style: none; }
ul.tsd-descriptions.active > .tsd-description { display: none; }
ul.tsd-descriptions.active > .tsd-description.current { display: block; }
ul.tsd-descriptions.active > .tsd-description.fade-in { -webkit-animation: fade-in-delayed 0.3s; animation: fade-in-delayed 0.3s; }
ul.tsd-descriptions.active > .tsd-description.fade-out { -webkit-animation: fade-out-delayed 0.3s; animation: fade-out-delayed 0.3s; position: absolute; display: block; top: 0; left: 0; right: 0; opacity: 0; visibility: hidden; }
ul.tsd-descriptions h4, ul.tsd-descriptions .tsd-index-panel h3, .tsd-index-panel ul.tsd-descriptions h3 { font-size: 16px; margin: 1em 0 0.5em 0; }
ul.tsd-parameters, ul.tsd-type-parameters { list-style: square; margin: 0; padding-left: 20px; }
ul.tsd-parameters > li.tsd-parameter-siganture, ul.tsd-type-parameters > li.tsd-parameter-siganture { list-style: none; margin-left: -20px; }
ul.tsd-parameters h5, ul.tsd-type-parameters h5 { font-size: 16px; margin: 1em 0 0.5em 0; }
ul.tsd-parameters .tsd-comment, ul.tsd-type-parameters .tsd-comment { margin-top: -0.5em; }
.tsd-sources { font-size: 14px; color: #808080; margin: 0 0 1em 0; }
.tsd-sources a { color: #808080; text-decoration: underline; }
.tsd-sources ul, .tsd-sources p { margin: 0 !important; }
.tsd-sources ul { list-style: none; padding: 0; }
.tsd-page-toolbar { position: absolute; z-index: 1; top: 0; left: 0; width: 100%; height: 40px; color: #333; background: #fff; border-bottom: 1px solid #eee; }
.tsd-page-toolbar a { color: #333; text-decoration: none; }
.tsd-page-toolbar a.title { font-weight: bold; }
.tsd-page-toolbar a.title:hover { text-decoration: underline; }
.tsd-page-toolbar .table-wrap { display: table; width: 100%; height: 40px; }
.tsd-page-toolbar .table-cell { display: table-cell; position: relative; white-space: nowrap; line-height: 40px; }
.tsd-page-toolbar .table-cell:first-child { width: 100%; }
.tsd-widget:before, .tsd-select .tsd-select-label:before, .tsd-select .tsd-select-list li:before { content: ""; display: inline-block; width: 40px; height: 40px; margin: 0 -8px 0 0; background-image: url(../images/widgets.png); background-repeat: no-repeat; text-indent: -1024px; vertical-align: bottom; }
@media (-webkit-min-device-pixel-ratio: 1.5), (min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) { .tsd-widget:before, .tsd-select .tsd-select-label:before, .tsd-select .tsd-select-list li:before { background-image: url(../images/widgets@2x.png); background-size: 320px 40px; } }
.tsd-widget { display: inline-block; overflow: hidden; opacity: 0.6; height: 40px; transition: opacity 0.1s, background-color 0.2s; vertical-align: bottom; cursor: pointer; }
.tsd-widget:hover { opacity: 0.8; }
.tsd-widget.active { opacity: 1; background-color: #eee; }
.tsd-widget.no-caption { width: 40px; }
.tsd-widget.no-caption:before { margin: 0; }
.tsd-widget.search:before { background-position: 0 0; }
.tsd-widget.menu:before { background-position: -40px 0; }
.tsd-widget.options:before { background-position: -80px 0; }
.tsd-widget.options, .tsd-widget.menu { display: none; }
@media (max-width: 900px) { .tsd-widget.options, .tsd-widget.menu { display: inline-block; } }
input[type=checkbox] + .tsd-widget:before { background-position: -120px 0; }
input[type=checkbox]:checked + .tsd-widget:before { background-position: -160px 0; }
.tsd-select { position: relative; display: inline-block; height: 40px; transition: opacity 0.1s, background-color 0.2s; vertical-align: bottom; cursor: pointer; }
.tsd-select .tsd-select-label { opacity: 0.6; transition: opacity 0.2s; }
.tsd-select .tsd-select-label:before { background-position: -240px 0; }
.tsd-select.active .tsd-select-label { opacity: 0.8; }
.tsd-select.active .tsd-select-list { visibility: visible; opacity: 1; transition-delay: 0s; }
.tsd-select .tsd-select-list { position: absolute; visibility: hidden; top: 40px; left: 0; margin: 0; padding: 0; opacity: 0; list-style: none; box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); transition: visibility 0s 0.2s, opacity 0.2s; }
.tsd-select .tsd-select-list li { padding: 0 20px 0 0; background-color: #fdfdfd; }
.tsd-select .tsd-select-list li:before { background-position: 40px 0; }
.tsd-select .tsd-select-list li:nth-child(even) { background-color: #fff; }
.tsd-select .tsd-select-list li:hover { background-color: #eee; }
.tsd-select .tsd-select-list li.selected:before { background-position: -200px 0; }
@media (max-width: 900px) { .tsd-select .tsd-select-list { top: 0; left: auto; right: 100%; margin-right: -5px; }
.tsd-select .tsd-select-label:before { background-position: -280px 0; } }
img { max-width: 100%; }

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 480 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 855 B

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -1,74 +0,0 @@
# BASIC Language Reference - Version 6.2.0
## New Workflow Orchestration Keywords
### ORCHESTRATE WORKFLOW
Creates multi-step workflows with bot coordination.
**Syntax:**
```basic
ORCHESTRATE WORKFLOW "workflow-name"
STEP 1: BOT "bot-name" "action"
STEP 2: HUMAN APPROVAL FROM "email@domain.com" TIMEOUT 1800
STEP 3: PARALLEL
BRANCH A: BOT "bot-a" "process"
BRANCH B: BOT "bot-b" "process"
END PARALLEL
END WORKFLOW
```
**Features:**
- Workflow state persists through server restarts
- Variables automatically passed between steps
- Human approval integration with timeouts
- Parallel processing support
### Event System
**ON EVENT**
```basic
ON EVENT "event-name" DO
TALK "Event received"
END ON
```
**PUBLISH EVENT**
```basic
PUBLISH EVENT "event-name"
```
**WAIT FOR EVENT**
```basic
WAIT FOR EVENT "approval-received" TIMEOUT 3600
```
### Enhanced Memory
**BOT SHARE MEMORY**
```basic
BOT SHARE MEMORY "key" WITH "target-bot"
```
**BOT SYNC MEMORY**
```basic
BOT SYNC MEMORY FROM "source-bot"
```
### Enhanced LLM (Feature-gated)
**Optimized LLM Calls**
```basic
result = LLM "Analyze data" WITH OPTIMIZE FOR "speed"
result = LLM "Complex task" WITH MAX_COST 0.05 MAX_LATENCY 2000
```
## File Type Detection
The designer automatically detects:
- **Tools**: Simple input/output functions
- **Workflows**: Multi-step orchestration
- **Regular Bots**: Conversational interfaces
## Backward Compatibility
All existing BASIC keywords continue to work unchanged. New keywords extend functionality without breaking existing `.gbai` packages.

View file

@ -0,0 +1,234 @@
<!doctype html>
<html class="default no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>GBServer | General Bots Open Core</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="../assets/css/main.css">
</head>
<body>
<header>
<div class="tsd-page-toolbar">
<div class="container">
<div class="table-wrap">
<div class="table-cell" id="tsd-search" data-index="../assets/js/search.js" data-base="..">
<div class="field">
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
<input id="tsd-search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<a href="../index.html" class="title">General Bots Open Core</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
<div class="tsd-filter-group">
<div class="tsd-select" id="tsd-filter-visibility">
<span class="tsd-select-label">All</span>
<ul class="tsd-select-list">
<li data-value="public">Public</li>
<li data-value="protected">Public/Protected</li>
<li data-value="private" class="selected">All</li>
</ul>
</div>
<input type="checkbox" id="tsd-filter-inherited" checked />
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
<input type="checkbox" id="tsd-filter-externals" checked />
<label class="tsd-widget" for="tsd-filter-externals">Externals</label>
<input type="checkbox" id="tsd-filter-only-exported" />
<label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label>
</div>
</div>
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
</div>
</div>
</div>
</div>
<div class="tsd-page-title">
<div class="container">
<ul class="tsd-breadcrumb">
<li>
<a href="../globals.html">Globals</a>
</li>
<li>
<a href="../modules/_src_app_.html">&quot;src/app&quot;</a>
</li>
<li>
<a href="_src_app_.gbserver.html">GBServer</a>
</li>
</ul>
<h1>Class GBServer</h1>
</div>
</div>
</header>
<div class="container container-main">
<div class="row">
<div class="col-8 col-content">
<section class="tsd-panel tsd-comment">
<div class="tsd-comment tsd-typography">
<div class="lead">
<p>General Bots open-core entry point.</p>
</div>
</div>
</section>
<section class="tsd-panel tsd-hierarchy">
<h3>Hierarchy</h3>
<ul class="tsd-hierarchy">
<li>
<span class="target">GBServer</span>
</li>
</ul>
</section>
<section class="tsd-panel-group tsd-index-group">
<h2>Index</h2>
<section class="tsd-panel tsd-index-panel">
<div class="tsd-index-content">
<section class="tsd-index-section ">
<h3>Methods</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-static"><a href="_src_app_.gbserver.html#run" class="tsd-kind-icon">run</a></li>
</ul>
</section>
</div>
</section>
</section>
<section class="tsd-panel-group tsd-member-group ">
<h2>Methods</h2>
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-static">
<a name="run" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagStatic">Static</span> run</h3>
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-static">
<li class="tsd-signature tsd-kind-icon">run<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/app.ts#L65">src/app.ts:65</a></li>
</ul>
</aside>
<div class="tsd-comment tsd-typography">
<div class="lead">
<p> Program entry-point.</p>
</div>
</div>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
</li>
</ul>
</section>
</section>
</div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<nav class="tsd-navigation primary">
<ul>
<li class="globals ">
<a href="../globals.html"><em>Globals</em></a>
</li>
<li class="current tsd-kind-external-module">
<a href="../modules/_src_app_.html">"src/app"</a>
</li>
</ul>
</nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul class="before-current">
</ul>
<ul class="current">
<li class="current tsd-kind-class tsd-parent-kind-external-module">
<a href="_src_app_.gbserver.html" class="tsd-kind-icon">GBServer</a>
<ul>
<li class=" tsd-kind-method tsd-parent-kind-class tsd-is-static">
<a href="_src_app_.gbserver.html#run" class="tsd-kind-icon">run</a>
</li>
</ul>
</li>
</ul>
<ul class="after-current">
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="../modules/_src_app_.html#apppackages" class="tsd-kind-icon">app<wbr>Packages</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="../modules/_src_app_.html#bodyparser" class="tsd-kind-icon">body<wbr>Parser</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="../modules/_src_app_.html#express" class="tsd-kind-icon">express</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="../modules/_src_app_.html#logger" class="tsd-kind-icon">logger</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<footer class="with-border-bottom">
<div class="container">
<h2>Legend</h2>
<div class="tsd-legend-group">
<ul class="tsd-legend">
<li class="tsd-kind-module"><span class="tsd-kind-icon">Module</span></li>
<li class="tsd-kind-object-literal"><span class="tsd-kind-icon">Object literal</span></li>
<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
<li class="tsd-kind-index-signature"><span class="tsd-kind-icon">Index signature</span></li>
<li class="tsd-kind-type-alias"><span class="tsd-kind-icon">Type alias</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-enum"><span class="tsd-kind-icon">Enumeration</span></li>
<li class="tsd-kind-enum-member"><span class="tsd-kind-icon">Enumeration member</span></li>
<li class="tsd-kind-property tsd-parent-kind-enum"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-enum"><span class="tsd-kind-icon">Method</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
<li class="tsd-kind-interface tsd-has-type-parameter"><span class="tsd-kind-icon">Interface with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-interface"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-interface"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class"><span class="tsd-kind-icon">Accessor</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-class"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static property</span></li>
<li class="tsd-kind-call-signature tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static method</span></li>
</ul>
</div>
</div>
</footer>
<div class="container tsd-generator">
<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="../assets/js/main.js"></script>
<script>if (location.protocol == 'file:') document.write('<script src="../assets/js/search.js"><' + '/script>');</script>
</body>
</html>

334
docs/reference/globals.html Normal file
View file

@ -0,0 +1,334 @@
<!doctype html>
<html class="default no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>General Bots Open Core</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="assets/css/main.css">
</head>
<body>
<header>
<div class="tsd-page-toolbar">
<div class="container">
<div class="table-wrap">
<div class="table-cell" id="tsd-search" data-index="assets/js/search.js" data-base=".">
<div class="field">
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
<input id="tsd-search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<a href="index.html" class="title">General Bots Open Core</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
<div class="tsd-filter-group">
<div class="tsd-select" id="tsd-filter-visibility">
<span class="tsd-select-label">All</span>
<ul class="tsd-select-list">
<li data-value="public">Public</li>
<li data-value="protected">Public/Protected</li>
<li data-value="private" class="selected">All</li>
</ul>
</div>
<input type="checkbox" id="tsd-filter-inherited" checked />
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
<input type="checkbox" id="tsd-filter-externals" checked />
<label class="tsd-widget" for="tsd-filter-externals">Externals</label>
<input type="checkbox" id="tsd-filter-only-exported" />
<label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label>
</div>
</div>
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
</div>
</div>
</div>
</div>
<div class="tsd-page-title">
<div class="container">
<ul class="tsd-breadcrumb">
<li>
<a href="globals.html">Globals</a>
</li>
</ul>
<h1> General Bots Open Core</h1>
</div>
</div>
</header>
<div class="container container-main">
<div class="row">
<div class="col-8 col-content">
<section class="tsd-panel-group tsd-index-group">
<h2>Index</h2>
<section class="tsd-panel tsd-index-panel">
<div class="tsd-index-content">
<section class="tsd-index-section ">
<h3>External modules</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_admin_gbapp_dialogs_admindialog_.html" class="tsd-kind-icon">"packages/admin.gbapp/dialogs/<wbr>Admin<wbr>Dialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_admin_gbapp_index_.html" class="tsd-kind-icon">"packages/admin.gbapp/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_admin_gbapp_models_adminmodel_.html" class="tsd-kind-icon">"packages/admin.gbapp/models/<wbr>Admin<wbr>Model"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_admin_gbapp_services_gbadminservice_.html" class="tsd-kind-icon">"packages/admin.gbapp/services/GBAdmin<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_admin_gbapp_strings_.html" class="tsd-kind-icon">"packages/admin.gbapp/strings"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_analytics_gblib_index_.html" class="tsd-kind-icon">"packages/analytics.gblib/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_analytics_gblib_models_index_.html" class="tsd-kind-icon">"packages/analytics.gblib/models/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_azuredeployer_gbapp_services_azuredeployerservice_.html" class="tsd-kind-icon">"packages/azuredeployer.gbapp/services/<wbr>Azure<wbr>Deployer<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_dialogs_welcomedialog_.html" class="tsd-kind-icon">"packages/core.gbapp/dialogs/<wbr>Welcome<wbr>Dialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_dialogs_whoamidialog_.html" class="tsd-kind-icon">"packages/core.gbapp/dialogs/<wbr>Who<wbr>AmIDialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_index_.html" class="tsd-kind-icon">"packages/core.gbapp/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_models_gbmodel_.html" class="tsd-kind-icon">"packages/core.gbapp/models/GBModel"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbapiservice_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBAPIService"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbconfigservice_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBConfig<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbconversationalservice_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBConversational<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbcoreservice_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBCore<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbdeployer_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBDeployer"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbimporterservice_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBImporter<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbminservice_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBMin<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_gbvmservice_.html" class="tsd-kind-icon">"packages/core.gbapp/services/GBVMService"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_services_tscompiler_.html" class="tsd-kind-icon">"packages/core.gbapp/services/TSCompiler"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_core_gbapp_strings_.html" class="tsd-kind-icon">"packages/core.gbapp/strings"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_customer_satisfaction_gbapp_dialogs_feedbackdialog_.html" class="tsd-kind-icon">"packages/customer-<wbr>satisfaction.gbapp/dialogs/<wbr>Feedback<wbr>Dialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_customer_satisfaction_gbapp_dialogs_qualitydialog_.html" class="tsd-kind-icon">"packages/customer-<wbr>satisfaction.gbapp/dialogs/<wbr>Quality<wbr>Dialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_customer_satisfaction_gbapp_index_.html" class="tsd-kind-icon">"packages/customer-<wbr>satisfaction.gbapp/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_customer_satisfaction_gbapp_models_index_.html" class="tsd-kind-icon">"packages/customer-<wbr>satisfaction.gbapp/models/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_customer_satisfaction_gbapp_services_csservice_.html" class="tsd-kind-icon">"packages/customer-<wbr>satisfaction.gbapp/services/CSService"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_customer_satisfaction_gbapp_strings_.html" class="tsd-kind-icon">"packages/customer-<wbr>satisfaction.gbapp/strings"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_kb_gbapp_dialogs_askdialog_.html" class="tsd-kind-icon">"packages/kb.gbapp/dialogs/<wbr>Ask<wbr>Dialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_kb_gbapp_dialogs_faqdialog_.html" class="tsd-kind-icon">"packages/kb.gbapp/dialogs/<wbr>Faq<wbr>Dialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_kb_gbapp_dialogs_menudialog_.html" class="tsd-kind-icon">"packages/kb.gbapp/dialogs/<wbr>Menu<wbr>Dialog"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_kb_gbapp_index_.html" class="tsd-kind-icon">"packages/kb.gbapp/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_kb_gbapp_models_index_.html" class="tsd-kind-icon">"packages/kb.gbapp/models/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_kb_gbapp_services_kbservice_.html" class="tsd-kind-icon">"packages/kb.gbapp/services/KBService"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_kb_gbapp_strings_.html" class="tsd-kind-icon">"packages/kb.gbapp/strings"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_security_gblib_index_.html" class="tsd-kind-icon">"packages/security.gblib/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_security_gblib_models_index_.html" class="tsd-kind-icon">"packages/security.gblib/models/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_security_gblib_services_secservice_.html" class="tsd-kind-icon">"packages/security.gblib/services/<wbr>Sec<wbr>Service"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_whatsapp_gblib_index_.html" class="tsd-kind-icon">"packages/whatsapp.gblib/index"</a></li>
<li class="tsd-kind-external-module tsd-is-external"><a href="modules/_packages_whatsapp_gblib_services_whatsappdirectline_.html" class="tsd-kind-icon">"packages/whatsapp.gblib/services/<wbr>Whatsapp<wbr>Direct<wbr>Line"</a></li>
<li class="tsd-kind-external-module"><a href="modules/_src_app_.html" class="tsd-kind-icon">"src/app"</a></li>
<li class="tsd-kind-external-module"><a href="modules/_src_logger_.html" class="tsd-kind-icon">"src/logger"</a></li>
</ul>
</section>
</div>
</section>
</section>
</div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<nav class="tsd-navigation primary">
<ul>
<li class="globals current ">
<a href="globals.html"><em>Globals</em></a>
</li>
<li class="label tsd-is-external">
<span>Internals</span>
</li>
<li class=" tsd-kind-external-module">
<a href="modules/_src_app_.html">"src/app"</a>
</li>
<li class=" tsd-kind-external-module">
<a href="modules/_src_logger_.html">"src/logger"</a>
</li>
<li class="label tsd-is-external">
<span>Externals</span>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_dialogs_admindialog_.html">"packages/admin.gbapp/dialogs/<wbr>Admin<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_index_.html">"packages/admin.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_models_adminmodel_.html">"packages/admin.gbapp/models/<wbr>Admin<wbr>Model"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_services_gbadminservice_.html">"packages/admin.gbapp/services/GBAdmin<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_strings_.html">"packages/admin.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_analytics_gblib_index_.html">"packages/analytics.gblib/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_analytics_gblib_models_index_.html">"packages/analytics.gblib/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_azuredeployer_gbapp_services_azuredeployerservice_.html">"packages/azuredeployer.gbapp/services/<wbr>Azure<wbr>Deployer<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_dialogs_welcomedialog_.html">"packages/core.gbapp/dialogs/<wbr>Welcome<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_dialogs_whoamidialog_.html">"packages/core.gbapp/dialogs/<wbr>Who<wbr>AmIDialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_index_.html">"packages/core.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_models_gbmodel_.html">"packages/core.gbapp/models/GBModel"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbapiservice_.html">"packages/core.gbapp/services/GBAPIService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbconfigservice_.html">"packages/core.gbapp/services/GBConfig<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbconversationalservice_.html">"packages/core.gbapp/services/GBConversational<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbcoreservice_.html">"packages/core.gbapp/services/GBCore<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbdeployer_.html">"packages/core.gbapp/services/GBDeployer"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbimporterservice_.html">"packages/core.gbapp/services/GBImporter<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbminservice_.html">"packages/core.gbapp/services/GBMin<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbvmservice_.html">"packages/core.gbapp/services/GBVMService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_tscompiler_.html">"packages/core.gbapp/services/TSCompiler"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_strings_.html">"packages/core.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_dialogs_feedbackdialog_.html">"packages/customer-<wbr>satisfaction.gbapp/dialogs/<wbr>Feedback<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_dialogs_qualitydialog_.html">"packages/customer-<wbr>satisfaction.gbapp/dialogs/<wbr>Quality<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_index_.html">"packages/customer-<wbr>satisfaction.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_models_index_.html">"packages/customer-<wbr>satisfaction.gbapp/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_services_csservice_.html">"packages/customer-<wbr>satisfaction.gbapp/services/CSService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_strings_.html">"packages/customer-<wbr>satisfaction.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_dialogs_askdialog_.html">"packages/kb.gbapp/dialogs/<wbr>Ask<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_dialogs_faqdialog_.html">"packages/kb.gbapp/dialogs/<wbr>Faq<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_dialogs_menudialog_.html">"packages/kb.gbapp/dialogs/<wbr>Menu<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_index_.html">"packages/kb.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_models_index_.html">"packages/kb.gbapp/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_services_kbservice_.html">"packages/kb.gbapp/services/KBService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_strings_.html">"packages/kb.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_security_gblib_index_.html">"packages/security.gblib/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_security_gblib_models_index_.html">"packages/security.gblib/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_security_gblib_services_secservice_.html">"packages/security.gblib/services/<wbr>Sec<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_whatsapp_gblib_index_.html">"packages/whatsapp.gblib/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_whatsapp_gblib_services_whatsappdirectline_.html">"packages/whatsapp.gblib/services/<wbr>Whatsapp<wbr>Direct<wbr>Line"</a>
</li>
</ul>
</nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul class="before-current">
</ul>
</nav>
</div>
</div>
</div>
<footer class="with-border-bottom">
<div class="container">
<h2>Legend</h2>
<div class="tsd-legend-group">
<ul class="tsd-legend">
<li class="tsd-kind-module"><span class="tsd-kind-icon">Module</span></li>
<li class="tsd-kind-object-literal"><span class="tsd-kind-icon">Object literal</span></li>
<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
<li class="tsd-kind-index-signature"><span class="tsd-kind-icon">Index signature</span></li>
<li class="tsd-kind-type-alias"><span class="tsd-kind-icon">Type alias</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-enum"><span class="tsd-kind-icon">Enumeration</span></li>
<li class="tsd-kind-enum-member"><span class="tsd-kind-icon">Enumeration member</span></li>
<li class="tsd-kind-property tsd-parent-kind-enum"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-enum"><span class="tsd-kind-icon">Method</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
<li class="tsd-kind-interface tsd-has-type-parameter"><span class="tsd-kind-icon">Interface with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-interface"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-interface"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class"><span class="tsd-kind-icon">Accessor</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-class"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static property</span></li>
<li class="tsd-kind-call-signature tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static method</span></li>
</ul>
</div>
</div>
</footer>
<div class="container tsd-generator">
<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="assets/js/main.js"></script>
<script>if (location.protocol == 'file:') document.write('<script src="assets/js/search.js"><' + '/script>');</script>
</body>
</html>

559
docs/reference/index.html Normal file
View file

@ -0,0 +1,559 @@
<!doctype html>
<html class="default no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>General Bots Open Core</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="assets/css/main.css">
</head>
<body>
<header>
<div class="tsd-page-toolbar">
<div class="container">
<div class="table-wrap">
<div class="table-cell" id="tsd-search" data-index="assets/js/search.js" data-base=".">
<div class="field">
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
<input id="tsd-search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<a href="index.html" class="title">General Bots Open Core</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
<div class="tsd-filter-group">
<div class="tsd-select" id="tsd-filter-visibility">
<span class="tsd-select-label">All</span>
<ul class="tsd-select-list">
<li data-value="public">Public</li>
<li data-value="protected">Public/Protected</li>
<li data-value="private" class="selected">All</li>
</ul>
</div>
<input type="checkbox" id="tsd-filter-inherited" checked />
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
<input type="checkbox" id="tsd-filter-externals" checked />
<label class="tsd-widget" for="tsd-filter-externals">Externals</label>
<input type="checkbox" id="tsd-filter-only-exported" />
<label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label>
</div>
</div>
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
</div>
</div>
</div>
</div>
<div class="tsd-page-title">
<div class="container">
<ul class="tsd-breadcrumb">
<li>
<a href="globals.html">Globals</a>
</li>
</ul>
<h1> General Bots Open Core</h1>
</div>
</div>
</header>
<div class="container container-main">
<div class="row">
<div class="col-8 col-content">
<div class="tsd-panel tsd-typography">
<table>
<thead>
<tr>
<th>Area</th>
<th>Status</th>
</tr>
</thead>
<tbody><tr>
<td>Community</td>
<td><a href="https://stackoverflow.com/questions/tagged/generalbots"><img src="https://img.shields.io/stackexchange/stackoverflow/t/generalbots.svg" alt="StackExchange"></a> <a href="https://gitter.im/GeneralBots"><img src="https://img.shields.io/gitter/room/pragmatismo-io/GeneralBots.svg" alt="Gitter"></a> <a href="https://badges.frapsoft.com"><img src="https://badges.frapsoft.com/os/v2/open-source.svg" alt="Open-source"></a> <a href="http://makeapullrequest.com"><img src="https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square" alt="PRs Welcome"></a> <a href="https://github.com/pragmatismo-io/BotServer/blob/master/LICENSE.txt"><img src="https://img.shields.io/badge/license-AGPL-blue.svg" alt="License"></a></td>
</tr>
<tr>
<td>Management</td>
<td><a href="https://gitHub.com/pragmatismo-io/BotServer/graphs/commit-activity"><img src="https://img.shields.io/badge/Maintained%3F-yes-green.svg" alt="Maintenance"></a> <a href="https://waffle.io/pragmatismo-io/BotServer"><img src="https://badge.waffle.io/pragmatismo-io/BotServer.svg?columns=all" alt="Waffle.io - Columns and their card count"></a></td>
</tr>
<tr>
<td>Security</td>
<td><a href="https://snyk.io/test/github/pragmatismo-io/BotServer"><img src="https://snyk.io/test/github/pragmatismo-io/BotServer/badge.svg" alt="Known Vulnerabilities"></a></td>
</tr>
<tr>
<td>Building &amp; Quality</td>
<td><a href="https://travis-ci.com/pragmatismo-io/BotServer"><img src="https://travis-ci.com/pragmatismo-io/BotServer.svg?branch=master" alt="Build Status"></a> <a href="https://coveralls.io/github/pragmatismo-io/BotServer"><img src="https://coveralls.io/repos/github/pragmatismo-io/BotServer/badge.svg" alt="Coverage Status"></a> <a href="https://github.com/prettier/prettier"><img src="https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square" alt="code style: prettier"></a></td>
</tr>
<tr>
<td>Packaging</td>
<td><a href="https://badge.fury.io"><img src="https://badge.fury.io/js/botserver.svg" alt="forthebadge"></a> <a href="https://david-dm.org"><img src="https://david-dm.org/pragmatismo-io/botserver.svg" alt="Dependencies"></a> <a href="https://greenkeeper.io/"><img src="https://badges.greenkeeper.io/pragmatismo-io/BotServer.svg" alt="Greenkeeper badge"></a> <a href="http://commitizen.github.io/cz-cli/"><img src="https://img.shields.io/badge/commitizen-friendly-brightgreen.svg" alt="Commitizen friendly"></a></td>
</tr>
<tr>
<td>Releases</td>
<td><a href="https://www.npmjs.com/package/botserver/"><img src="https://img.shields.io/npm/dt/botserver.svg?logo=npm&label=botserver" alt="General Bots"></a> <a href="https://www.npmjs.com/package/botlib/"><img src="https://img.shields.io/npm/dt/botlib.svg?logo=npm&label=botlib" alt=".gbapp lib"></a> <a href="https://github.com/semantic-release/semantic-release"><img src="https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg" alt="semantic-release"></a></td>
</tr>
<tr>
<td><a href="https://github.com/lpicanco/docker-botserver">Docker Image</a></td>
<td><img src="https://img.shields.io/docker/automated/lpicanco/botserver.svg" alt="Docker Automated build"> <img src="https://img.shields.io/docker/build/lpicanco/botserver.svg" alt="Docker Build Status"> <img src="https://img.shields.io/microbadger/image-size/lpicanco/botserver.svg" alt="MicroBadger Size"> <img src="https://img.shields.io/microbadger/layers/lpicanco/botserver.svg" alt="MicroBadger Layers"> <img src="https://img.shields.io/docker/pulls/lpicanco/botserver.svg" alt="Docker Pulls"> <br/> <em>Provided by <a href="https://github.com/lpicanco/docker-botserver">@lpicanco</a></em></td>
</tr>
</tbody></table>
<h4 id="watch-a-video-about-easeness-authoring-of-bot-packages-development-environment-and-self-deployment">Watch a video about easeness authoring of bot packages, development environment and self-deployment</h4>
<ul>
<li>Now with General Bots you can press F5 on Visual Studio to get a bot factory on your environment* published on November 10th, 2018.</li>
</ul>
<p><a href="https://www.youtube.com/watch?v=AfKTwljoMOs"><img src="https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/video-01-thumb.jpg" alt="General Bot Video"></a></p>
<h2 id="welcome-to-general-bot-community-edition">Welcome to General Bot Community Edition</h2>
<p><img src="https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/logo.png" alt="General Bot Logo"></p>
<p>General Bot is a package based chat bot server focused in convention over configuration and code-less approaches, which brings software packages and application server concepts to help parallel bot development.</p>
<h2 id="sample-package-1-default-gbdialog-vba-">Sample Package #1: <a href="https://github.com/pragmatismo-io/BotServer/tree/master/packages/default.gbdialog">default.gbdialog (VBA)</a></h2>
<ul>
<li>See how easy is to use &#39;hear&#39; and &#39;talk&#39; to build Microsoft BOT Framework v4 logic with plain BASIC * published on December 3rd, 2018.</li>
</ul>
<p><a href="https://www.youtube.com/watch?v=yX1sF9n9628"><img src="https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/video-02-thumb.jpg" alt="See how easy is to use &#39;hear&#39; and &#39;talk&#39; to build Microsoft BOT Framework v4 logic with plain BASIC"></a></p>
<h2 id="sample-package-2-azureadpasswordreset-gbapp-typescript-">Sample Package #2: <a href="https://github.com/pragmatismo-io/AzureADPasswordReset.gbapp">AzureADPasswordReset.gbapp (TypeScript)</a></h2>
<p>Custom dialogs for reseting user password in Azure Active Directory, Office 365, Dynamics 365 or any app published through Azure AD. See also <a href="https://github.com/pragmatismo-io/IntranetBotQuickStart.gbai">IntranetBotQuickStart.gbai</a> and related MSDN article <strong><a href="https://blogs.msdn.microsoft.com/buckwoody/2018/09/25/applied-ai-using-a-bot-for-password-reset">Applied AI Using a Bot for Password Reset</a></strong> by <em>Rodrigo Souza</em>.</p>
<h3 id="bot-administrator-setup-security">Bot Administrator - Setup Security</h3>
<p>So the Bot provides an <strong>admin</strong> mode allowing the user having the Directory.AccessAsUser.All permission to be logged on Administrative interface to obtain and save its token into the database.</p>
<p><img src="https://raw.githubusercontent.com/pragmatismo-io/AzureADPasswordReset.gbapp/master/docs/general-bots-reset-ad-password-admin.gif" alt="General Bot Logo"></p>
<h3 id="bot-user-reset-password">Bot User - Reset Password</h3>
<p>With the access token stored in the database, any user can access anonymously the
bot and through a combination of e-mail and mobile received code, the user will be able to reset her or his password.</p>
<h4 id="reset-password-via-web">Reset password via Web</h4>
<p>Any user can use a web address to talk to a reset password bot. Just provide credentials that are confronted with Microsoft Graph to ensure security.</p>
<p><img src="https://raw.githubusercontent.com/pragmatismo-io/AzureADPasswordReset.gbapp/master/docs/password.gif" alt="General Bot Logo"></p>
<p>general-bots-reset-ad-password.gif </p>
<h4 id="reset-password-via-skype">Reset password via Skype</h4>
<p>This is the case when user does not have the password to login on Skype for Business or Teams, and they need to reset their password, so the right tool is Skype.</p>
<p><img src="https://raw.githubusercontent.com/pragmatismo-io/AzureADPasswordReset.gbapp/master/docs/general-bots-reset-ad-password.gif" alt="General Bot Logo"></p>
<h2 id="what-is-a-bot-server-">What is a Bot Server?</h2>
<p><img src="https://github.com/pragmatismo-io/BotServer/blob/master/docs/images/generalbots-open-core-starting-from-scratch.gif" alt="General Bots Starting From Scrach"></p>
<p>Bot Server accelerates the process of developing a bot. It provisions all code
base, resources and deployment to the cloud, and gives you templates you can
choose from whenever you need a new bot. The server has a database and service
backend allowing you to further modify your bot package directly by downloading
a zip file, editing and uploading it back to the server (deploying process) with
no code. The Bot Server also provides a framework to develop bot packages in a more
advanced fashion writing custom code in editors like Visual Studio Code, Atom or Brackets.</p>
<p>Everyone can create bots by just copying and pasting some files and using their
favorite tools like Excel (or any text editor) or Photoshop (or any image
editor).</p>
<h2 id="package-quick-reference">Package Quick Reference</h2>
<table>
<thead>
<tr>
<th>Whatsapp</th>
<th>Web</th>
<th>Core</th>
<th>KB</th>
</tr>
</thead>
<tbody><tr>
<td><a href="https://github.com/pragmatismo-io/BotServer/tree/master/packages/whatsapp.gblib">whatsapp.gblib</a></td>
<td><a href="https://github.com/pragmatismo-io/BotServer/tree/master/packages/default.gbui">default.gbui</a></td>
<td><a href="https://github.com/pragmatismo-io/BotServer/tree/master/packages/core.gbapp">core.gbapp</a></td>
<td><a href="https://github.com/pragmatismo-io/BotServer/tree/master/packages/kb.gbapp">kb.gbapp</a></td>
</tr>
</tbody></table>
<h3 id="the-bot-development-stack">The bot development stack</h3>
<p><img src="https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/general-bots-stack.png" alt="General Bot Logo"></p>
<h3 id="the-bot-factory">The Bot Factory</h3>
<p><img src="https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/general-bots-block-architecture.png" alt="General Bots Block Architecture"></p>
<p>GeneralBots aims to delivery bots in azure in a very easy and fast fashion. Use Office tools like Word or Excel to edit your Bot - using code (JavaScript or TypeScript) just to empower custom requirements.</p>
<h4 id="use-excel-for-hierarchical-knowledge-base-editing">Use Excel for (Hierarchical) Knowledge Base Editing</h4>
<p><img src="https://github.com/pragmatismo-io/BotServer/blob/master/docs/images/general-bots-composing-subjects-json-and-excel.gif" alt="General Bots Inside Excel can enable bot production the masses"></p>
<h4 id="use-visual-studio-for-a-complete-gbai-package-building-system">Use Visual Studio for a complete .gbai package building system</h4>
<p><img src="https://raw.githubusercontent.com/pragmatismo-io/BotServer/master/docs/images/general-bots-inside-visual-studio-code-provides-a-complete-artificial-intelligence-based-conversational-platform.png" alt="General Bots Inside Visual Studio Code provides a complete artificial intelligence based conversational platform"></p>
<h2 id="how-to">How To</h2>
<h3 id="run-the-server-locally">Run the server locally</h3>
<ol>
<li>Install <a href="https://www.npmjs.com/get-npm">Node.js</a> the current generation General Bot code execution platform;</li>
<li>Open a <strong>Terminal</strong> on Linux and Mac or a <strong>Command Prompt</strong> window on Windows;</li>
<li>Type <code>npm install -g botserver</code> and press <em>ENTER</em>;</li>
<li>Type <code>gbot</code> to run the server core.</li>
</ol>
<p>Notes:</p>
<ul>
<li><a href="https://chocolatey.org/packages/nodejs.install"><em>nodejs.install</em> Chocolatey Package</a> is also available.</li>
<li>The zip source code of General Bot is also available for <a href="https://codeload.github.com/pragmatismo-io/BotServer/zip/master">Download</a>;</li>
</ul>
<h3 id="configure-the-server-to-deploy-specific-directory">Configure the server to deploy specific directory</h3>
<ol>
<li>Create/Edit the .env file and add the ADDITIONAL_DEPLOY_PATH key pointing to the .gbai local parent folder of .gbapp, .gbot, .gbtheme, .gbkb package directories.</li>
<li>Specify STORAGE_SYNC to TRUE so database sync is run when the server is run.</li>
<li>In case of Microsoft SQL Server add the following keys: STORAGE_SERVER, STORAGE_NAME, STORAGE_USERNAME, STORAGE_PASSWORD, STORAGE_DIALECT to <code>mssql</code>.</li>
</ol>
<p>Note:</p>
<ul>
<li>You can specify several bots separated by semicolon, the BotServer will serve all of them at once.</li>
</ul>
<h2 id="setup-development-environment-windows-">Setup development environment (Windows)</h2>
<ol>
<li>[Optional] Install <a href="https://chocolatey.org/install">Chocolatey</a>, a Windows Package Manager;</li>
<li>Install <a href="%60https://git-scm.com/%60">git</a>, a Software Configuration Management (SCM).;</li>
<li>Install <a href="npmjs.com/get-npm">Node.js</a>, a <a href="https://en.wikipedia.org/wiki/Runtime_system">Runtime system</a>.
(<a href="https://www.npmjs.com/get-npm">https://www.npmjs.com/get-npm</a>) (suggested: LTS 8.x.x);</li>
<li>Install <a href="https://chocolatey.org/packages/nodejs.install">Visual Studio Code</a>, Brackets or Atom as an editor of your choice;</li>
<li><a href="https://en.wikipedia.org/wiki/Fork_(software_development)">Fork</a> by visiting <a href="https://github.com/pragmatismo-io/BotServer/fork">https://github.com/pragmatismo-io/BotServer/fork</a></li>
<li>Clone the just forked repository by running <code>git clone &lt;your-forked-repository-url&gt;/BotServer.git</code> ;</li>
<li>Run <code>npm install -g typescript</code>;</li>
<li>Run <code>npm install</code> on Command Prompt or PowerShell on the General Bot source-code folder;</li>
<li>Enter &#39;./packages/default.gbui&#39; folder;</li>
<li>Run <code>npm install</code> folled by <code>npm run build</code> (To build default Bot UI);</li>
<li>Enter the On the downloaded folder (../..);</li>
<li>Compile the bot server by <code>tsc</code>.</li>
<li>Run the bot server by <code>npm start</code>.</li>
</ol>
<p>Note:</p>
<ul>
<li>Whenever you are ready to turn your open-source bot ideas in form of .gbapp (source-code) and artifacts like .gbkb, .gbtheme, .gbot or the .gbai full package read <a href="https://github.com/pragmatismo-io/BotServer/blob/master/CONTRIBUTING.md">CONTRIBUTING.md</a> about performing Pull Requests (PR) and creating other public custom packages repositories of your own personal or organization General Bot Community Edition powered packages.</li>
</ul>
<h3 id="running-unit-tests">Running unit tests</h3>
<ol>
<li>Enter the BotServer root folder.</li>
<li>Run tests by <code>npm test</code>.</li>
</ol>
<h3 id="just-copy-the-source-code-to-your-machine">Just copy the source code to your machine</h3>
<ol>
<li>[Download] the Zip file of (<a href="https://codeload.github.com/pragmatismo-io/BotServer/zip/master">https://codeload.github.com/pragmatismo-io/BotServer/zip/master</a>)</li>
</ol>
<h3 id="updating-the-bot-knoledge-base-gbkb-folder-">Updating the Bot Knoledge Base (.gbkb folder)</h3>
<p>The subjects.json file contains all information related to the subject tree and can be used to build the menu carrousel as well give a set of words to be used as subject catcher in the conversation. A hierarchy can be specified.</p>
<h3 id="creating-a-new-theme-folder-gbtheme-folder-">Creating a new Theme folder (.gbtheme folder)</h3>
<p>A theme is composed of some CSS files and images. That set of files can change
everything in the General Bot UI. Use them extensively before going to change
the UI application itself (HTML &amp; JS).</p>
<h2 id="package-types">Package Types</h2>
<h3 id="-gbai">.gbai</h3>
<p>Embraces all packages types (content, logic &amp; conversation) into a pluggable bot
directory. <a href="https://github.com/pragmatismo-io/IntranetBotQuickStart.gbai">A sample .gbai is available</a>.</p>
<h3 id="-gbapp">.gbapp</h3>
<p>The artificial intelligence extensions in form of pluggable apps. Dialogs,
Services and all model related to data. A set of interactions, use cases,
integrations in form of conversationals dialogs.
The .gbapp adds the General Bot base library (botlib) for building Node.js TypeScript Apps packages.</p>
<p>Four components builds up a General Bot App:</p>
<ul>
<li>dialogs</li>
<li>models</li>
<li>services</li>
<li>tests</li>
</ul>
<h4 id="dialogs">Dialogs</h4>
<p>All code contained in a dialog builds the flow to custom conversations in
built-in and additional packages .</p>
<h4 id="models">Models</h4>
<p>Models builds the foundation of data relationships in form of entities.</p>
<h4 id="services">Services</h4>
<p>Services are a façade for bot back-end logic and other custom processing.</p>
<h4 id="tests">Tests</h4>
<p>Tests try to automate code execution validation before crashing in production.</p>
<h3 id="-gbot">.gbot</h3>
<p>An expression of an artificial inteligence entity. A .gbot file defines
all bots dependencies related to services and other resources.</p>
<h3 id="-gbtheme">.gbtheme</h3>
<p>A theme of a bot at a given time. CSS files &amp; images that can compose all UI
presentation and using it a branding can be done. <a href="https://github.com/pragmatismo-io/Office365.gbtheme">A sample .gbtheme is available</a></p>
<h3 id="-gbkb">.gbkb</h3>
<p>A set of subjects that bot knows in a form of hierarchical menu-based QnA. <a href="https://github.com/pragmatismo-io/ProjectOnline.gbkb">A sample .gbkb is available</a>.</p>
<h3 id="-gblib">.gblib</h3>
<p>Shared code that can be used across bot apps.</p>
<h2 id="reference">Reference</h2>
<h3 id="generalbots-admin-commands">GeneralBots admin commands</h3>
<p>General Bot can be controlled by the same chat window people talk to, so
here is a list of admin commands related to deploying .gb* files.</p>
<table>
<thead>
<tr>
<th>Command</th>
<th>Description</th>
</tr>
</thead>
<tbody><tr>
<td>deployPackage</td>
<td>Deploy a KB package. Usage <strong>deployPackage</strong> [package-name]. Then, you need to run rebuildIndex.</td>
</tr>
<tr>
<td>undeployPackage</td>
<td>Undeploy a KB. Usage <strong>undeployPackage</strong> [package-name].</td>
</tr>
<tr>
<td>redeployPackage</td>
<td>Undeploy and then deploys the KB. Usage <strong>redeployPackage</strong> [package-name]. Then, you need to run rebuildIndex.</td>
</tr>
<tr>
<td>setupSecurity</td>
<td>Setup connection to user directories.</td>
</tr>
</tbody></table>
<p>Discontinued commands:</p>
<table>
<thead>
<tr>
<th>Command</th>
<th>Description</th>
<th>Reason</th>
</tr>
</thead>
<tbody><tr>
<td>rebuildIndex</td>
<td>Rebuild Azure Search indexes, must be run after <strong>deployPackage</strong> or <strong>redeployPackage</strong>.</td>
<td>Now it is called automatically</td>
</tr>
</tbody></table>
<h3 id="credits-inspiration">Credits &amp; Inspiration</h3>
<ul>
<li>Rodrigo Rodriguez (<a href="mailto:me@rodrigorodriguez.com">me@rodrigorodriguez.com</a>) - Coding, Docs &amp; Architecture.</li>
<li>David Lerner (<a href="mailto:david.lerner@hotmail.com">david.lerner@hotmail.com</a>) - UI, UX &amp; Theming.</li>
<li>Eduardo Romeiro (<a href="mailto:eromeirosp@outlook.com">eromeirosp@outlook.com</a>) - Content &amp; UX.</li>
<li>Jorge Ramos (<a href="mailto:jramos@pobox.com">jramos@pobox.com</a>) - Coding, Docs &amp; Architecture.</li>
<li>PH Nascimento (<a href="mailto:ph.an@outlook.com">ph.an@outlook.com</a>) - Product Manager</li>
</ul>
<p>Powered by Microsoft <a href="https://dev.botframework.com/">BOT Framework</a> and <a href="http://www.azure.com">Azure</a>.</p>
<p>General Bot Code Name is <a href="https://en.wikipedia.org/wiki/Guaribas">Guaribas</a>, the name of a city in Brasil, state of Piaui.
<a href="http://www.robertounger.com/en/">Roberto Mangabeira Unger</a>: &quot;No one should have to do work that can be done by a machine&quot;.</p>
<h2 id="contributing">Contributing</h2>
<p>This project welcomes contributions and suggestions.
See our <a href="https://github.com/pragmatismo-io/BotServer/blob/master/CONTRIBUTING.md">Contribution Guidelines</a> for more details.</p>
<h2 id="reporting-security-issues">Reporting Security Issues</h2>
<p>Security issues and bugs should be reported privately, via email, to the Pragmatismo.io Security
team at <a href="mailto:security@pragmatismo.io">security@pragmatismo.io</a>. You should
receive a response within 24 hours. If for some reason you do not, please follow up via
email to ensure we received your original message. </p>
<h2 id="license-warranty">License &amp; Warranty</h2>
<p>General Bot Copyright (c) Pragmatismo.io. All rights reserved.
Licensed under the AGPL-3.0. </p>
<p>According to our dual licensing model, this program can be used either
under the terms of the GNU Affero General Public License, version 3,
or under a proprietary license. </p>
<p>The texts of the GNU Affero General Public License with an additional
permission and of our proprietary license can be found at and
in the LICENSE file you have received along with this program.</p>
<p>This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.</p>
<p>&quot;General Bot&quot; is a registered trademark of Pragmatismo.io.
The licensing of the program under the AGPLv3 does not imply a
trademark license. Therefore any rights, title and interest in
our trademarks remain entirely with us.</p>
<p><a href="https://stackoverflow.com/questions/ask?tags=generalbots">:speech_balloon: Ask a question</a> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <a href="/docs">:book: Read the Docs</a></p>
</h2>
</div>
</div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<nav class="tsd-navigation primary">
<ul>
<li class="globals ">
<a href="globals.html"><em>Globals</em></a>
</li>
<li class="label tsd-is-external">
<span>Internals</span>
</li>
<li class=" tsd-kind-external-module">
<a href="modules/_src_app_.html">"src/app"</a>
</li>
<li class=" tsd-kind-external-module">
<a href="modules/_src_logger_.html">"src/logger"</a>
</li>
<li class="label tsd-is-external">
<span>Externals</span>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_dialogs_admindialog_.html">"packages/admin.gbapp/dialogs/<wbr>Admin<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_index_.html">"packages/admin.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_models_adminmodel_.html">"packages/admin.gbapp/models/<wbr>Admin<wbr>Model"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_services_gbadminservice_.html">"packages/admin.gbapp/services/GBAdmin<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_admin_gbapp_strings_.html">"packages/admin.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_analytics_gblib_index_.html">"packages/analytics.gblib/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_analytics_gblib_models_index_.html">"packages/analytics.gblib/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_azuredeployer_gbapp_services_azuredeployerservice_.html">"packages/azuredeployer.gbapp/services/<wbr>Azure<wbr>Deployer<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_dialogs_welcomedialog_.html">"packages/core.gbapp/dialogs/<wbr>Welcome<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_dialogs_whoamidialog_.html">"packages/core.gbapp/dialogs/<wbr>Who<wbr>AmIDialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_index_.html">"packages/core.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_models_gbmodel_.html">"packages/core.gbapp/models/GBModel"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbapiservice_.html">"packages/core.gbapp/services/GBAPIService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbconfigservice_.html">"packages/core.gbapp/services/GBConfig<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbconversationalservice_.html">"packages/core.gbapp/services/GBConversational<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbcoreservice_.html">"packages/core.gbapp/services/GBCore<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbdeployer_.html">"packages/core.gbapp/services/GBDeployer"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbimporterservice_.html">"packages/core.gbapp/services/GBImporter<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbminservice_.html">"packages/core.gbapp/services/GBMin<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_gbvmservice_.html">"packages/core.gbapp/services/GBVMService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_services_tscompiler_.html">"packages/core.gbapp/services/TSCompiler"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_core_gbapp_strings_.html">"packages/core.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_dialogs_feedbackdialog_.html">"packages/customer-<wbr>satisfaction.gbapp/dialogs/<wbr>Feedback<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_dialogs_qualitydialog_.html">"packages/customer-<wbr>satisfaction.gbapp/dialogs/<wbr>Quality<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_index_.html">"packages/customer-<wbr>satisfaction.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_models_index_.html">"packages/customer-<wbr>satisfaction.gbapp/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_services_csservice_.html">"packages/customer-<wbr>satisfaction.gbapp/services/CSService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_customer_satisfaction_gbapp_strings_.html">"packages/customer-<wbr>satisfaction.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_dialogs_askdialog_.html">"packages/kb.gbapp/dialogs/<wbr>Ask<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_dialogs_faqdialog_.html">"packages/kb.gbapp/dialogs/<wbr>Faq<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_dialogs_menudialog_.html">"packages/kb.gbapp/dialogs/<wbr>Menu<wbr>Dialog"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_index_.html">"packages/kb.gbapp/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_models_index_.html">"packages/kb.gbapp/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_services_kbservice_.html">"packages/kb.gbapp/services/KBService"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_kb_gbapp_strings_.html">"packages/kb.gbapp/strings"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_security_gblib_index_.html">"packages/security.gblib/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_security_gblib_models_index_.html">"packages/security.gblib/models/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_security_gblib_services_secservice_.html">"packages/security.gblib/services/<wbr>Sec<wbr>Service"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_whatsapp_gblib_index_.html">"packages/whatsapp.gblib/index"</a>
</li>
<li class=" tsd-kind-external-module tsd-is-external">
<a href="modules/_packages_whatsapp_gblib_services_whatsappdirectline_.html">"packages/whatsapp.gblib/services/<wbr>Whatsapp<wbr>Direct<wbr>Line"</a>
</li>
</ul>
</nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul class="before-current">
</ul>
</nav>
</div>
</div>
</div>
<footer class="with-border-bottom">
<div class="container">
<h2>Legend</h2>
<div class="tsd-legend-group">
<ul class="tsd-legend">
<li class="tsd-kind-module"><span class="tsd-kind-icon">Module</span></li>
<li class="tsd-kind-object-literal"><span class="tsd-kind-icon">Object literal</span></li>
<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
<li class="tsd-kind-index-signature"><span class="tsd-kind-icon">Index signature</span></li>
<li class="tsd-kind-type-alias"><span class="tsd-kind-icon">Type alias</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-enum"><span class="tsd-kind-icon">Enumeration</span></li>
<li class="tsd-kind-enum-member"><span class="tsd-kind-icon">Enumeration member</span></li>
<li class="tsd-kind-property tsd-parent-kind-enum"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-enum"><span class="tsd-kind-icon">Method</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
<li class="tsd-kind-interface tsd-has-type-parameter"><span class="tsd-kind-icon">Interface with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-interface"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-interface"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class"><span class="tsd-kind-icon">Accessor</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-class"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static property</span></li>
<li class="tsd-kind-call-signature tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static method</span></li>
</ul>
</div>
</div>
</footer>
<div class="container tsd-generator">
<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="assets/js/main.js"></script>
<script>if (location.protocol == 'file:') document.write('<script src="assets/js/search.js"><' + '/script>');</script>
</body>
</html>

View file

@ -0,0 +1,234 @@
<!doctype html>
<html class="default no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>&quot;src/app&quot; | General Bots Open Core</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="../assets/css/main.css">
</head>
<body>
<header>
<div class="tsd-page-toolbar">
<div class="container">
<div class="table-wrap">
<div class="table-cell" id="tsd-search" data-index="../assets/js/search.js" data-base="..">
<div class="field">
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
<input id="tsd-search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<a href="../index.html" class="title">General Bots Open Core</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
<div class="tsd-filter-group">
<div class="tsd-select" id="tsd-filter-visibility">
<span class="tsd-select-label">All</span>
<ul class="tsd-select-list">
<li data-value="public">Public</li>
<li data-value="protected">Public/Protected</li>
<li data-value="private" class="selected">All</li>
</ul>
</div>
<input type="checkbox" id="tsd-filter-inherited" checked />
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
<input type="checkbox" id="tsd-filter-externals" checked />
<label class="tsd-widget" for="tsd-filter-externals">Externals</label>
<input type="checkbox" id="tsd-filter-only-exported" />
<label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label>
</div>
</div>
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
</div>
</div>
</div>
</div>
<div class="tsd-page-title">
<div class="container">
<ul class="tsd-breadcrumb">
<li>
<a href="../globals.html">Globals</a>
</li>
<li>
<a href="_src_app_.html">&quot;src/app&quot;</a>
</li>
</ul>
<h1>External module &quot;src/app&quot;</h1>
</div>
</div>
</header>
<div class="container container-main">
<div class="row">
<div class="col-8 col-content">
<section class="tsd-panel-group tsd-index-group">
<h2>Index</h2>
<section class="tsd-panel tsd-index-panel">
<div class="tsd-index-content">
<section class="tsd-index-section ">
<h3>Classes</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-class tsd-parent-kind-external-module"><a href="../classes/_src_app_.gbserver.html" class="tsd-kind-icon">GBServer</a></li>
</ul>
</section>
<section class="tsd-index-section tsd-is-not-exported">
<h3>Variables</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_app_.html#apppackages" class="tsd-kind-icon">app<wbr>Packages</a></li>
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_app_.html#bodyparser" class="tsd-kind-icon">body<wbr>Parser</a></li>
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_app_.html#express" class="tsd-kind-icon">express</a></li>
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_app_.html#logger" class="tsd-kind-icon">logger</a></li>
</ul>
</section>
</div>
</section>
</section>
<section class="tsd-panel-group tsd-member-group tsd-is-not-exported">
<h2>Variables</h2>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="apppackages" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> app<wbr>Packages</h3>
<div class="tsd-signature tsd-kind-icon">app<wbr>Packages<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> =&nbsp;new Array&lt;IGBPackage&gt;()</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/app.ts#L55">src/app.ts:55</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="bodyparser" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> body<wbr>Parser</h3>
<div class="tsd-signature tsd-kind-icon">body<wbr>Parser<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol"> =&nbsp;require(&#x27;body-parser&#x27;)</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/app.ts#L42">src/app.ts:42</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="express" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> express</h3>
<div class="tsd-signature tsd-kind-icon">express<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol"> =&nbsp;require(&#x27;express&#x27;)</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/app.ts#L41">src/app.ts:41</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="logger" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> logger</h3>
<div class="tsd-signature tsd-kind-icon">logger<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol"> =&nbsp;require(&#x27;./logger&#x27;)</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/app.ts#L40">src/app.ts:40</a></li>
</ul>
</aside>
</section>
</section>
</div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<nav class="tsd-navigation primary">
<ul>
<li class="globals ">
<a href="../globals.html"><em>Globals</em></a>
</li>
<li class="current tsd-kind-external-module">
<a href="_src_app_.html">"src/app"</a>
</li>
</ul>
</nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul class="before-current">
<li class=" tsd-kind-class tsd-parent-kind-external-module">
<a href="../classes/_src_app_.gbserver.html" class="tsd-kind-icon">GBServer</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_app_.html#apppackages" class="tsd-kind-icon">app<wbr>Packages</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_app_.html#bodyparser" class="tsd-kind-icon">body<wbr>Parser</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_app_.html#express" class="tsd-kind-icon">express</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_app_.html#logger" class="tsd-kind-icon">logger</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<footer class="with-border-bottom">
<div class="container">
<h2>Legend</h2>
<div class="tsd-legend-group">
<ul class="tsd-legend">
<li class="tsd-kind-module"><span class="tsd-kind-icon">Module</span></li>
<li class="tsd-kind-object-literal"><span class="tsd-kind-icon">Object literal</span></li>
<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
<li class="tsd-kind-index-signature"><span class="tsd-kind-icon">Index signature</span></li>
<li class="tsd-kind-type-alias"><span class="tsd-kind-icon">Type alias</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-enum"><span class="tsd-kind-icon">Enumeration</span></li>
<li class="tsd-kind-enum-member"><span class="tsd-kind-icon">Enumeration member</span></li>
<li class="tsd-kind-property tsd-parent-kind-enum"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-enum"><span class="tsd-kind-icon">Method</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
<li class="tsd-kind-interface tsd-has-type-parameter"><span class="tsd-kind-icon">Interface with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-interface"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-interface"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class"><span class="tsd-kind-icon">Accessor</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-class"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static property</span></li>
<li class="tsd-kind-call-signature tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static method</span></li>
</ul>
</div>
</div>
</footer>
<div class="container tsd-generator">
<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="../assets/js/main.js"></script>
<script>if (location.protocol == 'file:') document.write('<script src="../assets/js/search.js"><' + '/script>');</script>
</body>
</html>

View file

@ -0,0 +1,464 @@
<!doctype html>
<html class="default no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>&quot;src/logger&quot; | General Bots Open Core</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="../assets/css/main.css">
</head>
<body>
<header>
<div class="tsd-page-toolbar">
<div class="container">
<div class="table-wrap">
<div class="table-cell" id="tsd-search" data-index="../assets/js/search.js" data-base="..">
<div class="field">
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
<input id="tsd-search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<a href="../index.html" class="title">General Bots Open Core</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
<div class="tsd-filter-group">
<div class="tsd-select" id="tsd-filter-visibility">
<span class="tsd-select-label">All</span>
<ul class="tsd-select-list">
<li data-value="public">Public</li>
<li data-value="protected">Public/Protected</li>
<li data-value="private" class="selected">All</li>
</ul>
</div>
<input type="checkbox" id="tsd-filter-inherited" checked />
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
<input type="checkbox" id="tsd-filter-externals" checked />
<label class="tsd-widget" for="tsd-filter-externals">Externals</label>
<input type="checkbox" id="tsd-filter-only-exported" />
<label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label>
</div>
</div>
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
</div>
</div>
</div>
</div>
<div class="tsd-page-title">
<div class="container">
<ul class="tsd-breadcrumb">
<li>
<a href="../globals.html">Globals</a>
</li>
<li>
<a href="_src_logger_.html">&quot;src/logger&quot;</a>
</li>
</ul>
<h1>External module &quot;src/logger&quot;</h1>
</div>
</div>
</header>
<div class="container container-main">
<div class="row">
<div class="col-8 col-content">
<section class="tsd-panel tsd-comment">
<div class="tsd-comment tsd-typography">
<div class="lead">
<p>\
| ( )_ _ |
| _ _ _ <em>_ _ _ __ <strong>_ _</strong> _ _ | ,</em>)(<em>) <strong>_ _</strong> _ |
| ( &#39;</em><code>\ ( &#39;__)/&#39;_</code> ) /&#39;_ <code>\/&#39; _</code> _ <code>\ /&#39;_</code> )| | | |/&#39;,<strong>)/&#39; _ <code>\ /&#39;_</code>\ |
| | (<em>) )| | ( (</em>| |( (<em>) || ( ) ( ) |( (</em>| || |_ | |\</strong>, | ( ) |( (<em>) ) |
| | ,__/&#39;(</em>) <code>\__,_)</code>__ |(<em>) (</em>) (<em>)`__,</em>)<code>\__)(_)(____/(_) (_)</code>_<strong>/&#39; |
| | | ( )<em>) | |
| (</em>) _</strong>/&#39; |
| |
| General Bots Copyright (c) Pragmatismo.io. All rights reserved. |
| Licensed under the AGPL-3.0. |
| |
| According to our dual licensing model, this program can be used either |
| under the terms of the GNU Affero General Public License, version 3, |
| or under a proprietary license. |
| |
| The texts of the GNU Affero General Public License with an additional |
| permission and of our proprietary license can be found at and |
| in the LICENSE file you have received along with this program. |
| |
| This program is distributed in the hope that it will be useful, |
| but WITHOUT ANY WARRANTY, without even the implied warranty of |
| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| GNU Affero General Public License for more details. |
| |
| &quot;General Bots&quot; is a registered trademark of Pragmatismo.io. |
| The licensing of the program under the AGPLv3 does not imply a |
| trademark license. Therefore any rights, title and interest in |
| our trademarks remain entirely with us. |
| |
\</p>
</div>
</div>
</section>
<section class="tsd-panel-group tsd-index-group">
<h2>Index</h2>
<section class="tsd-panel tsd-index-panel">
<div class="tsd-index-content">
<section class="tsd-index-section tsd-is-not-exported">
<h3>Variables</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_logger_.html#createlogger" class="tsd-kind-icon">create<wbr>Logger</a></li>
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_logger_.html#format" class="tsd-kind-icon">format</a></li>
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_logger_.html#logger" class="tsd-kind-icon">logger</a></li>
<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_logger_.html#transports" class="tsd-kind-icon">transports</a></li>
</ul>
</section>
<section class="tsd-index-section tsd-is-not-exported">
<h3>Object literals</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-object-literal tsd-parent-kind-external-module tsd-is-not-exported"><a href="_src_logger_.html#config" class="tsd-kind-icon">config</a></li>
</ul>
</section>
</div>
</section>
</section>
<section class="tsd-panel-group tsd-member-group tsd-is-not-exported">
<h2>Variables</h2>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="createlogger" class="tsd-anchor"></a>
<h3>create<wbr>Logger</h3>
<div class="tsd-signature tsd-kind-icon">create<wbr>Logger<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L37">src/logger.ts:37</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="format" class="tsd-anchor"></a>
<h3>format</h3>
<div class="tsd-signature tsd-kind-icon">format<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L37">src/logger.ts:37</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="logger" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> logger</h3>
<div class="tsd-signature tsd-kind-icon">logger<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol"> =&nbsp;createLogger({format: format.combine(format.colorize(),format.simple(),format.label({ label: &#x27;GeneralBots&#x27; }),format.timestamp(),format.printf(nfo &#x3D;&gt; {return &#x60;${nfo.timestamp} [${nfo.label}] ${nfo.level}: ${nfo.message}&#x60;;})),levels: config.levels,transports: [new transports.Console()]})</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L62">src/logger.ts:62</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a name="transports" class="tsd-anchor"></a>
<h3>transports</h3>
<div class="tsd-signature tsd-kind-icon">transports<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L37">src/logger.ts:37</a></li>
</ul>
</aside>
</section>
</section>
<section class="tsd-panel-group tsd-member-group tsd-is-not-exported">
<h2>Object literals</h2>
<section class="tsd-panel tsd-member tsd-kind-object-literal tsd-parent-kind-external-module tsd-is-not-exported">
<a name="config" class="tsd-anchor"></a>
<h3><span class="tsd-flag ts-flagConst">Const</span> config</h3>
<div class="tsd-signature tsd-kind-icon">config<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">object</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L39">src/logger.ts:39</a></li>
</ul>
</aside>
<section class="tsd-panel tsd-member tsd-kind-object-literal tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors" class="tsd-anchor"></a>
<h3>colors</h3>
<div class="tsd-signature tsd-kind-icon">colors<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">object</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L50">src/logger.ts:50</a></li>
</ul>
</aside>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.custom" class="tsd-anchor"></a>
<h3>custom</h3>
<div class="tsd-signature tsd-kind-icon">custom<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;yellow&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L58">src/logger.ts:58</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.data" class="tsd-anchor"></a>
<h3>data</h3>
<div class="tsd-signature tsd-kind-icon">data<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;grey&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L54">src/logger.ts:54</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.debug" class="tsd-anchor"></a>
<h3>debug</h3>
<div class="tsd-signature tsd-kind-icon">debug<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;blue&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L52">src/logger.ts:52</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.error" class="tsd-anchor"></a>
<h3>error</h3>
<div class="tsd-signature tsd-kind-icon">error<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;red&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L51">src/logger.ts:51</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.info" class="tsd-anchor"></a>
<h3>info</h3>
<div class="tsd-signature tsd-kind-icon">info<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;green&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L55">src/logger.ts:55</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.silly" class="tsd-anchor"></a>
<h3>silly</h3>
<div class="tsd-signature tsd-kind-icon">silly<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;magenta&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L57">src/logger.ts:57</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.verbose" class="tsd-anchor"></a>
<h3>verbose</h3>
<div class="tsd-signature tsd-kind-icon">verbose<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;cyan&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L56">src/logger.ts:56</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.colors.warn" class="tsd-anchor"></a>
<h3>warn</h3>
<div class="tsd-signature tsd-kind-icon">warn<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> =&nbsp;&quot;yellow&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L53">src/logger.ts:53</a></li>
</ul>
</aside>
</section>
</section>
<section class="tsd-panel tsd-member tsd-kind-object-literal tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels" class="tsd-anchor"></a>
<h3>levels</h3>
<div class="tsd-signature tsd-kind-icon">levels<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">object</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L40">src/logger.ts:40</a></li>
</ul>
</aside>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.custom-1" class="tsd-anchor"></a>
<h3>custom</h3>
<div class="tsd-signature tsd-kind-icon">custom<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;7</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L48">src/logger.ts:48</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.data-1" class="tsd-anchor"></a>
<h3>data</h3>
<div class="tsd-signature tsd-kind-icon">data<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;3</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L44">src/logger.ts:44</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.debug-1" class="tsd-anchor"></a>
<h3>debug</h3>
<div class="tsd-signature tsd-kind-icon">debug<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;1</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L42">src/logger.ts:42</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.error-1" class="tsd-anchor"></a>
<h3>error</h3>
<div class="tsd-signature tsd-kind-icon">error<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;0</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L41">src/logger.ts:41</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.info-1" class="tsd-anchor"></a>
<h3>info</h3>
<div class="tsd-signature tsd-kind-icon">info<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;4</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L45">src/logger.ts:45</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.silly-1" class="tsd-anchor"></a>
<h3>silly</h3>
<div class="tsd-signature tsd-kind-icon">silly<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;6</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L47">src/logger.ts:47</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.verbose-1" class="tsd-anchor"></a>
<h3>verbose</h3>
<div class="tsd-signature tsd-kind-icon">verbose<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;5</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L46">src/logger.ts:46</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal tsd-is-not-exported">
<a name="config.levels.warn-1" class="tsd-anchor"></a>
<h3>warn</h3>
<div class="tsd-signature tsd-kind-icon">warn<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;2</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/rodrigorodriguez/BotServer/blob/8490f5e/src/logger.ts#L43">src/logger.ts:43</a></li>
</ul>
</aside>
</section>
</section>
</section>
</section>
</div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<nav class="tsd-navigation primary">
<ul>
<li class="globals ">
<a href="../globals.html"><em>Globals</em></a>
</li>
<li class="current tsd-kind-external-module">
<a href="_src_logger_.html">"src/logger"</a>
</li>
</ul>
</nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul class="before-current">
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_logger_.html#createlogger" class="tsd-kind-icon">create<wbr>Logger</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_logger_.html#format" class="tsd-kind-icon">format</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_logger_.html#logger" class="tsd-kind-icon">logger</a>
</li>
<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_logger_.html#transports" class="tsd-kind-icon">transports</a>
</li>
<li class=" tsd-kind-object-literal tsd-parent-kind-external-module tsd-is-not-exported">
<a href="_src_logger_.html#config" class="tsd-kind-icon">config</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<footer class="with-border-bottom">
<div class="container">
<h2>Legend</h2>
<div class="tsd-legend-group">
<ul class="tsd-legend">
<li class="tsd-kind-module"><span class="tsd-kind-icon">Module</span></li>
<li class="tsd-kind-object-literal"><span class="tsd-kind-icon">Object literal</span></li>
<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
<li class="tsd-kind-index-signature"><span class="tsd-kind-icon">Index signature</span></li>
<li class="tsd-kind-type-alias"><span class="tsd-kind-icon">Type alias</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-enum"><span class="tsd-kind-icon">Enumeration</span></li>
<li class="tsd-kind-enum-member"><span class="tsd-kind-icon">Enumeration member</span></li>
<li class="tsd-kind-property tsd-parent-kind-enum"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-enum"><span class="tsd-kind-icon">Method</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
<li class="tsd-kind-interface tsd-has-type-parameter"><span class="tsd-kind-icon">Interface with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-interface"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-interface"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class"><span class="tsd-kind-icon">Accessor</span></li>
<li class="tsd-kind-index-signature tsd-parent-kind-class"><span class="tsd-kind-icon">Index signature</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private method</span></li>
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private accessor</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static property</span></li>
<li class="tsd-kind-call-signature tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static method</span></li>
</ul>
</div>
</div>
</footer>
<div class="container tsd-generator">
<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="../assets/js/main.js"></script>
<script>if (location.protocol == 'file:') document.write('<script src="../assets/js/search.js"><' + '/script>');</script>
</body>
</html>

View file

@ -1,99 +0,0 @@
#!/bin/bash
set -e # Exit on error
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PROJECT_ROOT="$SCRIPT_DIR"
OUTPUT_FILE="/tmp/prompt.out"
# Check required commands
command -v cargo >/dev/null 2>&1 || { echo "cargo is required but not installed" >&2; exit 1; }
command -v xclip >/dev/null 2>&1 || { echo "xclip is required but not installed" >&2; exit 1; }
echo "Please, fix this consolidated LLM Context" > "$OUTPUT_FILE"
prompts=(
"./PROMPT.md"
"./Cargo.toml"
)
# Validate files exist
for file in "${prompts[@]}"; do
if [ ! -f "$file" ]; then
echo "Required file not found: $file" >&2
exit 1
fi
done
for file in "${prompts[@]}"; do
cat "$file" >> "$OUTPUT_FILE"
echo "" >> "$OUTPUT_FILE"
done
dirs=(
)
for dir in "${dirs[@]}"; do
if [ -d "$PROJECT_ROOT/src/$dir" ]; then
find "$PROJECT_ROOT/src/$dir" -name "*.rs" | while read -r file; do
if [ -f "$file" ]; then
echo "$file" >> "$OUTPUT_FILE"
cat "$file" >> "$OUTPUT_FILE"
echo "" >> "$OUTPUT_FILE"
fi
done
fi
done
# Also append the specific files you mentioned
echo "$PROJECT_ROOT/src/main.rs" >> "$OUTPUT_FILE"
cat "$PROJECT_ROOT/src/main.rs" >> "$OUTPUT_FILE"
# Files with config import errors
error_files=(
"src/main.rs"
"src/basic/keywords/kb_statistics.rs"
"src/core/bootstrap/mod.rs"
"src/core/kb/kb_indexer.rs"
"src/core/kb/website_crawler_service.rs"
"src/core/shared/utils.rs"
"src/multimodal/mod.rs"
"src/console/status_panel.rs"
"src/drive/drive_monitor/mod.rs"
"src/email/mod.rs"
"src/llm/cache.rs"
"src/llm/local.rs"
"src/llm/episodic_memory.rs"
"src/basic/keywords/create_site.rs"
"src/basic/keywords/save_from_unstructured.rs"
)
for file in "${error_files[@]}"; do
echo "$PROJECT_ROOT/$file" >> "$OUTPUT_FILE"
cat "$PROJECT_ROOT/$file" >> "$OUTPUT_FILE"
echo "" >> "$OUTPUT_FILE"
echo "---" >> "$OUTPUT_FILE"
done
echo "" >> "$OUTPUT_FILE"
echo "Compiling..."
cargo build --message-format=short 2>&1 | grep -E 'error' >> "$OUTPUT_FILE"
# Calculate and display token count (approximation: words * 1.3)
WORD_COUNT=$(wc -w < "$OUTPUT_FILE") || { echo "Error counting words" >&2; exit 1; }
TOKEN_COUNT=$(echo "$WORD_COUNT * 1.3 / 1" | bc) || { echo "Error calculating tokens" >&2; exit 1; }
FILE_SIZE=$(wc -c < "$OUTPUT_FILE") || { echo "Error getting file size" >&2; exit 1; }
echo "" >> "$OUTPUT_FILE"
echo "Approximate token count: $TOKEN_COUNT"
echo "Context size: $FILE_SIZE bytes"
if ! cat "$OUTPUT_FILE" | xclip -selection clipboard; then
echo "Error copying to clipboard" >&2
exit 1
fi
echo "Content copied to clipboard (xclip)"
rm -f "$OUTPUT_FILE"

2
gbot.cmd Normal file
View file

@ -0,0 +1,2 @@
@echo off
node dist/src/app.js

File diff suppressed because one or more lines are too long

View file

@ -1 +0,0 @@
{}

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

11
greenkeeper.json Normal file
View file

@ -0,0 +1,11 @@
{
"groups": {
"default": {
"packages": [
"package.json",
"packages/default.gbtheme/package.json",
"packages/default.gbui/package.json"
]
}
}
}

BIN
logo.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 7.6 KiB

View file

@ -1,483 +0,0 @@
DROP TABLE public.usage_analytics;
DROP TABLE public.message_history;
DROP TABLE public.context_injections;
DROP TABLE public.whatsapp_numbers;
DROP TABLE public.user_sessions;
DROP TABLE public.bot_channels;
DROP TABLE public.users;
DROP TABLE public.tools;
DROP TABLE public.system_automations;
DROP TABLE public.organizations;
DROP TABLE public.clicks;
DROP TABLE public.bots;
DROP INDEX idx_bot_memories_key;
DROP INDEX idx_bot_memories_bot_id;
DROP TABLE bot_memories;
-- Drop triggers
DROP TRIGGER IF EXISTS update_basic_tools_updated_at ON basic_tools;
DROP TRIGGER IF EXISTS update_kb_collections_updated_at ON kb_collections;
DROP TRIGGER IF EXISTS update_kb_documents_updated_at ON kb_documents;
-- Drop function
DROP FUNCTION IF EXISTS update_updated_at_column;
-- Drop indexes
DROP INDEX IF EXISTS idx_basic_tools_active;
DROP INDEX IF EXISTS idx_basic_tools_name;
DROP INDEX IF EXISTS idx_basic_tools_bot_id;
DROP INDEX IF EXISTS idx_kb_collections_name;
DROP INDEX IF EXISTS idx_kb_collections_bot_id;
DROP INDEX IF EXISTS idx_kb_documents_indexed_at;
DROP INDEX IF EXISTS idx_kb_documents_hash;
DROP INDEX IF EXISTS idx_kb_documents_collection;
DROP INDEX IF EXISTS idx_kb_documents_bot_id;
-- Drop tables
DROP TABLE IF EXISTS basic_tools;
DROP TABLE IF EXISTS kb_collections;
DROP TABLE IF EXISTS kb_documents;
-- Drop indexes
DROP INDEX IF EXISTS idx_session_tool_name;
DROP INDEX IF EXISTS idx_session_tool_session;
DROP INDEX IF EXISTS idx_user_kb_website;
DROP INDEX IF EXISTS idx_user_kb_name;
DROP INDEX IF EXISTS idx_user_kb_bot_id;
DROP INDEX IF EXISTS idx_user_kb_user_id;
-- Drop tables
DROP TABLE IF EXISTS session_tool_associations;
DROP TABLE IF EXISTS user_kb_associations;
-- Drop indexes first
DROP INDEX IF EXISTS idx_gbot_sync_bot;
DROP INDEX IF EXISTS idx_component_logs_created;
DROP INDEX IF EXISTS idx_component_logs_level;
DROP INDEX IF EXISTS idx_component_logs_component;
DROP INDEX IF EXISTS idx_component_status;
DROP INDEX IF EXISTS idx_component_name;
DROP INDEX IF EXISTS idx_connection_config_active;
DROP INDEX IF EXISTS idx_connection_config_name;
DROP INDEX IF EXISTS idx_connection_config_bot;
DROP INDEX IF EXISTS idx_model_config_default;
DROP INDEX IF EXISTS idx_model_config_active;
DROP INDEX IF EXISTS idx_model_config_type;
DROP INDEX IF EXISTS idx_bot_config_key;
DROP INDEX IF EXISTS idx_bot_config_bot;
DROP INDEX IF EXISTS idx_tenant_config_key;
DROP INDEX IF EXISTS idx_tenant_config_tenant;
DROP INDEX IF EXISTS idx_server_config_type;
DROP INDEX IF EXISTS idx_server_config_key;
-- Drop tables
DROP TABLE IF EXISTS gbot_config_sync;
DROP TABLE IF EXISTS component_logs;
DROP TABLE IF EXISTS component_installations;
DROP TABLE IF EXISTS connection_configurations;
DROP TABLE IF EXISTS model_configurations;
DROP TABLE IF EXISTS bot_configuration;
DROP TABLE IF EXISTS tenant_configuration;
DROP TABLE IF EXISTS server_configuration;
-- Remove added columns if they exist
DO $$
BEGIN
IF EXISTS (
SELECT 1 FROM information_schema.columns
WHERE table_name = 'user_sessions' AND column_name = 'tenant_id'
) THEN
ALTER TABLE user_sessions DROP COLUMN tenant_id;
END IF;
IF EXISTS (
SELECT 1 FROM information_schema.columns
WHERE table_name = 'bots' AND column_name = 'tenant_id'
) THEN
ALTER TABLE bots DROP COLUMN tenant_id;
END IF;
END $$;
-- Drop tenant indexes if they exist
DROP INDEX IF EXISTS idx_user_sessions_tenant;
DROP INDEX IF EXISTS idx_bots_tenant;
-- Remove default tenant
DELETE FROM tenants WHERE slug = 'default';
-- Revert clicks table changes
CREATE TABLE IF NOT EXISTS public.old_clicks (
campaign_id text NOT NULL,
email text NOT NULL,
updated_at timestamptz DEFAULT now() NULL,
CONSTRAINT clicks_campaign_id_email_key UNIQUE (campaign_id, email)
);
INSERT INTO public.old_clicks (campaign_id, email, updated_at)
SELECT campaign_id, email, updated_at FROM public.clicks;
DROP TABLE public.clicks;
ALTER TABLE public.old_clicks RENAME TO clicks;
-- Remove system_automations constraints and indexes
DROP INDEX IF EXISTS idx_system_automations_bot_kind_param;
ALTER TABLE public.system_automations DROP CONSTRAINT IF EXISTS system_automations_bot_kind_param_unique;
DROP INDEX IF EXISTS idx_system_automations_bot_id;
ALTER TABLE public.system_automations DROP COLUMN IF EXISTS bot_id;
DROP INDEX IF EXISTS idx_system_automations_name;
ALTER TABLE public.system_automations DROP COLUMN IF EXISTS name;
-- Remove bot_configuration constraint
ALTER TABLE bot_configuration DROP CONSTRAINT IF EXISTS bot_configuration_config_key_unique;
-- Drop login tokens table
DROP TABLE IF EXISTS public.user_login_tokens;
-- Drop user preferences table
DROP TABLE IF EXISTS public.user_preferences;
-- Remove session enhancement
ALTER TABLE public.user_sessions
DROP CONSTRAINT IF EXISTS user_sessions_email_account_id_fkey,
DROP COLUMN IF EXISTS active_email_account_id;
-- Drop email folders table
DROP TABLE IF EXISTS public.email_folders;
-- Drop email drafts table
DROP TABLE IF EXISTS public.email_drafts;
-- Drop user email accounts table
DROP TABLE IF EXISTS public.user_email_accounts;
-- Drop triggers
DROP TRIGGER IF EXISTS update_directory_users_updated_at ON public.directory_users;
DROP TRIGGER IF EXISTS update_oauth_applications_updated_at ON public.oauth_applications;
-- Drop function if no other triggers use it
DROP FUNCTION IF EXISTS update_updated_at_column() CASCADE;
-- Drop tables in reverse order of dependencies
DROP TABLE IF EXISTS public.bot_access CASCADE;
DROP TABLE IF EXISTS public.oauth_applications CASCADE;
DROP TABLE IF EXISTS public.directory_users CASCADE;
-- Drop indexes
DROP INDEX IF EXISTS idx_bots_org_id;
-- Remove columns from bots table
ALTER TABLE public.bots
DROP CONSTRAINT IF EXISTS bots_org_id_fkey,
DROP COLUMN IF EXISTS org_id,
DROP COLUMN IF EXISTS is_default;
-- Note: We don't delete the default organization or bot data as they may have other relationships
-- The application should handle orphaned data appropriately
-- Drop session_website_associations table and related indexes
DROP TABLE IF EXISTS session_website_associations;
-- Drop website_crawls table and related objects
DROP TRIGGER IF EXISTS website_crawls_updated_at_trigger ON website_crawls;
DROP FUNCTION IF EXISTS update_website_crawls_updated_at();
DROP TABLE IF EXISTS website_crawls;
-- Rollback Migration: 6.1.0 Enterprise Features
-- WARNING: This will delete all enterprise feature data!
-- NOTE: TABLES AND INDEXES ONLY - No views, triggers, or functions per project standards
-- Includes rollback for: config ID fixes, connected accounts, bot hierarchy, monitors
-- ============================================================================
-- ROLLBACK: Bot Hierarchy and Monitors (from 6.1.3)
-- ============================================================================
-- Drop comments first
COMMENT ON TABLE public.user_organizations IS NULL;
COMMENT ON TABLE public.email_received_events IS NULL;
COMMENT ON TABLE public.folder_change_events IS NULL;
COMMENT ON TABLE public.folder_monitors IS NULL;
COMMENT ON TABLE public.email_monitors IS NULL;
COMMENT ON COLUMN public.bots.inherit_parent_config IS NULL;
COMMENT ON COLUMN public.bots.enabled_tabs_json IS NULL;
COMMENT ON COLUMN public.bots.parent_bot_id IS NULL;
COMMENT ON TABLE public.system_automations IS NULL;
-- Drop user organizations table
DROP INDEX IF EXISTS idx_user_orgs_default;
DROP INDEX IF EXISTS idx_user_orgs_org;
DROP INDEX IF EXISTS idx_user_orgs_user;
DROP TABLE IF EXISTS public.user_organizations;
-- Drop email received events table
DROP INDEX IF EXISTS idx_email_events_received;
DROP INDEX IF EXISTS idx_email_events_processed;
DROP INDEX IF EXISTS idx_email_events_monitor;
DROP TABLE IF EXISTS public.email_received_events;
-- Drop folder change events table
DROP INDEX IF EXISTS idx_folder_events_created;
DROP INDEX IF EXISTS idx_folder_events_processed;
DROP INDEX IF EXISTS idx_folder_events_monitor;
DROP TABLE IF EXISTS public.folder_change_events;
-- Drop folder monitors table
DROP INDEX IF EXISTS idx_folder_monitors_account_email;
DROP INDEX IF EXISTS idx_folder_monitors_active;
DROP INDEX IF EXISTS idx_folder_monitors_provider;
DROP INDEX IF EXISTS idx_folder_monitors_bot_id;
DROP TABLE IF EXISTS public.folder_monitors;
-- Drop email monitors table
DROP INDEX IF EXISTS idx_email_monitors_active;
DROP INDEX IF EXISTS idx_email_monitors_email;
DROP INDEX IF EXISTS idx_email_monitors_bot_id;
DROP TABLE IF EXISTS public.email_monitors;
-- Remove bot hierarchy columns
DROP INDEX IF EXISTS idx_bots_parent_bot_id;
ALTER TABLE public.bots DROP COLUMN IF EXISTS inherit_parent_config;
ALTER TABLE public.bots DROP COLUMN IF EXISTS enabled_tabs_json;
ALTER TABLE public.bots DROP COLUMN IF EXISTS parent_bot_id;
-- ============================================================================
-- ROLLBACK: Connected Accounts (from 6.1.2)
-- ============================================================================
DROP INDEX IF EXISTS idx_account_sync_items_unique;
DROP INDEX IF EXISTS idx_account_sync_items_embedding;
DROP INDEX IF EXISTS idx_account_sync_items_date;
DROP INDEX IF EXISTS idx_account_sync_items_type;
DROP INDEX IF EXISTS idx_account_sync_items_account;
DROP TABLE IF EXISTS account_sync_items;
DROP INDEX IF EXISTS idx_session_account_assoc_unique;
DROP INDEX IF EXISTS idx_session_account_assoc_active;
DROP INDEX IF EXISTS idx_session_account_assoc_account;
DROP INDEX IF EXISTS idx_session_account_assoc_session;
DROP TABLE IF EXISTS session_account_associations;
DROP INDEX IF EXISTS idx_connected_accounts_bot_email;
DROP INDEX IF EXISTS idx_connected_accounts_status;
DROP INDEX IF EXISTS idx_connected_accounts_provider;
DROP INDEX IF EXISTS idx_connected_accounts_email;
DROP INDEX IF EXISTS idx_connected_accounts_user_id;
DROP INDEX IF EXISTS idx_connected_accounts_bot_id;
DROP TABLE IF EXISTS connected_accounts;
-- ============================================================================
-- ROLLBACK: Config ID Type Fixes (from 6.1.1)
-- Revert UUID columns back to TEXT
-- ============================================================================
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'bot_configuration'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE bot_configuration
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'server_configuration'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE server_configuration
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'tenant_configuration'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE tenant_configuration
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'model_configurations'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE model_configurations
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'connection_configurations'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE connection_configurations
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'component_installations'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE component_installations
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'component_logs'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE component_logs
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
DO $$
BEGIN
IF EXISTS (SELECT 1 FROM information_schema.columns
WHERE table_name = 'gbot_config_sync'
AND column_name = 'id'
AND data_type = 'uuid') THEN
ALTER TABLE gbot_config_sync
ALTER COLUMN id TYPE TEXT USING id::text;
END IF;
END $$;
-- ============================================================================
-- FEATURE TABLES MOVED TO DEDICATED MIGRATIONS
-- ============================================================================
-- Drop triggers and functions
DROP TRIGGER IF EXISTS external_connections_updated_at_trigger ON external_connections;
DROP FUNCTION IF EXISTS update_external_connections_updated_at();
DROP TRIGGER IF EXISTS dynamic_table_definitions_updated_at_trigger ON dynamic_table_definitions;
DROP FUNCTION IF EXISTS update_dynamic_table_definitions_updated_at();
-- Drop indexes
DROP INDEX IF EXISTS idx_external_connections_name;
DROP INDEX IF EXISTS idx_external_connections_bot_id;
DROP INDEX IF EXISTS idx_dynamic_table_fields_name;
DROP INDEX IF EXISTS idx_dynamic_table_fields_table_id;
DROP INDEX IF EXISTS idx_dynamic_table_definitions_connection;
DROP INDEX IF EXISTS idx_dynamic_table_definitions_name;
DROP INDEX IF EXISTS idx_dynamic_table_definitions_bot_id;
-- Drop tables (order matters due to foreign keys)
DROP TABLE IF EXISTS external_connections;
DROP TABLE IF EXISTS dynamic_table_fields;
DROP TABLE IF EXISTS dynamic_table_definitions;
-- Rollback Migration: 6.1.1 AutoTask System
-- Description: Drop tables for the AutoTask system
-- Drop indexes first (automatically dropped with tables, but explicit for clarity)
-- Drop designer_pending_changes
DROP INDEX IF EXISTS idx_designer_pending_changes_expires_at;
DROP INDEX IF EXISTS idx_designer_pending_changes_bot_id;
DROP TABLE IF EXISTS designer_pending_changes;
-- Drop designer_changes
DROP INDEX IF EXISTS idx_designer_changes_created_at;
DROP INDEX IF EXISTS idx_designer_changes_bot_id;
DROP TABLE IF EXISTS designer_changes;
-- Drop intent_classifications
DROP INDEX IF EXISTS idx_intent_classifications_created_at;
DROP INDEX IF EXISTS idx_intent_classifications_intent_type;
DROP INDEX IF EXISTS idx_intent_classifications_bot_id;
DROP TABLE IF EXISTS intent_classifications;
-- Drop generated_apps
DROP INDEX IF EXISTS idx_generated_apps_is_active;
DROP INDEX IF EXISTS idx_generated_apps_name;
DROP INDEX IF EXISTS idx_generated_apps_bot_id;
DROP TABLE IF EXISTS generated_apps;
-- Drop safety_audit_log
DROP INDEX IF EXISTS idx_safety_audit_log_created_at;
DROP INDEX IF EXISTS idx_safety_audit_log_outcome;
DROP INDEX IF EXISTS idx_safety_audit_log_task_id;
DROP INDEX IF EXISTS idx_safety_audit_log_bot_id;
DROP TABLE IF EXISTS safety_audit_log;
-- Drop task_decisions
DROP INDEX IF EXISTS idx_task_decisions_status;
DROP INDEX IF EXISTS idx_task_decisions_task_id;
DROP INDEX IF EXISTS idx_task_decisions_bot_id;
DROP TABLE IF EXISTS task_decisions;
-- Drop task_approvals
DROP INDEX IF EXISTS idx_task_approvals_expires_at;
DROP INDEX IF EXISTS idx_task_approvals_status;
DROP INDEX IF EXISTS idx_task_approvals_task_id;
DROP INDEX IF EXISTS idx_task_approvals_bot_id;
DROP TABLE IF EXISTS task_approvals;
-- Drop execution_plans
DROP INDEX IF EXISTS idx_execution_plans_intent_type;
DROP INDEX IF EXISTS idx_execution_plans_status;
DROP INDEX IF EXISTS idx_execution_plans_task_id;
DROP INDEX IF EXISTS idx_execution_plans_bot_id;
DROP TABLE IF EXISTS execution_plans;
-- Drop auto_tasks
DROP INDEX IF EXISTS idx_auto_tasks_created_at;
DROP INDEX IF EXISTS idx_auto_tasks_priority;
DROP INDEX IF EXISTS idx_auto_tasks_status;
DROP INDEX IF EXISTS idx_auto_tasks_session_id;
DROP INDEX IF EXISTS idx_auto_tasks_bot_id;
DROP TABLE IF EXISTS auto_tasks;
-- Drop pending_info
DROP INDEX IF EXISTS idx_pending_info_is_filled;
DROP INDEX IF EXISTS idx_pending_info_config_key;
DROP INDEX IF EXISTS idx_pending_info_bot_id;
DROP TABLE IF EXISTS pending_info;
-- Rollback: Remove role-based access control columns from dynamic tables
-- Migration: 6.1.2_table_role_access
-- Remove columns from dynamic_table_definitions
ALTER TABLE dynamic_table_definitions
DROP COLUMN IF EXISTS read_roles,
DROP COLUMN IF EXISTS write_roles;
-- Remove columns from dynamic_table_fields
ALTER TABLE dynamic_table_fields
DROP COLUMN IF EXISTS read_roles,
DROP COLUMN IF EXISTS write_roles;
-- Rollback Migration: Knowledge Base Sources
-- Drop triggers first
DROP TRIGGER IF EXISTS update_knowledge_sources_updated_at ON knowledge_sources;
-- Drop indexes
DROP INDEX IF EXISTS idx_knowledge_sources_bot_id;
DROP INDEX IF EXISTS idx_knowledge_sources_status;
DROP INDEX IF EXISTS idx_knowledge_sources_collection;
DROP INDEX IF EXISTS idx_knowledge_sources_content_hash;
DROP INDEX IF EXISTS idx_knowledge_sources_created_at;
DROP INDEX IF EXISTS idx_knowledge_chunks_source_id;
DROP INDEX IF EXISTS idx_knowledge_chunks_chunk_index;
DROP INDEX IF EXISTS idx_knowledge_chunks_content_fts;
DROP INDEX IF EXISTS idx_knowledge_chunks_embedding;
DROP INDEX IF EXISTS idx_research_search_history_bot_id;
DROP INDEX IF EXISTS idx_research_search_history_user_id;
DROP INDEX IF EXISTS idx_research_search_history_created_at;
-- Drop tables (order matters due to foreign key constraints)
DROP TABLE IF EXISTS research_search_history;
DROP TABLE IF EXISTS knowledge_chunks;
DROP TABLE IF EXISTS knowledge_sources;

File diff suppressed because it is too large Load diff

View file

@ -1,5 +0,0 @@
DROP INDEX IF EXISTS idx_bots_tenant_id;
DROP INDEX IF EXISTS idx_bots_database_name;
ALTER TABLE bots DROP COLUMN IF EXISTS tenant_id;
ALTER TABLE bots DROP COLUMN IF EXISTS database_name;

View file

@ -1,8 +0,0 @@
ALTER TABLE bots ADD COLUMN IF NOT EXISTS database_name VARCHAR(255) NULL;
ALTER TABLE bots ADD COLUMN IF NOT EXISTS tenant_id UUID NULL;
CREATE INDEX IF NOT EXISTS idx_bots_database_name ON bots(database_name);
CREATE INDEX IF NOT EXISTS idx_bots_tenant_id ON bots(tenant_id);
COMMENT ON COLUMN bots.database_name IS 'Name of the PostgreSQL database for this bot (bot_{name})';
COMMENT ON COLUMN bots.tenant_id IS 'Tenant/organization ID for multi-tenant isolation';

View file

@ -1,36 +0,0 @@
DROP INDEX IF EXISTS idx_product_variants_sku;
DROP INDEX IF EXISTS idx_product_variants_product;
DROP INDEX IF EXISTS idx_inventory_movements_created;
DROP INDEX IF EXISTS idx_inventory_movements_product;
DROP INDEX IF EXISTS idx_inventory_movements_org_bot;
DROP INDEX IF EXISTS idx_price_list_items_service;
DROP INDEX IF EXISTS idx_price_list_items_product;
DROP INDEX IF EXISTS idx_price_list_items_list;
DROP INDEX IF EXISTS idx_price_lists_default;
DROP INDEX IF EXISTS idx_price_lists_active;
DROP INDEX IF EXISTS idx_price_lists_org_bot;
DROP INDEX IF EXISTS idx_product_categories_slug;
DROP INDEX IF EXISTS idx_product_categories_parent;
DROP INDEX IF EXISTS idx_product_categories_org_bot;
DROP INDEX IF EXISTS idx_services_active;
DROP INDEX IF EXISTS idx_services_category;
DROP INDEX IF EXISTS idx_services_org_bot;
DROP INDEX IF EXISTS idx_products_org_sku;
DROP INDEX IF EXISTS idx_products_sku;
DROP INDEX IF EXISTS idx_products_active;
DROP INDEX IF EXISTS idx_products_category;
DROP INDEX IF EXISTS idx_products_org_bot;
DROP TABLE IF EXISTS product_variants;
DROP TABLE IF EXISTS inventory_movements;
DROP TABLE IF EXISTS price_list_items;
DROP TABLE IF EXISTS price_lists;
DROP TABLE IF EXISTS product_categories;
DROP TABLE IF EXISTS services;
DROP TABLE IF EXISTS products;

View file

@ -1,139 +0,0 @@
CREATE TABLE products (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
sku VARCHAR(100),
name VARCHAR(255) NOT NULL,
description TEXT,
category VARCHAR(100),
product_type VARCHAR(50) NOT NULL DEFAULT 'physical',
price DECIMAL(15,2) NOT NULL DEFAULT 0,
cost DECIMAL(15,2),
currency VARCHAR(3) NOT NULL DEFAULT 'USD',
tax_rate DECIMAL(5,2) NOT NULL DEFAULT 0,
unit VARCHAR(50) NOT NULL DEFAULT 'unit',
stock_quantity INTEGER NOT NULL DEFAULT 0,
low_stock_threshold INTEGER NOT NULL DEFAULT 10,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
images JSONB NOT NULL DEFAULT '[]',
attributes JSONB NOT NULL DEFAULT '{}',
weight DECIMAL(10,2),
dimensions JSONB,
barcode VARCHAR(100),
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE services (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
category VARCHAR(100),
service_type VARCHAR(50) NOT NULL DEFAULT 'hourly',
hourly_rate DECIMAL(15,2),
fixed_price DECIMAL(15,2),
currency VARCHAR(3) NOT NULL DEFAULT 'USD',
duration_minutes INTEGER,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
attributes JSONB NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE product_categories (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
parent_id UUID REFERENCES product_categories(id) ON DELETE SET NULL,
slug VARCHAR(255),
image_url TEXT,
sort_order INTEGER NOT NULL DEFAULT 0,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE price_lists (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
currency VARCHAR(3) NOT NULL DEFAULT 'USD',
is_default BOOLEAN NOT NULL DEFAULT FALSE,
valid_from DATE,
valid_until DATE,
customer_group VARCHAR(100),
discount_percent DECIMAL(5,2) NOT NULL DEFAULT 0,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE price_list_items (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
price_list_id UUID NOT NULL REFERENCES price_lists(id) ON DELETE CASCADE,
product_id UUID REFERENCES products(id) ON DELETE CASCADE,
service_id UUID REFERENCES services(id) ON DELETE CASCADE,
price DECIMAL(15,2) NOT NULL,
min_quantity INTEGER NOT NULL DEFAULT 1,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE inventory_movements (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
product_id UUID NOT NULL REFERENCES products(id) ON DELETE CASCADE,
movement_type VARCHAR(50) NOT NULL,
quantity INTEGER NOT NULL,
reference_type VARCHAR(50),
reference_id UUID,
notes TEXT,
created_by UUID,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE product_variants (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
product_id UUID NOT NULL REFERENCES products(id) ON DELETE CASCADE,
sku VARCHAR(100),
name VARCHAR(255) NOT NULL,
price_adjustment DECIMAL(15,2) NOT NULL DEFAULT 0,
stock_quantity INTEGER NOT NULL DEFAULT 0,
attributes JSONB NOT NULL DEFAULT '{}',
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE INDEX idx_products_org_bot ON products(org_id, bot_id);
CREATE INDEX idx_products_category ON products(category);
CREATE INDEX idx_products_active ON products(is_active);
CREATE INDEX idx_products_sku ON products(sku);
CREATE UNIQUE INDEX idx_products_org_sku ON products(org_id, sku) WHERE sku IS NOT NULL;
CREATE INDEX idx_services_org_bot ON services(org_id, bot_id);
CREATE INDEX idx_services_category ON services(category);
CREATE INDEX idx_services_active ON services(is_active);
CREATE INDEX idx_product_categories_org_bot ON product_categories(org_id, bot_id);
CREATE INDEX idx_product_categories_parent ON product_categories(parent_id);
CREATE INDEX idx_product_categories_slug ON product_categories(slug);
CREATE INDEX idx_price_lists_org_bot ON price_lists(org_id, bot_id);
CREATE INDEX idx_price_lists_active ON price_lists(is_active);
CREATE INDEX idx_price_lists_default ON price_lists(is_default);
CREATE INDEX idx_price_list_items_list ON price_list_items(price_list_id);
CREATE INDEX idx_price_list_items_product ON price_list_items(product_id);
CREATE INDEX idx_price_list_items_service ON price_list_items(service_id);
CREATE INDEX idx_inventory_movements_org_bot ON inventory_movements(org_id, bot_id);
CREATE INDEX idx_inventory_movements_product ON inventory_movements(product_id);
CREATE INDEX idx_inventory_movements_created ON inventory_movements(created_at DESC);
CREATE INDEX idx_product_variants_product ON product_variants(product_id);
CREATE INDEX idx_product_variants_sku ON product_variants(sku);

View file

@ -1,43 +0,0 @@
DROP INDEX IF EXISTS idx_people_time_off_status;
DROP INDEX IF EXISTS idx_people_time_off_dates;
DROP INDEX IF EXISTS idx_people_time_off_person;
DROP INDEX IF EXISTS idx_people_time_off_org_bot;
DROP INDEX IF EXISTS idx_people_person_skills_skill;
DROP INDEX IF EXISTS idx_people_person_skills_person;
DROP INDEX IF EXISTS idx_people_skills_category;
DROP INDEX IF EXISTS idx_people_skills_org_bot;
DROP INDEX IF EXISTS idx_people_departments_org_code;
DROP INDEX IF EXISTS idx_people_departments_head;
DROP INDEX IF EXISTS idx_people_departments_parent;
DROP INDEX IF EXISTS idx_people_departments_org_bot;
DROP INDEX IF EXISTS idx_people_org_chart_reports_to;
DROP INDEX IF EXISTS idx_people_org_chart_person;
DROP INDEX IF EXISTS idx_people_org_chart_org;
DROP INDEX IF EXISTS idx_people_team_members_person;
DROP INDEX IF EXISTS idx_people_team_members_team;
DROP INDEX IF EXISTS idx_people_teams_leader;
DROP INDEX IF EXISTS idx_people_teams_parent;
DROP INDEX IF EXISTS idx_people_teams_org_bot;
DROP INDEX IF EXISTS idx_people_org_email;
DROP INDEX IF EXISTS idx_people_user;
DROP INDEX IF EXISTS idx_people_active;
DROP INDEX IF EXISTS idx_people_manager;
DROP INDEX IF EXISTS idx_people_department;
DROP INDEX IF EXISTS idx_people_email;
DROP INDEX IF EXISTS idx_people_org_bot;
DROP TABLE IF EXISTS people_time_off;
DROP TABLE IF EXISTS people_person_skills;
DROP TABLE IF EXISTS people_skills;
DROP TABLE IF EXISTS people_departments;
DROP TABLE IF EXISTS people_org_chart;
DROP TABLE IF EXISTS people_team_members;
DROP TABLE IF EXISTS people_teams;
DROP TABLE IF EXISTS people;

View file

@ -1,160 +0,0 @@
CREATE TABLE people (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
user_id UUID,
first_name VARCHAR(255) NOT NULL,
last_name VARCHAR(255),
email VARCHAR(255),
phone VARCHAR(50),
mobile VARCHAR(50),
job_title VARCHAR(255),
department VARCHAR(255),
manager_id UUID REFERENCES people(id) ON DELETE SET NULL,
office_location VARCHAR(255),
hire_date DATE,
birthday DATE,
avatar_url TEXT,
bio TEXT,
skills TEXT[] NOT NULL DEFAULT '{}',
social_links JSONB NOT NULL DEFAULT '{}',
custom_fields JSONB NOT NULL DEFAULT '{}',
timezone VARCHAR(50),
locale VARCHAR(10),
is_active BOOLEAN NOT NULL DEFAULT TRUE,
last_seen_at TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE people_teams (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
leader_id UUID REFERENCES people(id) ON DELETE SET NULL,
parent_team_id UUID REFERENCES people_teams(id) ON DELETE SET NULL,
color VARCHAR(20),
icon VARCHAR(50),
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE people_team_members (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
team_id UUID NOT NULL REFERENCES people_teams(id) ON DELETE CASCADE,
person_id UUID NOT NULL REFERENCES people(id) ON DELETE CASCADE,
role VARCHAR(100),
is_primary BOOLEAN NOT NULL DEFAULT FALSE,
joined_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(team_id, person_id)
);
CREATE TABLE people_org_chart (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
person_id UUID NOT NULL REFERENCES people(id) ON DELETE CASCADE,
reports_to_id UUID REFERENCES people(id) ON DELETE SET NULL,
position_title VARCHAR(255),
position_level INTEGER NOT NULL DEFAULT 0,
position_order INTEGER NOT NULL DEFAULT 0,
effective_from DATE,
effective_until DATE,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(org_id, person_id, effective_from)
);
CREATE TABLE people_departments (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
code VARCHAR(50),
parent_id UUID REFERENCES people_departments(id) ON DELETE SET NULL,
head_id UUID REFERENCES people(id) ON DELETE SET NULL,
cost_center VARCHAR(50),
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE people_skills (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
category VARCHAR(100),
description TEXT,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE people_person_skills (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
person_id UUID NOT NULL REFERENCES people(id) ON DELETE CASCADE,
skill_id UUID NOT NULL REFERENCES people_skills(id) ON DELETE CASCADE,
proficiency_level INTEGER NOT NULL DEFAULT 1,
years_experience DECIMAL(4,1),
verified_by UUID REFERENCES people(id) ON DELETE SET NULL,
verified_at TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(person_id, skill_id)
);
CREATE TABLE people_time_off (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
person_id UUID NOT NULL REFERENCES people(id) ON DELETE CASCADE,
time_off_type VARCHAR(50) NOT NULL,
status VARCHAR(50) NOT NULL DEFAULT 'pending',
start_date DATE NOT NULL,
end_date DATE NOT NULL,
hours_requested DECIMAL(5,1),
reason TEXT,
approved_by UUID REFERENCES people(id) ON DELETE SET NULL,
approved_at TIMESTAMPTZ,
notes TEXT,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE INDEX idx_people_org_bot ON people(org_id, bot_id);
CREATE INDEX idx_people_email ON people(email);
CREATE INDEX idx_people_department ON people(department);
CREATE INDEX idx_people_manager ON people(manager_id);
CREATE INDEX idx_people_active ON people(is_active);
CREATE INDEX idx_people_user ON people(user_id);
CREATE UNIQUE INDEX idx_people_org_email ON people(org_id, email) WHERE email IS NOT NULL;
CREATE INDEX idx_people_teams_org_bot ON people_teams(org_id, bot_id);
CREATE INDEX idx_people_teams_parent ON people_teams(parent_team_id);
CREATE INDEX idx_people_teams_leader ON people_teams(leader_id);
CREATE INDEX idx_people_team_members_team ON people_team_members(team_id);
CREATE INDEX idx_people_team_members_person ON people_team_members(person_id);
CREATE INDEX idx_people_org_chart_org ON people_org_chart(org_id, bot_id);
CREATE INDEX idx_people_org_chart_person ON people_org_chart(person_id);
CREATE INDEX idx_people_org_chart_reports_to ON people_org_chart(reports_to_id);
CREATE INDEX idx_people_departments_org_bot ON people_departments(org_id, bot_id);
CREATE INDEX idx_people_departments_parent ON people_departments(parent_id);
CREATE INDEX idx_people_departments_head ON people_departments(head_id);
CREATE UNIQUE INDEX idx_people_departments_org_code ON people_departments(org_id, code) WHERE code IS NOT NULL;
CREATE INDEX idx_people_skills_org_bot ON people_skills(org_id, bot_id);
CREATE INDEX idx_people_skills_category ON people_skills(category);
CREATE INDEX idx_people_person_skills_person ON people_person_skills(person_id);
CREATE INDEX idx_people_person_skills_skill ON people_person_skills(skill_id);
CREATE INDEX idx_people_time_off_org_bot ON people_time_off(org_id, bot_id);
CREATE INDEX idx_people_time_off_person ON people_time_off(person_id);
CREATE INDEX idx_people_time_off_dates ON people_time_off(start_date, end_date);
CREATE INDEX idx_people_time_off_status ON people_time_off(status);

View file

@ -1,43 +0,0 @@
DROP INDEX IF EXISTS idx_attendant_session_wrap_up_session;
DROP INDEX IF EXISTS idx_attendant_wrap_up_codes_org_code;
DROP INDEX IF EXISTS idx_attendant_wrap_up_codes_org_bot;
DROP INDEX IF EXISTS idx_attendant_tags_org_name;
DROP INDEX IF EXISTS idx_attendant_tags_org_bot;
DROP INDEX IF EXISTS idx_attendant_canned_shortcut;
DROP INDEX IF EXISTS idx_attendant_canned_org_bot;
DROP INDEX IF EXISTS idx_attendant_transfers_session;
DROP INDEX IF EXISTS idx_attendant_agent_status_status;
DROP INDEX IF EXISTS idx_attendant_agent_status_org;
DROP INDEX IF EXISTS idx_attendant_queue_agents_agent;
DROP INDEX IF EXISTS idx_attendant_queue_agents_queue;
DROP INDEX IF EXISTS idx_attendant_session_messages_created;
DROP INDEX IF EXISTS idx_attendant_session_messages_session;
DROP INDEX IF EXISTS idx_attendant_sessions_number;
DROP INDEX IF EXISTS idx_attendant_sessions_created;
DROP INDEX IF EXISTS idx_attendant_sessions_customer;
DROP INDEX IF EXISTS idx_attendant_sessions_queue;
DROP INDEX IF EXISTS idx_attendant_sessions_agent;
DROP INDEX IF EXISTS idx_attendant_sessions_status;
DROP INDEX IF EXISTS idx_attendant_sessions_org_bot;
DROP INDEX IF EXISTS idx_attendant_queues_active;
DROP INDEX IF EXISTS idx_attendant_queues_org_bot;
DROP TABLE IF EXISTS attendant_session_wrap_up;
DROP TABLE IF EXISTS attendant_wrap_up_codes;
DROP TABLE IF EXISTS attendant_tags;
DROP TABLE IF EXISTS attendant_canned_responses;
DROP TABLE IF EXISTS attendant_transfers;
DROP TABLE IF EXISTS attendant_agent_status;
DROP TABLE IF EXISTS attendant_queue_agents;
DROP TABLE IF EXISTS attendant_session_messages;
DROP TABLE IF EXISTS attendant_sessions;
DROP TABLE IF EXISTS attendant_queues;

View file

@ -1,183 +0,0 @@
CREATE TABLE attendant_queues (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
priority INTEGER NOT NULL DEFAULT 0,
max_wait_minutes INTEGER NOT NULL DEFAULT 30,
auto_assign BOOLEAN NOT NULL DEFAULT TRUE,
working_hours JSONB NOT NULL DEFAULT '{}',
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE attendant_sessions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
session_number VARCHAR(50) NOT NULL,
channel VARCHAR(50) NOT NULL,
customer_id UUID,
customer_name VARCHAR(255),
customer_email VARCHAR(255),
customer_phone VARCHAR(50),
status VARCHAR(50) NOT NULL DEFAULT 'waiting',
priority INTEGER NOT NULL DEFAULT 0,
agent_id UUID,
queue_id UUID REFERENCES attendant_queues(id) ON DELETE SET NULL,
subject VARCHAR(500),
initial_message TEXT,
started_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
assigned_at TIMESTAMPTZ,
first_response_at TIMESTAMPTZ,
ended_at TIMESTAMPTZ,
wait_time_seconds INTEGER,
handle_time_seconds INTEGER,
satisfaction_rating INTEGER,
satisfaction_comment TEXT,
tags TEXT[] NOT NULL DEFAULT '{}',
metadata JSONB NOT NULL DEFAULT '{}',
notes TEXT,
transfer_count INTEGER NOT NULL DEFAULT 0,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE attendant_session_messages (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
session_id UUID NOT NULL REFERENCES attendant_sessions(id) ON DELETE CASCADE,
sender_type VARCHAR(20) NOT NULL,
sender_id UUID,
sender_name VARCHAR(255),
content TEXT NOT NULL,
content_type VARCHAR(50) NOT NULL DEFAULT 'text',
attachments JSONB NOT NULL DEFAULT '[]',
is_internal BOOLEAN NOT NULL DEFAULT FALSE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE attendant_queue_agents (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
queue_id UUID NOT NULL REFERENCES attendant_queues(id) ON DELETE CASCADE,
agent_id UUID NOT NULL,
max_concurrent INTEGER NOT NULL DEFAULT 3,
priority INTEGER NOT NULL DEFAULT 0,
skills TEXT[] NOT NULL DEFAULT '{}',
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(queue_id, agent_id)
);
CREATE TABLE attendant_agent_status (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
agent_id UUID NOT NULL,
status VARCHAR(50) NOT NULL DEFAULT 'offline',
status_message VARCHAR(255),
current_sessions INTEGER NOT NULL DEFAULT 0,
max_sessions INTEGER NOT NULL DEFAULT 5,
last_activity_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
break_started_at TIMESTAMPTZ,
break_reason VARCHAR(255),
available_since TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(org_id, agent_id)
);
CREATE TABLE attendant_transfers (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
session_id UUID NOT NULL REFERENCES attendant_sessions(id) ON DELETE CASCADE,
from_agent_id UUID,
to_agent_id UUID,
to_queue_id UUID REFERENCES attendant_queues(id) ON DELETE SET NULL,
reason VARCHAR(255),
notes TEXT,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE attendant_canned_responses (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
title VARCHAR(255) NOT NULL,
content TEXT NOT NULL,
shortcut VARCHAR(50),
category VARCHAR(100),
queue_id UUID REFERENCES attendant_queues(id) ON DELETE SET NULL,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
usage_count INTEGER NOT NULL DEFAULT 0,
created_by UUID,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE attendant_tags (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(100) NOT NULL,
color VARCHAR(20),
description TEXT,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE attendant_wrap_up_codes (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
code VARCHAR(50) NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
requires_notes BOOLEAN NOT NULL DEFAULT FALSE,
is_active BOOLEAN NOT NULL DEFAULT TRUE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE attendant_session_wrap_up (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
session_id UUID NOT NULL REFERENCES attendant_sessions(id) ON DELETE CASCADE,
wrap_up_code_id UUID REFERENCES attendant_wrap_up_codes(id) ON DELETE SET NULL,
notes TEXT,
follow_up_required BOOLEAN NOT NULL DEFAULT FALSE,
follow_up_date DATE,
created_by UUID,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(session_id)
);
CREATE INDEX idx_attendant_queues_org_bot ON attendant_queues(org_id, bot_id);
CREATE INDEX idx_attendant_queues_active ON attendant_queues(is_active);
CREATE INDEX idx_attendant_sessions_org_bot ON attendant_sessions(org_id, bot_id);
CREATE INDEX idx_attendant_sessions_status ON attendant_sessions(status);
CREATE INDEX idx_attendant_sessions_agent ON attendant_sessions(agent_id);
CREATE INDEX idx_attendant_sessions_queue ON attendant_sessions(queue_id);
CREATE INDEX idx_attendant_sessions_customer ON attendant_sessions(customer_id);
CREATE INDEX idx_attendant_sessions_created ON attendant_sessions(created_at DESC);
CREATE UNIQUE INDEX idx_attendant_sessions_number ON attendant_sessions(org_id, session_number);
CREATE INDEX idx_attendant_session_messages_session ON attendant_session_messages(session_id);
CREATE INDEX idx_attendant_session_messages_created ON attendant_session_messages(created_at);
CREATE INDEX idx_attendant_queue_agents_queue ON attendant_queue_agents(queue_id);
CREATE INDEX idx_attendant_queue_agents_agent ON attendant_queue_agents(agent_id);
CREATE INDEX idx_attendant_agent_status_org ON attendant_agent_status(org_id, bot_id);
CREATE INDEX idx_attendant_agent_status_status ON attendant_agent_status(status);
CREATE INDEX idx_attendant_transfers_session ON attendant_transfers(session_id);
CREATE INDEX idx_attendant_canned_org_bot ON attendant_canned_responses(org_id, bot_id);
CREATE INDEX idx_attendant_canned_shortcut ON attendant_canned_responses(shortcut);
CREATE INDEX idx_attendant_tags_org_bot ON attendant_tags(org_id, bot_id);
CREATE UNIQUE INDEX idx_attendant_tags_org_name ON attendant_tags(org_id, bot_id, name);
CREATE INDEX idx_attendant_wrap_up_codes_org_bot ON attendant_wrap_up_codes(org_id, bot_id);
CREATE UNIQUE INDEX idx_attendant_wrap_up_codes_org_code ON attendant_wrap_up_codes(org_id, bot_id, code);
CREATE INDEX idx_attendant_session_wrap_up_session ON attendant_session_wrap_up(session_id);

View file

@ -1,26 +0,0 @@
DROP INDEX IF EXISTS idx_calendar_shares_email;
DROP INDEX IF EXISTS idx_calendar_shares_user;
DROP INDEX IF EXISTS idx_calendar_shares_calendar;
DROP INDEX IF EXISTS idx_calendar_event_reminders_pending;
DROP INDEX IF EXISTS idx_calendar_event_reminders_event;
DROP INDEX IF EXISTS idx_calendar_event_attendees_email;
DROP INDEX IF EXISTS idx_calendar_event_attendees_event;
DROP INDEX IF EXISTS idx_calendar_events_recurrence;
DROP INDEX IF EXISTS idx_calendar_events_status;
DROP INDEX IF EXISTS idx_calendar_events_time_range;
DROP INDEX IF EXISTS idx_calendar_events_owner;
DROP INDEX IF EXISTS idx_calendar_events_calendar;
DROP INDEX IF EXISTS idx_calendar_events_org_bot;
DROP INDEX IF EXISTS idx_calendars_primary;
DROP INDEX IF EXISTS idx_calendars_owner;
DROP INDEX IF EXISTS idx_calendars_org_bot;
DROP TABLE IF EXISTS calendar_shares;
DROP TABLE IF EXISTS calendar_event_reminders;
DROP TABLE IF EXISTS calendar_event_attendees;
DROP TABLE IF EXISTS calendar_events;
DROP TABLE IF EXISTS calendars;

View file

@ -1,95 +0,0 @@
CREATE TABLE calendars (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
owner_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
color VARCHAR(20) DEFAULT '#3b82f6',
timezone VARCHAR(100) DEFAULT 'UTC',
is_primary BOOLEAN NOT NULL DEFAULT FALSE,
is_visible BOOLEAN NOT NULL DEFAULT TRUE,
is_shared BOOLEAN NOT NULL DEFAULT FALSE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE calendar_events (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
calendar_id UUID NOT NULL REFERENCES calendars(id) ON DELETE CASCADE,
owner_id UUID NOT NULL,
title VARCHAR(500) NOT NULL,
description TEXT,
location VARCHAR(500),
start_time TIMESTAMPTZ NOT NULL,
end_time TIMESTAMPTZ NOT NULL,
all_day BOOLEAN NOT NULL DEFAULT FALSE,
recurrence_rule TEXT,
recurrence_id UUID REFERENCES calendar_events(id) ON DELETE SET NULL,
color VARCHAR(20),
status VARCHAR(50) NOT NULL DEFAULT 'confirmed',
visibility VARCHAR(50) NOT NULL DEFAULT 'default',
busy_status VARCHAR(50) NOT NULL DEFAULT 'busy',
reminders JSONB NOT NULL DEFAULT '[]',
attendees JSONB NOT NULL DEFAULT '[]',
conference_data JSONB,
metadata JSONB NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE calendar_event_attendees (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
event_id UUID NOT NULL REFERENCES calendar_events(id) ON DELETE CASCADE,
email VARCHAR(255) NOT NULL,
name VARCHAR(255),
status VARCHAR(50) NOT NULL DEFAULT 'needs-action',
role VARCHAR(50) NOT NULL DEFAULT 'req-participant',
rsvp_time TIMESTAMPTZ,
comment TEXT,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE calendar_event_reminders (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
event_id UUID NOT NULL REFERENCES calendar_events(id) ON DELETE CASCADE,
reminder_type VARCHAR(50) NOT NULL DEFAULT 'notification',
minutes_before INTEGER NOT NULL,
is_sent BOOLEAN NOT NULL DEFAULT FALSE,
sent_at TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE calendar_shares (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
calendar_id UUID NOT NULL REFERENCES calendars(id) ON DELETE CASCADE,
shared_with_user_id UUID,
shared_with_email VARCHAR(255),
permission VARCHAR(50) NOT NULL DEFAULT 'read',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(calendar_id, shared_with_user_id),
UNIQUE(calendar_id, shared_with_email)
);
CREATE INDEX idx_calendars_org_bot ON calendars(org_id, bot_id);
CREATE INDEX idx_calendars_owner ON calendars(owner_id);
CREATE INDEX idx_calendars_primary ON calendars(owner_id, is_primary) WHERE is_primary = TRUE;
CREATE INDEX idx_calendar_events_org_bot ON calendar_events(org_id, bot_id);
CREATE INDEX idx_calendar_events_calendar ON calendar_events(calendar_id);
CREATE INDEX idx_calendar_events_owner ON calendar_events(owner_id);
CREATE INDEX idx_calendar_events_time_range ON calendar_events(start_time, end_time);
CREATE INDEX idx_calendar_events_status ON calendar_events(status);
CREATE INDEX idx_calendar_events_recurrence ON calendar_events(recurrence_id) WHERE recurrence_id IS NOT NULL;
CREATE INDEX idx_calendar_event_attendees_event ON calendar_event_attendees(event_id);
CREATE INDEX idx_calendar_event_attendees_email ON calendar_event_attendees(email);
CREATE INDEX idx_calendar_event_reminders_event ON calendar_event_reminders(event_id);
CREATE INDEX idx_calendar_event_reminders_pending ON calendar_event_reminders(is_sent, minutes_before) WHERE is_sent = FALSE;
CREATE INDEX idx_calendar_shares_calendar ON calendar_shares(calendar_id);
CREATE INDEX idx_calendar_shares_user ON calendar_shares(shared_with_user_id) WHERE shared_with_user_id IS NOT NULL;
CREATE INDEX idx_calendar_shares_email ON calendar_shares(shared_with_email) WHERE shared_with_email IS NOT NULL;

View file

@ -1,43 +0,0 @@
DROP INDEX IF EXISTS idx_okr_activity_created;
DROP INDEX IF EXISTS idx_okr_activity_user;
DROP INDEX IF EXISTS idx_okr_activity_key_result;
DROP INDEX IF EXISTS idx_okr_activity_objective;
DROP INDEX IF EXISTS idx_okr_activity_org_bot;
DROP INDEX IF EXISTS idx_okr_comments_parent;
DROP INDEX IF EXISTS idx_okr_comments_key_result;
DROP INDEX IF EXISTS idx_okr_comments_objective;
DROP INDEX IF EXISTS idx_okr_comments_org_bot;
DROP INDEX IF EXISTS idx_okr_templates_system;
DROP INDEX IF EXISTS idx_okr_templates_category;
DROP INDEX IF EXISTS idx_okr_templates_org_bot;
DROP INDEX IF EXISTS idx_okr_alignments_parent;
DROP INDEX IF EXISTS idx_okr_alignments_child;
DROP INDEX IF EXISTS idx_okr_alignments_org_bot;
DROP INDEX IF EXISTS idx_okr_checkins_created;
DROP INDEX IF EXISTS idx_okr_checkins_user;
DROP INDEX IF EXISTS idx_okr_checkins_key_result;
DROP INDEX IF EXISTS idx_okr_checkins_org_bot;
DROP INDEX IF EXISTS idx_okr_key_results_due_date;
DROP INDEX IF EXISTS idx_okr_key_results_status;
DROP INDEX IF EXISTS idx_okr_key_results_owner;
DROP INDEX IF EXISTS idx_okr_key_results_objective;
DROP INDEX IF EXISTS idx_okr_key_results_org_bot;
DROP INDEX IF EXISTS idx_okr_objectives_status;
DROP INDEX IF EXISTS idx_okr_objectives_period;
DROP INDEX IF EXISTS idx_okr_objectives_parent;
DROP INDEX IF EXISTS idx_okr_objectives_owner;
DROP INDEX IF EXISTS idx_okr_objectives_org_bot;
DROP TABLE IF EXISTS okr_activity_log;
DROP TABLE IF EXISTS okr_comments;
DROP TABLE IF EXISTS okr_templates;
DROP TABLE IF EXISTS okr_alignments;
DROP TABLE IF EXISTS okr_checkins;
DROP TABLE IF EXISTS okr_key_results;
DROP TABLE IF EXISTS okr_objectives;

View file

@ -1,150 +0,0 @@
CREATE TABLE okr_objectives (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
owner_id UUID NOT NULL,
parent_id UUID REFERENCES okr_objectives(id) ON DELETE SET NULL,
title VARCHAR(500) NOT NULL,
description TEXT,
period VARCHAR(50) NOT NULL,
period_start DATE,
period_end DATE,
status VARCHAR(50) NOT NULL DEFAULT 'draft',
progress DECIMAL(5,2) NOT NULL DEFAULT 0,
visibility VARCHAR(50) NOT NULL DEFAULT 'team',
weight DECIMAL(3,2) NOT NULL DEFAULT 1.0,
tags TEXT[] NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE okr_key_results (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
objective_id UUID NOT NULL REFERENCES okr_objectives(id) ON DELETE CASCADE,
owner_id UUID NOT NULL,
title VARCHAR(500) NOT NULL,
description TEXT,
metric_type VARCHAR(50) NOT NULL,
start_value DECIMAL(15,2) NOT NULL DEFAULT 0,
target_value DECIMAL(15,2) NOT NULL,
current_value DECIMAL(15,2) NOT NULL DEFAULT 0,
unit VARCHAR(50),
weight DECIMAL(3,2) NOT NULL DEFAULT 1.0,
status VARCHAR(50) NOT NULL DEFAULT 'not_started',
due_date DATE,
scoring_type VARCHAR(50) NOT NULL DEFAULT 'linear',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE okr_checkins (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
key_result_id UUID NOT NULL REFERENCES okr_key_results(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
previous_value DECIMAL(15,2),
new_value DECIMAL(15,2) NOT NULL,
note TEXT,
confidence VARCHAR(50),
blockers TEXT,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE okr_alignments (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
child_objective_id UUID NOT NULL REFERENCES okr_objectives(id) ON DELETE CASCADE,
parent_objective_id UUID NOT NULL REFERENCES okr_objectives(id) ON DELETE CASCADE,
alignment_type VARCHAR(50) NOT NULL DEFAULT 'supports',
weight DECIMAL(3,2) NOT NULL DEFAULT 1.0,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(child_objective_id, parent_objective_id)
);
CREATE TABLE okr_templates (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
category VARCHAR(100),
objective_template JSONB NOT NULL DEFAULT '{}',
key_result_templates JSONB NOT NULL DEFAULT '[]',
is_system BOOLEAN NOT NULL DEFAULT FALSE,
usage_count INTEGER NOT NULL DEFAULT 0,
created_by UUID,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE okr_comments (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
objective_id UUID REFERENCES okr_objectives(id) ON DELETE CASCADE,
key_result_id UUID REFERENCES okr_key_results(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
content TEXT NOT NULL,
parent_comment_id UUID REFERENCES okr_comments(id) ON DELETE CASCADE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
CONSTRAINT okr_comments_target_check CHECK (
(objective_id IS NOT NULL AND key_result_id IS NULL) OR
(objective_id IS NULL AND key_result_id IS NOT NULL)
)
);
CREATE TABLE okr_activity_log (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
objective_id UUID REFERENCES okr_objectives(id) ON DELETE CASCADE,
key_result_id UUID REFERENCES okr_key_results(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
activity_type VARCHAR(50) NOT NULL,
description TEXT,
old_value TEXT,
new_value TEXT,
metadata JSONB NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE INDEX idx_okr_objectives_org_bot ON okr_objectives(org_id, bot_id);
CREATE INDEX idx_okr_objectives_owner ON okr_objectives(owner_id);
CREATE INDEX idx_okr_objectives_parent ON okr_objectives(parent_id) WHERE parent_id IS NOT NULL;
CREATE INDEX idx_okr_objectives_period ON okr_objectives(period, period_start, period_end);
CREATE INDEX idx_okr_objectives_status ON okr_objectives(status);
CREATE INDEX idx_okr_key_results_org_bot ON okr_key_results(org_id, bot_id);
CREATE INDEX idx_okr_key_results_objective ON okr_key_results(objective_id);
CREATE INDEX idx_okr_key_results_owner ON okr_key_results(owner_id);
CREATE INDEX idx_okr_key_results_status ON okr_key_results(status);
CREATE INDEX idx_okr_key_results_due_date ON okr_key_results(due_date) WHERE due_date IS NOT NULL;
CREATE INDEX idx_okr_checkins_org_bot ON okr_checkins(org_id, bot_id);
CREATE INDEX idx_okr_checkins_key_result ON okr_checkins(key_result_id);
CREATE INDEX idx_okr_checkins_user ON okr_checkins(user_id);
CREATE INDEX idx_okr_checkins_created ON okr_checkins(created_at DESC);
CREATE INDEX idx_okr_alignments_org_bot ON okr_alignments(org_id, bot_id);
CREATE INDEX idx_okr_alignments_child ON okr_alignments(child_objective_id);
CREATE INDEX idx_okr_alignments_parent ON okr_alignments(parent_objective_id);
CREATE INDEX idx_okr_templates_org_bot ON okr_templates(org_id, bot_id);
CREATE INDEX idx_okr_templates_category ON okr_templates(category);
CREATE INDEX idx_okr_templates_system ON okr_templates(is_system) WHERE is_system = TRUE;
CREATE INDEX idx_okr_comments_org_bot ON okr_comments(org_id, bot_id);
CREATE INDEX idx_okr_comments_objective ON okr_comments(objective_id) WHERE objective_id IS NOT NULL;
CREATE INDEX idx_okr_comments_key_result ON okr_comments(key_result_id) WHERE key_result_id IS NOT NULL;
CREATE INDEX idx_okr_comments_parent ON okr_comments(parent_comment_id) WHERE parent_comment_id IS NOT NULL;
CREATE INDEX idx_okr_activity_org_bot ON okr_activity_log(org_id, bot_id);
CREATE INDEX idx_okr_activity_objective ON okr_activity_log(objective_id) WHERE objective_id IS NOT NULL;
CREATE INDEX idx_okr_activity_key_result ON okr_activity_log(key_result_id) WHERE key_result_id IS NOT NULL;
CREATE INDEX idx_okr_activity_user ON okr_activity_log(user_id);
CREATE INDEX idx_okr_activity_created ON okr_activity_log(created_at DESC);

View file

@ -1,25 +0,0 @@
DROP INDEX IF EXISTS idx_canvas_comments_unresolved;
DROP INDEX IF EXISTS idx_canvas_comments_parent;
DROP INDEX IF EXISTS idx_canvas_comments_element;
DROP INDEX IF EXISTS idx_canvas_comments_canvas;
DROP INDEX IF EXISTS idx_canvas_versions_number;
DROP INDEX IF EXISTS idx_canvas_versions_canvas;
DROP INDEX IF EXISTS idx_canvas_collaborators_user;
DROP INDEX IF EXISTS idx_canvas_collaborators_canvas;
DROP INDEX IF EXISTS idx_canvas_elements_z_index;
DROP INDEX IF EXISTS idx_canvas_elements_type;
DROP INDEX IF EXISTS idx_canvas_elements_canvas;
DROP INDEX IF EXISTS idx_canvases_template;
DROP INDEX IF EXISTS idx_canvases_public;
DROP INDEX IF EXISTS idx_canvases_created_by;
DROP INDEX IF EXISTS idx_canvases_org_bot;
DROP TABLE IF EXISTS canvas_comments;
DROP TABLE IF EXISTS canvas_versions;
DROP TABLE IF EXISTS canvas_collaborators;
DROP TABLE IF EXISTS canvas_elements;
DROP TABLE IF EXISTS canvases;

View file

@ -1,90 +0,0 @@
CREATE TABLE canvases (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
width INTEGER NOT NULL DEFAULT 1920,
height INTEGER NOT NULL DEFAULT 1080,
background_color VARCHAR(20) DEFAULT '#ffffff',
thumbnail_url TEXT,
is_public BOOLEAN NOT NULL DEFAULT FALSE,
is_template BOOLEAN NOT NULL DEFAULT FALSE,
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE canvas_elements (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
canvas_id UUID NOT NULL REFERENCES canvases(id) ON DELETE CASCADE,
element_type VARCHAR(50) NOT NULL,
x DOUBLE PRECISION NOT NULL DEFAULT 0,
y DOUBLE PRECISION NOT NULL DEFAULT 0,
width DOUBLE PRECISION NOT NULL DEFAULT 100,
height DOUBLE PRECISION NOT NULL DEFAULT 100,
rotation DOUBLE PRECISION NOT NULL DEFAULT 0,
z_index INTEGER NOT NULL DEFAULT 0,
locked BOOLEAN NOT NULL DEFAULT FALSE,
properties JSONB NOT NULL DEFAULT '{}',
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE canvas_collaborators (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
canvas_id UUID NOT NULL REFERENCES canvases(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
permission VARCHAR(50) NOT NULL DEFAULT 'view',
added_by UUID,
added_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(canvas_id, user_id)
);
CREATE TABLE canvas_versions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
canvas_id UUID NOT NULL REFERENCES canvases(id) ON DELETE CASCADE,
version_number INTEGER NOT NULL,
name VARCHAR(255),
elements_snapshot JSONB NOT NULL DEFAULT '[]',
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(canvas_id, version_number)
);
CREATE TABLE canvas_comments (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
canvas_id UUID NOT NULL REFERENCES canvases(id) ON DELETE CASCADE,
element_id UUID REFERENCES canvas_elements(id) ON DELETE CASCADE,
parent_comment_id UUID REFERENCES canvas_comments(id) ON DELETE CASCADE,
author_id UUID NOT NULL,
content TEXT NOT NULL,
x_position DOUBLE PRECISION,
y_position DOUBLE PRECISION,
resolved BOOLEAN NOT NULL DEFAULT FALSE,
resolved_by UUID,
resolved_at TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE INDEX idx_canvases_org_bot ON canvases(org_id, bot_id);
CREATE INDEX idx_canvases_created_by ON canvases(created_by);
CREATE INDEX idx_canvases_public ON canvases(is_public) WHERE is_public = TRUE;
CREATE INDEX idx_canvases_template ON canvases(is_template) WHERE is_template = TRUE;
CREATE INDEX idx_canvas_elements_canvas ON canvas_elements(canvas_id);
CREATE INDEX idx_canvas_elements_type ON canvas_elements(element_type);
CREATE INDEX idx_canvas_elements_z_index ON canvas_elements(canvas_id, z_index);
CREATE INDEX idx_canvas_collaborators_canvas ON canvas_collaborators(canvas_id);
CREATE INDEX idx_canvas_collaborators_user ON canvas_collaborators(user_id);
CREATE INDEX idx_canvas_versions_canvas ON canvas_versions(canvas_id);
CREATE INDEX idx_canvas_versions_number ON canvas_versions(canvas_id, version_number DESC);
CREATE INDEX idx_canvas_comments_canvas ON canvas_comments(canvas_id);
CREATE INDEX idx_canvas_comments_element ON canvas_comments(element_id) WHERE element_id IS NOT NULL;
CREATE INDEX idx_canvas_comments_parent ON canvas_comments(parent_comment_id) WHERE parent_comment_id IS NOT NULL;
CREATE INDEX idx_canvas_comments_unresolved ON canvas_comments(canvas_id, resolved) WHERE resolved = FALSE;

View file

@ -1,39 +0,0 @@
DROP INDEX IF EXISTS idx_workspace_templates_system;
DROP INDEX IF EXISTS idx_workspace_templates_category;
DROP INDEX IF EXISTS idx_workspace_templates_org_bot;
DROP INDEX IF EXISTS idx_workspace_comment_reactions_comment;
DROP INDEX IF EXISTS idx_workspace_comments_unresolved;
DROP INDEX IF EXISTS idx_workspace_comments_parent;
DROP INDEX IF EXISTS idx_workspace_comments_block;
DROP INDEX IF EXISTS idx_workspace_comments_page;
DROP INDEX IF EXISTS idx_workspace_comments_workspace;
DROP INDEX IF EXISTS idx_workspace_page_permissions_user;
DROP INDEX IF EXISTS idx_workspace_page_permissions_page;
DROP INDEX IF EXISTS idx_workspace_page_versions_number;
DROP INDEX IF EXISTS idx_workspace_page_versions_page;
DROP INDEX IF EXISTS idx_workspace_pages_position;
DROP INDEX IF EXISTS idx_workspace_pages_public;
DROP INDEX IF EXISTS idx_workspace_pages_template;
DROP INDEX IF EXISTS idx_workspace_pages_parent;
DROP INDEX IF EXISTS idx_workspace_pages_workspace;
DROP INDEX IF EXISTS idx_workspace_members_role;
DROP INDEX IF EXISTS idx_workspace_members_user;
DROP INDEX IF EXISTS idx_workspace_members_workspace;
DROP INDEX IF EXISTS idx_workspaces_created_by;
DROP INDEX IF EXISTS idx_workspaces_org_bot;
DROP TABLE IF EXISTS workspace_templates;
DROP TABLE IF EXISTS workspace_comment_reactions;
DROP TABLE IF EXISTS workspace_comments;
DROP TABLE IF EXISTS workspace_page_permissions;
DROP TABLE IF EXISTS workspace_page_versions;
DROP TABLE IF EXISTS workspace_pages;
DROP TABLE IF EXISTS workspace_members;
DROP TABLE IF EXISTS workspaces;

View file

@ -1,141 +0,0 @@
CREATE TABLE workspaces (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
icon_type VARCHAR(20) DEFAULT 'emoji',
icon_value VARCHAR(100),
cover_image TEXT,
settings JSONB NOT NULL DEFAULT '{}',
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE workspace_members (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
workspace_id UUID NOT NULL REFERENCES workspaces(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
role VARCHAR(50) NOT NULL DEFAULT 'member',
invited_by UUID,
joined_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(workspace_id, user_id)
);
CREATE TABLE workspace_pages (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
workspace_id UUID NOT NULL REFERENCES workspaces(id) ON DELETE CASCADE,
parent_id UUID REFERENCES workspace_pages(id) ON DELETE CASCADE,
title VARCHAR(500) NOT NULL,
icon_type VARCHAR(20),
icon_value VARCHAR(100),
cover_image TEXT,
content JSONB NOT NULL DEFAULT '[]',
properties JSONB NOT NULL DEFAULT '{}',
is_template BOOLEAN NOT NULL DEFAULT FALSE,
template_id UUID REFERENCES workspace_pages(id) ON DELETE SET NULL,
is_public BOOLEAN NOT NULL DEFAULT FALSE,
public_edit BOOLEAN NOT NULL DEFAULT FALSE,
position INTEGER NOT NULL DEFAULT 0,
created_by UUID NOT NULL,
last_edited_by UUID,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE workspace_page_versions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
page_id UUID NOT NULL REFERENCES workspace_pages(id) ON DELETE CASCADE,
version_number INTEGER NOT NULL,
title VARCHAR(500) NOT NULL,
content JSONB NOT NULL DEFAULT '[]',
change_summary TEXT,
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(page_id, version_number)
);
CREATE TABLE workspace_page_permissions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
page_id UUID NOT NULL REFERENCES workspace_pages(id) ON DELETE CASCADE,
user_id UUID,
role VARCHAR(50),
permission VARCHAR(50) NOT NULL DEFAULT 'view',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(page_id, user_id),
UNIQUE(page_id, role)
);
CREATE TABLE workspace_comments (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
workspace_id UUID NOT NULL REFERENCES workspaces(id) ON DELETE CASCADE,
page_id UUID NOT NULL REFERENCES workspace_pages(id) ON DELETE CASCADE,
block_id UUID,
parent_comment_id UUID REFERENCES workspace_comments(id) ON DELETE CASCADE,
author_id UUID NOT NULL,
content TEXT NOT NULL,
resolved BOOLEAN NOT NULL DEFAULT FALSE,
resolved_by UUID,
resolved_at TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE workspace_comment_reactions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
comment_id UUID NOT NULL REFERENCES workspace_comments(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
emoji VARCHAR(20) NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(comment_id, user_id, emoji)
);
CREATE TABLE workspace_templates (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
category VARCHAR(100),
icon_type VARCHAR(20),
icon_value VARCHAR(100),
cover_image TEXT,
content JSONB NOT NULL DEFAULT '[]',
is_system BOOLEAN NOT NULL DEFAULT FALSE,
usage_count INTEGER NOT NULL DEFAULT 0,
created_by UUID,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE INDEX idx_workspaces_org_bot ON workspaces(org_id, bot_id);
CREATE INDEX idx_workspaces_created_by ON workspaces(created_by);
CREATE INDEX idx_workspace_members_workspace ON workspace_members(workspace_id);
CREATE INDEX idx_workspace_members_user ON workspace_members(user_id);
CREATE INDEX idx_workspace_members_role ON workspace_members(role);
CREATE INDEX idx_workspace_pages_workspace ON workspace_pages(workspace_id);
CREATE INDEX idx_workspace_pages_parent ON workspace_pages(parent_id) WHERE parent_id IS NOT NULL;
CREATE INDEX idx_workspace_pages_template ON workspace_pages(is_template) WHERE is_template = TRUE;
CREATE INDEX idx_workspace_pages_public ON workspace_pages(is_public) WHERE is_public = TRUE;
CREATE INDEX idx_workspace_pages_position ON workspace_pages(workspace_id, parent_id, position);
CREATE INDEX idx_workspace_page_versions_page ON workspace_page_versions(page_id);
CREATE INDEX idx_workspace_page_versions_number ON workspace_page_versions(page_id, version_number DESC);
CREATE INDEX idx_workspace_page_permissions_page ON workspace_page_permissions(page_id);
CREATE INDEX idx_workspace_page_permissions_user ON workspace_page_permissions(user_id) WHERE user_id IS NOT NULL;
CREATE INDEX idx_workspace_comments_workspace ON workspace_comments(workspace_id);
CREATE INDEX idx_workspace_comments_page ON workspace_comments(page_id);
CREATE INDEX idx_workspace_comments_block ON workspace_comments(block_id) WHERE block_id IS NOT NULL;
CREATE INDEX idx_workspace_comments_parent ON workspace_comments(parent_comment_id) WHERE parent_comment_id IS NOT NULL;
CREATE INDEX idx_workspace_comments_unresolved ON workspace_comments(page_id, resolved) WHERE resolved = FALSE;
CREATE INDEX idx_workspace_comment_reactions_comment ON workspace_comment_reactions(comment_id);
CREATE INDEX idx_workspace_templates_org_bot ON workspace_templates(org_id, bot_id);
CREATE INDEX idx_workspace_templates_category ON workspace_templates(category);
CREATE INDEX idx_workspace_templates_system ON workspace_templates(is_system) WHERE is_system = TRUE;

View file

@ -1,63 +0,0 @@
DROP INDEX IF EXISTS idx_social_hashtags_popular;
DROP INDEX IF EXISTS idx_social_hashtags_tag;
DROP INDEX IF EXISTS idx_social_hashtags_org_bot;
DROP INDEX IF EXISTS idx_social_bookmarks_post;
DROP INDEX IF EXISTS idx_social_bookmarks_user;
DROP INDEX IF EXISTS idx_social_praises_created;
DROP INDEX IF EXISTS idx_social_praises_to;
DROP INDEX IF EXISTS idx_social_praises_from;
DROP INDEX IF EXISTS idx_social_praises_org_bot;
DROP INDEX IF EXISTS idx_social_announcements_pinned;
DROP INDEX IF EXISTS idx_social_announcements_priority;
DROP INDEX IF EXISTS idx_social_announcements_active;
DROP INDEX IF EXISTS idx_social_announcements_org_bot;
DROP INDEX IF EXISTS idx_social_poll_votes_user;
DROP INDEX IF EXISTS idx_social_poll_votes_poll;
DROP INDEX IF EXISTS idx_social_poll_options_poll;
DROP INDEX IF EXISTS idx_social_polls_post;
DROP INDEX IF EXISTS idx_social_reactions_user;
DROP INDEX IF EXISTS idx_social_reactions_comment;
DROP INDEX IF EXISTS idx_social_reactions_post;
DROP INDEX IF EXISTS idx_social_comments_created;
DROP INDEX IF EXISTS idx_social_comments_author;
DROP INDEX IF EXISTS idx_social_comments_parent;
DROP INDEX IF EXISTS idx_social_comments_post;
DROP INDEX IF EXISTS idx_social_posts_hashtags;
DROP INDEX IF EXISTS idx_social_posts_created;
DROP INDEX IF EXISTS idx_social_posts_announcement;
DROP INDEX IF EXISTS idx_social_posts_pinned;
DROP INDEX IF EXISTS idx_social_posts_visibility;
DROP INDEX IF EXISTS idx_social_posts_parent;
DROP INDEX IF EXISTS idx_social_posts_community;
DROP INDEX IF EXISTS idx_social_posts_author;
DROP INDEX IF EXISTS idx_social_posts_org_bot;
DROP INDEX IF EXISTS idx_social_community_members_role;
DROP INDEX IF EXISTS idx_social_community_members_user;
DROP INDEX IF EXISTS idx_social_community_members_community;
DROP INDEX IF EXISTS idx_social_communities_owner;
DROP INDEX IF EXISTS idx_social_communities_featured;
DROP INDEX IF EXISTS idx_social_communities_visibility;
DROP INDEX IF EXISTS idx_social_communities_slug;
DROP INDEX IF EXISTS idx_social_communities_org_bot;
DROP TABLE IF EXISTS social_hashtags;
DROP TABLE IF EXISTS social_bookmarks;
DROP TABLE IF EXISTS social_praises;
DROP TABLE IF EXISTS social_announcements;
DROP TABLE IF EXISTS social_poll_votes;
DROP TABLE IF EXISTS social_poll_options;
DROP TABLE IF EXISTS social_polls;
DROP TABLE IF EXISTS social_reactions;
DROP TABLE IF EXISTS social_comments;
DROP TABLE IF EXISTS social_posts;
DROP TABLE IF EXISTS social_community_members;
DROP TABLE IF EXISTS social_communities;

View file

@ -1,219 +0,0 @@
CREATE TABLE social_communities (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
slug VARCHAR(255) NOT NULL,
description TEXT,
cover_image TEXT,
icon TEXT,
visibility VARCHAR(50) NOT NULL DEFAULT 'public',
join_policy VARCHAR(50) NOT NULL DEFAULT 'open',
owner_id UUID NOT NULL,
member_count INTEGER NOT NULL DEFAULT 0,
post_count INTEGER NOT NULL DEFAULT 0,
is_official BOOLEAN NOT NULL DEFAULT FALSE,
is_featured BOOLEAN NOT NULL DEFAULT FALSE,
settings JSONB NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
archived_at TIMESTAMPTZ
);
CREATE TABLE social_community_members (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
community_id UUID NOT NULL REFERENCES social_communities(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
role VARCHAR(50) NOT NULL DEFAULT 'member',
notifications_enabled BOOLEAN NOT NULL DEFAULT TRUE,
joined_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
last_seen_at TIMESTAMPTZ,
UNIQUE(community_id, user_id)
);
CREATE TABLE social_posts (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
author_id UUID NOT NULL,
community_id UUID REFERENCES social_communities(id) ON DELETE CASCADE,
parent_id UUID REFERENCES social_posts(id) ON DELETE CASCADE,
content TEXT NOT NULL,
content_type VARCHAR(50) NOT NULL DEFAULT 'text',
attachments JSONB NOT NULL DEFAULT '[]',
mentions JSONB NOT NULL DEFAULT '[]',
hashtags TEXT[] NOT NULL DEFAULT '{}',
visibility VARCHAR(50) NOT NULL DEFAULT 'public',
is_announcement BOOLEAN NOT NULL DEFAULT FALSE,
is_pinned BOOLEAN NOT NULL DEFAULT FALSE,
poll_id UUID,
reaction_counts JSONB NOT NULL DEFAULT '{}',
comment_count INTEGER NOT NULL DEFAULT 0,
share_count INTEGER NOT NULL DEFAULT 0,
view_count INTEGER NOT NULL DEFAULT 0,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
edited_at TIMESTAMPTZ,
deleted_at TIMESTAMPTZ
);
CREATE TABLE social_comments (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
post_id UUID NOT NULL REFERENCES social_posts(id) ON DELETE CASCADE,
parent_comment_id UUID REFERENCES social_comments(id) ON DELETE CASCADE,
author_id UUID NOT NULL,
content TEXT NOT NULL,
mentions JSONB NOT NULL DEFAULT '[]',
reaction_counts JSONB NOT NULL DEFAULT '{}',
reply_count INTEGER NOT NULL DEFAULT 0,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
edited_at TIMESTAMPTZ,
deleted_at TIMESTAMPTZ
);
CREATE TABLE social_reactions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
post_id UUID REFERENCES social_posts(id) ON DELETE CASCADE,
comment_id UUID REFERENCES social_comments(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
reaction_type VARCHAR(50) NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
CONSTRAINT social_reactions_target_check CHECK (
(post_id IS NOT NULL AND comment_id IS NULL) OR
(post_id IS NULL AND comment_id IS NOT NULL)
),
UNIQUE(post_id, user_id, reaction_type),
UNIQUE(comment_id, user_id, reaction_type)
);
CREATE TABLE social_polls (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
post_id UUID NOT NULL REFERENCES social_posts(id) ON DELETE CASCADE,
question TEXT NOT NULL,
allow_multiple BOOLEAN NOT NULL DEFAULT FALSE,
allow_add_options BOOLEAN NOT NULL DEFAULT FALSE,
anonymous BOOLEAN NOT NULL DEFAULT FALSE,
total_votes INTEGER NOT NULL DEFAULT 0,
ends_at TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE social_poll_options (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
poll_id UUID NOT NULL REFERENCES social_polls(id) ON DELETE CASCADE,
text VARCHAR(500) NOT NULL,
vote_count INTEGER NOT NULL DEFAULT 0,
position INTEGER NOT NULL DEFAULT 0,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE social_poll_votes (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
poll_id UUID NOT NULL REFERENCES social_polls(id) ON DELETE CASCADE,
option_id UUID NOT NULL REFERENCES social_poll_options(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(poll_id, option_id, user_id)
);
CREATE TABLE social_announcements (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
author_id UUID NOT NULL,
title VARCHAR(500) NOT NULL,
content TEXT NOT NULL,
priority VARCHAR(50) NOT NULL DEFAULT 'normal',
target_audience JSONB NOT NULL DEFAULT '{}',
is_pinned BOOLEAN NOT NULL DEFAULT FALSE,
requires_acknowledgment BOOLEAN NOT NULL DEFAULT FALSE,
acknowledged_by JSONB NOT NULL DEFAULT '[]',
starts_at TIMESTAMPTZ,
ends_at TIMESTAMPTZ,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE social_praises (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
from_user_id UUID NOT NULL,
to_user_id UUID NOT NULL,
badge_type VARCHAR(50) NOT NULL,
message TEXT,
is_public BOOLEAN NOT NULL DEFAULT TRUE,
post_id UUID REFERENCES social_posts(id) ON DELETE SET NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE social_bookmarks (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
user_id UUID NOT NULL,
post_id UUID NOT NULL REFERENCES social_posts(id) ON DELETE CASCADE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(user_id, post_id)
);
CREATE TABLE social_hashtags (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
tag VARCHAR(100) NOT NULL,
post_count INTEGER NOT NULL DEFAULT 0,
last_used_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(org_id, bot_id, tag)
);
CREATE INDEX idx_social_communities_org_bot ON social_communities(org_id, bot_id);
CREATE INDEX idx_social_communities_slug ON social_communities(slug);
CREATE INDEX idx_social_communities_visibility ON social_communities(visibility);
CREATE INDEX idx_social_communities_featured ON social_communities(is_featured) WHERE is_featured = TRUE;
CREATE INDEX idx_social_communities_owner ON social_communities(owner_id);
CREATE INDEX idx_social_community_members_community ON social_community_members(community_id);
CREATE INDEX idx_social_community_members_user ON social_community_members(user_id);
CREATE INDEX idx_social_community_members_role ON social_community_members(community_id, role);
CREATE INDEX idx_social_posts_org_bot ON social_posts(org_id, bot_id);
CREATE INDEX idx_social_posts_author ON social_posts(author_id);
CREATE INDEX idx_social_posts_community ON social_posts(community_id) WHERE community_id IS NOT NULL;
CREATE INDEX idx_social_posts_parent ON social_posts(parent_id) WHERE parent_id IS NOT NULL;
CREATE INDEX idx_social_posts_visibility ON social_posts(visibility);
CREATE INDEX idx_social_posts_pinned ON social_posts(community_id, is_pinned) WHERE is_pinned = TRUE;
CREATE INDEX idx_social_posts_announcement ON social_posts(is_announcement) WHERE is_announcement = TRUE;
CREATE INDEX idx_social_posts_created ON social_posts(created_at DESC);
CREATE INDEX idx_social_posts_hashtags ON social_posts USING GIN(hashtags);
CREATE INDEX idx_social_comments_post ON social_comments(post_id);
CREATE INDEX idx_social_comments_parent ON social_comments(parent_comment_id) WHERE parent_comment_id IS NOT NULL;
CREATE INDEX idx_social_comments_author ON social_comments(author_id);
CREATE INDEX idx_social_comments_created ON social_comments(created_at DESC);
CREATE INDEX idx_social_reactions_post ON social_reactions(post_id) WHERE post_id IS NOT NULL;
CREATE INDEX idx_social_reactions_comment ON social_reactions(comment_id) WHERE comment_id IS NOT NULL;
CREATE INDEX idx_social_reactions_user ON social_reactions(user_id);
CREATE INDEX idx_social_polls_post ON social_polls(post_id);
CREATE INDEX idx_social_poll_options_poll ON social_poll_options(poll_id);
CREATE INDEX idx_social_poll_votes_poll ON social_poll_votes(poll_id);
CREATE INDEX idx_social_poll_votes_user ON social_poll_votes(user_id);
CREATE INDEX idx_social_announcements_org_bot ON social_announcements(org_id, bot_id);
CREATE INDEX idx_social_announcements_active ON social_announcements(starts_at, ends_at);
CREATE INDEX idx_social_announcements_priority ON social_announcements(priority);
CREATE INDEX idx_social_announcements_pinned ON social_announcements(is_pinned) WHERE is_pinned = TRUE;
CREATE INDEX idx_social_praises_org_bot ON social_praises(org_id, bot_id);
CREATE INDEX idx_social_praises_from ON social_praises(from_user_id);
CREATE INDEX idx_social_praises_to ON social_praises(to_user_id);
CREATE INDEX idx_social_praises_created ON social_praises(created_at DESC);
CREATE INDEX idx_social_bookmarks_user ON social_bookmarks(user_id);
CREATE INDEX idx_social_bookmarks_post ON social_bookmarks(post_id);
CREATE INDEX idx_social_hashtags_org_bot ON social_hashtags(org_id, bot_id);
CREATE INDEX idx_social_hashtags_tag ON social_hashtags(tag);
CREATE INDEX idx_social_hashtags_popular ON social_hashtags(org_id, bot_id, post_count DESC);

View file

@ -1,34 +0,0 @@
DROP INDEX IF EXISTS idx_research_exports_status;
DROP INDEX IF EXISTS idx_research_exports_project;
DROP INDEX IF EXISTS idx_research_collaborators_user;
DROP INDEX IF EXISTS idx_research_collaborators_project;
DROP INDEX IF EXISTS idx_research_citations_style;
DROP INDEX IF EXISTS idx_research_citations_source;
DROP INDEX IF EXISTS idx_research_findings_status;
DROP INDEX IF EXISTS idx_research_findings_type;
DROP INDEX IF EXISTS idx_research_findings_project;
DROP INDEX IF EXISTS idx_research_notes_tags;
DROP INDEX IF EXISTS idx_research_notes_type;
DROP INDEX IF EXISTS idx_research_notes_source;
DROP INDEX IF EXISTS idx_research_notes_project;
DROP INDEX IF EXISTS idx_research_sources_verified;
DROP INDEX IF EXISTS idx_research_sources_type;
DROP INDEX IF EXISTS idx_research_sources_project;
DROP INDEX IF EXISTS idx_research_projects_tags;
DROP INDEX IF EXISTS idx_research_projects_status;
DROP INDEX IF EXISTS idx_research_projects_owner;
DROP INDEX IF EXISTS idx_research_projects_org_bot;
DROP TABLE IF EXISTS research_exports;
DROP TABLE IF EXISTS research_collaborators;
DROP TABLE IF EXISTS research_citations;
DROP TABLE IF EXISTS research_findings;
DROP TABLE IF EXISTS research_notes;
DROP TABLE IF EXISTS research_sources;
DROP TABLE IF EXISTS research_projects;

View file

@ -1,118 +0,0 @@
CREATE TABLE research_projects (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
status VARCHAR(50) NOT NULL DEFAULT 'active',
owner_id UUID NOT NULL,
tags TEXT[] NOT NULL DEFAULT '{}',
settings JSONB NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE research_sources (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
project_id UUID NOT NULL REFERENCES research_projects(id) ON DELETE CASCADE,
source_type VARCHAR(50) NOT NULL,
name VARCHAR(500) NOT NULL,
url TEXT,
content TEXT,
summary TEXT,
metadata JSONB NOT NULL DEFAULT '{}',
credibility_score INTEGER,
is_verified BOOLEAN NOT NULL DEFAULT FALSE,
added_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE research_notes (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
project_id UUID NOT NULL REFERENCES research_projects(id) ON DELETE CASCADE,
source_id UUID REFERENCES research_sources(id) ON DELETE SET NULL,
title VARCHAR(500),
content TEXT NOT NULL,
note_type VARCHAR(50) NOT NULL DEFAULT 'general',
tags TEXT[] NOT NULL DEFAULT '{}',
highlight_text TEXT,
highlight_position JSONB,
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE research_findings (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
project_id UUID NOT NULL REFERENCES research_projects(id) ON DELETE CASCADE,
title VARCHAR(500) NOT NULL,
content TEXT NOT NULL,
finding_type VARCHAR(50) NOT NULL DEFAULT 'insight',
confidence_level VARCHAR(50),
supporting_sources JSONB NOT NULL DEFAULT '[]',
related_findings JSONB NOT NULL DEFAULT '[]',
status VARCHAR(50) NOT NULL DEFAULT 'draft',
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE research_citations (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
source_id UUID NOT NULL REFERENCES research_sources(id) ON DELETE CASCADE,
citation_style VARCHAR(50) NOT NULL DEFAULT 'apa',
formatted_citation TEXT NOT NULL,
bibtex TEXT,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE research_collaborators (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
project_id UUID NOT NULL REFERENCES research_projects(id) ON DELETE CASCADE,
user_id UUID NOT NULL,
role VARCHAR(50) NOT NULL DEFAULT 'viewer',
invited_by UUID,
joined_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(project_id, user_id)
);
CREATE TABLE research_exports (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
project_id UUID NOT NULL REFERENCES research_projects(id) ON DELETE CASCADE,
export_type VARCHAR(50) NOT NULL,
format VARCHAR(50) NOT NULL,
file_url TEXT,
file_size INTEGER,
status VARCHAR(50) NOT NULL DEFAULT 'pending',
created_by UUID NOT NULL,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
completed_at TIMESTAMPTZ
);
CREATE INDEX idx_research_projects_org_bot ON research_projects(org_id, bot_id);
CREATE INDEX idx_research_projects_owner ON research_projects(owner_id);
CREATE INDEX idx_research_projects_status ON research_projects(status);
CREATE INDEX idx_research_projects_tags ON research_projects USING GIN(tags);
CREATE INDEX idx_research_sources_project ON research_sources(project_id);
CREATE INDEX idx_research_sources_type ON research_sources(source_type);
CREATE INDEX idx_research_sources_verified ON research_sources(is_verified) WHERE is_verified = TRUE;
CREATE INDEX idx_research_notes_project ON research_notes(project_id);
CREATE INDEX idx_research_notes_source ON research_notes(source_id) WHERE source_id IS NOT NULL;
CREATE INDEX idx_research_notes_type ON research_notes(note_type);
CREATE INDEX idx_research_notes_tags ON research_notes USING GIN(tags);
CREATE INDEX idx_research_findings_project ON research_findings(project_id);
CREATE INDEX idx_research_findings_type ON research_findings(finding_type);
CREATE INDEX idx_research_findings_status ON research_findings(status);
CREATE INDEX idx_research_citations_source ON research_citations(source_id);
CREATE INDEX idx_research_citations_style ON research_citations(citation_style);
CREATE INDEX idx_research_collaborators_project ON research_collaborators(project_id);
CREATE INDEX idx_research_collaborators_user ON research_collaborators(user_id);
CREATE INDEX idx_research_exports_project ON research_exports(project_id);
CREATE INDEX idx_research_exports_status ON research_exports(status);

View file

@ -1,13 +0,0 @@
DROP INDEX IF EXISTS idx_dashboard_filters_dashboard;
DROP INDEX IF EXISTS idx_dashboard_data_sources_dashboard;
DROP INDEX IF EXISTS idx_dashboard_data_sources_org_bot;
DROP INDEX IF EXISTS idx_dashboard_widgets_dashboard;
DROP INDEX IF EXISTS idx_dashboards_template;
DROP INDEX IF EXISTS idx_dashboards_public;
DROP INDEX IF EXISTS idx_dashboards_owner;
DROP INDEX IF EXISTS idx_dashboards_org_bot;
DROP TABLE IF EXISTS dashboard_filters;
DROP TABLE IF EXISTS dashboard_widgets;
DROP TABLE IF EXISTS dashboard_data_sources;
DROP TABLE IF EXISTS dashboards;

View file

@ -1,100 +0,0 @@
CREATE TABLE dashboards (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
owner_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
layout JSONB NOT NULL DEFAULT '{"columns": 12, "row_height": 80, "gap": 16}',
refresh_interval INTEGER,
is_public BOOLEAN NOT NULL DEFAULT FALSE,
is_template BOOLEAN NOT NULL DEFAULT FALSE,
tags TEXT[] NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE dashboard_widgets (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
dashboard_id UUID NOT NULL REFERENCES dashboards(id) ON DELETE CASCADE,
widget_type VARCHAR(50) NOT NULL,
title VARCHAR(255) NOT NULL,
position_x INTEGER NOT NULL DEFAULT 0,
position_y INTEGER NOT NULL DEFAULT 0,
width INTEGER NOT NULL DEFAULT 4,
height INTEGER NOT NULL DEFAULT 3,
config JSONB NOT NULL DEFAULT '{}',
data_query JSONB,
style JSONB NOT NULL DEFAULT '{}',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE dashboard_data_sources (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
name VARCHAR(255) NOT NULL,
description TEXT,
source_type VARCHAR(50) NOT NULL,
connection JSONB NOT NULL DEFAULT '{}',
schema_definition JSONB NOT NULL DEFAULT '{}',
refresh_schedule VARCHAR(100),
last_sync TIMESTAMPTZ,
status VARCHAR(50) NOT NULL DEFAULT 'active',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE dashboard_filters (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
dashboard_id UUID NOT NULL REFERENCES dashboards(id) ON DELETE CASCADE,
name VARCHAR(255) NOT NULL,
field VARCHAR(255) NOT NULL,
filter_type VARCHAR(50) NOT NULL,
default_value JSONB,
options JSONB NOT NULL DEFAULT '[]',
linked_widgets JSONB NOT NULL DEFAULT '[]',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE TABLE dashboard_widget_data_sources (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
widget_id UUID NOT NULL REFERENCES dashboard_widgets(id) ON DELETE CASCADE,
data_source_id UUID NOT NULL REFERENCES dashboard_data_sources(id) ON DELETE CASCADE,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
UNIQUE(widget_id, data_source_id)
);
CREATE TABLE conversational_queries (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
org_id UUID NOT NULL,
bot_id UUID NOT NULL,
dashboard_id UUID REFERENCES dashboards(id) ON DELETE SET NULL,
user_id UUID NOT NULL,
natural_language TEXT NOT NULL,
generated_query TEXT,
result_widget_config JSONB,
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE INDEX idx_dashboards_org_bot ON dashboards(org_id, bot_id);
CREATE INDEX idx_dashboards_owner ON dashboards(owner_id);
CREATE INDEX idx_dashboards_is_public ON dashboards(is_public) WHERE is_public = TRUE;
CREATE INDEX idx_dashboards_is_template ON dashboards(is_template) WHERE is_template = TRUE;
CREATE INDEX idx_dashboards_tags ON dashboards USING GIN(tags);
CREATE INDEX idx_dashboards_created ON dashboards(created_at DESC);
CREATE INDEX idx_dashboard_widgets_dashboard ON dashboard_widgets(dashboard_id);
CREATE INDEX idx_dashboard_widgets_type ON dashboard_widgets(widget_type);
CREATE INDEX idx_dashboard_data_sources_org_bot ON dashboard_data_sources(org_id, bot_id);
CREATE INDEX idx_dashboard_data_sources_type ON dashboard_data_sources(source_type);
CREATE INDEX idx_dashboard_data_sources_status ON dashboard_data_sources(status);
CREATE INDEX idx_dashboard_filters_dashboard ON dashboard_filters(dashboard_id);
CREATE INDEX idx_conversational_queries_org_bot ON conversational_queries(org_id, bot_id);
CREATE INDEX idx_conversational_queries_dashboard ON conversational_queries(dashboard_id) WHERE dashboard_id IS NOT NULL;
CREATE INDEX idx_conversational_queries_user ON conversational_queries(user_id);
CREATE INDEX idx_conversational_queries_created ON conversational_queries(created_at DESC);

View file

@ -1,84 +0,0 @@
-- Rollback extended product fields
-- Remove variant indexes
DROP INDEX IF EXISTS idx_product_variants_global_trade_number;
-- Remove variant fields
ALTER TABLE product_variants DROP COLUMN IF EXISTS global_trade_number;
ALTER TABLE product_variants DROP COLUMN IF EXISTS net_weight;
ALTER TABLE product_variants DROP COLUMN IF EXISTS gross_weight;
ALTER TABLE product_variants DROP COLUMN IF EXISTS width;
ALTER TABLE product_variants DROP COLUMN IF EXISTS height;
ALTER TABLE product_variants DROP COLUMN IF EXISTS length;
ALTER TABLE product_variants DROP COLUMN IF EXISTS color;
ALTER TABLE product_variants DROP COLUMN IF EXISTS size;
ALTER TABLE product_variants DROP COLUMN IF EXISTS images;
-- Remove product indexes
DROP INDEX IF EXISTS idx_products_tax_code;
DROP INDEX IF EXISTS idx_products_global_trade_number;
DROP INDEX IF EXISTS idx_products_brand;
DROP INDEX IF EXISTS idx_products_slug;
DROP INDEX IF EXISTS idx_products_expiration;
DROP INDEX IF EXISTS idx_products_external_id;
-- Remove SEO and search
ALTER TABLE products DROP COLUMN IF EXISTS slug;
ALTER TABLE products DROP COLUMN IF EXISTS meta_title;
ALTER TABLE products DROP COLUMN IF EXISTS meta_description;
ALTER TABLE products DROP COLUMN IF EXISTS tags;
-- Remove payment gateway integration
ALTER TABLE products DROP COLUMN IF EXISTS external_id;
ALTER TABLE products DROP COLUMN IF EXISTS external_category_id;
ALTER TABLE products DROP COLUMN IF EXISTS external_metadata;
-- Remove detailed pricing
ALTER TABLE products DROP COLUMN IF EXISTS sale_price;
ALTER TABLE products DROP COLUMN IF EXISTS sale_start;
ALTER TABLE products DROP COLUMN IF EXISTS sale_end;
ALTER TABLE products DROP COLUMN IF EXISTS shipping_cost;
ALTER TABLE products DROP COLUMN IF EXISTS profit_margin;
-- Remove advanced inventory control
ALTER TABLE products DROP COLUMN IF EXISTS warehouse_location;
ALTER TABLE products DROP COLUMN IF EXISTS batch_number;
ALTER TABLE products DROP COLUMN IF EXISTS expiration_date;
ALTER TABLE products DROP COLUMN IF EXISTS manufacture_date;
ALTER TABLE products DROP COLUMN IF EXISTS min_stock;
ALTER TABLE products DROP COLUMN IF EXISTS max_stock;
ALTER TABLE products DROP COLUMN IF EXISTS reorder_point;
-- Remove marketplace and e-commerce fields
ALTER TABLE products DROP COLUMN IF EXISTS brand;
ALTER TABLE products DROP COLUMN IF EXISTS model;
ALTER TABLE products DROP COLUMN IF EXISTS color;
ALTER TABLE products DROP COLUMN IF EXISTS size;
ALTER TABLE products DROP COLUMN IF EXISTS material;
ALTER TABLE products DROP COLUMN IF EXISTS gender;
-- Remove tax rates by type
ALTER TABLE products DROP COLUMN IF EXISTS sales_tax_code;
ALTER TABLE products DROP COLUMN IF EXISTS sales_tax_rate;
ALTER TABLE products DROP COLUMN IF EXISTS excise_tax_code;
ALTER TABLE products DROP COLUMN IF EXISTS excise_tax_rate;
ALTER TABLE products DROP COLUMN IF EXISTS vat_code;
ALTER TABLE products DROP COLUMN IF EXISTS vat_rate;
ALTER TABLE products DROP COLUMN IF EXISTS service_tax_code;
ALTER TABLE products DROP COLUMN IF EXISTS service_tax_rate;
-- Remove detailed dimensions
ALTER TABLE products DROP COLUMN IF EXISTS net_weight;
ALTER TABLE products DROP COLUMN IF EXISTS gross_weight;
ALTER TABLE products DROP COLUMN IF EXISTS width;
ALTER TABLE products DROP COLUMN IF EXISTS height;
ALTER TABLE products DROP COLUMN IF EXISTS length;
ALTER TABLE products DROP COLUMN IF EXISTS package_count;
-- Remove tax and fiscal identification fields
ALTER TABLE products DROP COLUMN IF EXISTS tax_code;
ALTER TABLE products DROP COLUMN IF EXISTS tax_class;
ALTER TABLE products DROP COLUMN IF EXISTS fiscal_code;
ALTER TABLE products DROP COLUMN IF EXISTS origin_code;
ALTER TABLE products DROP COLUMN IF EXISTS global_trade_number;
ALTER TABLE products DROP COLUMN IF EXISTS tax_unit_code;

View file

@ -1,83 +0,0 @@
-- Extended product fields for e-commerce and payment integrations
-- Tax and fiscal identification fields
ALTER TABLE products ADD COLUMN IF NOT EXISTS tax_code VARCHAR(10);
ALTER TABLE products ADD COLUMN IF NOT EXISTS tax_class VARCHAR(50);
ALTER TABLE products ADD COLUMN IF NOT EXISTS fiscal_code VARCHAR(10);
ALTER TABLE products ADD COLUMN IF NOT EXISTS origin_code INTEGER DEFAULT 0;
ALTER TABLE products ADD COLUMN IF NOT EXISTS global_trade_number VARCHAR(14);
ALTER TABLE products ADD COLUMN IF NOT EXISTS tax_unit_code VARCHAR(14);
-- Detailed dimensions (for shipping calculation)
ALTER TABLE products ADD COLUMN IF NOT EXISTS net_weight DECIMAL(10,3);
ALTER TABLE products ADD COLUMN IF NOT EXISTS gross_weight DECIMAL(10,3);
ALTER TABLE products ADD COLUMN IF NOT EXISTS width DECIMAL(10,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS height DECIMAL(10,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS length DECIMAL(10,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS package_count INTEGER DEFAULT 1;
-- Tax rates by type
ALTER TABLE products ADD COLUMN IF NOT EXISTS sales_tax_code VARCHAR(3);
ALTER TABLE products ADD COLUMN IF NOT EXISTS sales_tax_rate DECIMAL(5,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS excise_tax_code VARCHAR(2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS excise_tax_rate DECIMAL(5,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS vat_code VARCHAR(2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS vat_rate DECIMAL(5,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS service_tax_code VARCHAR(2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS service_tax_rate DECIMAL(5,2);
-- Marketplace and e-commerce fields
ALTER TABLE products ADD COLUMN IF NOT EXISTS brand VARCHAR(100);
ALTER TABLE products ADD COLUMN IF NOT EXISTS model VARCHAR(100);
ALTER TABLE products ADD COLUMN IF NOT EXISTS color VARCHAR(50);
ALTER TABLE products ADD COLUMN IF NOT EXISTS size VARCHAR(20);
ALTER TABLE products ADD COLUMN IF NOT EXISTS material VARCHAR(100);
ALTER TABLE products ADD COLUMN IF NOT EXISTS gender VARCHAR(20);
-- Advanced inventory control
ALTER TABLE products ADD COLUMN IF NOT EXISTS warehouse_location VARCHAR(100);
ALTER TABLE products ADD COLUMN IF NOT EXISTS batch_number VARCHAR(50);
ALTER TABLE products ADD COLUMN IF NOT EXISTS expiration_date DATE;
ALTER TABLE products ADD COLUMN IF NOT EXISTS manufacture_date DATE;
ALTER TABLE products ADD COLUMN IF NOT EXISTS min_stock INTEGER DEFAULT 0;
ALTER TABLE products ADD COLUMN IF NOT EXISTS max_stock INTEGER;
ALTER TABLE products ADD COLUMN IF NOT EXISTS reorder_point INTEGER;
-- Detailed pricing
ALTER TABLE products ADD COLUMN IF NOT EXISTS sale_price DECIMAL(15,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS sale_start TIMESTAMPTZ;
ALTER TABLE products ADD COLUMN IF NOT EXISTS sale_end TIMESTAMPTZ;
ALTER TABLE products ADD COLUMN IF NOT EXISTS shipping_cost DECIMAL(15,2);
ALTER TABLE products ADD COLUMN IF NOT EXISTS profit_margin DECIMAL(5,2);
-- Payment gateway integration
ALTER TABLE products ADD COLUMN IF NOT EXISTS external_id VARCHAR(100);
ALTER TABLE products ADD COLUMN IF NOT EXISTS external_category_id VARCHAR(100);
ALTER TABLE products ADD COLUMN IF NOT EXISTS external_metadata JSONB DEFAULT '{}';
-- SEO and search
ALTER TABLE products ADD COLUMN IF NOT EXISTS slug VARCHAR(255);
ALTER TABLE products ADD COLUMN IF NOT EXISTS meta_title VARCHAR(255);
ALTER TABLE products ADD COLUMN IF NOT EXISTS meta_description TEXT;
ALTER TABLE products ADD COLUMN IF NOT EXISTS tags TEXT[];
-- Indexes for new fields
CREATE INDEX IF NOT EXISTS idx_products_tax_code ON products(tax_code);
CREATE INDEX IF NOT EXISTS idx_products_global_trade_number ON products(global_trade_number);
CREATE INDEX IF NOT EXISTS idx_products_brand ON products(brand);
CREATE INDEX IF NOT EXISTS idx_products_slug ON products(slug);
CREATE INDEX IF NOT EXISTS idx_products_expiration ON products(expiration_date);
CREATE INDEX IF NOT EXISTS idx_products_external_id ON products(external_id);
-- Add similar fields to product variants
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS global_trade_number VARCHAR(14);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS net_weight DECIMAL(10,3);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS gross_weight DECIMAL(10,3);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS width DECIMAL(10,2);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS height DECIMAL(10,2);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS length DECIMAL(10,2);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS color VARCHAR(50);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS size VARCHAR(20);
ALTER TABLE product_variants ADD COLUMN IF NOT EXISTS images JSONB DEFAULT '[]';
CREATE INDEX IF NOT EXISTS idx_product_variants_global_trade_number ON product_variants(global_trade_number);

View file

@ -1,12 +0,0 @@
DROP INDEX IF EXISTS idx_consent_history_consent;
DROP INDEX IF EXISTS idx_consent_history_created;
DROP INDEX IF EXISTS idx_cookie_consents_user;
DROP INDEX IF EXISTS idx_cookie_consents_session;
DROP INDEX IF EXISTS idx_cookie_consents_org_bot;
DROP INDEX IF EXISTS idx_legal_documents_org_bot;
DROP INDEX IF EXISTS idx_legal_documents_slug;
DROP INDEX IF EXISTS idx_legal_documents_type;
DROP TABLE IF EXISTS consent_history;
DROP TABLE IF EXISTS cookie_consents;
DROP TABLE IF EXISTS legal_documents;

Some files were not shown because too many files have changed in this diff Show more