@botpress/api 0.8.0 → 0.10.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.
@@ -2010,7 +2010,7 @@ export declare const state: {
2010
2010
  properties: {
2011
2011
  targetWorkspaceId: {
2012
2012
  type: "string";
2013
- format: string;
2013
+ minLength: number;
2014
2014
  description: string;
2015
2015
  };
2016
2016
  };
@@ -2309,6 +2309,167 @@ export declare const state: {
2309
2309
  };
2310
2310
  };
2311
2311
  };
2312
+ listBotIssues: {
2313
+ name: string;
2314
+ description: string;
2315
+ method: "get";
2316
+ path: string;
2317
+ section: "bot";
2318
+ parameters: {
2319
+ id: {
2320
+ type: "string";
2321
+ description: string;
2322
+ in: "path";
2323
+ };
2324
+ nextToken: {
2325
+ in: "query";
2326
+ description: string;
2327
+ type: "string";
2328
+ };
2329
+ };
2330
+ response: {
2331
+ description: string;
2332
+ schema: {
2333
+ type: "object";
2334
+ properties: {
2335
+ issues: {
2336
+ type: "array";
2337
+ items: {
2338
+ type: "object";
2339
+ properties: {
2340
+ id: {
2341
+ type: "string";
2342
+ };
2343
+ code: {
2344
+ type: "string";
2345
+ };
2346
+ createdAt: {
2347
+ type: "string";
2348
+ format: string;
2349
+ };
2350
+ lastSeenAt: {
2351
+ type: "string";
2352
+ format: string;
2353
+ };
2354
+ title: {
2355
+ type: "string";
2356
+ };
2357
+ description: {
2358
+ type: "string";
2359
+ };
2360
+ groupedData: {
2361
+ type: "object";
2362
+ properties: {};
2363
+ };
2364
+ eventsCount: {
2365
+ type: "number";
2366
+ };
2367
+ category: {
2368
+ type: "string";
2369
+ enum: string[];
2370
+ };
2371
+ resolutionLink: {
2372
+ type: "string";
2373
+ nullable: true;
2374
+ };
2375
+ };
2376
+ required: string[];
2377
+ };
2378
+ };
2379
+ meta: {
2380
+ type: "object";
2381
+ properties: {
2382
+ nextToken: {
2383
+ type: "string";
2384
+ description: string;
2385
+ };
2386
+ };
2387
+ additionalProperties: false;
2388
+ };
2389
+ };
2390
+ required: string[];
2391
+ title: string;
2392
+ additionalProperties: false;
2393
+ };
2394
+ };
2395
+ };
2396
+ deleteBotIssue: {
2397
+ name: string;
2398
+ description: string;
2399
+ method: "delete";
2400
+ path: string;
2401
+ section: "bot";
2402
+ parameters: {
2403
+ id: {
2404
+ type: "string";
2405
+ description: string;
2406
+ in: "path";
2407
+ };
2408
+ issueId: {
2409
+ in: "path";
2410
+ description: string;
2411
+ type: "string";
2412
+ };
2413
+ };
2414
+ response: {
2415
+ description: string;
2416
+ schema: {
2417
+ type: "object";
2418
+ title: string;
2419
+ additionalProperties: false;
2420
+ };
2421
+ };
2422
+ };
2423
+ listBotIssueEvents: {
2424
+ name: string;
2425
+ description: string;
2426
+ method: "get";
2427
+ path: string;
2428
+ section: "bot";
2429
+ parameters: {
2430
+ id: {
2431
+ type: "string";
2432
+ description: string;
2433
+ in: "path";
2434
+ };
2435
+ issueId: {
2436
+ in: "path";
2437
+ description: string;
2438
+ type: "string";
2439
+ };
2440
+ };
2441
+ response: {
2442
+ description: string;
2443
+ schema: {
2444
+ type: "object";
2445
+ properties: {
2446
+ issueEvents: {
2447
+ type: "array";
2448
+ items: {
2449
+ type: "object";
2450
+ properties: {
2451
+ id: {
2452
+ type: "string";
2453
+ };
2454
+ createdAt: {
2455
+ type: "string";
2456
+ format: string;
2457
+ };
2458
+ data: {
2459
+ type: "object";
2460
+ properties: {};
2461
+ };
2462
+ };
2463
+ required: string[];
2464
+ };
2465
+ };
2466
+ };
2467
+ required: string[];
2468
+ title: string;
2469
+ additionalProperties: false;
2470
+ };
2471
+ };
2472
+ };
2312
2473
  createWorkspace: {
2313
2474
  name: string;
2314
2475
  description: string;
@@ -2874,7 +3035,6 @@ export declare const state: {
2874
3035
  properties: {
2875
3036
  id: {
2876
3037
  type: "string";
2877
- format: string;
2878
3038
  };
2879
3039
  recordedAt: {
2880
3040
  type: "string";
@@ -2891,7 +3051,6 @@ export declare const state: {
2891
3051
  };
2892
3052
  resourceId: {
2893
3053
  type: "string";
2894
- format: string;
2895
3054
  nullable: true;
2896
3055
  };
2897
3056
  resourceName: {
@@ -4414,6 +4573,9 @@ export declare const state: {
4414
4573
  getBotLogsResponse: true;
4415
4574
  getBotWebchatResponse: true;
4416
4575
  getBotAnalyticsResponse: true;
4576
+ listBotIssuesResponse: true;
4577
+ deleteBotIssueResponse: true;
4578
+ listBotIssueEventsResponse: true;
4417
4579
  createWorkspaceResponse: true;
4418
4580
  getWorkspaceResponse: true;
4419
4581
  listWorkspaceUsagesResponse: true;
@@ -4451,6 +4613,8 @@ export declare const state: {
4451
4613
  WorkspaceMember: true;
4452
4614
  Account: true;
4453
4615
  Usage: true;
4616
+ Issue: true;
4617
+ IssueEvent: true;
4454
4618
  User: true;
4455
4619
  Conversation: true;
4456
4620
  Event: true;
@@ -5201,6 +5365,72 @@ export declare const state: {
5201
5365
  additionalProperties: false;
5202
5366
  };
5203
5367
  };
5368
+ Issue: {
5369
+ section: "bot";
5370
+ schema: {
5371
+ type: "object";
5372
+ properties: {
5373
+ id: {
5374
+ type: "string";
5375
+ };
5376
+ code: {
5377
+ type: "string";
5378
+ };
5379
+ createdAt: {
5380
+ type: "string";
5381
+ format: string;
5382
+ };
5383
+ lastSeenAt: {
5384
+ type: "string";
5385
+ format: string;
5386
+ };
5387
+ title: {
5388
+ type: "string";
5389
+ };
5390
+ description: {
5391
+ type: "string";
5392
+ };
5393
+ groupedData: {
5394
+ type: "object";
5395
+ additionalProperties: false;
5396
+ };
5397
+ eventsCount: {
5398
+ type: "number";
5399
+ };
5400
+ category: {
5401
+ type: "string";
5402
+ enum: string[];
5403
+ };
5404
+ resolutionLink: {
5405
+ type: "string";
5406
+ nullable: true;
5407
+ };
5408
+ };
5409
+ required: string[];
5410
+ additionalProperties: false;
5411
+ };
5412
+ };
5413
+ IssueEvent: {
5414
+ section: "bot";
5415
+ schema: {
5416
+ type: "object";
5417
+ properties: {
5418
+ id: {
5419
+ type: "string";
5420
+ };
5421
+ createdAt: {
5422
+ type: "string";
5423
+ format: string;
5424
+ };
5425
+ data: {
5426
+ type: "object";
5427
+ additionalProperties: false;
5428
+ };
5429
+ };
5430
+ required: string[];
5431
+ additionalProperties: false;
5432
+ };
5433
+ };
5204
5434
  User: {
5205
5435
  section: "user";
5206
5436
  schema: {
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  export declare const api: {
2
- getState: () => import("@bpinternal/opapi").State<"Bot" | "Integration" | "Workspace" | "WorkspaceMember" | "Account" | "Usage" | "User" | "Conversation" | "Event" | "Message" | "State" | "File", "x-workspace-id", "user" | "conversation" | "event" | "message" | "file" | "state" | "hub" | "action" | "bot" | "integration" | "workspace" | "workspaceMember" | "account" | "usage">;
3
- getModelRef: (name: "Bot" | "Integration" | "Workspace" | "WorkspaceMember" | "Account" | "Usage" | "User" | "Conversation" | "Event" | "Message" | "State" | "File") => import("@bpinternal/opapi").OpenApiZodAny;
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">;
3
+ getModelRef: (name: "Bot" | "Integration" | "Workspace" | "WorkspaceMember" | "Account" | "Usage" | "Issue" | "IssueEvent" | "User" | "Conversation" | "Event" | "Message" | "State" | "File") => import("@bpinternal/opapi").OpenApiZodAny;
4
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", 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>;
package/dist/index.js CHANGED
@@ -427321,7 +427321,7 @@ var state = {
427321
427321
  parameters: {
427322
427322
  id: {
427323
427323
  type: "string",
427324
- description: "Integration Id",
427324
+ description: "Integration ID",
427325
427325
  in: "path"
427326
427326
  }
427327
427327
  },
@@ -427903,7 +427903,7 @@ var state = {
427903
427903
  properties: {
427904
427904
  targetWorkspaceId: {
427905
427905
  type: "string",
427906
- format: "uuid",
427906
+ minLength: 28,
427907
427907
  description: "The ID of the workspace you want to transfer the bot to."
427908
427908
  }
427909
427909
  },
@@ -428209,6 +428209,178 @@ var state = {
428209
428209
  }
428210
428210
  }
428211
428211
  },
428212
+ listBotIssues: {
428213
+ name: "listBotIssues",
428214
+ description: "List Bot Issues",
428215
+ method: "get",
428216
+ path: "/v1/admin/bots/{id}/issues",
428217
+ section: "bot",
428218
+ parameters: {
428219
+ id: {
428220
+ type: "string",
428221
+ description: "Bot ID",
428222
+ in: "path"
428223
+ },
428224
+ nextToken: {
428225
+ in: "query",
428226
+ description: "Provide the `meta.nextToken` value provided in the last API response to retrieve the next page of results",
428227
+ type: "string"
428228
+ }
428229
+ },
428230
+ response: {
428231
+ description: "Success",
428232
+ schema: {
428233
+ type: "object",
428234
+ properties: {
428235
+ issues: {
428236
+ type: "array",
428237
+ items: {
428238
+ type: "object",
428239
+ properties: {
428240
+ id: {
428241
+ type: "string"
428242
+ },
428243
+ code: {
428244
+ type: "string"
428245
+ },
428246
+ createdAt: {
428247
+ type: "string",
428248
+ format: "date-time"
428249
+ },
428250
+ lastSeenAt: {
428251
+ type: "string",
428252
+ format: "date-time"
428253
+ },
428254
+ title: {
428255
+ type: "string"
428256
+ },
428257
+ description: {
428258
+ type: "string"
428259
+ },
428260
+ groupedData: {
428261
+ type: "object",
428262
+ properties: {}
428263
+ },
428264
+ eventsCount: {
428265
+ type: "number"
428266
+ },
428267
+ category: {
428268
+ type: "string",
428269
+ enum: ["user_code", "limits", "configuration", "other"]
428270
+ },
428271
+ resolutionLink: {
428272
+ type: "string",
428273
+ nullable: true
428274
+ }
428275
+ },
428276
+ required: [
428277
+ "id",
428278
+ "code",
428279
+ "createdAt",
428280
+ "lastSeenAt",
428281
+ "title",
428282
+ "description",
428283
+ "groupedData",
428284
+ "eventsCount",
428285
+ "category",
428286
+ "resolutionLink"
428287
+ ]
428288
+ }
428289
+ },
428290
+ meta: {
428291
+ type: "object",
428292
+ properties: {
428293
+ nextToken: {
428294
+ type: "string",
428295
+ description: "The token to use to retrieve the next page of results, passed as a query string parameter (value should be URL-encoded) to this API endpoint."
428296
+ }
428297
+ },
428298
+ additionalProperties: false
428299
+ }
428300
+ },
428301
+ required: ["issues", "meta"],
428302
+ title: "listBotIssuesResponse",
428303
+ additionalProperties: false
428304
+ }
428305
+ }
428306
+ },
428307
+ deleteBotIssue: {
428308
+ name: "deleteBotIssue",
428309
+ description: "Delete Bot Issue",
428310
+ method: "delete",
428311
+ path: "/v1/admin/bots/{id}/issues/{issueId}",
428312
+ section: "bot",
428313
+ parameters: {
428314
+ id: {
428315
+ type: "string",
428316
+ description: "Bot ID",
428317
+ in: "path"
428318
+ },
428319
+ issueId: {
428320
+ in: "path",
428321
+ description: "Issue ID",
428322
+ type: "string"
428323
+ }
428324
+ },
428325
+ response: {
428326
+ description: "Success",
428327
+ schema: {
428328
+ type: "object",
428329
+ title: "deleteBotIssueResponse",
428330
+ additionalProperties: false
428331
+ }
428332
+ }
428333
+ },
428334
+ listBotIssueEvents: {
428335
+ name: "listBotIssueEvents",
428336
+ description: "List Events for a Bot Issue",
428337
+ method: "get",
428338
+ path: "/v1/admin/bots/{id}/issues/{issueId}/events",
428339
+ section: "bot",
428340
+ parameters: {
428341
+ id: {
428342
+ type: "string",
428343
+ description: "Bot ID",
428344
+ in: "path"
428345
+ },
428346
+ issueId: {
428347
+ in: "path",
428348
+ description: "Issue ID",
428349
+ type: "string"
428350
+ }
428351
+ },
428352
+ response: {
428353
+ description: "Success",
428354
+ schema: {
428355
+ type: "object",
428356
+ properties: {
428357
+ issueEvents: {
428358
+ type: "array",
428359
+ items: {
428360
+ type: "object",
428361
+ properties: {
428362
+ id: {
428363
+ type: "string"
428364
+ },
428365
+ createdAt: {
428366
+ type: "string",
428367
+ format: "date-time"
428368
+ },
428369
+ data: {
428370
+ type: "object",
428371
+ properties: {}
428372
+ }
428373
+ },
428374
+ required: ["id", "createdAt", "data"]
428375
+ }
428376
+ }
428377
+ },
428378
+ required: ["issueEvents"],
428379
+ title: "listBotIssueEventsResponse",
428380
+ additionalProperties: false
428381
+ }
428382
+ }
428383
+ },
428212
428384
  createWorkspace: {
428213
428385
  name: "createWorkspace",
428214
428386
  description: "Create workspace",
@@ -428863,8 +429035,7 @@ var state = {
428863
429035
  type: "object",
428864
429036
  properties: {
428865
429037
  id: {
428866
- type: "string",
428867
- format: "uuid"
429038
+ type: "string"
428868
429039
  },
428869
429040
  recordedAt: {
428870
429041
  type: "string",
@@ -428881,7 +429052,6 @@ var state = {
428881
429052
  },
428882
429053
  resourceId: {
428883
429054
  type: "string",
428884
- format: "uuid",
428885
429055
  nullable: true
428886
429056
  },
428887
429057
  resourceName: {
@@ -429493,7 +429663,7 @@ var state = {
429493
429663
  parameters: {
429494
429664
  id: {
429495
429665
  type: "string",
429496
- description: "Integration Id",
429666
+ description: "Integration ID",
429497
429667
  in: "path"
429498
429668
  }
429499
429669
  },
@@ -429918,7 +430088,7 @@ var state = {
429918
430088
  parameters: {
429919
430089
  id: {
429920
430090
  type: "string",
429921
- description: "Integration Id",
430091
+ description: "Integration ID",
429922
430092
  in: "path"
429923
430093
  }
429924
430094
  },
@@ -429946,7 +430116,7 @@ var state = {
429946
430116
  parameters: {
429947
430117
  id: {
429948
430118
  type: "string",
429949
- description: "Integration Id",
430119
+ description: "Integration ID",
429950
430120
  in: "path"
429951
430121
  },
429952
430122
  timeStart: {
@@ -430043,7 +430213,7 @@ var state = {
430043
430213
  parameters: {
430044
430214
  id: {
430045
430215
  type: "string",
430046
- description: "Integration Id",
430216
+ description: "Integration ID",
430047
430217
  in: "path"
430048
430218
  }
430049
430219
  },
@@ -430372,7 +430542,7 @@ var state = {
430372
430542
  title: "Botpress API",
430373
430543
  description: "API for Botpress Cloud",
430374
430544
  server: "https://api.botpress.cloud",
430375
- version: "0.8.0",
430545
+ version: "0.10.0",
430376
430546
  prefix: "v1"
430377
430547
  },
430378
430548
  errors: [
@@ -430556,6 +430726,9 @@ var state = {
430556
430726
  getBotLogsResponse: true,
430557
430727
  getBotWebchatResponse: true,
430558
430728
  getBotAnalyticsResponse: true,
430729
+ listBotIssuesResponse: true,
430730
+ deleteBotIssueResponse: true,
430731
+ listBotIssueEventsResponse: true,
430559
430732
  createWorkspaceResponse: true,
430560
430733
  getWorkspaceResponse: true,
430561
430734
  listWorkspaceUsagesResponse: true,
@@ -430593,6 +430766,8 @@ var state = {
430593
430766
  WorkspaceMember: true,
430594
430767
  Account: true,
430595
430768
  Usage: true,
430769
+ Issue: true,
430770
+ IssueEvent: true,
430596
430771
  User: true,
430597
430772
  Conversation: true,
430598
430773
  Event: true,
@@ -431424,6 +431599,83 @@ var state = {
431424
431599
  additionalProperties: false
431425
431600
  }
431426
431601
  },
431602
+ Issue: {
431603
+ section: "bot",
431604
+ schema: {
431605
+ type: "object",
431606
+ properties: {
431607
+ id: {
431608
+ type: "string"
431609
+ },
431610
+ code: {
431611
+ type: "string"
431612
+ },
431613
+ createdAt: {
431614
+ type: "string",
431615
+ format: "date-time"
431616
+ },
431617
+ lastSeenAt: {
431618
+ type: "string",
431619
+ format: "date-time"
431620
+ },
431621
+ title: {
431622
+ type: "string"
431623
+ },
431624
+ description: {
431625
+ type: "string"
431626
+ },
431627
+ groupedData: {
431628
+ type: "object",
431629
+ additionalProperties: false
431630
+ },
431631
+ eventsCount: {
431632
+ type: "number"
431633
+ },
431634
+ category: {
431635
+ type: "string",
431636
+ enum: ["user_code", "limits", "configuration", "other"]
431637
+ },
431638
+ resolutionLink: {
431639
+ type: "string",
431640
+ nullable: true
431641
+ }
431642
+ },
431643
+ required: [
431644
+ "id",
431645
+ "code",
431646
+ "createdAt",
431647
+ "lastSeenAt",
431648
+ "title",
431649
+ "description",
431650
+ "groupedData",
431651
+ "eventsCount",
431652
+ "category",
431653
+ "resolutionLink"
431654
+ ],
431655
+ additionalProperties: false
431656
+ }
431657
+ },
431658
+ IssueEvent: {
431659
+ section: "bot",
431660
+ schema: {
431661
+ type: "object",
431662
+ properties: {
431663
+ id: {
431664
+ type: "string"
431665
+ },
431666
+ createdAt: {
431667
+ type: "string",
431668
+ format: "date-time"
431669
+ },
431670
+ data: {
431671
+ type: "object",
431672
+ additionalProperties: false
431673
+ }
431674
+ },
431675
+ required: ["id", "createdAt", "data"],
431676
+ additionalProperties: false
431677
+ }
431678
+ },
431427
431679
  User: {
431428
431680
  section: "user",
431429
431681
  schema: {
@@ -431789,7 +432041,10 @@ var state = {
431789
432041
  "deleteBot",
431790
432042
  "getBotLogs",
431791
432043
  "getBotWebchat",
431792
- "getBotAnalytics"
432044
+ "getBotAnalytics",
432045
+ "listBotIssues",
432046
+ "deleteBotIssue",
432047
+ "listBotIssueEvents"
431793
432048
  ],
431794
432049
  schema: "Bot"
431795
432050
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botpress/api",
3
- "version": "0.8.0",
3
+ "version": "0.10.0",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {