@botpress/api 0.15.7 → 0.15.9
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.
- package/dist/gen/state.d.ts +68 -0
- package/dist/index.d.ts +5 -3
- package/dist/index.js +292 -175
- package/package.json +2 -2
- package/src/gen/metadata.json +1 -1
- package/src/gen/openapi.json +1 -1
- package/src/gen/state.ts +115 -34
- package/src/index.ts +1 -0
package/dist/gen/state.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import * as opapi from "@bpinternal/opapi";
|
|
2
|
+
export type State = opapi.State<"Bot" | "Integration" | "Workspace" | "WorkspaceMember" | "Account" | "Usage" | "Issue" | "IssueEvent" | "User" | "Conversation" | "Event" | "Message" | "State" | "File", never, "user" | "conversation" | "event" | "message" | "file" | "state" | "hub" | "action" | "bot" | "integration" | "workspace" | "workspaceMember" | "account" | "usage" | "quotas" | "helper">;
|
|
1
3
|
export declare const state: {
|
|
2
4
|
operations: {
|
|
3
5
|
createConversation: {
|
|
@@ -1402,6 +1404,51 @@ export declare const state: {
|
|
|
1402
1404
|
};
|
|
1403
1405
|
parameters: {};
|
|
1404
1406
|
};
|
|
1407
|
+
runVrl: {
|
|
1408
|
+
name: string;
|
|
1409
|
+
description: string;
|
|
1410
|
+
method: "post";
|
|
1411
|
+
path: string;
|
|
1412
|
+
section: "helper";
|
|
1413
|
+
requestBody: {
|
|
1414
|
+
description: string;
|
|
1415
|
+
schema: {
|
|
1416
|
+
type: "object";
|
|
1417
|
+
properties: {
|
|
1418
|
+
data: {
|
|
1419
|
+
type: "object";
|
|
1420
|
+
additionalProperties: true;
|
|
1421
|
+
};
|
|
1422
|
+
script: {
|
|
1423
|
+
type: "string";
|
|
1424
|
+
};
|
|
1425
|
+
};
|
|
1426
|
+
required: string[];
|
|
1427
|
+
title: string;
|
|
1428
|
+
additionalProperties: false;
|
|
1429
|
+
};
|
|
1430
|
+
};
|
|
1431
|
+
response: {
|
|
1432
|
+
description: string;
|
|
1433
|
+
schema: {
|
|
1434
|
+
type: "object";
|
|
1435
|
+
properties: {
|
|
1436
|
+
data: {
|
|
1437
|
+
type: "object";
|
|
1438
|
+
additionalProperties: true;
|
|
1439
|
+
};
|
|
1440
|
+
result: {
|
|
1441
|
+
type: "object";
|
|
1442
|
+
additionalProperties: true;
|
|
1443
|
+
};
|
|
1444
|
+
};
|
|
1445
|
+
required: string[];
|
|
1446
|
+
title: string;
|
|
1447
|
+
additionalProperties: false;
|
|
1448
|
+
};
|
|
1449
|
+
};
|
|
1450
|
+
parameters: {};
|
|
1451
|
+
};
|
|
1405
1452
|
getAccount: {
|
|
1406
1453
|
name: string;
|
|
1407
1454
|
description: string;
|
|
@@ -2226,6 +2273,10 @@ export declare const state: {
|
|
|
2226
2273
|
};
|
|
2227
2274
|
description: string;
|
|
2228
2275
|
};
|
|
2276
|
+
alwaysAlive: {
|
|
2277
|
+
type: "boolean";
|
|
2278
|
+
description: string;
|
|
2279
|
+
};
|
|
2229
2280
|
};
|
|
2230
2281
|
title: string;
|
|
2231
2282
|
additionalProperties: false;
|
|
@@ -5374,6 +5425,7 @@ export declare const state: {
|
|
|
5374
5425
|
patchStateBody: true;
|
|
5375
5426
|
callActionBody: true;
|
|
5376
5427
|
configureIntegrationBody: true;
|
|
5428
|
+
runVrlBody: true;
|
|
5377
5429
|
createPersonalAccessTokenBody: true;
|
|
5378
5430
|
createBotBody: true;
|
|
5379
5431
|
updateBotBody: true;
|
|
@@ -5422,6 +5474,7 @@ export declare const state: {
|
|
|
5422
5474
|
patchStateResponse: true;
|
|
5423
5475
|
callActionResponse: true;
|
|
5424
5476
|
configureIntegrationResponse: true;
|
|
5477
|
+
runVrlResponse: true;
|
|
5425
5478
|
getAccountResponse: true;
|
|
5426
5479
|
listPersonalAccessTokensResponse: true;
|
|
5427
5480
|
createPersonalAccessTokenResponse: true;
|
|
@@ -5809,6 +5862,15 @@ export declare const state: {
|
|
|
5809
5862
|
type: "string";
|
|
5810
5863
|
description: string;
|
|
5811
5864
|
};
|
|
5865
|
+
alwaysAlive: {
|
|
5866
|
+
type: "boolean";
|
|
5867
|
+
description: string;
|
|
5868
|
+
};
|
|
5869
|
+
status: {
|
|
5870
|
+
type: "string";
|
|
5871
|
+
enum: string[];
|
|
5872
|
+
description: string;
|
|
5873
|
+
};
|
|
5812
5874
|
medias: {
|
|
5813
5875
|
type: "array";
|
|
5814
5876
|
items: {
|
|
@@ -6779,6 +6841,12 @@ export declare const state: {
|
|
|
6779
6841
|
name: "quotas";
|
|
6780
6842
|
operations: string[];
|
|
6781
6843
|
schema?: undefined;
|
|
6844
|
+
} | {
|
|
6845
|
+
title: string;
|
|
6846
|
+
description: string;
|
|
6847
|
+
name: "helper";
|
|
6848
|
+
operations: string[];
|
|
6849
|
+
schema?: undefined;
|
|
6782
6850
|
})[];
|
|
6783
6851
|
options: {
|
|
6784
6852
|
allowUnions: false;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
|
+
export * from './gen/state';
|
|
1
2
|
export declare const api: {
|
|
2
|
-
getState: () => import("@bpinternal/opapi").State<"Bot" | "Integration" | "Workspace" | "WorkspaceMember" | "Account" | "Usage" | "Issue" | "IssueEvent" | "User" | "Conversation" | "Event" | "Message" | "State" | "File", "x-workspace-id", "user" | "conversation" | "event" | "message" | "file" | "state" | "hub" | "action" | "bot" | "integration" | "workspace" | "workspaceMember" | "account" | "usage" | "quotas">;
|
|
3
3
|
getModelRef: (name: "Bot" | "Integration" | "Workspace" | "WorkspaceMember" | "Account" | "Usage" | "Issue" | "IssueEvent" | "User" | "Conversation" | "Event" | "Message" | "State" | "File") => import("@bpinternal/opapi").OpenApiZodAny;
|
|
4
|
-
addOperation: <Path extends string>(operationProps: import("@bpinternal/opapi").Operation<"x-workspace-id", "user" | "conversation" | "event" | "message" | "file" | "state" | "hub" | "action" | "bot" | "integration" | "workspace" | "workspaceMember" | "account" | "usage" | "quotas", Path, "zod-schema">) => void;
|
|
4
|
+
addOperation: <Path extends string>(operationProps: import("@bpinternal/opapi").Operation<"x-workspace-id", "user" | "conversation" | "event" | "message" | "file" | "state" | "hub" | "action" | "bot" | "integration" | "workspace" | "workspaceMember" | "account" | "usage" | "quotas" | "helper", Path, "zod-schema">) => void;
|
|
5
5
|
exportClient: (dir: string | undefined, openapiGeneratorEndpoint: string, postProcessors?: import("@bpinternal/opapi").OpenApiPostProcessors | undefined) => Promise<void>;
|
|
6
6
|
exportTypesBySection: (dir?: string | undefined) => Promise<void>;
|
|
7
7
|
exportServer: (dir: string | undefined, useExpressTypes: boolean) => Promise<void>;
|
|
8
8
|
exportOpenapi: (dir?: string | undefined) => void;
|
|
9
|
-
exportState: (dir?: string | undefined
|
|
9
|
+
exportState: (dir?: string | undefined, opts?: Partial<{
|
|
10
|
+
importPath: string;
|
|
11
|
+
}> | undefined) => void;
|
|
10
12
|
exportErrors: (dir?: string | undefined) => void;
|
|
11
13
|
};
|