@remnawave/backend-contract 0.3.7 → 0.3.8
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/build/backend/api/controllers/hosts.d.ts +1 -0
- package/build/backend/api/controllers/hosts.d.ts.map +1 -1
- package/build/backend/api/controllers/hosts.js +1 -0
- package/build/backend/api/routes.d.ts +1 -0
- package/build/backend/api/routes.d.ts.map +1 -1
- package/build/backend/api/routes.js +1 -0
- package/build/backend/commands/hosts/get-one.command.d.ts +92 -0
- package/build/backend/commands/hosts/get-one.command.d.ts.map +1 -0
- package/build/backend/commands/hosts/get-one.command.js +17 -0
- package/build/backend/commands/hosts/index.d.ts +1 -0
- package/build/backend/commands/hosts/index.d.ts.map +1 -1
- package/build/backend/commands/hosts/index.js +1 -0
- package/build/backend/constants/errors/errors.d.ts +5 -0
- package/build/backend/constants/errors/errors.d.ts.map +1 -1
- package/build/backend/constants/errors/errors.js +5 -0
- package/build/frontend/api/controllers/hosts.js +1 -0
- package/build/frontend/api/routes.js +1 -0
- package/build/frontend/commands/hosts/get-one.command.js +17 -0
- package/build/frontend/commands/hosts/index.js +1 -0
- package/build/frontend/constants/errors/errors.js +5 -0
- package/package.json +1 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"hosts.d.ts","sourceRoot":"","sources":["../../../../api/controllers/hosts.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,EAAG,OAAgB,CAAC;AAEjD,eAAO,MAAM,YAAY
|
1
|
+
{"version":3,"file":"hosts.d.ts","sourceRoot":"","sources":["../../../../api/controllers/hosts.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,EAAG,OAAgB,CAAC;AAEjD,eAAO,MAAM,YAAY;;;;;;;;CAQf,CAAC"}
|
@@ -67,6 +67,7 @@ export declare const REST_API: {
|
|
67
67
|
readonly UPDATE_MANY: "/api/hosts/many";
|
68
68
|
readonly REORDER: "/api/hosts/reorder";
|
69
69
|
readonly DELETE: (uuid: string) => string;
|
70
|
+
readonly GET_ONE: (uuid: string) => string;
|
70
71
|
};
|
71
72
|
readonly SYSTEM: {
|
72
73
|
readonly STATS: "/api/system/stats";
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"routes.d.ts","sourceRoot":"","sources":["../../../api/routes.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,IAAI,EAAG,MAAe,CAAC;AACpC,eAAO,MAAM,YAAY,EAAG,UAAmB,CAAC;AAChD,eAAO,MAAM,cAAc,EAAG,SAAkB,CAAC;AAEjD,eAAO,MAAM,QAAQ;;;;;;;;gCAQE,MAAM;;;;;;;;gCASN,MAAM;;;iCAIL,MAAM;iCAEN,MAAM;iCAEN,MAAM;gCAEP,MAAM;;;;;;;;;;;;;;;;qCAiBD,MAAM;gDAEK,MAAM;6CAET,MAAM;8DAEW,MAAM;6CAEvB,MAAM;sCAEb,MAAM;qCAEP,MAAM;qCAEN,MAAM;;;4CAIC,MAAM;;;;kDAKA,MAAM;uCAEjB,MAAM;;;kCAIX,MAAM;uCAED,MAAM;;;;;;;;gCASb,MAAM;;;;;;;;
|
1
|
+
{"version":3,"file":"routes.d.ts","sourceRoot":"","sources":["../../../api/routes.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,IAAI,EAAG,MAAe,CAAC;AACpC,eAAO,MAAM,YAAY,EAAG,UAAmB,CAAC;AAChD,eAAO,MAAM,cAAc,EAAG,SAAkB,CAAC;AAEjD,eAAO,MAAM,QAAQ;;;;;;;;gCAQE,MAAM;;;;;;;;gCASN,MAAM;;;iCAIL,MAAM;iCAEN,MAAM;iCAEN,MAAM;gCAEP,MAAM;;;;;;;;;;;;;;;;qCAiBD,MAAM;gDAEK,MAAM;6CAET,MAAM;8DAEW,MAAM;6CAEvB,MAAM;sCAEb,MAAM;qCAEP,MAAM;qCAEN,MAAM;;;4CAIC,MAAM;;;;kDAKA,MAAM;uCAEjB,MAAM;;;kCAIX,MAAM;uCAED,MAAM;;;;;;;;gCASb,MAAM;iCAEL,MAAM;;;;;;;;8CASO,MAAM;;;CAIjC,CAAC"}
|
@@ -104,6 +104,7 @@ exports.REST_API = {
|
|
104
104
|
UPDATE_MANY: `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.UPDATE_MANY}`,
|
105
105
|
REORDER: `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.REORDER}`,
|
106
106
|
DELETE: (uuid) => `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.DELETE}/${uuid}`,
|
107
|
+
GET_ONE: (uuid) => `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.GET_ONE}/${uuid}`,
|
107
108
|
},
|
108
109
|
SYSTEM: {
|
109
110
|
STATS: `${exports.ROOT}/${CONTROLLERS.SYSTEM_CONTROLLER}/${CONTROLLERS.SYSTEM_ROUTES.STATS}`,
|
@@ -0,0 +1,92 @@
|
|
1
|
+
import { z } from 'zod';
|
2
|
+
export declare namespace GetOneHostCommand {
|
3
|
+
const url: (uuid: string) => string;
|
4
|
+
const TSQ_url: string;
|
5
|
+
const RequestSchema: z.ZodObject<{
|
6
|
+
uuid: z.ZodString;
|
7
|
+
}, "strip", z.ZodTypeAny, {
|
8
|
+
uuid: string;
|
9
|
+
}, {
|
10
|
+
uuid: string;
|
11
|
+
}>;
|
12
|
+
type Request = z.infer<typeof RequestSchema>;
|
13
|
+
const ResponseSchema: z.ZodObject<{
|
14
|
+
response: z.ZodObject<{
|
15
|
+
uuid: z.ZodString;
|
16
|
+
inboundUuid: z.ZodString;
|
17
|
+
viewPosition: z.ZodNumber;
|
18
|
+
remark: z.ZodString;
|
19
|
+
address: z.ZodString;
|
20
|
+
port: z.ZodNumber;
|
21
|
+
path: z.ZodNullable<z.ZodString>;
|
22
|
+
sni: z.ZodNullable<z.ZodString>;
|
23
|
+
host: z.ZodNullable<z.ZodString>;
|
24
|
+
alpn: z.ZodNullable<z.ZodString>;
|
25
|
+
fingerprint: z.ZodNullable<z.ZodString>;
|
26
|
+
allowInsecure: z.ZodDefault<z.ZodBoolean>;
|
27
|
+
isDisabled: z.ZodDefault<z.ZodBoolean>;
|
28
|
+
}, "strip", z.ZodTypeAny, {
|
29
|
+
uuid: string;
|
30
|
+
path: string | null;
|
31
|
+
inboundUuid: string;
|
32
|
+
viewPosition: number;
|
33
|
+
remark: string;
|
34
|
+
address: string;
|
35
|
+
port: number;
|
36
|
+
sni: string | null;
|
37
|
+
host: string | null;
|
38
|
+
alpn: string | null;
|
39
|
+
fingerprint: string | null;
|
40
|
+
allowInsecure: boolean;
|
41
|
+
isDisabled: boolean;
|
42
|
+
}, {
|
43
|
+
uuid: string;
|
44
|
+
path: string | null;
|
45
|
+
inboundUuid: string;
|
46
|
+
viewPosition: number;
|
47
|
+
remark: string;
|
48
|
+
address: string;
|
49
|
+
port: number;
|
50
|
+
sni: string | null;
|
51
|
+
host: string | null;
|
52
|
+
alpn: string | null;
|
53
|
+
fingerprint: string | null;
|
54
|
+
allowInsecure?: boolean | undefined;
|
55
|
+
isDisabled?: boolean | undefined;
|
56
|
+
}>;
|
57
|
+
}, "strip", z.ZodTypeAny, {
|
58
|
+
response: {
|
59
|
+
uuid: string;
|
60
|
+
path: string | null;
|
61
|
+
inboundUuid: string;
|
62
|
+
viewPosition: number;
|
63
|
+
remark: string;
|
64
|
+
address: string;
|
65
|
+
port: number;
|
66
|
+
sni: string | null;
|
67
|
+
host: string | null;
|
68
|
+
alpn: string | null;
|
69
|
+
fingerprint: string | null;
|
70
|
+
allowInsecure: boolean;
|
71
|
+
isDisabled: boolean;
|
72
|
+
};
|
73
|
+
}, {
|
74
|
+
response: {
|
75
|
+
uuid: string;
|
76
|
+
path: string | null;
|
77
|
+
inboundUuid: string;
|
78
|
+
viewPosition: number;
|
79
|
+
remark: string;
|
80
|
+
address: string;
|
81
|
+
port: number;
|
82
|
+
sni: string | null;
|
83
|
+
host: string | null;
|
84
|
+
alpn: string | null;
|
85
|
+
fingerprint: string | null;
|
86
|
+
allowInsecure?: boolean | undefined;
|
87
|
+
isDisabled?: boolean | undefined;
|
88
|
+
};
|
89
|
+
}>;
|
90
|
+
type Response = z.infer<typeof ResponseSchema>;
|
91
|
+
}
|
92
|
+
//# sourceMappingURL=get-one.command.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"get-one.command.d.ts","sourceRoot":"","sources":["../../../../commands/hosts/get-one.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,iBAAiB,CAAC;IACxB,MAAM,GAAG,0BAAyB,CAAC;IACnC,MAAM,OAAO,QAAe,CAAC;IAE7B,MAAM,aAAa;;;;;;MAExB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAEzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.GetOneHostCommand = void 0;
|
4
|
+
const zod_1 = require("zod");
|
5
|
+
const api_1 = require("../../api");
|
6
|
+
const __1 = require("../..");
|
7
|
+
var GetOneHostCommand;
|
8
|
+
(function (GetOneHostCommand) {
|
9
|
+
GetOneHostCommand.url = api_1.REST_API.HOSTS.GET_ONE;
|
10
|
+
GetOneHostCommand.TSQ_url = GetOneHostCommand.url(':uuid');
|
11
|
+
GetOneHostCommand.RequestSchema = zod_1.z.object({
|
12
|
+
uuid: zod_1.z.string().uuid(),
|
13
|
+
});
|
14
|
+
GetOneHostCommand.ResponseSchema = zod_1.z.object({
|
15
|
+
response: __1.HostsSchema,
|
16
|
+
});
|
17
|
+
})(GetOneHostCommand || (exports.GetOneHostCommand = GetOneHostCommand = {}));
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../commands/hosts/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC"}
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../commands/hosts/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC"}
|
@@ -17,5 +17,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./create.command"), exports);
|
18
18
|
__exportStar(require("./delete.command"), exports);
|
19
19
|
__exportStar(require("./get-all.command"), exports);
|
20
|
+
__exportStar(require("./get-one.command"), exports);
|
20
21
|
__exportStar(require("./reorder.command"), exports);
|
21
22
|
__exportStar(require("./update.command"), exports);
|
@@ -369,5 +369,10 @@ export declare const ERRORS: {
|
|
369
369
|
readonly message: "Disable node error";
|
370
370
|
readonly httpCode: 500;
|
371
371
|
};
|
372
|
+
readonly GET_ONE_HOST_ERROR: {
|
373
|
+
readonly code: "A070";
|
374
|
+
readonly message: "Get one host error";
|
375
|
+
readonly httpCode: 500;
|
376
|
+
};
|
372
377
|
};
|
373
378
|
//# sourceMappingURL=errors.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../constants/errors/errors.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAwJY,MAAM;;;;;;;;;;wCAUN,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCA4IN,MAAM
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../constants/errors/errors.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAwJY,MAAM;;;;;;;;;;wCAUN,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCA4IN,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2C3B,CAAC"}
|
@@ -104,6 +104,7 @@ exports.REST_API = {
|
|
104
104
|
UPDATE_MANY: `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.UPDATE_MANY}`,
|
105
105
|
REORDER: `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.REORDER}`,
|
106
106
|
DELETE: (uuid) => `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.DELETE}/${uuid}`,
|
107
|
+
GET_ONE: (uuid) => `${exports.ROOT}/${CONTROLLERS.HOSTS_CONTROLLER}/${CONTROLLERS.HOSTS_ROUTES.GET_ONE}/${uuid}`,
|
107
108
|
},
|
108
109
|
SYSTEM: {
|
109
110
|
STATS: `${exports.ROOT}/${CONTROLLERS.SYSTEM_CONTROLLER}/${CONTROLLERS.SYSTEM_ROUTES.STATS}`,
|
@@ -0,0 +1,17 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.GetOneHostCommand = void 0;
|
4
|
+
const zod_1 = require("zod");
|
5
|
+
const api_1 = require("../../api");
|
6
|
+
const __1 = require("../..");
|
7
|
+
var GetOneHostCommand;
|
8
|
+
(function (GetOneHostCommand) {
|
9
|
+
GetOneHostCommand.url = api_1.REST_API.HOSTS.GET_ONE;
|
10
|
+
GetOneHostCommand.TSQ_url = GetOneHostCommand.url(':uuid');
|
11
|
+
GetOneHostCommand.RequestSchema = zod_1.z.object({
|
12
|
+
uuid: zod_1.z.string().uuid(),
|
13
|
+
});
|
14
|
+
GetOneHostCommand.ResponseSchema = zod_1.z.object({
|
15
|
+
response: __1.HostsSchema,
|
16
|
+
});
|
17
|
+
})(GetOneHostCommand || (exports.GetOneHostCommand = GetOneHostCommand = {}));
|
@@ -17,5 +17,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./create.command"), exports);
|
18
18
|
__exportStar(require("./delete.command"), exports);
|
19
19
|
__exportStar(require("./get-all.command"), exports);
|
20
|
+
__exportStar(require("./get-one.command"), exports);
|
20
21
|
__exportStar(require("./reorder.command"), exports);
|
21
22
|
__exportStar(require("./update.command"), exports);
|