@botpress/api 0.3.3 → 0.4.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.
package/src/gen/state.ts CHANGED
@@ -2267,6 +2267,79 @@ export const state = {
2267
2267
  },
2268
2268
  },
2269
2269
  },
2270
+ createWorkspace: {
2271
+ name: "createWorkspace",
2272
+ description: "Create workspace",
2273
+ method: "post",
2274
+ path: "/v1/admin/workspaces",
2275
+ disableDefaultParameters: {
2276
+ "x-workspace-id": true,
2277
+ },
2278
+ requestBody: {
2279
+ description: "Workspace metadata",
2280
+ schema: {
2281
+ type: "object",
2282
+ properties: {
2283
+ name: {
2284
+ type: "string",
2285
+ },
2286
+ },
2287
+ required: ["name"],
2288
+ title: "createWorkspaceBody",
2289
+ additionalProperties: false,
2290
+ },
2291
+ },
2292
+ response: {
2293
+ description: "Success",
2294
+ schema: {
2295
+ type: "object",
2296
+ properties: {
2297
+ id: {
2298
+ type: "string",
2299
+ },
2300
+ name: {
2301
+ type: "string",
2302
+ },
2303
+ ownerId: {
2304
+ type: "string",
2305
+ },
2306
+ createdAt: {
2307
+ type: "string",
2308
+ },
2309
+ updatedAt: {
2310
+ type: "string",
2311
+ },
2312
+ botCount: {
2313
+ type: "number",
2314
+ },
2315
+ accountType: {
2316
+ type: "string",
2317
+ enum: ["free", "premium"],
2318
+ },
2319
+ blocked: {
2320
+ type: "boolean",
2321
+ },
2322
+ spendingLimit: {
2323
+ type: "number",
2324
+ },
2325
+ },
2326
+ required: [
2327
+ "id",
2328
+ "name",
2329
+ "ownerId",
2330
+ "createdAt",
2331
+ "updatedAt",
2332
+ "botCount",
2333
+ "accountType",
2334
+ "blocked",
2335
+ "spendingLimit",
2336
+ ],
2337
+ title: "createWorkspaceResponse",
2338
+ additionalProperties: false,
2339
+ },
2340
+ },
2341
+ parameters: {},
2342
+ },
2270
2343
  getWorkspace: {
2271
2344
  name: "getWorkspace",
2272
2345
  description: "Get workspace details",
@@ -2337,6 +2410,9 @@ export const state = {
2337
2410
  description: "Update workspace",
2338
2411
  method: "put",
2339
2412
  path: "/v1/admin/workspaces/{id}",
2413
+ disableDefaultParameters: {
2414
+ "x-workspace-id": true,
2415
+ },
2340
2416
  parameters: {
2341
2417
  id: {
2342
2418
  type: "string",
@@ -2354,10 +2430,6 @@ export const state = {
2354
2430
  minLength: 1,
2355
2431
  maxLength: 64,
2356
2432
  },
2357
- accountType: {
2358
- type: "string",
2359
- enum: ["free", "premium"],
2360
- },
2361
2433
  spendingLimit: {
2362
2434
  type: "number",
2363
2435
  minimum: 5,
@@ -2466,6 +2538,12 @@ export const state = {
2466
2538
  type: "string",
2467
2539
  enum: ["free", "premium"],
2468
2540
  },
2541
+ blocked: {
2542
+ type: "boolean",
2543
+ },
2544
+ spendingLimit: {
2545
+ type: "number",
2546
+ },
2469
2547
  },
2470
2548
  required: [
2471
2549
  "id",
@@ -2475,7 +2553,10 @@ export const state = {
2475
2553
  "updatedAt",
2476
2554
  "botCount",
2477
2555
  "accountType",
2556
+ "blocked",
2557
+ "spendingLimit",
2478
2558
  ],
2559
+ title: "updateWorkspaceResponse",
2479
2560
  },
2480
2561
  },
2481
2562
  meta: {
@@ -2496,6 +2577,110 @@ export const state = {
2496
2577
  },
2497
2578
  },
2498
2579
  },
2580
+ changeWorkspacePlan: {
2581
+ name: "changeWorkspacePlan",
2582
+ description: "Change workspace billing plan",
2583
+ method: "put",
2584
+ path: "/v1/admin/workspaces/{id}/change-plan",
2585
+ disableDefaultParameters: {
2586
+ "x-workspace-id": true,
2587
+ },
2588
+ parameters: {
2589
+ id: {
2590
+ type: "string",
2591
+ description: "Workspace ID",
2592
+ in: "path",
2593
+ },
2594
+ },
2595
+ requestBody: {
2596
+ description: "Billing plan to change the workspace to",
2597
+ schema: {
2598
+ type: "object",
2599
+ properties: {
2600
+ plan: {
2601
+ type: "string",
2602
+ enum: ["free", "premium"],
2603
+ },
2604
+ },
2605
+ required: ["plan"],
2606
+ title: "changeWorkspacePlanBody",
2607
+ additionalProperties: false,
2608
+ },
2609
+ },
2610
+ response: {
2611
+ description: "Success",
2612
+ schema: {
2613
+ type: "object",
2614
+ properties: {
2615
+ id: {
2616
+ type: "string",
2617
+ },
2618
+ name: {
2619
+ type: "string",
2620
+ },
2621
+ ownerId: {
2622
+ type: "string",
2623
+ },
2624
+ createdAt: {
2625
+ type: "string",
2626
+ },
2627
+ updatedAt: {
2628
+ type: "string",
2629
+ },
2630
+ botCount: {
2631
+ type: "number",
2632
+ },
2633
+ accountType: {
2634
+ type: "string",
2635
+ enum: ["free", "premium"],
2636
+ },
2637
+ blocked: {
2638
+ type: "boolean",
2639
+ },
2640
+ spendingLimit: {
2641
+ type: "number",
2642
+ },
2643
+ },
2644
+ required: [
2645
+ "id",
2646
+ "name",
2647
+ "ownerId",
2648
+ "createdAt",
2649
+ "updatedAt",
2650
+ "botCount",
2651
+ "accountType",
2652
+ "blocked",
2653
+ "spendingLimit",
2654
+ ],
2655
+ title: "changeWorkspacePlanResponse",
2656
+ additionalProperties: false,
2657
+ },
2658
+ },
2659
+ },
2660
+ deleteWorkspace: {
2661
+ name: "deleteWorkspace",
2662
+ description: "Delete workspace",
2663
+ method: "delete",
2664
+ path: "/v1/admin/workspaces/{id}",
2665
+ disableDefaultParameters: {
2666
+ "x-workspace-id": true,
2667
+ },
2668
+ parameters: {
2669
+ id: {
2670
+ type: "string",
2671
+ description: "Workspace ID",
2672
+ in: "path",
2673
+ },
2674
+ },
2675
+ response: {
2676
+ description: "Success",
2677
+ schema: {
2678
+ type: "object",
2679
+ title: "deleteWorkspaceResponse",
2680
+ additionalProperties: false,
2681
+ },
2682
+ },
2683
+ },
2499
2684
  createIntegration: {
2500
2685
  name: "createIntegration",
2501
2686
  description: "Create integration",
@@ -3853,7 +4038,7 @@ export const state = {
3853
4038
  title: "Botpress API",
3854
4039
  description: "API for Botpress Cloud",
3855
4040
  server: "https://api.botpress.cloud",
3856
- version: "0.3.3",
4041
+ version: "0.4.0",
3857
4042
  prefix: "v1",
3858
4043
  },
3859
4044
  errors: [
@@ -3975,7 +4160,9 @@ export const state = {
3975
4160
  createBotBody: true,
3976
4161
  updateBotBody: true,
3977
4162
  transferBotBody: true,
4163
+ createWorkspaceBody: true,
3978
4164
  updateWorkspaceBody: true,
4165
+ changeWorkspacePlanBody: true,
3979
4166
  createIntegrationBody: true,
3980
4167
  updateIntegrationBody: true,
3981
4168
  createWorkspaceMemberBody: true,
@@ -4022,9 +4209,12 @@ export const state = {
4022
4209
  getBotLogsResponse: true,
4023
4210
  getBotWebchatResponse: true,
4024
4211
  getBotAnalyticsResponse: true,
4212
+ createWorkspaceResponse: true,
4025
4213
  getWorkspaceResponse: true,
4026
4214
  updateWorkspaceResponse: true,
4027
4215
  listWorkspacesResponse: true,
4216
+ changeWorkspacePlanResponse: true,
4217
+ deleteWorkspaceResponse: true,
4028
4218
  createIntegrationResponse: true,
4029
4219
  updateIntegrationResponse: true,
4030
4220
  listIntegrationsResponse: true,
@@ -4092,9 +4282,12 @@ export const state = {
4092
4282
  },
4093
4283
  name: {
4094
4284
  type: "string",
4285
+ description: "Name of the [Integration](#schema_integration)",
4095
4286
  },
4096
4287
  version: {
4097
4288
  type: "string",
4289
+ description:
4290
+ "Version of the [Integration](#schema_integration)",
4098
4291
  },
4099
4292
  webhookUrl: {
4100
4293
  type: "string",
@@ -4118,6 +4311,40 @@ export const state = {
4118
4311
  type: "string",
4119
4312
  nullable: true,
4120
4313
  },
4314
+ id: {
4315
+ type: "string",
4316
+ description: "Id of the [Integration](#schema_integration)",
4317
+ },
4318
+ createdAt: {
4319
+ type: "string",
4320
+ format: "date-time",
4321
+ description:
4322
+ "Creation date of the [Integration](#schema_integration) in the ISO 8601 format",
4323
+ },
4324
+ updatedAt: {
4325
+ type: "string",
4326
+ format: "date-time",
4327
+ description:
4328
+ "Updating date of the [Integration](#schema_integration) in the ISO 8601 format",
4329
+ },
4330
+ title: {
4331
+ type: "string",
4332
+ minLength: 1,
4333
+ maxLength: 64,
4334
+ description:
4335
+ "Title of the integration. This is the name that will be displayed in the UI",
4336
+ },
4337
+ description: {
4338
+ type: "string",
4339
+ maxLength: 256,
4340
+ description:
4341
+ "Description of the integration. This is the description that will be displayed in the UI",
4342
+ },
4343
+ iconUrl: {
4344
+ type: "string",
4345
+ description:
4346
+ "URL of the icon of the integration. This is the icon that will be displayed in the UI",
4347
+ },
4121
4348
  },
4122
4349
  required: [
4123
4350
  "enabled",
@@ -4127,6 +4354,12 @@ export const state = {
4127
4354
  "configuration",
4128
4355
  "status",
4129
4356
  "statusReason",
4357
+ "id",
4358
+ "createdAt",
4359
+ "updatedAt",
4360
+ "title",
4361
+ "description",
4362
+ "iconUrl",
4130
4363
  ],
4131
4364
  additionalProperties: false,
4132
4365
  },