@botpress/cli 4.20.3 → 4.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/.turbo/turbo-build.log +12 -12
  2. package/dist/api/client.d.ts +1 -0
  3. package/dist/api/client.js +16 -0
  4. package/dist/api/client.js.map +2 -2
  5. package/dist/command-implementations/deploy-command.js +1 -1
  6. package/dist/command-implementations/deploy-command.js.map +2 -2
  7. package/dist/command-implementations/dev-command.js +1 -1
  8. package/dist/command-implementations/dev-command.js.map +2 -2
  9. package/dist/command-implementations/project-command.d.ts +11 -1
  10. package/dist/command-implementations/project-command.js +129 -8
  11. package/dist/command-implementations/project-command.js.map +3 -3
  12. package/dist/consts.d.ts +2 -0
  13. package/dist/consts.js +12 -6
  14. package/dist/consts.js.map +2 -2
  15. package/dist/logger/base-logger.d.ts +1 -1
  16. package/dist/logger/base-logger.js +3 -1
  17. package/dist/logger/base-logger.js.map +2 -2
  18. package/dist/utils/index.d.ts +1 -0
  19. package/dist/utils/index.js +5 -2
  20. package/dist/utils/index.js.map +2 -2
  21. package/dist/utils/vrl-utils.d.ts +4 -0
  22. package/dist/utils/vrl-utils.js +47 -0
  23. package/dist/utils/vrl-utils.js.map +7 -0
  24. package/dist/worker/config.d.ts +2 -2
  25. package/package.json +2 -1
  26. package/templates/empty-bot/tsconfig.json +0 -1
  27. package/templates/empty-integration/tsconfig.json +0 -1
  28. package/templates/empty-plugin/tsconfig.json +0 -1
  29. package/templates/hello-world/tsconfig.json +0 -1
  30. package/templates/webhook-message/tsconfig.json +0 -1
  31. package/templates/empty-bot/.botpress/implementation/index.ts +0 -62
  32. package/templates/empty-bot/.botpress/implementation/plugins/index.ts +0 -11
  33. package/templates/empty-bot/.botpress/implementation/typings/actions/index.ts +0 -6
  34. package/templates/empty-bot/.botpress/implementation/typings/events/index.ts +0 -6
  35. package/templates/empty-bot/.botpress/implementation/typings/index.ts +0 -26
  36. package/templates/empty-bot/.botpress/implementation/typings/integrations/index.ts +0 -6
  37. package/templates/empty-bot/.botpress/implementation/typings/states/index.ts +0 -6
  38. package/templates/empty-bot/.botpress/implementation/typings/tables/index.ts +0 -6
  39. package/templates/empty-bot/.botpress/implementation/typings/workflows/index.ts +0 -6
  40. package/templates/empty-bot/.botpress/index.ts +0 -5
  41. package/templates/empty-integration/.botpress/implementation/index.ts +0 -57
  42. package/templates/empty-integration/.botpress/implementation/typings/actions/index.ts +0 -6
  43. package/templates/empty-integration/.botpress/implementation/typings/channels/index.ts +0 -6
  44. package/templates/empty-integration/.botpress/implementation/typings/configuration/index.ts +0 -2
  45. package/templates/empty-integration/.botpress/implementation/typings/configurations/index.ts +0 -6
  46. package/templates/empty-integration/.botpress/implementation/typings/entities/index.ts +0 -6
  47. package/templates/empty-integration/.botpress/implementation/typings/events/index.ts +0 -6
  48. package/templates/empty-integration/.botpress/implementation/typings/index.ts +0 -31
  49. package/templates/empty-integration/.botpress/implementation/typings/states/index.ts +0 -6
  50. package/templates/empty-integration/.botpress/index.ts +0 -2
  51. package/templates/empty-integration/.botpress/secrets/index.ts +0 -6
  52. package/templates/empty-plugin/.botpress/implementation/index.ts +0 -67
  53. package/templates/empty-plugin/.botpress/implementation/typings/actions/index.ts +0 -6
  54. package/templates/empty-plugin/.botpress/implementation/typings/configuration/index.ts +0 -2
  55. package/templates/empty-plugin/.botpress/implementation/typings/events/index.ts +0 -6
  56. package/templates/empty-plugin/.botpress/implementation/typings/index.ts +0 -34
  57. package/templates/empty-plugin/.botpress/implementation/typings/integrations/index.ts +0 -6
  58. package/templates/empty-plugin/.botpress/implementation/typings/interfaces/index.ts +0 -6
  59. package/templates/empty-plugin/.botpress/implementation/typings/states/index.ts +0 -6
  60. package/templates/empty-plugin/.botpress/implementation/typings/tables/index.ts +0 -6
  61. package/templates/empty-plugin/.botpress/implementation/typings/workflows/index.ts +0 -6
  62. package/templates/empty-plugin/.botpress/index.ts +0 -1
  63. package/templates/hello-world/.botpress/implementation/index.ts +0 -57
  64. package/templates/hello-world/.botpress/implementation/typings/actions/helloWorld/index.ts +0 -12
  65. package/templates/hello-world/.botpress/implementation/typings/actions/helloWorld/input.ts +0 -5
  66. package/templates/hello-world/.botpress/implementation/typings/actions/helloWorld/output.ts +0 -5
  67. package/templates/hello-world/.botpress/implementation/typings/actions/index.ts +0 -9
  68. package/templates/hello-world/.botpress/implementation/typings/channels/index.ts +0 -6
  69. package/templates/hello-world/.botpress/implementation/typings/configuration/index.ts +0 -2
  70. package/templates/hello-world/.botpress/implementation/typings/configurations/index.ts +0 -6
  71. package/templates/hello-world/.botpress/implementation/typings/entities/index.ts +0 -6
  72. package/templates/hello-world/.botpress/implementation/typings/events/index.ts +0 -6
  73. package/templates/hello-world/.botpress/implementation/typings/index.ts +0 -31
  74. package/templates/hello-world/.botpress/implementation/typings/states/index.ts +0 -6
  75. package/templates/hello-world/.botpress/index.ts +0 -2
  76. package/templates/hello-world/.botpress/secrets/index.ts +0 -6
  77. package/templates/webhook-message/.botpress/implementation/index.ts +0 -57
  78. package/templates/webhook-message/.botpress/implementation/typings/actions/index.ts +0 -6
  79. package/templates/webhook-message/.botpress/implementation/typings/channels/index.ts +0 -9
  80. package/templates/webhook-message/.botpress/implementation/typings/channels/webhook/index.ts +0 -12
  81. package/templates/webhook-message/.botpress/implementation/typings/channels/webhook/messages/index.ts +0 -9
  82. package/templates/webhook-message/.botpress/implementation/typings/channels/webhook/messages/text.ts +0 -5
  83. package/templates/webhook-message/.botpress/implementation/typings/configuration/index.ts +0 -8
  84. package/templates/webhook-message/.botpress/implementation/typings/configurations/index.ts +0 -6
  85. package/templates/webhook-message/.botpress/implementation/typings/entities/index.ts +0 -6
  86. package/templates/webhook-message/.botpress/implementation/typings/events/index.ts +0 -6
  87. package/templates/webhook-message/.botpress/implementation/typings/index.ts +0 -31
  88. package/templates/webhook-message/.botpress/implementation/typings/states/index.ts +0 -6
  89. package/templates/webhook-message/.botpress/index.ts +0 -2
  90. package/templates/webhook-message/.botpress/secrets/index.ts +0 -6
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Channels = {
6
- }
@@ -1,2 +0,0 @@
1
- /** Default Configuration of the Integration */
2
- export type Configuration = Record<string, never>;
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Configurations = {
6
- }
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Entities = {
6
- }
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Events = {
6
- }
@@ -1,31 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- import * as configuration from "./configuration/index"
6
- import * as configurations from "./configurations/index"
7
- import * as actions from "./actions/index"
8
- import * as channels from "./channels/index"
9
- import * as events from "./events/index"
10
- import * as states from "./states/index"
11
- import * as entities from "./entities/index"
12
- export * as configuration from "./configuration/index"
13
- export * as configurations from "./configurations/index"
14
- export * as actions from "./actions/index"
15
- export * as channels from "./channels/index"
16
- export * as events from "./events/index"
17
- export * as states from "./states/index"
18
- export * as entities from "./entities/index"
19
-
20
- export type TIntegration = {
21
- name: "hello-world"
22
- version: "0.1.0"
23
- user: { "tags": {}, "creation": { "enabled": false, "requiredTags": [] } }
24
- configuration: configuration.Configuration
25
- configurations: configurations.Configurations
26
- actions: actions.Actions
27
- channels: channels.Channels
28
- events: events.Events
29
- states: states.States
30
- entities: entities.Entities
31
- }
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type States = {
6
- }
@@ -1,2 +0,0 @@
1
- export * from './implementation'
2
- export * from './secrets'
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
- class Secrets {
5
- }
6
- export const secrets = new Secrets()
@@ -1,57 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- import * as sdk from "@botpress/sdk"
6
- import * as typings from "./typings/index"
7
- export * from "./typings/index"
8
-
9
- type TIntegration = sdk.DefaultIntegration<typings.TIntegration>
10
-
11
- export type IntegrationProps = sdk.IntegrationProps<TIntegration>
12
-
13
- export class Integration extends sdk.Integration<TIntegration> {}
14
-
15
- export type Client = sdk.IntegrationSpecificClient<TIntegration>
16
-
17
- // extra types
18
-
19
- type Cast<X, Y> = X extends Y ? X : Y
20
- type ValueOf<T> = T[keyof T]
21
- type AsyncFunction = (...args: any[]) => Promise<any>
22
-
23
- export type HandlerProps = Parameters<IntegrationProps['handler']>[0]
24
-
25
- export type ActionProps = {
26
- [K in keyof IntegrationProps['actions']]: Parameters<IntegrationProps['actions'][K]>[0]
27
- }
28
- export type AnyActionProps = ValueOf<ActionProps>
29
-
30
- export type MessageProps = {
31
- [TChannel in keyof IntegrationProps['channels']]: {
32
- [TMessage in keyof IntegrationProps['channels'][TChannel]['messages']]: Parameters<
33
- IntegrationProps['channels'][TChannel]['messages'][TMessage]
34
- >[0]
35
- }
36
- }
37
- export type AnyMessageProps = ValueOf<ValueOf<MessageProps>>
38
-
39
- export type Context = HandlerProps['ctx']
40
- export type Logger = HandlerProps['logger']
41
-
42
- export type AckFunctions = {
43
- [TChannel in keyof MessageProps]: {
44
- [TMessage in keyof MessageProps[TChannel]]: Cast<MessageProps[TChannel][TMessage], AnyMessageProps>['ack']
45
- }
46
- }
47
- export type AnyAckFunction = ValueOf<ValueOf<AckFunctions>>
48
-
49
- export type ClientOperation = ValueOf<{
50
- [K in keyof Client as Client[K] extends AsyncFunction ? K : never]: K
51
- }>
52
- export type ClientRequests = {
53
- [K in ClientOperation]: Parameters<Client[K]>[0]
54
- }
55
- export type ClientResponses = {
56
- [K in ClientOperation]: Awaited<ReturnType<Client[K]>>
57
- }
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Actions = {
6
- }
@@ -1,9 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
- import * as webhook from "./webhook/index";
5
- export * as webhook from "./webhook/index";
6
-
7
- export type Channels = {
8
- "webhook": webhook.Webhook;
9
- }
@@ -1,12 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- import { Messages } from './messages/index'
6
- export * from './messages/index'
7
-
8
- export type Webhook = {
9
- messages: Messages
10
- message: { "tags": {} }
11
- conversation: { "tags": { "id": { "title": "Conversation ID", "description": "The ID of the conversation" } }, "creation": { "enabled": false, "requiredTags": [] } }
12
- }
@@ -1,9 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
- import * as text from "./text";
5
- export * as text from "./text";
6
-
7
- export type Messages = {
8
- "text": text.Text;
9
- }
@@ -1,5 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Text = { text: string };
@@ -1,8 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Configuration = {
6
- /** The url to post the bot answers to. */
7
- webhookUrl: string;
8
- };
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Configurations = {
6
- }
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Entities = {
6
- }
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type Events = {
6
- }
@@ -1,31 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- import * as configuration from "./configuration/index"
6
- import * as configurations from "./configurations/index"
7
- import * as actions from "./actions/index"
8
- import * as channels from "./channels/index"
9
- import * as events from "./events/index"
10
- import * as states from "./states/index"
11
- import * as entities from "./entities/index"
12
- export * as configuration from "./configuration/index"
13
- export * as configurations from "./configurations/index"
14
- export * as actions from "./actions/index"
15
- export * as channels from "./channels/index"
16
- export * as events from "./events/index"
17
- export * as states from "./states/index"
18
- export * as entities from "./entities/index"
19
-
20
- export type TIntegration = {
21
- name: "webhook-message"
22
- version: "0.1.0"
23
- user: { "tags": { "id": { "title": "User ID", "description": "The ID of the user" } }, "creation": { "enabled": false, "requiredTags": [] } }
24
- configuration: configuration.Configuration
25
- configurations: configurations.Configurations
26
- actions: actions.Actions
27
- channels: channels.Channels
28
- events: events.Events
29
- states: states.States
30
- entities: entities.Entities
31
- }
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
-
5
- export type States = {
6
- }
@@ -1,2 +0,0 @@
1
- export * from './implementation'
2
- export * from './secrets'
@@ -1,6 +0,0 @@
1
- /* eslint-disable */
2
- /* tslint:disable */
3
- // This file is generated. Do not edit it manually.
4
- class Secrets {
5
- }
6
- export const secrets = new Secrets()