@breign/client 1.0.55 → 1.0.56

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.
@@ -38,6 +38,9 @@ export interface SetToolTokenRequest {
38
38
  toolId: string;
39
39
  setTokenRequestUio: SetTokenRequestUio;
40
40
  }
41
+ export interface SetupToolRequest {
42
+ toolId: string;
43
+ }
41
44
  /**
42
45
  *
43
46
  */
@@ -106,4 +109,12 @@ export declare class ToolsApi extends runtime.BaseAPI {
106
109
  * Set or update the tool secret token
107
110
  */
108
111
  setToolToken(toolId: string, setTokenRequestUio: SetTokenRequestUio, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
112
+ /**
113
+ * Complete the setup of a tool (oauth2 configuration)
114
+ */
115
+ setupToolRaw(requestParameters: SetupToolRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
116
+ /**
117
+ * Complete the setup of a tool (oauth2 configuration)
118
+ */
119
+ setupTool(toolId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
109
120
  }
@@ -276,5 +276,31 @@ class ToolsApi extends runtime.BaseAPI {
276
276
  async setToolToken(toolId, setTokenRequestUio, initOverrides) {
277
277
  await this.setToolTokenRaw({ toolId: toolId, setTokenRequestUio: setTokenRequestUio }, initOverrides);
278
278
  }
279
+ /**
280
+ * Complete the setup of a tool (oauth2 configuration)
281
+ */
282
+ async setupToolRaw(requestParameters, initOverrides) {
283
+ if (requestParameters['toolId'] == null) {
284
+ throw new runtime.RequiredError('toolId', 'Required parameter "toolId" was null or undefined when calling setupTool().');
285
+ }
286
+ const queryParameters = {};
287
+ const headerParameters = {};
288
+ if (this.configuration && this.configuration.apiKey) {
289
+ headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
290
+ }
291
+ const response = await this.request({
292
+ path: `/tools/{toolId}/setup`.replace(`{${"toolId"}}`, encodeURIComponent(String(requestParameters['toolId']))),
293
+ method: 'POST',
294
+ headers: headerParameters,
295
+ query: queryParameters,
296
+ }, initOverrides);
297
+ return new runtime.VoidApiResponse(response);
298
+ }
299
+ /**
300
+ * Complete the setup of a tool (oauth2 configuration)
301
+ */
302
+ async setupTool(toolId, initOverrides) {
303
+ await this.setupToolRaw({ toolId: toolId }, initOverrides);
304
+ }
279
305
  }
280
306
  exports.ToolsApi = ToolsApi;
package/dist/openapi.json CHANGED
@@ -5561,6 +5561,42 @@
5561
5561
  "tags" : [ "tools" ]
5562
5562
  }
5563
5563
  },
5564
+ "/tools/{toolId}/setup" : {
5565
+ "post" : {
5566
+ "operationId" : "setupTool",
5567
+ "parameters" : [ {
5568
+ "description" : "Tool identifier",
5569
+ "in" : "path",
5570
+ "name" : "toolId",
5571
+ "required" : true,
5572
+ "schema" : {
5573
+ "type" : "string"
5574
+ }
5575
+ } ],
5576
+ "responses" : {
5577
+ "204" : {
5578
+ "description" : "Tool setup completed"
5579
+ },
5580
+ "400" : {
5581
+ "description" : "Tool setup not required or failed."
5582
+ },
5583
+ "401" : {
5584
+ "description" : "Unauthorized"
5585
+ },
5586
+ "403" : {
5587
+ "description" : "Forbidden"
5588
+ },
5589
+ "404" : {
5590
+ "description" : "Tool not found"
5591
+ },
5592
+ "500" : {
5593
+ "description" : "Internal server error"
5594
+ }
5595
+ },
5596
+ "summary" : "Complete the setup of a tool (oauth2 configuration)",
5597
+ "tags" : [ "tools" ]
5598
+ }
5599
+ },
5564
5600
  "/tools/{toolId}/token" : {
5565
5601
  "put" : {
5566
5602
  "operationId" : "setToolToken",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@breign/client",
3
- "version": "1.0.55",
3
+ "version": "1.0.56",
4
4
  "main": "dist/index.js",
5
5
  "exports": {
6
6
  ".": "./dist/index.js",