@remnawave/backend-contract 2.0.0-alpha.21 → 2.0.0-alpha.22

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.
Files changed (35) hide show
  1. package/build/backend/commands/infra-billing/create-billing-node.command.d.ts +106 -54
  2. package/build/backend/commands/infra-billing/create-billing-node.command.d.ts.map +1 -1
  3. package/build/backend/commands/infra-billing/delete-billing-node-by-uuid.command.d.ts +106 -54
  4. package/build/backend/commands/infra-billing/delete-billing-node-by-uuid.command.d.ts.map +1 -1
  5. package/build/backend/commands/infra-billing/get-blling-nodes.command.d.ts +106 -54
  6. package/build/backend/commands/infra-billing/get-blling-nodes.command.d.ts.map +1 -1
  7. package/build/backend/commands/infra-billing/update-billing-node.command.d.ts +106 -54
  8. package/build/backend/commands/infra-billing/update-billing-node.command.d.ts.map +1 -1
  9. package/build/backend/commands/nodes/actions/disable.command.d.ts +105 -71
  10. package/build/backend/commands/nodes/actions/disable.command.d.ts.map +1 -1
  11. package/build/backend/commands/nodes/actions/enable.command.d.ts +105 -71
  12. package/build/backend/commands/nodes/actions/enable.command.d.ts.map +1 -1
  13. package/build/backend/commands/nodes/actions/reorder.command.d.ts +158 -98
  14. package/build/backend/commands/nodes/actions/reorder.command.d.ts.map +1 -1
  15. package/build/backend/commands/nodes/create.command.d.ts +123 -77
  16. package/build/backend/commands/nodes/create.command.d.ts.map +1 -1
  17. package/build/backend/commands/nodes/create.command.js +6 -4
  18. package/build/backend/commands/nodes/get-all.command.d.ts +105 -71
  19. package/build/backend/commands/nodes/get-all.command.d.ts.map +1 -1
  20. package/build/backend/commands/nodes/get-one.command.d.ts +105 -71
  21. package/build/backend/commands/nodes/get-one.command.d.ts.map +1 -1
  22. package/build/backend/commands/nodes/update.command.d.ts +176 -104
  23. package/build/backend/commands/nodes/update.command.d.ts.map +1 -1
  24. package/build/backend/commands/nodes/update.command.js +8 -4
  25. package/build/backend/models/infra-billing-available-node.schema.d.ts +53 -27
  26. package/build/backend/models/infra-billing-available-node.schema.d.ts.map +1 -1
  27. package/build/backend/models/infra-billing-node.schema.d.ts +53 -27
  28. package/build/backend/models/infra-billing-node.schema.d.ts.map +1 -1
  29. package/build/backend/models/nodes.schema.d.ts +79 -49
  30. package/build/backend/models/nodes.schema.d.ts.map +1 -1
  31. package/build/backend/models/nodes.schema.js +4 -2
  32. package/build/frontend/commands/nodes/create.command.js +6 -4
  33. package/build/frontend/commands/nodes/update.command.js +8 -4
  34. package/build/frontend/models/nodes.schema.js +4 -2
  35. package/package.json +1 -1
@@ -27,35 +27,61 @@ export declare const NodesSchema: z.ZodObject<{
27
27
  totalRam: z.ZodNullable<z.ZodString>;
28
28
  createdAt: z.ZodEffects<z.ZodString, Date, string>;
29
29
  updatedAt: z.ZodEffects<z.ZodString, Date, string>;
30
- activeConfigProfileUuid: z.ZodNullable<z.ZodString>;
31
- activeInbounds: z.ZodNullable<z.ZodArray<z.ZodObject<{
32
- uuid: z.ZodString;
33
- profileUuid: z.ZodString;
34
- tag: z.ZodString;
35
- type: z.ZodString;
36
- network: z.ZodNullable<z.ZodString>;
37
- security: z.ZodNullable<z.ZodString>;
38
- port: z.ZodNullable<z.ZodNumber>;
39
- rawInbound: z.ZodNullable<z.ZodUnknown>;
30
+ configProfile: z.ZodObject<{
31
+ activeConfigProfileUuid: z.ZodNullable<z.ZodString>;
32
+ activeInbounds: z.ZodArray<z.ZodObject<{
33
+ uuid: z.ZodString;
34
+ profileUuid: z.ZodString;
35
+ tag: z.ZodString;
36
+ type: z.ZodString;
37
+ network: z.ZodNullable<z.ZodString>;
38
+ security: z.ZodNullable<z.ZodString>;
39
+ port: z.ZodNullable<z.ZodNumber>;
40
+ rawInbound: z.ZodNullable<z.ZodUnknown>;
41
+ }, "strip", z.ZodTypeAny, {
42
+ type: string;
43
+ uuid: string;
44
+ profileUuid: string;
45
+ tag: string;
46
+ network: string | null;
47
+ security: string | null;
48
+ port: number | null;
49
+ rawInbound?: unknown;
50
+ }, {
51
+ type: string;
52
+ uuid: string;
53
+ profileUuid: string;
54
+ tag: string;
55
+ network: string | null;
56
+ security: string | null;
57
+ port: number | null;
58
+ rawInbound?: unknown;
59
+ }>, "many">;
40
60
  }, "strip", z.ZodTypeAny, {
41
- type: string;
42
- uuid: string;
43
- profileUuid: string;
44
- tag: string;
45
- network: string | null;
46
- security: string | null;
47
- port: number | null;
48
- rawInbound?: unknown;
61
+ activeConfigProfileUuid: string | null;
62
+ activeInbounds: {
63
+ type: string;
64
+ uuid: string;
65
+ profileUuid: string;
66
+ tag: string;
67
+ network: string | null;
68
+ security: string | null;
69
+ port: number | null;
70
+ rawInbound?: unknown;
71
+ }[];
49
72
  }, {
50
- type: string;
51
- uuid: string;
52
- profileUuid: string;
53
- tag: string;
54
- network: string | null;
55
- security: string | null;
56
- port: number | null;
57
- rawInbound?: unknown;
58
- }>, "many">>;
73
+ activeConfigProfileUuid: string | null;
74
+ activeInbounds: {
75
+ type: string;
76
+ uuid: string;
77
+ profileUuid: string;
78
+ tag: string;
79
+ network: string | null;
80
+ security: string | null;
81
+ port: number | null;
82
+ rawInbound?: unknown;
83
+ }[];
84
+ }>;
59
85
  providerUuid: z.ZodNullable<z.ZodString>;
60
86
  provider: z.ZodNullable<z.ZodObject<{
61
87
  uuid: z.ZodString;
@@ -107,17 +133,19 @@ export declare const NodesSchema: z.ZodObject<{
107
133
  cpuCount: number | null;
108
134
  cpuModel: string | null;
109
135
  totalRam: string | null;
110
- activeConfigProfileUuid: string | null;
111
- activeInbounds: {
112
- type: string;
113
- uuid: string;
114
- profileUuid: string;
115
- tag: string;
116
- network: string | null;
117
- security: string | null;
118
- port: number | null;
119
- rawInbound?: unknown;
120
- }[] | null;
136
+ configProfile: {
137
+ activeConfigProfileUuid: string | null;
138
+ activeInbounds: {
139
+ type: string;
140
+ uuid: string;
141
+ profileUuid: string;
142
+ tag: string;
143
+ network: string | null;
144
+ security: string | null;
145
+ port: number | null;
146
+ rawInbound?: unknown;
147
+ }[];
148
+ };
121
149
  providerUuid: string | null;
122
150
  provider: {
123
151
  uuid: string;
@@ -155,17 +183,19 @@ export declare const NodesSchema: z.ZodObject<{
155
183
  cpuCount: number | null;
156
184
  cpuModel: string | null;
157
185
  totalRam: string | null;
158
- activeConfigProfileUuid: string | null;
159
- activeInbounds: {
160
- type: string;
161
- uuid: string;
162
- profileUuid: string;
163
- tag: string;
164
- network: string | null;
165
- security: string | null;
166
- port: number | null;
167
- rawInbound?: unknown;
168
- }[] | null;
186
+ configProfile: {
187
+ activeConfigProfileUuid: string | null;
188
+ activeInbounds: {
189
+ type: string;
190
+ uuid: string;
191
+ profileUuid: string;
192
+ tag: string;
193
+ network: string | null;
194
+ security: string | null;
195
+ port: number | null;
196
+ rawInbound?: unknown;
197
+ }[];
198
+ };
169
199
  providerUuid: string | null;
170
200
  provider: {
171
201
  uuid: string;
@@ -1 +1 @@
1
- {"version":3,"file":"nodes.schema.d.ts","sourceRoot":"","sources":["../../../models/nodes.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAgDtB,CAAC"}
1
+ {"version":3,"file":"nodes.schema.d.ts","sourceRoot":"","sources":["../../../models/nodes.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkDtB,CAAC"}
@@ -41,8 +41,10 @@ exports.NodesSchema = zod_1.z.object({
41
41
  .string()
42
42
  .datetime()
43
43
  .transform((str) => new Date(str)),
44
- activeConfigProfileUuid: zod_1.z.nullable(zod_1.z.string().uuid()),
45
- activeInbounds: zod_1.z.nullable(zod_1.z.array(config_profile_inbounds_schema_1.ConfigProfileInboundsSchema)),
44
+ configProfile: zod_1.z.object({
45
+ activeConfigProfileUuid: zod_1.z.nullable(zod_1.z.string().uuid()),
46
+ activeInbounds: zod_1.z.array(config_profile_inbounds_schema_1.ConfigProfileInboundsSchema),
47
+ }),
46
48
  providerUuid: zod_1.z.nullable(zod_1.z.string().uuid()),
47
49
  provider: zod_1.z.nullable(infra_provider_schema_1.PartialInfraProviderSchema),
48
50
  });
@@ -35,10 +35,12 @@ var CreateNodeCommand;
35
35
  .number()
36
36
  .min(0.1, 'Consumption multiplier must be greater than 0')
37
37
  .transform((n) => Number(n.toFixed(1)))),
38
- activeConfigProfileUuid: zod_1.z.optional(zod_1.z.string().uuid()),
39
- activeInbounds: zod_1.z.optional(zod_1.z.array(zod_1.z.string().uuid(), {
40
- invalid_type_error: 'Active inbounds must be an array of UUIDs',
41
- })),
38
+ configProfile: zod_1.z.object({
39
+ activeConfigProfileUuid: zod_1.z.string().uuid(),
40
+ activeInbounds: zod_1.z.array(zod_1.z.string().uuid(), {
41
+ invalid_type_error: 'Config profile inbound UUID must be an array of UUIDs',
42
+ }),
43
+ }),
42
44
  providerUuid: zod_1.z.optional(zod_1.z.nullable(zod_1.z.string().uuid())),
43
45
  });
44
46
  CreateNodeCommand.ResponseSchema = zod_1.z.object({
@@ -31,10 +31,14 @@ var UpdateNodeCommand;
31
31
  .number()
32
32
  .min(0.1, 'Consumption multiplier must be greater than 0')
33
33
  .transform((n) => Number(n.toFixed(1)))),
34
- activeConfigProfileUuid: zod_1.z.optional(zod_1.z.string().uuid()),
35
- activeInbounds: zod_1.z.optional(zod_1.z.array(zod_1.z.string().uuid(), {
36
- invalid_type_error: 'Active inbounds must be an array of UUIDs',
37
- })),
34
+ configProfile: zod_1.z
35
+ .object({
36
+ activeConfigProfileUuid: zod_1.z.string().uuid(),
37
+ activeInbounds: zod_1.z.array(zod_1.z.string().uuid(), {
38
+ invalid_type_error: 'Must be an array of UUIDs',
39
+ }),
40
+ })
41
+ .optional(),
38
42
  providerUuid: zod_1.z.optional(zod_1.z.nullable(zod_1.z.string().uuid())),
39
43
  });
40
44
  UpdateNodeCommand.ResponseSchema = zod_1.z.object({
@@ -41,8 +41,10 @@ exports.NodesSchema = zod_1.z.object({
41
41
  .string()
42
42
  .datetime()
43
43
  .transform((str) => new Date(str)),
44
- activeConfigProfileUuid: zod_1.z.nullable(zod_1.z.string().uuid()),
45
- activeInbounds: zod_1.z.nullable(zod_1.z.array(config_profile_inbounds_schema_1.ConfigProfileInboundsSchema)),
44
+ configProfile: zod_1.z.object({
45
+ activeConfigProfileUuid: zod_1.z.nullable(zod_1.z.string().uuid()),
46
+ activeInbounds: zod_1.z.array(config_profile_inbounds_schema_1.ConfigProfileInboundsSchema),
47
+ }),
46
48
  providerUuid: zod_1.z.nullable(zod_1.z.string().uuid()),
47
49
  provider: zod_1.z.nullable(infra_provider_schema_1.PartialInfraProviderSchema),
48
50
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remnawave/backend-contract",
3
- "version": "2.0.0-alpha.21",
3
+ "version": "2.0.0-alpha.22",
4
4
  "public": true,
5
5
  "license": "AGPL-3.0-only",
6
6
  "description": "A contract library for Remnawave Backend. It can be used in backend and frontend.",