@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.
@@ -2131,6 +2131,69 @@ export declare const state: {
2131
2131
  };
2132
2132
  };
2133
2133
  };
2134
+ createWorkspace: {
2135
+ name: string;
2136
+ description: string;
2137
+ method: "post";
2138
+ path: string;
2139
+ disableDefaultParameters: {
2140
+ "x-workspace-id": boolean;
2141
+ };
2142
+ requestBody: {
2143
+ description: string;
2144
+ schema: {
2145
+ type: "object";
2146
+ properties: {
2147
+ name: {
2148
+ type: "string";
2149
+ };
2150
+ };
2151
+ required: string[];
2152
+ title: string;
2153
+ additionalProperties: false;
2154
+ };
2155
+ };
2156
+ response: {
2157
+ description: string;
2158
+ schema: {
2159
+ type: "object";
2160
+ properties: {
2161
+ id: {
2162
+ type: "string";
2163
+ };
2164
+ name: {
2165
+ type: "string";
2166
+ };
2167
+ ownerId: {
2168
+ type: "string";
2169
+ };
2170
+ createdAt: {
2171
+ type: "string";
2172
+ };
2173
+ updatedAt: {
2174
+ type: "string";
2175
+ };
2176
+ botCount: {
2177
+ type: "number";
2178
+ };
2179
+ accountType: {
2180
+ type: "string";
2181
+ enum: string[];
2182
+ };
2183
+ blocked: {
2184
+ type: "boolean";
2185
+ };
2186
+ spendingLimit: {
2187
+ type: "number";
2188
+ };
2189
+ };
2190
+ required: string[];
2191
+ title: string;
2192
+ additionalProperties: false;
2193
+ };
2194
+ };
2195
+ parameters: {};
2196
+ };
2134
2197
  getWorkspace: {
2135
2198
  name: string;
2136
2199
  description: string;
@@ -2191,6 +2254,9 @@ export declare const state: {
2191
2254
  description: string;
2192
2255
  method: "put";
2193
2256
  path: string;
2257
+ disableDefaultParameters: {
2258
+ "x-workspace-id": boolean;
2259
+ };
2194
2260
  parameters: {
2195
2261
  id: {
2196
2262
  type: "string";
@@ -2208,10 +2274,6 @@ export declare const state: {
2208
2274
  minLength: number;
2209
2275
  maxLength: number;
2210
2276
  };
2211
- accountType: {
2212
- type: "string";
2213
- enum: string[];
2214
- };
2215
2277
  spendingLimit: {
2216
2278
  type: "number";
2217
2279
  minimum: number;
@@ -2309,8 +2371,15 @@ export declare const state: {
2309
2371
  type: "string";
2310
2372
  enum: string[];
2311
2373
  };
2374
+ blocked: {
2375
+ type: "boolean";
2376
+ };
2377
+ spendingLimit: {
2378
+ type: "number";
2379
+ };
2312
2380
  };
2313
2381
  required: string[];
2382
+ title: string;
2314
2383
  };
2315
2384
  };
2316
2385
  meta: {
@@ -2330,6 +2399,100 @@ export declare const state: {
2330
2399
  };
2331
2400
  };
2332
2401
  };
2402
+ changeWorkspacePlan: {
2403
+ name: string;
2404
+ description: string;
2405
+ method: "put";
2406
+ path: string;
2407
+ disableDefaultParameters: {
2408
+ "x-workspace-id": boolean;
2409
+ };
2410
+ parameters: {
2411
+ id: {
2412
+ type: "string";
2413
+ description: string;
2414
+ in: "path";
2415
+ };
2416
+ };
2417
+ requestBody: {
2418
+ description: string;
2419
+ schema: {
2420
+ type: "object";
2421
+ properties: {
2422
+ plan: {
2423
+ type: "string";
2424
+ enum: string[];
2425
+ };
2426
+ };
2427
+ required: string[];
2428
+ title: string;
2429
+ additionalProperties: false;
2430
+ };
2431
+ };
2432
+ response: {
2433
+ description: string;
2434
+ schema: {
2435
+ type: "object";
2436
+ properties: {
2437
+ id: {
2438
+ type: "string";
2439
+ };
2440
+ name: {
2441
+ type: "string";
2442
+ };
2443
+ ownerId: {
2444
+ type: "string";
2445
+ };
2446
+ createdAt: {
2447
+ type: "string";
2448
+ };
2449
+ updatedAt: {
2450
+ type: "string";
2451
+ };
2452
+ botCount: {
2453
+ type: "number";
2454
+ };
2455
+ accountType: {
2456
+ type: "string";
2457
+ enum: string[];
2458
+ };
2459
+ blocked: {
2460
+ type: "boolean";
2461
+ };
2462
+ spendingLimit: {
2463
+ type: "number";
2464
+ };
2465
+ };
2466
+ required: string[];
2467
+ title: string;
2468
+ additionalProperties: false;
2469
+ };
2470
+ };
2471
+ };
2472
+ deleteWorkspace: {
2473
+ name: string;
2474
+ description: string;
2475
+ method: "delete";
2476
+ path: string;
2477
+ disableDefaultParameters: {
2478
+ "x-workspace-id": boolean;
2479
+ };
2480
+ parameters: {
2481
+ id: {
2482
+ type: "string";
2483
+ description: string;
2484
+ in: "path";
2485
+ };
2486
+ };
2487
+ response: {
2488
+ description: string;
2489
+ schema: {
2490
+ type: "object";
2491
+ title: string;
2492
+ additionalProperties: false;
2493
+ };
2494
+ };
2495
+ };
2333
2496
  createIntegration: {
2334
2497
  name: string;
2335
2498
  description: string;
@@ -3660,7 +3823,9 @@ export declare const state: {
3660
3823
  createBotBody: true;
3661
3824
  updateBotBody: true;
3662
3825
  transferBotBody: true;
3826
+ createWorkspaceBody: true;
3663
3827
  updateWorkspaceBody: true;
3828
+ changeWorkspacePlanBody: true;
3664
3829
  createIntegrationBody: true;
3665
3830
  updateIntegrationBody: true;
3666
3831
  createWorkspaceMemberBody: true;
@@ -3707,9 +3872,12 @@ export declare const state: {
3707
3872
  getBotLogsResponse: true;
3708
3873
  getBotWebchatResponse: true;
3709
3874
  getBotAnalyticsResponse: true;
3875
+ createWorkspaceResponse: true;
3710
3876
  getWorkspaceResponse: true;
3711
3877
  updateWorkspaceResponse: true;
3712
3878
  listWorkspacesResponse: true;
3879
+ changeWorkspacePlanResponse: true;
3880
+ deleteWorkspaceResponse: true;
3713
3881
  createIntegrationResponse: true;
3714
3882
  updateIntegrationResponse: true;
3715
3883
  listIntegrationsResponse: true;
@@ -3775,9 +3943,11 @@ export declare const state: {
3775
3943
  };
3776
3944
  name: {
3777
3945
  type: "string";
3946
+ description: string;
3778
3947
  };
3779
3948
  version: {
3780
3949
  type: "string";
3950
+ description: string;
3781
3951
  };
3782
3952
  webhookUrl: {
3783
3953
  type: "string";
@@ -3794,6 +3964,35 @@ export declare const state: {
3794
3964
  type: "string";
3795
3965
  nullable: true;
3796
3966
  };
3967
+ id: {
3968
+ type: "string";
3969
+ description: string;
3970
+ };
3971
+ createdAt: {
3972
+ type: "string";
3973
+ format: string;
3974
+ description: string;
3975
+ };
3976
+ updatedAt: {
3977
+ type: "string";
3978
+ format: string;
3979
+ description: string;
3980
+ };
3981
+ title: {
3982
+ type: "string";
3983
+ minLength: number;
3984
+ maxLength: number;
3985
+ description: string;
3986
+ };
3987
+ description: {
3988
+ type: "string";
3989
+ maxLength: number;
3990
+ description: string;
3991
+ };
3992
+ iconUrl: {
3993
+ type: "string";
3994
+ description: string;
3995
+ };
3797
3996
  };
3798
3997
  required: string[];
3799
3998
  additionalProperties: false;
package/dist/index.js CHANGED
@@ -227597,6 +227597,79 @@ var state = {
227597
227597
  }
227598
227598
  }
227599
227599
  },
227600
+ createWorkspace: {
227601
+ name: "createWorkspace",
227602
+ description: "Create workspace",
227603
+ method: "post",
227604
+ path: "/v1/admin/workspaces",
227605
+ disableDefaultParameters: {
227606
+ "x-workspace-id": true
227607
+ },
227608
+ requestBody: {
227609
+ description: "Workspace metadata",
227610
+ schema: {
227611
+ type: "object",
227612
+ properties: {
227613
+ name: {
227614
+ type: "string"
227615
+ }
227616
+ },
227617
+ required: ["name"],
227618
+ title: "createWorkspaceBody",
227619
+ additionalProperties: false
227620
+ }
227621
+ },
227622
+ response: {
227623
+ description: "Success",
227624
+ schema: {
227625
+ type: "object",
227626
+ properties: {
227627
+ id: {
227628
+ type: "string"
227629
+ },
227630
+ name: {
227631
+ type: "string"
227632
+ },
227633
+ ownerId: {
227634
+ type: "string"
227635
+ },
227636
+ createdAt: {
227637
+ type: "string"
227638
+ },
227639
+ updatedAt: {
227640
+ type: "string"
227641
+ },
227642
+ botCount: {
227643
+ type: "number"
227644
+ },
227645
+ accountType: {
227646
+ type: "string",
227647
+ enum: ["free", "premium"]
227648
+ },
227649
+ blocked: {
227650
+ type: "boolean"
227651
+ },
227652
+ spendingLimit: {
227653
+ type: "number"
227654
+ }
227655
+ },
227656
+ required: [
227657
+ "id",
227658
+ "name",
227659
+ "ownerId",
227660
+ "createdAt",
227661
+ "updatedAt",
227662
+ "botCount",
227663
+ "accountType",
227664
+ "blocked",
227665
+ "spendingLimit"
227666
+ ],
227667
+ title: "createWorkspaceResponse",
227668
+ additionalProperties: false
227669
+ }
227670
+ },
227671
+ parameters: {}
227672
+ },
227600
227673
  getWorkspace: {
227601
227674
  name: "getWorkspace",
227602
227675
  description: "Get workspace details",
@@ -227667,6 +227740,9 @@ var state = {
227667
227740
  description: "Update workspace",
227668
227741
  method: "put",
227669
227742
  path: "/v1/admin/workspaces/{id}",
227743
+ disableDefaultParameters: {
227744
+ "x-workspace-id": true
227745
+ },
227670
227746
  parameters: {
227671
227747
  id: {
227672
227748
  type: "string",
@@ -227684,10 +227760,6 @@ var state = {
227684
227760
  minLength: 1,
227685
227761
  maxLength: 64
227686
227762
  },
227687
- accountType: {
227688
- type: "string",
227689
- enum: ["free", "premium"]
227690
- },
227691
227763
  spendingLimit: {
227692
227764
  type: "number",
227693
227765
  minimum: 5,
@@ -227794,6 +227866,12 @@ var state = {
227794
227866
  accountType: {
227795
227867
  type: "string",
227796
227868
  enum: ["free", "premium"]
227869
+ },
227870
+ blocked: {
227871
+ type: "boolean"
227872
+ },
227873
+ spendingLimit: {
227874
+ type: "number"
227797
227875
  }
227798
227876
  },
227799
227877
  required: [
@@ -227803,8 +227881,11 @@ var state = {
227803
227881
  "createdAt",
227804
227882
  "updatedAt",
227805
227883
  "botCount",
227806
- "accountType"
227807
- ]
227884
+ "accountType",
227885
+ "blocked",
227886
+ "spendingLimit"
227887
+ ],
227888
+ title: "updateWorkspaceResponse"
227808
227889
  }
227809
227890
  },
227810
227891
  meta: {
@@ -227824,6 +227905,110 @@ var state = {
227824
227905
  }
227825
227906
  }
227826
227907
  },
227908
+ changeWorkspacePlan: {
227909
+ name: "changeWorkspacePlan",
227910
+ description: "Change workspace billing plan",
227911
+ method: "put",
227912
+ path: "/v1/admin/workspaces/{id}/change-plan",
227913
+ disableDefaultParameters: {
227914
+ "x-workspace-id": true
227915
+ },
227916
+ parameters: {
227917
+ id: {
227918
+ type: "string",
227919
+ description: "Workspace ID",
227920
+ in: "path"
227921
+ }
227922
+ },
227923
+ requestBody: {
227924
+ description: "Billing plan to change the workspace to",
227925
+ schema: {
227926
+ type: "object",
227927
+ properties: {
227928
+ plan: {
227929
+ type: "string",
227930
+ enum: ["free", "premium"]
227931
+ }
227932
+ },
227933
+ required: ["plan"],
227934
+ title: "changeWorkspacePlanBody",
227935
+ additionalProperties: false
227936
+ }
227937
+ },
227938
+ response: {
227939
+ description: "Success",
227940
+ schema: {
227941
+ type: "object",
227942
+ properties: {
227943
+ id: {
227944
+ type: "string"
227945
+ },
227946
+ name: {
227947
+ type: "string"
227948
+ },
227949
+ ownerId: {
227950
+ type: "string"
227951
+ },
227952
+ createdAt: {
227953
+ type: "string"
227954
+ },
227955
+ updatedAt: {
227956
+ type: "string"
227957
+ },
227958
+ botCount: {
227959
+ type: "number"
227960
+ },
227961
+ accountType: {
227962
+ type: "string",
227963
+ enum: ["free", "premium"]
227964
+ },
227965
+ blocked: {
227966
+ type: "boolean"
227967
+ },
227968
+ spendingLimit: {
227969
+ type: "number"
227970
+ }
227971
+ },
227972
+ required: [
227973
+ "id",
227974
+ "name",
227975
+ "ownerId",
227976
+ "createdAt",
227977
+ "updatedAt",
227978
+ "botCount",
227979
+ "accountType",
227980
+ "blocked",
227981
+ "spendingLimit"
227982
+ ],
227983
+ title: "changeWorkspacePlanResponse",
227984
+ additionalProperties: false
227985
+ }
227986
+ }
227987
+ },
227988
+ deleteWorkspace: {
227989
+ name: "deleteWorkspace",
227990
+ description: "Delete workspace",
227991
+ method: "delete",
227992
+ path: "/v1/admin/workspaces/{id}",
227993
+ disableDefaultParameters: {
227994
+ "x-workspace-id": true
227995
+ },
227996
+ parameters: {
227997
+ id: {
227998
+ type: "string",
227999
+ description: "Workspace ID",
228000
+ in: "path"
228001
+ }
228002
+ },
228003
+ response: {
228004
+ description: "Success",
228005
+ schema: {
228006
+ type: "object",
228007
+ title: "deleteWorkspaceResponse",
228008
+ additionalProperties: false
228009
+ }
228010
+ }
228011
+ },
227827
228012
  createIntegration: {
227828
228013
  name: "createIntegration",
227829
228014
  description: "Create integration",
@@ -229134,7 +229319,7 @@ var state = {
229134
229319
  title: "Botpress API",
229135
229320
  description: "API for Botpress Cloud",
229136
229321
  server: "https://api.botpress.cloud",
229137
- version: "0.3.3",
229322
+ version: "0.4.0",
229138
229323
  prefix: "v1"
229139
229324
  },
229140
229325
  errors: [
@@ -229249,7 +229434,9 @@ var state = {
229249
229434
  createBotBody: true,
229250
229435
  updateBotBody: true,
229251
229436
  transferBotBody: true,
229437
+ createWorkspaceBody: true,
229252
229438
  updateWorkspaceBody: true,
229439
+ changeWorkspacePlanBody: true,
229253
229440
  createIntegrationBody: true,
229254
229441
  updateIntegrationBody: true,
229255
229442
  createWorkspaceMemberBody: true,
@@ -229296,9 +229483,12 @@ var state = {
229296
229483
  getBotLogsResponse: true,
229297
229484
  getBotWebchatResponse: true,
229298
229485
  getBotAnalyticsResponse: true,
229486
+ createWorkspaceResponse: true,
229299
229487
  getWorkspaceResponse: true,
229300
229488
  updateWorkspaceResponse: true,
229301
229489
  listWorkspacesResponse: true,
229490
+ changeWorkspacePlanResponse: true,
229491
+ deleteWorkspaceResponse: true,
229302
229492
  createIntegrationResponse: true,
229303
229493
  updateIntegrationResponse: true,
229304
229494
  listIntegrationsResponse: true,
@@ -229363,10 +229553,12 @@ var state = {
229363
229553
  type: "boolean"
229364
229554
  },
229365
229555
  name: {
229366
- type: "string"
229556
+ type: "string",
229557
+ description: "Name of the [Integration](#schema_integration)"
229367
229558
  },
229368
229559
  version: {
229369
- type: "string"
229560
+ type: "string",
229561
+ description: "Version of the [Integration](#schema_integration)"
229370
229562
  },
229371
229563
  webhookUrl: {
229372
229564
  type: "string"
@@ -229389,6 +229581,35 @@ var state = {
229389
229581
  statusReason: {
229390
229582
  type: "string",
229391
229583
  nullable: true
229584
+ },
229585
+ id: {
229586
+ type: "string",
229587
+ description: "Id of the [Integration](#schema_integration)"
229588
+ },
229589
+ createdAt: {
229590
+ type: "string",
229591
+ format: "date-time",
229592
+ description: "Creation date of the [Integration](#schema_integration) in the ISO 8601 format"
229593
+ },
229594
+ updatedAt: {
229595
+ type: "string",
229596
+ format: "date-time",
229597
+ description: "Updating date of the [Integration](#schema_integration) in the ISO 8601 format"
229598
+ },
229599
+ title: {
229600
+ type: "string",
229601
+ minLength: 1,
229602
+ maxLength: 64,
229603
+ description: "Title of the integration. This is the name that will be displayed in the UI"
229604
+ },
229605
+ description: {
229606
+ type: "string",
229607
+ maxLength: 256,
229608
+ description: "Description of the integration. This is the description that will be displayed in the UI"
229609
+ },
229610
+ iconUrl: {
229611
+ type: "string",
229612
+ description: "URL of the icon of the integration. This is the icon that will be displayed in the UI"
229392
229613
  }
229393
229614
  },
229394
229615
  required: [
@@ -229398,7 +229619,13 @@ var state = {
229398
229619
  "webhookUrl",
229399
229620
  "configuration",
229400
229621
  "status",
229401
- "statusReason"
229622
+ "statusReason",
229623
+ "id",
229624
+ "createdAt",
229625
+ "updatedAt",
229626
+ "title",
229627
+ "description",
229628
+ "iconUrl"
229402
229629
  ],
229403
229630
  additionalProperties: false
229404
229631
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botpress/api",
3
- "version": "0.3.3",
3
+ "version": "0.4.0",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {