@devopness/sdk-js 2.30.0 → 2.31.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.
@@ -0,0 +1,27 @@
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 { ApiBaseService } from "../../../services/ApiBaseService";
13
+ import { ApiResponse } from "../../../common/ApiResponse";
14
+ import { Log } from '../../generated/models';
15
+ /**
16
+ * ActionsLogsApiService - Auto-generated
17
+ */
18
+ export declare class ActionsLogsApiService extends ApiBaseService {
19
+ /**
20
+ *
21
+ * @summary Get action server step log
22
+ * @param {number} actionId The ID of the action.
23
+ * @param {number} actionStepOrder The action step order.
24
+ * @param {number} serverId The ID of the server.
25
+ */
26
+ getActionLog(actionId: number, actionStepOrder: number, serverId: number): Promise<ApiResponse<Log>>;
27
+ }
@@ -0,0 +1,57 @@
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
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
15
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16
+ return new (P || (P = Promise))(function (resolve, reject) {
17
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
18
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
19
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
20
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
21
+ });
22
+ };
23
+ Object.defineProperty(exports, "__esModule", { value: true });
24
+ exports.ActionsLogsApiService = void 0;
25
+ const ApiBaseService_1 = require("../../../services/ApiBaseService");
26
+ const ApiResponse_1 = require("../../../common/ApiResponse");
27
+ const Exceptions_1 = require("../../../common/Exceptions");
28
+ /**
29
+ * ActionsLogsApiService - Auto-generated
30
+ */
31
+ class ActionsLogsApiService extends ApiBaseService_1.ApiBaseService {
32
+ /**
33
+ *
34
+ * @summary Get action server step log
35
+ * @param {number} actionId The ID of the action.
36
+ * @param {number} actionStepOrder The action step order.
37
+ * @param {number} serverId The ID of the server.
38
+ */
39
+ getActionLog(actionId, actionStepOrder, serverId) {
40
+ return __awaiter(this, void 0, void 0, function* () {
41
+ if (actionId === null || actionId === undefined) {
42
+ throw new Exceptions_1.ArgumentNullException('actionId', 'getActionLog');
43
+ }
44
+ if (actionStepOrder === null || actionStepOrder === undefined) {
45
+ throw new Exceptions_1.ArgumentNullException('actionStepOrder', 'getActionLog');
46
+ }
47
+ if (serverId === null || serverId === undefined) {
48
+ throw new Exceptions_1.ArgumentNullException('serverId', 'getActionLog');
49
+ }
50
+ let queryString = '';
51
+ const requestUrl = '/actions/{action_id}/servers/{server_id}/steps/{action_step_order}/logs' + (queryString ? `?${queryString}` : '');
52
+ const response = yield this.get(requestUrl.replace(`{${"action_id"}}`, encodeURIComponent(String(actionId))).replace(`{${"action_step_order"}}`, encodeURIComponent(String(actionStepOrder))).replace(`{${"server_id"}}`, encodeURIComponent(String(serverId))));
53
+ return new ApiResponse_1.ApiResponse(response);
54
+ });
55
+ }
56
+ }
57
+ exports.ActionsLogsApiService = ActionsLogsApiService;
@@ -149,7 +149,6 @@ export * from './role-update';
149
149
  export * from './script-runner';
150
150
  export * from './server';
151
151
  export * from './server-action';
152
- export * from './server-action-log';
153
152
  export * from './server-action-log-step';
154
153
  export * from './server-blueprint';
155
154
  export * from './server-cloud-service';
@@ -165,7 +165,6 @@ __exportStar(require("./role-update"), exports);
165
165
  __exportStar(require("./script-runner"), exports);
166
166
  __exportStar(require("./server"), exports);
167
167
  __exportStar(require("./server-action"), exports);
168
- __exportStar(require("./server-action-log"), exports);
169
168
  __exportStar(require("./server-action-log-step"), exports);
170
169
  __exportStar(require("./server-blueprint"), exports);
171
170
  __exportStar(require("./server-cloud-service"), exports);
@@ -9,7 +9,8 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import { ServerActionLog } from './server-action-log';
12
+ import { ServerActionLogStep } from './server-action-log-step';
13
+ import { ServerRelation } from './server-relation';
13
14
  /**
14
15
  *
15
16
  * @export
@@ -17,15 +18,21 @@ import { ServerActionLog } from './server-action-log';
17
18
  */
18
19
  export interface Log {
19
20
  /**
20
- * The date and time when the requested log record was last updated
21
- * @type {string}
21
+ *
22
+ * @type {ServerRelation}
22
23
  * @memberof Log
23
24
  */
24
- updated_at?: string | null;
25
+ server: ServerRelation | null;
25
26
  /**
26
- * List of logs from multiple servers
27
- * @type {Array<ServerActionLog>}
27
+ *
28
+ * @type {ServerActionLogStep}
29
+ * @memberof Log
30
+ */
31
+ step: ServerActionLogStep | null;
32
+ /**
33
+ * The date and time when the requested log record was last updated
34
+ * @type {string}
28
35
  * @memberof Log
29
36
  */
30
- servers: Array<ServerActionLog>;
37
+ updated_at: string | null;
31
38
  }
@@ -1,3 +1,3 @@
1
- import { LogsApiService } from "../api/generated/apis/logs-api";
2
- export declare class LogService extends LogsApiService {
1
+ import { ActionsLogsApiService } from "../api/generated/apis/actions-logs-api";
2
+ export declare class LogService extends ActionsLogsApiService {
3
3
  }
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.LogService = void 0;
4
- const logs_api_1 = require("../api/generated/apis/logs-api");
5
- class LogService extends logs_api_1.LogsApiService {
4
+ const actions_logs_api_1 = require("../api/generated/apis/actions-logs-api");
5
+ class LogService extends actions_logs_api_1.ActionsLogsApiService {
6
6
  }
7
7
  exports.LogService = LogService;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devopness/sdk-js",
3
- "version": "2.30.0",
3
+ "version": "2.31.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -1,64 +0,0 @@
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 { ApiBaseService } from "../../../services/ApiBaseService";
13
- import { ApiResponse } from "../../../common/ApiResponse";
14
- import { ActionStepLog } from '../../generated/models';
15
- import { Log } from '../../generated/models';
16
- /**
17
- * LogsApiService - Auto-generated
18
- */
19
- export declare class LogsApiService extends ApiBaseService {
20
- /**
21
- *
22
- * @summary Get action log
23
- * @param {number} actionId Unique ID of the action to get logs from
24
- */
25
- getActionLog(actionId: number): Promise<ApiResponse<Log>>;
26
- /**
27
- *
28
- * @summary Get action step log
29
- * @param {number} actionId Unique ID of the action to get logs from
30
- * @param {number} serverId Unique ID of the server to get logs from
31
- * @param {number} actionStepOrder Step\&#39;s order number to get the logs from
32
- */
33
- getActionStepLog(actionId: number, serverId: number, actionStepOrder: number): Promise<ApiResponse<ActionStepLog>>;
34
- /**
35
- *
36
- * @summary Get service reload log
37
- * @param {number} serviceId The unique id of the service
38
- */
39
- getServiceReloadLog(serviceId: number): Promise<ApiResponse<Log>>;
40
- /**
41
- *
42
- * @summary Get service restart log
43
- * @param {number} serviceId The unique id of the service
44
- */
45
- getServiceRestartLog(serviceId: number): Promise<ApiResponse<Log>>;
46
- /**
47
- *
48
- * @summary Get service start log
49
- * @param {number} serviceId The unique id of the service
50
- */
51
- getServiceStartLog(serviceId: number): Promise<ApiResponse<Log>>;
52
- /**
53
- *
54
- * @summary Get service status log
55
- * @param {number} serviceId The unique id of the service
56
- */
57
- getServiceStatusLog(serviceId: number): Promise<ApiResponse<Log>>;
58
- /**
59
- *
60
- * @summary Get service stop log
61
- * @param {number} serviceId The unique id of the service
62
- */
63
- getServiceStopLog(serviceId: number): Promise<ApiResponse<Log>>;
64
- }
@@ -1,153 +0,0 @@
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
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
15
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16
- return new (P || (P = Promise))(function (resolve, reject) {
17
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
18
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
19
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
20
- step((generator = generator.apply(thisArg, _arguments || [])).next());
21
- });
22
- };
23
- Object.defineProperty(exports, "__esModule", { value: true });
24
- exports.LogsApiService = void 0;
25
- const ApiBaseService_1 = require("../../../services/ApiBaseService");
26
- const ApiResponse_1 = require("../../../common/ApiResponse");
27
- const Exceptions_1 = require("../../../common/Exceptions");
28
- /**
29
- * LogsApiService - Auto-generated
30
- */
31
- class LogsApiService extends ApiBaseService_1.ApiBaseService {
32
- /**
33
- *
34
- * @summary Get action log
35
- * @param {number} actionId Unique ID of the action to get logs from
36
- */
37
- getActionLog(actionId) {
38
- return __awaiter(this, void 0, void 0, function* () {
39
- if (actionId === null || actionId === undefined) {
40
- throw new Exceptions_1.ArgumentNullException('actionId', 'getActionLog');
41
- }
42
- let queryString = '';
43
- const requestUrl = '/logs/action/{action_id}' + (queryString ? `?${queryString}` : '');
44
- const response = yield this.get(requestUrl.replace(`{${"action_id"}}`, encodeURIComponent(String(actionId))));
45
- return new ApiResponse_1.ApiResponse(response);
46
- });
47
- }
48
- /**
49
- *
50
- * @summary Get action step log
51
- * @param {number} actionId Unique ID of the action to get logs from
52
- * @param {number} serverId Unique ID of the server to get logs from
53
- * @param {number} actionStepOrder Step\&#39;s order number to get the logs from
54
- */
55
- getActionStepLog(actionId, serverId, actionStepOrder) {
56
- return __awaiter(this, void 0, void 0, function* () {
57
- if (actionId === null || actionId === undefined) {
58
- throw new Exceptions_1.ArgumentNullException('actionId', 'getActionStepLog');
59
- }
60
- if (serverId === null || serverId === undefined) {
61
- throw new Exceptions_1.ArgumentNullException('serverId', 'getActionStepLog');
62
- }
63
- if (actionStepOrder === null || actionStepOrder === undefined) {
64
- throw new Exceptions_1.ArgumentNullException('actionStepOrder', 'getActionStepLog');
65
- }
66
- let queryString = '';
67
- const requestUrl = '/logs/action/{action_id}/server/{server_id}/step/{action_step_order}' + (queryString ? `?${queryString}` : '');
68
- const response = yield this.get(requestUrl.replace(`{${"action_id"}}`, encodeURIComponent(String(actionId))).replace(`{${"server_id"}}`, encodeURIComponent(String(serverId))).replace(`{${"action_step_order"}}`, encodeURIComponent(String(actionStepOrder))));
69
- return new ApiResponse_1.ApiResponse(response);
70
- });
71
- }
72
- /**
73
- *
74
- * @summary Get service reload log
75
- * @param {number} serviceId The unique id of the service
76
- */
77
- getServiceReloadLog(serviceId) {
78
- return __awaiter(this, void 0, void 0, function* () {
79
- if (serviceId === null || serviceId === undefined) {
80
- throw new Exceptions_1.ArgumentNullException('serviceId', 'getServiceReloadLog');
81
- }
82
- let queryString = '';
83
- const requestUrl = '/logs/service/{service_id}/reload' + (queryString ? `?${queryString}` : '');
84
- const response = yield this.get(requestUrl.replace(`{${"service_id"}}`, encodeURIComponent(String(serviceId))));
85
- return new ApiResponse_1.ApiResponse(response);
86
- });
87
- }
88
- /**
89
- *
90
- * @summary Get service restart log
91
- * @param {number} serviceId The unique id of the service
92
- */
93
- getServiceRestartLog(serviceId) {
94
- return __awaiter(this, void 0, void 0, function* () {
95
- if (serviceId === null || serviceId === undefined) {
96
- throw new Exceptions_1.ArgumentNullException('serviceId', 'getServiceRestartLog');
97
- }
98
- let queryString = '';
99
- const requestUrl = '/logs/service/{service_id}/restart' + (queryString ? `?${queryString}` : '');
100
- const response = yield this.get(requestUrl.replace(`{${"service_id"}}`, encodeURIComponent(String(serviceId))));
101
- return new ApiResponse_1.ApiResponse(response);
102
- });
103
- }
104
- /**
105
- *
106
- * @summary Get service start log
107
- * @param {number} serviceId The unique id of the service
108
- */
109
- getServiceStartLog(serviceId) {
110
- return __awaiter(this, void 0, void 0, function* () {
111
- if (serviceId === null || serviceId === undefined) {
112
- throw new Exceptions_1.ArgumentNullException('serviceId', 'getServiceStartLog');
113
- }
114
- let queryString = '';
115
- const requestUrl = '/logs/service/{service_id}/start' + (queryString ? `?${queryString}` : '');
116
- const response = yield this.get(requestUrl.replace(`{${"service_id"}}`, encodeURIComponent(String(serviceId))));
117
- return new ApiResponse_1.ApiResponse(response);
118
- });
119
- }
120
- /**
121
- *
122
- * @summary Get service status log
123
- * @param {number} serviceId The unique id of the service
124
- */
125
- getServiceStatusLog(serviceId) {
126
- return __awaiter(this, void 0, void 0, function* () {
127
- if (serviceId === null || serviceId === undefined) {
128
- throw new Exceptions_1.ArgumentNullException('serviceId', 'getServiceStatusLog');
129
- }
130
- let queryString = '';
131
- const requestUrl = '/logs/service/{service_id}/status' + (queryString ? `?${queryString}` : '');
132
- const response = yield this.get(requestUrl.replace(`{${"service_id"}}`, encodeURIComponent(String(serviceId))));
133
- return new ApiResponse_1.ApiResponse(response);
134
- });
135
- }
136
- /**
137
- *
138
- * @summary Get service stop log
139
- * @param {number} serviceId The unique id of the service
140
- */
141
- getServiceStopLog(serviceId) {
142
- return __awaiter(this, void 0, void 0, function* () {
143
- if (serviceId === null || serviceId === undefined) {
144
- throw new Exceptions_1.ArgumentNullException('serviceId', 'getServiceStopLog');
145
- }
146
- let queryString = '';
147
- const requestUrl = '/logs/service/{service_id}/stop' + (queryString ? `?${queryString}` : '');
148
- const response = yield this.get(requestUrl.replace(`{${"service_id"}}`, encodeURIComponent(String(serviceId))));
149
- return new ApiResponse_1.ApiResponse(response);
150
- });
151
- }
152
- }
153
- exports.LogsApiService = LogsApiService;
@@ -1,37 +0,0 @@
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 { ServerActionLogStep } from './server-action-log-step';
13
- /**
14
- *
15
- * @export
16
- * @interface ServerActionLog
17
- */
18
- export interface ServerActionLog {
19
- /**
20
- * The unique id of the server
21
- * @type {number}
22
- * @memberof ServerActionLog
23
- */
24
- id?: number;
25
- /**
26
- * The server\'s hostname
27
- * @type {string}
28
- * @memberof ServerActionLog
29
- */
30
- name?: string;
31
- /**
32
- * List of server action steps
33
- * @type {Array<ServerActionLogStep>}
34
- * @memberof ServerActionLog
35
- */
36
- steps?: Array<ServerActionLogStep>;
37
- }
@@ -1,14 +0,0 @@
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 });