attlaz-client 1.10.0 → 1.10.1
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/dist/Service/AdapterEndpoint.js +4 -4
- package/dist/Service/ChannelEndpoint.js +1 -1
- package/dist/Service/CodeSourceStrategiesEndpoint.js +2 -2
- package/dist/Service/ConfigEndpoint.js +1 -1
- package/dist/Service/Endpoint.js +1 -1
- package/dist/Service/FirewallEndpoint.js +3 -3
- package/dist/Service/FlowEndpoint.js +2 -2
- package/dist/Service/FlowRunRequestEndpoint.js +1 -1
- package/dist/Service/FlowRunStatsEndpoint.js +1 -1
- package/dist/Service/HealthAlertEndpoint.js +1 -1
- package/dist/Service/LogEndpoint.js +3 -3
- package/dist/Service/PlatformEndpoint.js +2 -2
- package/dist/Service/ProjectEndpoint.js +1 -1
- package/dist/Service/QueueEndpoint.js +1 -1
- package/dist/Service/SourcesAccountEndpoint.js +1 -1
- package/dist/Service/StorageEndpoint.js +1 -1
- package/dist/Service/SubscriberEndpoint.js +1 -1
- package/package.json +1 -1
|
@@ -5,7 +5,7 @@ import { AdapterConfiguration } from '../Model/Adapter/AdapterConfiguration.js';
|
|
|
5
5
|
export class AdapterEndpoint extends Endpoint {
|
|
6
6
|
async getAdapters() {
|
|
7
7
|
try {
|
|
8
|
-
let url = '/adapters
|
|
8
|
+
let url = '/adapters';
|
|
9
9
|
const result = await this.requestCollection(url, Adapter.parse);
|
|
10
10
|
return result;
|
|
11
11
|
}
|
|
@@ -31,7 +31,7 @@ export class AdapterEndpoint extends Endpoint {
|
|
|
31
31
|
}
|
|
32
32
|
async getAdapterConfiguration(adapterId) {
|
|
33
33
|
try {
|
|
34
|
-
let url = '/adapters/' + adapterId + '/configuration
|
|
34
|
+
let url = '/adapters/' + adapterId + '/configuration';
|
|
35
35
|
const result = await this.requestCollection(url, AdapterConfiguration.parse);
|
|
36
36
|
return result;
|
|
37
37
|
}
|
|
@@ -44,7 +44,7 @@ export class AdapterEndpoint extends Endpoint {
|
|
|
44
44
|
}
|
|
45
45
|
async getConnections(projectId) {
|
|
46
46
|
try {
|
|
47
|
-
let url = '/projects/' + projectId + '/connections
|
|
47
|
+
let url = '/projects/' + projectId + '/connections';
|
|
48
48
|
const result = await this.requestCollection(url, AdapterConnection.parse);
|
|
49
49
|
return result;
|
|
50
50
|
}
|
|
@@ -70,7 +70,7 @@ export class AdapterEndpoint extends Endpoint {
|
|
|
70
70
|
}
|
|
71
71
|
async saveConnection(projectId, adapter) {
|
|
72
72
|
try {
|
|
73
|
-
let url = '/projects/' + projectId + '/connections
|
|
73
|
+
let url = '/projects/' + projectId + '/connections';
|
|
74
74
|
const result = await this.requestObject(url, adapter, AdapterConnection.parse, 'POST');
|
|
75
75
|
const updatedAdapterConnection = result.getData();
|
|
76
76
|
if (updatedAdapterConnection === null) {
|
|
@@ -93,7 +93,7 @@ export class ChannelEndpoint extends Endpoint {
|
|
|
93
93
|
}
|
|
94
94
|
async testChannel(subscriberChannel) {
|
|
95
95
|
try {
|
|
96
|
-
let url = '/channels/' + subscriberChannel.id + '/test
|
|
96
|
+
let url = '/channels/' + subscriberChannel.id + '/test';
|
|
97
97
|
const parser = (raw) => {
|
|
98
98
|
return { tested: raw.tested };
|
|
99
99
|
};
|
|
@@ -3,13 +3,13 @@ import { CodeSourceBuildStrategy } from '../Model/Deployment/CodeSourceBuildStra
|
|
|
3
3
|
import { CodeSourceRunStrategy } from '../Model/Deployment/CodeSourceRunStrategy.js';
|
|
4
4
|
export class CodeSourceStrategiesEndpoint extends Endpoint {
|
|
5
5
|
async getAllDeployStrategies(workspaceId) {
|
|
6
|
-
let cmd = '/workspaces/' + workspaceId + '/codesources/deploystrategies
|
|
6
|
+
let cmd = '/workspaces/' + workspaceId + '/codesources/deploystrategies';
|
|
7
7
|
const result = await this.requestCollection(cmd, CodeSourceBuildStrategy.parse);
|
|
8
8
|
return result;
|
|
9
9
|
return result;
|
|
10
10
|
}
|
|
11
11
|
async getAllRunStrategies(workspaceId) {
|
|
12
|
-
let cmd = '/workspaces/' + workspaceId + '/codesources/runstrategies
|
|
12
|
+
let cmd = '/workspaces/' + workspaceId + '/codesources/runstrategies';
|
|
13
13
|
const result = await this.requestCollection(cmd, CodeSourceRunStrategy.parse);
|
|
14
14
|
return result;
|
|
15
15
|
return result;
|
|
@@ -32,7 +32,7 @@ export class ConfigEndpoint extends Endpoint {
|
|
|
32
32
|
}
|
|
33
33
|
async saveConfigs(projectId, configs) {
|
|
34
34
|
try {
|
|
35
|
-
let url = '/configvalues
|
|
35
|
+
let url = '/configvalues';
|
|
36
36
|
const result = await this.requestCollection(url, Config.parse, configs, 'POST');
|
|
37
37
|
return result;
|
|
38
38
|
}
|
package/dist/Service/Endpoint.js
CHANGED
|
@@ -65,7 +65,7 @@ export class Endpoint {
|
|
|
65
65
|
}
|
|
66
66
|
if (formattedKey.endsWith('_ids')) {
|
|
67
67
|
// TODO: update this to format correct plurals (for example category_ids should become categories instead of categorys)
|
|
68
|
-
formattedKey = formattedKey.substring(0, formattedKey.length - '_ids'.length) + 's
|
|
68
|
+
formattedKey = formattedKey.substring(0, formattedKey.length - '_ids'.length) + 's';
|
|
69
69
|
}
|
|
70
70
|
return formattedKey;
|
|
71
71
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Endpoint } from './Endpoint.js';
|
|
2
2
|
export class FirewallEndpoint extends Endpoint {
|
|
3
3
|
async getInformation() {
|
|
4
|
-
let cmd = '/system/firewall
|
|
4
|
+
let cmd = '/system/firewall/';
|
|
5
5
|
try {
|
|
6
6
|
const parser = (raw) => {
|
|
7
7
|
const info = {
|
|
@@ -22,7 +22,7 @@ export class FirewallEndpoint extends Endpoint {
|
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
async createIpRule(ip, action, description = '') {
|
|
25
|
-
let cmd = '/system/firewall/ip_rules
|
|
25
|
+
let cmd = '/system/firewall/ip_rules';
|
|
26
26
|
try {
|
|
27
27
|
const parser = (raw) => {
|
|
28
28
|
return raw.success;
|
|
@@ -43,7 +43,7 @@ export class FirewallEndpoint extends Endpoint {
|
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
async unblockIP(ip) {
|
|
46
|
-
let cmd = '/system/firewall/blocked_ips
|
|
46
|
+
let cmd = '/system/firewall/blocked_ips';
|
|
47
47
|
try {
|
|
48
48
|
const parser = (raw) => {
|
|
49
49
|
return { success: raw.success };
|
|
@@ -6,7 +6,7 @@ import { FlowSummary } from '../Model/Flow/FlowSummary.js';
|
|
|
6
6
|
export class FlowEndpoint extends Endpoint {
|
|
7
7
|
async getByProject(projectId) {
|
|
8
8
|
try {
|
|
9
|
-
let url = '/projects/' + projectId + '/flows
|
|
9
|
+
let url = '/projects/' + projectId + '/flows';
|
|
10
10
|
const result = await this.requestCollection(url, Flow.parse);
|
|
11
11
|
return result;
|
|
12
12
|
}
|
|
@@ -70,7 +70,7 @@ export class FlowEndpoint extends Endpoint {
|
|
|
70
70
|
}
|
|
71
71
|
async save(flow) {
|
|
72
72
|
try {
|
|
73
|
-
let url = '/projects/' + flow.projectId + '/flows
|
|
73
|
+
let url = '/projects/' + flow.projectId + '/flows';
|
|
74
74
|
const result = await this.requestObject(url, flow, Flow.parse, 'POST');
|
|
75
75
|
const updatedFlow = result.getData();
|
|
76
76
|
if (updatedFlow === null) {
|
|
@@ -2,7 +2,7 @@ import { Endpoint } from './Endpoint.js';
|
|
|
2
2
|
import { FlowRunResponse } from '../Model/Flow/FlowRunResponse.js';
|
|
3
3
|
export class FlowRunRequestEndpoint extends Endpoint {
|
|
4
4
|
async requestFlowRun(flowId, params, wait = false) {
|
|
5
|
-
let url = '/flows/' + flowId + '/flowrunrequests
|
|
5
|
+
let url = '/flows/' + flowId + '/flowrunrequests';
|
|
6
6
|
if (wait) {
|
|
7
7
|
url = url + "?wait=true";
|
|
8
8
|
}
|
|
@@ -2,7 +2,7 @@ import { Endpoint } from './Endpoint.js';
|
|
|
2
2
|
import { FlowRunStats } from '../Model/Flow/FlowRunStats.js';
|
|
3
3
|
export class FlowRunStatsEndpoint extends Endpoint {
|
|
4
4
|
async create(flowRunStats) {
|
|
5
|
-
let url = '/flowruns/' + flowRunStats.flowRunId + '/stats
|
|
5
|
+
let url = '/flowruns/' + flowRunStats.flowRunId + '/stats';
|
|
6
6
|
try {
|
|
7
7
|
const result = await this.requestObject(url, flowRunStats, FlowRunStats.parse, 'POST');
|
|
8
8
|
const createdFlowRunStat = result.getData();
|
|
@@ -3,7 +3,7 @@ import { HealthAlert } from '../Model/HealthAlert/HealthAlert.js';
|
|
|
3
3
|
export class HealthAlertEndpoint extends Endpoint {
|
|
4
4
|
async getLatestByProjectEnvironment(projectEnvironmentId) {
|
|
5
5
|
try {
|
|
6
|
-
|
|
6
|
+
const url = '/projectenvironments/' + projectEnvironmentId + '/health';
|
|
7
7
|
const result = await this.requestCollection(url, HealthAlert.parse);
|
|
8
8
|
return result;
|
|
9
9
|
}
|
|
@@ -63,7 +63,7 @@ export class LogEndpoint extends Endpoint {
|
|
|
63
63
|
}
|
|
64
64
|
async save(log) {
|
|
65
65
|
try {
|
|
66
|
-
let cmd = '/logstreams/' + Utils.base64encode(log.logStream.id) + '/logs
|
|
66
|
+
let cmd = '/logstreams/' + Utils.base64encode(log.logStream.id) + '/logs';
|
|
67
67
|
const result = await this.requestObject(cmd, log, Log.parse, 'POST');
|
|
68
68
|
const updatedLogEntry = result.getData();
|
|
69
69
|
if (updatedLogEntry === null) {
|
|
@@ -100,7 +100,7 @@ export class LogEndpoint extends Endpoint {
|
|
|
100
100
|
}
|
|
101
101
|
}
|
|
102
102
|
async clear(logStreamId) {
|
|
103
|
-
let cmd = '/logstreams/' + Utils.base64encode(logStreamId.id) + '/clear
|
|
103
|
+
let cmd = '/logstreams/' + Utils.base64encode(logStreamId.id) + '/clear';
|
|
104
104
|
try {
|
|
105
105
|
const parser = (raw) => {
|
|
106
106
|
return { cleared: raw.cleared };
|
|
@@ -122,7 +122,7 @@ export class LogEndpoint extends Endpoint {
|
|
|
122
122
|
}
|
|
123
123
|
async getInformation(logStreamId) {
|
|
124
124
|
try {
|
|
125
|
-
let url = '/logstreams/' + Utils.base64encode(logStreamId.id) + '/info
|
|
125
|
+
let url = '/logstreams/' + Utils.base64encode(logStreamId.id) + '/info';
|
|
126
126
|
const result = await this.requestObject(url, null, LogStreamInformation.parse);
|
|
127
127
|
return result.getData();
|
|
128
128
|
}
|
|
@@ -3,12 +3,12 @@ import { Platform } from '../Model/Worker/Platform.js';
|
|
|
3
3
|
import { PlatformImage } from '../Model/Worker/PlatformImage.js';
|
|
4
4
|
export class PlatformEndpoint extends Endpoint {
|
|
5
5
|
async getAll(workspaceId) {
|
|
6
|
-
let cmd = '/workspaces/' + workspaceId + '/platforms
|
|
6
|
+
let cmd = '/workspaces/' + workspaceId + '/platforms';
|
|
7
7
|
const result = await this.requestCollection(cmd, Platform.parse);
|
|
8
8
|
return result;
|
|
9
9
|
}
|
|
10
10
|
async getPlatformImages(workspaceId, platformId) {
|
|
11
|
-
let cmd = '/workspaces/' + workspaceId + '/platforms/' + platformId + '/images
|
|
11
|
+
let cmd = '/workspaces/' + workspaceId + '/platforms/' + platformId + '/images';
|
|
12
12
|
const result = await this.requestCollection(cmd, PlatformImage.parse);
|
|
13
13
|
return result;
|
|
14
14
|
}
|
|
@@ -44,7 +44,7 @@ export class ProjectEndpoint extends Endpoint {
|
|
|
44
44
|
}
|
|
45
45
|
async save(project) {
|
|
46
46
|
try {
|
|
47
|
-
let url = '/projects
|
|
47
|
+
let url = '/projects';
|
|
48
48
|
const result = await this.requestObject(url, project, Project.parse, 'POST');
|
|
49
49
|
const updatedProject = result.getData();
|
|
50
50
|
if (updatedProject === null) {
|
|
@@ -3,7 +3,7 @@ import { QueueStatus } from '../Model/Queue/QueueStatus.js';
|
|
|
3
3
|
export class QueueEndpoint extends Endpoint {
|
|
4
4
|
async getByProjectEnvironment(projectEnvironmentId) {
|
|
5
5
|
try {
|
|
6
|
-
let url = '/projectenvironments/' + projectEnvironmentId + '/queues
|
|
6
|
+
let url = '/projectenvironments/' + projectEnvironmentId + '/queues';
|
|
7
7
|
const result = await this.requestObject(url, null, QueueStatus.parse);
|
|
8
8
|
return result.getData();
|
|
9
9
|
}
|
|
@@ -60,7 +60,7 @@ export class SourcesAccountEndpoint extends Endpoint {
|
|
|
60
60
|
}
|
|
61
61
|
async saveCodeSource(codeSource) {
|
|
62
62
|
try {
|
|
63
|
-
let url = '/codesources
|
|
63
|
+
let url = '/codesources/';
|
|
64
64
|
const result = await this.requestObject(url, codeSource, CodeSource.parse, 'POST');
|
|
65
65
|
const updatedCodeSource = result.getData();
|
|
66
66
|
if (updatedCodeSource === null) {
|
|
@@ -46,7 +46,7 @@ export class StorageEndpoint extends Endpoint {
|
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
async getPoolItemsInformation(projectEnvironmentId, storageType, poolKey) {
|
|
49
|
-
let cmd = '/projectenvironments/' + projectEnvironmentId + '/storage/' + storageType + '/' + poolKey + '/items
|
|
49
|
+
let cmd = '/projectenvironments/' + projectEnvironmentId + '/storage/' + storageType + '/' + poolKey + '/items';
|
|
50
50
|
try {
|
|
51
51
|
const result = await this.requestCollection(cmd, StorageItemInformation.parse, null, 'GET');
|
|
52
52
|
return result;
|
|
@@ -15,7 +15,7 @@ export class SubscriberEndpoint extends Endpoint {
|
|
|
15
15
|
return result;
|
|
16
16
|
}
|
|
17
17
|
async save(subscriber) {
|
|
18
|
-
let url = '/flows/' + subscriber.flowId + '/subscribers
|
|
18
|
+
let url = '/flows/' + subscriber.flowId + '/subscribers';
|
|
19
19
|
const result = await this.requestObject(url, subscriber, Subscriber.parseRaw, 'POST');
|
|
20
20
|
const createdSubscriber = result.getData();
|
|
21
21
|
if (createdSubscriber === null) {
|