@kumori/aurora-interfaces 1.0.3 → 1.0.5

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,16 @@
1
+ import { Usage } from "./usage-interface";
2
+
3
+ export interface Revision {
4
+ id: string;
5
+ schema: any;
6
+ usage: Usage;
7
+ status: {
8
+ code: string;
9
+ message: string;
10
+ timestamp: string;
11
+ args: string[];
12
+ };
13
+ errorCode?: string;
14
+ errorMsg?: string;
15
+ createdAt?: string;
16
+ }
@@ -1,80 +1,79 @@
1
- import { Channel } from './channel-interface';
2
- import { Usage } from './usage-interface';
3
- import { Link } from './link-interface';
4
- import { Resource } from './resource-interface';
5
- import { Instance } from './instance-interface';
6
-
1
+ import { Channel } from "./channel-interface";
2
+ import { Usage } from "./usage-interface";
3
+ import { Link } from "./link-interface";
4
+ import { Resource } from "./resource-interface";
5
+ import { Instance } from "./instance-interface";
6
+ import { Revision } from "./revision-interface";
7
7
 
8
8
  export interface Service {
9
- id: string;
10
- tenant: string;
11
- account: string;
12
- environment: string;
13
- name: string;
14
- logo: string;
15
- description: string;
16
- revisions: string[];
17
- status: {
18
- message: string;
19
- timestamp: string;
20
- args: string[];
21
- code: string;
22
- };
23
- role: {
24
- name: string;
25
- instances: Instance[];
26
- logo?: string;
27
- category?: string;
28
- version?: string;
29
- description?: string;
30
- resource?: Resource[];
31
- parameters?: { [key: string]: string }[];
32
- registry?: string;
33
- imageTag?: string;
34
- entrypoint?: string;
35
- cmd?: string;
36
- scalling?: {
37
- cpu: {
38
- up: string;
39
- down: string;
40
- },
41
- memory: {
42
- up: string;
43
- down: string;
44
- }
45
- instances: {
46
- max: number;
47
- min: number;
48
- }
49
- histeresys: string;
50
- },
51
- hsize?: number;
52
- }[];
53
- links: Link[];
54
- resources: Resource[];
55
- usage: Usage;
56
- minReplicas?: number;
57
- maxReplicas?: number;
58
- lastDeployed?: string;
59
- project: string;
60
- registry: string;
61
- imageName: string;
62
- entrypoint: string;
63
- cmd: string;
64
- serverChannels: Channel[];
65
- clientChannels: Channel[];
66
- duplexChannels: Channel[];
67
- cloudProvider: string;
68
- currentRevision?: string;
69
- startedAt?: string;
70
- parameters: { [key: string]: string }[];
71
- error?: {
72
- code: string;
73
- message: string;
74
- timestamp?: string;
75
- };
76
- download? : boolean;
77
- serviceData? : Blob;
78
- dsl?: boolean;
9
+ id: string;
10
+ tenant: string;
11
+ account: string;
12
+ environment: string;
13
+ name: string;
14
+ logo: string;
15
+ description: string;
16
+ revisions: Revision[];
17
+ status: {
18
+ message: string;
19
+ timestamp: string;
20
+ args: string[];
21
+ code: string;
22
+ };
23
+ role: {
24
+ name: string;
25
+ instances: Instance[];
26
+ logo?: string;
27
+ category?: string;
28
+ version?: string;
29
+ description?: string;
30
+ resource?: Resource[];
31
+ parameters?: { [key: string]: string }[];
32
+ registry?: string;
33
+ imageTag?: string;
34
+ entrypoint?: string;
35
+ cmd?: string;
36
+ scalling?: {
37
+ cpu: {
38
+ up: string;
39
+ down: string;
40
+ };
41
+ memory: {
42
+ up: string;
43
+ down: string;
44
+ };
45
+ instances: {
46
+ max: number;
47
+ min: number;
48
+ };
49
+ histeresys: string;
50
+ };
51
+ hsize?: number;
52
+ }[];
53
+ links: Link[];
54
+ resources: Resource[];
55
+ usage: Usage;
56
+ minReplicas?: number;
57
+ maxReplicas?: number;
58
+ lastDeployed?: string;
59
+ project: string;
60
+ registry: string;
61
+ imageName: string;
62
+ entrypoint: string;
63
+ cmd: string;
64
+ serverChannels: Channel[];
65
+ clientChannels: Channel[];
66
+ duplexChannels: Channel[];
67
+ cloudProvider: string;
68
+ currentRevision?: string;
69
+ startedAt?: string;
70
+ parameters: { [key: string]: string }[];
71
+ error?: {
72
+ code: string;
73
+ message: string;
74
+ timestamp?: string;
75
+ };
76
+ download?: boolean;
77
+ serviceData?: Blob;
78
+ dsl?: boolean;
79
79
  }
80
-
@@ -1,96 +1,104 @@
1
- import { Notification } from './notification-interface';
2
- import { Plan } from './plan-interface';
3
- import { Token } from './token-interface';
4
- import { Tenant } from './tenant-interface';
5
- import { ClusterToken } from './token-interface';
6
- import { Organization } from './organization-interface';
1
+ import { Notification } from "./notification-interface";
2
+ import { Plan } from "./plan-interface";
3
+ import { Token } from "./token-interface";
4
+ import { Tenant } from "./tenant-interface";
5
+ import { ClusterToken } from "./token-interface";
6
+ import { Organization } from "./organization-interface";
7
7
 
8
8
  export interface Platform {
9
- instanceName: string;
10
- platformVersion: string;
11
- referenceDomain: string;
12
- apiVersions: string[];
13
- oidProviders: string[];
14
- iaasProviders: Record<string, any>;
15
- freemiumAdvancedLimits: {
16
- vcpu: { lowmark: number; highmark: number; unit: string };
17
- memory: { lowmark: number; highmark: number; unit: string };
18
- vstorage: { lowmark: number; highmark: number; unit: string };
19
- nrstorage: { lowmark: number; highmark: number; unit: string };
20
- rstorage: { lowmark: number; highmark: number; unit: string };
21
- storage: { lowmark: number; highmark: number; unit: string };
22
- cost: { lowmark: number; highmark: number; unit: string };
23
- };
24
- freemiumLimits: {
25
- vcpu: { lowmark: number; highmark: number; unit: string };
26
- memory: { lowmark: number; highmark: number; unit: string };
27
- vstorage: { lowmark: number; highmark: number; unit: string };
28
- nrstorage: { lowmark: number; highmark: number; unit: string };
29
- rstorage: { lowmark: number; highmark: number; unit: string };
30
- storage: { lowmark: number; highmark: number; unit: string };
31
- cost: { lowmark: number; highmark: number; unit: string };
32
- };
33
- portrange: number[];
9
+ instanceName: string;
10
+ platformVersion: string;
11
+ referenceDomain: string;
12
+ apiVersions: string[];
13
+ oidProviders: string[];
14
+ iaasProviders: Record<string, any>;
15
+ freemiumAdvancedLimits: {
16
+ vcpu: { lowmark: number; highmark: number; unit: string };
17
+ memory: { lowmark: number; highmark: number; unit: string };
18
+ vstorage: { lowmark: number; highmark: number; unit: string };
19
+ nrstorage: { lowmark: number; highmark: number; unit: string };
20
+ rstorage: { lowmark: number; highmark: number; unit: string };
21
+ storage: { lowmark: number; highmark: number; unit: string };
22
+ cost: { lowmark: number; highmark: number; unit: string };
23
+ };
24
+ freemiumLimits: {
25
+ vcpu: { lowmark: number; highmark: number; unit: string };
26
+ memory: { lowmark: number; highmark: number; unit: string };
27
+ vstorage: { lowmark: number; highmark: number; unit: string };
28
+ nrstorage: { lowmark: number; highmark: number; unit: string };
29
+ rstorage: { lowmark: number; highmark: number; unit: string };
30
+ storage: { lowmark: number; highmark: number; unit: string };
31
+ cost: { lowmark: number; highmark: number; unit: string };
32
+ };
33
+ portrange: number[];
34
34
  }
35
35
  export interface UserData {
36
- id: string;
37
- name: string;
38
- surname: string;
39
- provider: {
36
+ id: string;
37
+ name: string;
38
+ surname: string;
39
+ provider: {
40
40
  name: string;
41
41
  email: string;
42
42
  password?: string;
43
43
  }[];
44
- notificationsEnabled: string;
45
- organizations: Organization[];
46
- clusterTokens: ClusterToken[];
47
- tokens: Token[];
48
- tenants: Tenant[];
49
- axebowPlan: "freemium" | "premium";
50
- companyName: string;
51
- rol: string;
52
- platform?: Platform;
53
- status?: "logged" | "notlogged" | "maintenance" | "unknown";
54
- notifications?: Notification[];
55
- plans?: Plan[];
44
+ notificationsEnabled: string;
45
+ organizations: Organization[];
46
+ clusterTokens: ClusterToken[];
47
+ tokens: Token[];
48
+ tenants: Tenant[];
49
+ axebowPlan: "freemium" | "premium";
50
+ companyName: string;
51
+ rol: string;
52
+ platform?: Platform;
53
+ status?: "logged" | "notlogged" | "maintenance" | "unknown";
54
+ notifications?: Notification[];
55
+ plans?: Plan[];
56
+ discoveryMethod?: string;
56
57
  }
57
58
  export class User implements UserData {
58
- constructor(userData: UserData, tenants: Tenant[] = [], organizations: Organization[] = [], platform?: Platform) {
59
- this.id = userData.id || "";
60
- this.name = userData.name || "";
61
- this.surname = userData.surname || "";
62
- this.notificationsEnabled = userData.notificationsEnabled || "false";
63
- this.organizations = organizations || [];
64
- this.clusterTokens = userData.clusterTokens || [];
65
- this.tokens = userData.tokens || [];
66
- this.tenants = tenants || [];
67
- this.axebowPlan = userData.axebowPlan || "freemium";
68
- this.companyName = userData.companyName || "";
69
- this.rol = userData.rol || "user";
70
- this.platform = platform ?? userData.platform;
71
- this.status = userData.status || "logged";
72
- this.notifications = userData.notifications || [];
73
- this.plans = userData.plans || [];
74
- this.provider = userData.provider;
75
- }
76
- id: string;
77
- name: string;
78
- surname: string;
79
- provider: {
59
+ constructor(
60
+ userData: UserData,
61
+ tenants: Tenant[] = [],
62
+ organizations: Organization[] = [],
63
+ platform?: Platform,
64
+ ) {
65
+ this.id = userData.id || "";
66
+ this.name = userData.name || "";
67
+ this.surname = userData.surname || "";
68
+ this.notificationsEnabled = userData.notificationsEnabled || "false";
69
+ this.organizations = organizations || [];
70
+ this.clusterTokens = userData.clusterTokens || [];
71
+ this.tokens = userData.tokens || [];
72
+ this.tenants = tenants || [];
73
+ this.axebowPlan = userData.axebowPlan || "freemium";
74
+ this.companyName = userData.companyName || "";
75
+ this.rol = userData.rol || "user";
76
+ this.platform = platform ?? userData.platform;
77
+ this.status = userData.status || "logged";
78
+ this.notifications = userData.notifications || [];
79
+ this.plans = userData.plans || [];
80
+ this.provider = userData.provider;
81
+ this.discoveryMethod = userData.discoveryMethod;
82
+ }
83
+ id: string;
84
+ name: string;
85
+ surname: string;
86
+ provider: {
80
87
  name: string;
81
88
  email: string;
82
89
  password?: string;
83
90
  }[];
84
- notificationsEnabled: string;
85
- organizations: Organization[];
86
- clusterTokens: ClusterToken[];
87
- tokens: Token[];
88
- tenants: Tenant[];
89
- axebowPlan: "freemium" | "premium";
90
- companyName: string;
91
- rol: string;
92
- platform?: Platform;
93
- status?: "logged" | "notlogged" | "maintenance" | "unknown";
94
- notifications?: Notification[];
95
- plans?: Plan[];
91
+ notificationsEnabled: string;
92
+ organizations: Organization[];
93
+ clusterTokens: ClusterToken[];
94
+ tokens: Token[];
95
+ tenants: Tenant[];
96
+ axebowPlan: "freemium" | "premium";
97
+ companyName: string;
98
+ rol: string;
99
+ platform?: Platform;
100
+ status?: "logged" | "notlogged" | "maintenance" | "unknown";
101
+ notifications?: Notification[];
102
+ plans?: Plan[];
103
+ discoveryMethod?: string;
96
104
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kumori/aurora-interfaces",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "description": "aurora interfaces",
5
5
  "main": "export-interfaces.ts",
6
6
  "repository": {