@devopness/sdk-js 2.6.1 → 2.7.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.
@@ -13,6 +13,7 @@ import { ApiBaseService } from "../../../services/ApiBaseService";
13
13
  import { ApiResponse } from "../../../common/ApiResponse";
14
14
  import { PipelineStep } from '../../generated/models';
15
15
  import { PipelineStepCreate } from '../../generated/models';
16
+ import { PipelineStepUpdate } from '../../generated/models';
16
17
  /**
17
18
  * PipelinesStepsApiService - Auto-generated
18
19
  */
@@ -38,4 +39,12 @@ export declare class PipelinesStepsApiService extends ApiBaseService {
38
39
  * @param {number} stepId Unique ID of the step to be unlinked
39
40
  */
40
41
  unlinkStepFromPipeline(pipelineId: number, stepId: number): Promise<ApiResponse<void>>;
42
+ /**
43
+ *
44
+ * @summary Update a pipeline step
45
+ * @param {number} pipelineId Unique ID of the pipeline
46
+ * @param {number} stepId Unique ID of the pipeline step to update information from
47
+ * @param {PipelineStepUpdate} pipelineStepUpdate A JSON object containing pipeline step data
48
+ */
49
+ updatePipelineStep(pipelineId: number, stepId: number, pipelineStepUpdate: PipelineStepUpdate): Promise<ApiResponse<void>>;
41
50
  }
@@ -89,5 +89,29 @@ class PipelinesStepsApiService extends ApiBaseService_1.ApiBaseService {
89
89
  return new ApiResponse_1.ApiResponse(response);
90
90
  });
91
91
  }
92
+ /**
93
+ *
94
+ * @summary Update a pipeline step
95
+ * @param {number} pipelineId Unique ID of the pipeline
96
+ * @param {number} stepId Unique ID of the pipeline step to update information from
97
+ * @param {PipelineStepUpdate} pipelineStepUpdate A JSON object containing pipeline step data
98
+ */
99
+ updatePipelineStep(pipelineId, stepId, pipelineStepUpdate) {
100
+ return __awaiter(this, void 0, void 0, function* () {
101
+ if (pipelineId === null || pipelineId === undefined) {
102
+ throw new Exceptions_1.ArgumentNullException('pipelineId', 'updatePipelineStep');
103
+ }
104
+ if (stepId === null || stepId === undefined) {
105
+ throw new Exceptions_1.ArgumentNullException('stepId', 'updatePipelineStep');
106
+ }
107
+ if (pipelineStepUpdate === null || pipelineStepUpdate === undefined) {
108
+ throw new Exceptions_1.ArgumentNullException('pipelineStepUpdate', 'updatePipelineStep');
109
+ }
110
+ let queryString = '';
111
+ const requestUrl = '/pipelines/{pipeline_id}/steps/{step_id}' + (queryString ? `?${queryString}` : '');
112
+ const response = yield this.put(requestUrl.replace(`{${"pipeline_id"}}`, encodeURIComponent(String(pipelineId))).replace(`{${"step_id"}}`, encodeURIComponent(String(stepId))), pipelineStepUpdate);
113
+ return new ApiResponse_1.ApiResponse(response);
114
+ });
115
+ }
92
116
  }
93
117
  exports.PipelinesStepsApiService = PipelinesStepsApiService;
@@ -121,6 +121,7 @@ export * from './pipeline-create';
121
121
  export * from './pipeline-step';
122
122
  export * from './pipeline-step-create';
123
123
  export * from './pipeline-step-runner-name';
124
+ export * from './pipeline-step-update';
124
125
  export * from './project';
125
126
  export * from './project-create';
126
127
  export * from './project-relation';
@@ -137,6 +137,7 @@ __exportStar(require("./pipeline-create"), exports);
137
137
  __exportStar(require("./pipeline-step"), exports);
138
138
  __exportStar(require("./pipeline-step-create"), exports);
139
139
  __exportStar(require("./pipeline-step-runner-name"), exports);
140
+ __exportStar(require("./pipeline-step-update"), exports);
140
141
  __exportStar(require("./project"), exports);
141
142
  __exportStar(require("./project-create"), exports);
142
143
  __exportStar(require("./project-relation"), exports);
@@ -0,0 +1,49 @@
1
+ /**
2
+ * devopness API
3
+ * Devopness API - Painless essential DevOps to everyone
4
+ *
5
+ * The version of the OpenAPI document: latest
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { PipelineStepRunnerName } from './pipeline-step-runner-name';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface PipelineStepUpdate
17
+ */
18
+ export interface PipelineStepUpdate {
19
+ /**
20
+ * Name/short description of the script
21
+ * @type {string}
22
+ * @memberof PipelineStepUpdate
23
+ */
24
+ name: string;
25
+ /**
26
+ * A command line or multiline bash script
27
+ * @type {string}
28
+ * @memberof PipelineStepUpdate
29
+ */
30
+ command: string;
31
+ /**
32
+ *
33
+ * @type {PipelineStepRunnerName}
34
+ * @memberof PipelineStepUpdate
35
+ */
36
+ runner: PipelineStepRunnerName;
37
+ /**
38
+ * The name of the Unix user on behalf of which the script will be executed
39
+ * @type {string}
40
+ * @memberof PipelineStepUpdate
41
+ */
42
+ run_as_user?: string;
43
+ /**
44
+ * Repositions the pipeline step after the step with the given `trigger_order`
45
+ * @type {number}
46
+ * @memberof PipelineStepUpdate
47
+ */
48
+ trigger_after?: number;
49
+ }
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ /* eslint-disable */
3
+ /**
4
+ * devopness API
5
+ * Devopness API - Painless essential DevOps to everyone
6
+ *
7
+ * The version of the OpenAPI document: latest
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ Object.defineProperty(exports, "__esModule", { value: true });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devopness/sdk-js",
3
- "version": "2.6.1",
3
+ "version": "2.7.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },