@remnawave/backend-contract 0.3.20 → 0.3.23

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 (73) hide show
  1. package/build/backend/api/controllers/subscription.d.ts +1 -0
  2. package/build/backend/api/controllers/subscription.d.ts.map +1 -1
  3. package/build/backend/api/controllers/subscription.js +1 -0
  4. package/build/backend/api/routes.d.ts +2 -1
  5. package/build/backend/api/routes.d.ts.map +1 -1
  6. package/build/backend/api/routes.js +2 -1
  7. package/build/backend/commands/hosts/get-one.command.js +2 -2
  8. package/build/backend/commands/subscription/get-outline-subscription-by-short-uuid.command.d.ts +20 -0
  9. package/build/backend/commands/subscription/get-outline-subscription-by-short-uuid.command.d.ts.map +1 -0
  10. package/build/backend/commands/subscription/get-outline-subscription-by-short-uuid.command.js +15 -0
  11. package/build/backend/commands/subscription/get-subscription-by-short-uuid-by-client-type.command.d.ts +24 -0
  12. package/build/backend/commands/subscription/get-subscription-by-short-uuid-by-client-type.command.d.ts.map +1 -0
  13. package/build/backend/commands/subscription/get-subscription-by-short-uuid-by-client-type.command.js +15 -0
  14. package/build/backend/commands/subscription/get-subscription-by-short-uuid.command.d.ts +0 -6
  15. package/build/backend/commands/subscription/get-subscription-by-short-uuid.command.d.ts.map +1 -1
  16. package/build/backend/commands/subscription/get-subscription-by-short-uuid.command.js +0 -2
  17. package/build/backend/commands/subscription/index.d.ts +2 -0
  18. package/build/backend/commands/subscription/index.d.ts.map +1 -1
  19. package/build/backend/commands/subscription/index.js +2 -0
  20. package/build/backend/commands/subscription-settings/get-subscription-settings.command.d.ts +5 -0
  21. package/build/backend/commands/subscription-settings/get-subscription-settings.command.d.ts.map +1 -1
  22. package/build/backend/commands/subscription-settings/update-subscription-settings.command.d.ts +8 -0
  23. package/build/backend/commands/subscription-settings/update-subscription-settings.command.d.ts.map +1 -1
  24. package/build/backend/commands/subscription-settings/update-subscription-settings.command.js +1 -0
  25. package/build/backend/commands/subscription-template/get-template.command.d.ts +9 -7
  26. package/build/backend/commands/subscription-template/get-template.command.d.ts.map +1 -1
  27. package/build/backend/commands/subscription-template/update-template.command.d.ts +8 -6
  28. package/build/backend/commands/subscription-template/update-template.command.d.ts.map +1 -1
  29. package/build/backend/commands/users/create-user.command.js +1 -1
  30. package/build/backend/commands/users/{disable-user.command.ts.d.ts → disable-user.command.d.ts} +1 -1
  31. package/build/backend/commands/users/disable-user.command.d.ts.map +1 -0
  32. package/build/backend/commands/users/get-user-by-email.command.js +1 -1
  33. package/build/backend/commands/users/index.d.ts +1 -1
  34. package/build/backend/commands/users/index.d.ts.map +1 -1
  35. package/build/backend/commands/users/index.js +1 -1
  36. package/build/backend/commands/users/update-user.command.js +1 -1
  37. package/build/backend/constants/errors/errors.d.ts +1 -1
  38. package/build/backend/constants/errors/errors.js +1 -1
  39. package/build/backend/constants/subscription-template/template-type/index.d.ts +1 -0
  40. package/build/backend/constants/subscription-template/template-type/index.d.ts.map +1 -1
  41. package/build/backend/constants/subscription-template/template-type/index.js +1 -0
  42. package/build/backend/constants/subscription-template/template-type/request-template-type.constant.d.ts +12 -0
  43. package/build/backend/constants/subscription-template/template-type/request-template-type.constant.d.ts.map +1 -0
  44. package/build/backend/constants/subscription-template/template-type/request-template-type.constant.js +12 -0
  45. package/build/backend/constants/subscription-template/template-type/template-type.constant.d.ts +2 -1
  46. package/build/backend/constants/subscription-template/template-type/template-type.constant.d.ts.map +1 -1
  47. package/build/backend/constants/subscription-template/template-type/template-type.constant.js +1 -0
  48. package/build/backend/models/subscription-settings.schema.d.ts +3 -0
  49. package/build/backend/models/subscription-settings.schema.d.ts.map +1 -1
  50. package/build/backend/models/subscription-settings.schema.js +5 -1
  51. package/build/backend/models/users.schema.js +1 -1
  52. package/build/frontend/api/controllers/subscription.js +1 -0
  53. package/build/frontend/api/routes.js +2 -1
  54. package/build/frontend/commands/hosts/get-one.command.js +2 -2
  55. package/build/frontend/commands/subscription/get-outline-subscription-by-short-uuid.command.js +15 -0
  56. package/build/frontend/commands/subscription/get-subscription-by-short-uuid-by-client-type.command.js +15 -0
  57. package/build/frontend/commands/subscription/get-subscription-by-short-uuid.command.js +0 -2
  58. package/build/frontend/commands/subscription/index.js +2 -0
  59. package/build/frontend/commands/subscription-settings/update-subscription-settings.command.js +1 -0
  60. package/build/frontend/commands/users/create-user.command.js +1 -1
  61. package/build/frontend/commands/users/get-user-by-email.command.js +1 -1
  62. package/build/frontend/commands/users/index.js +1 -1
  63. package/build/frontend/commands/users/update-user.command.js +1 -1
  64. package/build/frontend/constants/errors/errors.js +1 -1
  65. package/build/frontend/constants/subscription-template/template-type/index.js +1 -0
  66. package/build/frontend/constants/subscription-template/template-type/request-template-type.constant.js +12 -0
  67. package/build/frontend/constants/subscription-template/template-type/template-type.constant.js +1 -0
  68. package/build/frontend/models/subscription-settings.schema.js +5 -1
  69. package/build/frontend/models/users.schema.js +1 -1
  70. package/package.json +1 -1
  71. package/build/backend/commands/users/disable-user.command.ts.d.ts.map +0 -1
  72. /package/build/backend/commands/users/{disable-user.command.ts.js → disable-user.command.js} +0 -0
  73. /package/build/frontend/commands/users/{disable-user.command.ts.js → disable-user.command.js} +0 -0
@@ -1,6 +1,7 @@
1
1
  export declare const SUBSCRIPTION_CONTROLLER: "sub";
2
2
  export declare const SUBSCRIPTION_ROUTES: {
3
3
  readonly GET: "";
4
+ readonly GET_OUTLINE: "/outline";
4
5
  readonly GET_INFO: "/info";
5
6
  };
6
7
  //# sourceMappingURL=subscription.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"subscription.d.ts","sourceRoot":"","sources":["../../../../api/controllers/subscription.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,uBAAuB,EAAG,KAAc,CAAC;AAEtD,eAAO,MAAM,mBAAmB;;;CAGtB,CAAC"}
1
+ {"version":3,"file":"subscription.d.ts","sourceRoot":"","sources":["../../../../api/controllers/subscription.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,uBAAuB,EAAG,KAAc,CAAC;AAEtD,eAAO,MAAM,mBAAmB;;;;CAItB,CAAC"}
@@ -4,5 +4,6 @@ exports.SUBSCRIPTION_ROUTES = exports.SUBSCRIPTION_CONTROLLER = void 0;
4
4
  exports.SUBSCRIPTION_CONTROLLER = 'sub';
5
5
  exports.SUBSCRIPTION_ROUTES = {
6
6
  GET: '',
7
+ GET_OUTLINE: '/outline',
7
8
  GET_INFO: '/info',
8
9
  };
@@ -58,6 +58,7 @@ export declare const REST_API: {
58
58
  };
59
59
  readonly SUBSCRIPTION: {
60
60
  readonly GET: (shortUuid: string) => string;
61
+ readonly GET_OUTLINE: (shortUuid: string) => string;
61
62
  readonly GET_INFO: (shortUuid: string) => string;
62
63
  };
63
64
  readonly HOSTS: {
@@ -75,7 +76,7 @@ export declare const REST_API: {
75
76
  readonly NODES_STATISTIC: "/api/system/statistics/nodes";
76
77
  };
77
78
  readonly SUBSCRIPTION_TEMPLATE: {
78
- readonly GET_INFO: (subscriptionType: string) => string;
79
+ readonly GET_INFO: (templateType: string) => string;
79
80
  readonly UPDATE_TEMPLATE: "/api/subscription-templates/update-template";
80
81
  };
81
82
  readonly SUBSCRIPTION_SETTINGS: {
@@ -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;iCAEL,MAAM;;;;;;;;8CASO,MAAM;;;;;;;CAQjC,CAAC"}
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;0CAEE,MAAM;uCAET,MAAM;;;;;;;;gCASb,MAAM;iCAEL,MAAM;;;;;;;;0CASG,MAAM;;;;;;;CAQ7B,CAAC"}
@@ -95,6 +95,7 @@ exports.REST_API = {
95
95
  },
96
96
  SUBSCRIPTION: {
97
97
  GET: (shortUuid) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_ROUTES.GET}/${shortUuid}`,
98
+ GET_OUTLINE: (shortUuid) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_ROUTES.GET_OUTLINE}/${shortUuid}/`,
98
99
  GET_INFO: (shortUuid) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_CONTROLLER}/${shortUuid}${CONTROLLERS.SUBSCRIPTION_ROUTES.GET_INFO}`,
99
100
  },
100
101
  HOSTS: {
@@ -112,7 +113,7 @@ exports.REST_API = {
112
113
  NODES_STATISTIC: `${exports.ROOT}/${CONTROLLERS.SYSTEM_CONTROLLER}/${CONTROLLERS.SYSTEM_ROUTES.STATISTIC.NODES}`,
113
114
  },
114
115
  SUBSCRIPTION_TEMPLATE: {
115
- GET_INFO: (subscriptionType) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_ROUTES.GET_TEMPLATE}/${subscriptionType}`,
116
+ GET_INFO: (templateType) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_ROUTES.GET_TEMPLATE}/${templateType}`,
116
117
  UPDATE_TEMPLATE: `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_ROUTES.UPDATE_TEMPLATE}`,
117
118
  },
118
119
  SUBSCRIPTION_SETTINGS: {
@@ -2,8 +2,8 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.GetOneHostCommand = void 0;
4
4
  const zod_1 = require("zod");
5
+ const models_1 = require("../../models");
5
6
  const api_1 = require("../../api");
6
- const __1 = require("../..");
7
7
  var GetOneHostCommand;
8
8
  (function (GetOneHostCommand) {
9
9
  GetOneHostCommand.url = api_1.REST_API.HOSTS.GET_ONE;
@@ -12,6 +12,6 @@ var GetOneHostCommand;
12
12
  uuid: zod_1.z.string().uuid(),
13
13
  });
14
14
  GetOneHostCommand.ResponseSchema = zod_1.z.object({
15
- response: __1.HostsSchema,
15
+ response: models_1.HostsSchema,
16
16
  });
17
17
  })(GetOneHostCommand || (exports.GetOneHostCommand = GetOneHostCommand = {}));
@@ -0,0 +1,20 @@
1
+ import { z } from 'zod';
2
+ export declare namespace GetOutlineSubscriptionByShortUuidCommand {
3
+ const url: (shortUuid: string) => string;
4
+ const TSQ_url: string;
5
+ const RequestSchema: z.ZodObject<{
6
+ shortUuid: z.ZodString;
7
+ type: z.ZodOptional<z.ZodString>;
8
+ encodedTag: z.ZodOptional<z.ZodString>;
9
+ }, "strip", z.ZodTypeAny, {
10
+ shortUuid: string;
11
+ type?: string | undefined;
12
+ encodedTag?: string | undefined;
13
+ }, {
14
+ shortUuid: string;
15
+ type?: string | undefined;
16
+ encodedTag?: string | undefined;
17
+ }>;
18
+ type Request = z.infer<typeof RequestSchema>;
19
+ }
20
+ //# sourceMappingURL=get-outline-subscription-by-short-uuid.command.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-outline-subscription-by-short-uuid.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription/get-outline-subscription-by-short-uuid.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,yBAAiB,wCAAwC,CAAC;IAC/C,MAAM,GAAG,+BAA4B,CAAC;IACtC,MAAM,OAAO,QAAoB,CAAC;IAElC,MAAM,aAAa;;;;;;;;;;;;MAIxB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;CACvD"}
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetOutlineSubscriptionByShortUuidCommand = void 0;
4
+ const zod_1 = require("zod");
5
+ const api_1 = require("../../api");
6
+ var GetOutlineSubscriptionByShortUuidCommand;
7
+ (function (GetOutlineSubscriptionByShortUuidCommand) {
8
+ GetOutlineSubscriptionByShortUuidCommand.url = api_1.REST_API.SUBSCRIPTION.GET;
9
+ GetOutlineSubscriptionByShortUuidCommand.TSQ_url = GetOutlineSubscriptionByShortUuidCommand.url(':shortUuid');
10
+ GetOutlineSubscriptionByShortUuidCommand.RequestSchema = zod_1.z.object({
11
+ shortUuid: zod_1.z.string(),
12
+ type: zod_1.z.optional(zod_1.z.string()),
13
+ encodedTag: zod_1.z.optional(zod_1.z.string()),
14
+ });
15
+ })(GetOutlineSubscriptionByShortUuidCommand || (exports.GetOutlineSubscriptionByShortUuidCommand = GetOutlineSubscriptionByShortUuidCommand = {}));
@@ -0,0 +1,24 @@
1
+ import { z } from 'zod';
2
+ export declare namespace GetSubscriptionByShortUuidByClientTypeCommand {
3
+ const url: (shortUuid: string) => string;
4
+ const TSQ_url: string;
5
+ const RequestSchema: z.ZodObject<{
6
+ shortUuid: z.ZodString;
7
+ clientType: z.ZodNativeEnum<{
8
+ readonly STASH: "stash";
9
+ readonly SINGBOX: "singbox";
10
+ readonly SINGBOX_LEGACY: "singbox-legacy";
11
+ readonly MIHOMO: "mihomo";
12
+ readonly XRAY_JSON: "json";
13
+ readonly CLASH: "clash";
14
+ }>;
15
+ }, "strip", z.ZodTypeAny, {
16
+ shortUuid: string;
17
+ clientType: "stash" | "singbox" | "singbox-legacy" | "mihomo" | "json" | "clash";
18
+ }, {
19
+ shortUuid: string;
20
+ clientType: "stash" | "singbox" | "singbox-legacy" | "mihomo" | "json" | "clash";
21
+ }>;
22
+ type Request = z.infer<typeof RequestSchema>;
23
+ }
24
+ //# sourceMappingURL=get-subscription-by-short-uuid-by-client-type.command.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-subscription-by-short-uuid-by-client-type.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription/get-subscription-by-short-uuid-by-client-type.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,6CAA6C,CAAC;IACpD,MAAM,GAAG,+BAA4B,CAAC;IACtC,MAAM,OAAO,QAAoB,CAAC;IAElC,MAAM,aAAa;;;;;;;;;;;;;;;;MAGxB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;CACvD"}
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetSubscriptionByShortUuidByClientTypeCommand = void 0;
4
+ const zod_1 = require("zod");
5
+ const constants_1 = require("../../constants");
6
+ const api_1 = require("../../api");
7
+ var GetSubscriptionByShortUuidByClientTypeCommand;
8
+ (function (GetSubscriptionByShortUuidByClientTypeCommand) {
9
+ GetSubscriptionByShortUuidByClientTypeCommand.url = api_1.REST_API.SUBSCRIPTION.GET;
10
+ GetSubscriptionByShortUuidByClientTypeCommand.TSQ_url = GetSubscriptionByShortUuidByClientTypeCommand.url(':shortUuid');
11
+ GetSubscriptionByShortUuidByClientTypeCommand.RequestSchema = zod_1.z.object({
12
+ shortUuid: zod_1.z.string(),
13
+ clientType: zod_1.z.nativeEnum(constants_1.REQUEST_TEMPLATE_TYPE),
14
+ });
15
+ })(GetSubscriptionByShortUuidByClientTypeCommand || (exports.GetSubscriptionByShortUuidByClientTypeCommand = GetSubscriptionByShortUuidByClientTypeCommand = {}));
@@ -4,16 +4,10 @@ export declare namespace GetSubscriptionByShortUuidCommand {
4
4
  const TSQ_url: string;
5
5
  const RequestSchema: z.ZodObject<{
6
6
  shortUuid: z.ZodString;
7
- type: z.ZodOptional<z.ZodString>;
8
- encodedTag: z.ZodOptional<z.ZodString>;
9
7
  }, "strip", z.ZodTypeAny, {
10
8
  shortUuid: string;
11
- type?: string | undefined;
12
- encodedTag?: string | undefined;
13
9
  }, {
14
10
  shortUuid: string;
15
- type?: string | undefined;
16
- encodedTag?: string | undefined;
17
11
  }>;
18
12
  type Request = z.infer<typeof RequestSchema>;
19
13
  }
@@ -1 +1 @@
1
- {"version":3,"file":"get-subscription-by-short-uuid.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription/get-subscription-by-short-uuid.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,yBAAiB,iCAAiC,CAAC;IACxC,MAAM,GAAG,+BAA4B,CAAC;IACtC,MAAM,OAAO,QAAoB,CAAC;IAElC,MAAM,aAAa;;;;;;;;;;;;MAIxB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;CACvD"}
1
+ {"version":3,"file":"get-subscription-by-short-uuid.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription/get-subscription-by-short-uuid.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,yBAAiB,iCAAiC,CAAC;IACxC,MAAM,GAAG,+BAA4B,CAAC;IACtC,MAAM,OAAO,QAAoB,CAAC;IAElC,MAAM,aAAa;;;;;;MAExB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;CACvD"}
@@ -9,7 +9,5 @@ var GetSubscriptionByShortUuidCommand;
9
9
  GetSubscriptionByShortUuidCommand.TSQ_url = GetSubscriptionByShortUuidCommand.url(':shortUuid');
10
10
  GetSubscriptionByShortUuidCommand.RequestSchema = zod_1.z.object({
11
11
  shortUuid: zod_1.z.string(),
12
- type: zod_1.z.optional(zod_1.z.string()),
13
- encodedTag: zod_1.z.optional(zod_1.z.string()),
14
12
  });
15
13
  })(GetSubscriptionByShortUuidCommand || (exports.GetSubscriptionByShortUuidCommand = GetSubscriptionByShortUuidCommand = {}));
@@ -1,3 +1,5 @@
1
+ export * from './get-outline-subscription-by-short-uuid.command';
2
+ export * from './get-subscription-by-short-uuid-by-client-type.command';
1
3
  export * from './get-subscription-by-short-uuid.command';
2
4
  export * from './get-subscription-info-by-short-uuid.command';
3
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../commands/subscription/index.ts"],"names":[],"mappings":"AAAA,cAAc,0CAA0C,CAAC;AACzD,cAAc,+CAA+C,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../commands/subscription/index.ts"],"names":[],"mappings":"AAAA,cAAc,kDAAkD,CAAC;AACjE,cAAc,yDAAyD,CAAC;AACxE,cAAc,0CAA0C,CAAC;AACzD,cAAc,+CAA+C,CAAC"}
@@ -14,5 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./get-outline-subscription-by-short-uuid.command"), exports);
18
+ __exportStar(require("./get-subscription-by-short-uuid-by-client-type.command"), exports);
17
19
  __exportStar(require("./get-subscription-by-short-uuid.command"), exports);
18
20
  __exportStar(require("./get-subscription-info-by-short-uuid.command"), exports);
@@ -9,6 +9,7 @@ export declare namespace GetSubscriptionSettingsCommand {
9
9
  supportLink: z.ZodString;
10
10
  profileUpdateInterval: z.ZodNumber;
11
11
  isProfileWebpageUrlEnabled: z.ZodBoolean;
12
+ serveJsonAtBaseSubscription: z.ZodBoolean;
12
13
  happAnnounce: z.ZodNullable<z.ZodString>;
13
14
  happRouting: z.ZodNullable<z.ZodString>;
14
15
  expiredUsersRemarks: z.ZodArray<z.ZodString, "many">;
@@ -24,6 +25,7 @@ export declare namespace GetSubscriptionSettingsCommand {
24
25
  supportLink: string;
25
26
  profileUpdateInterval: number;
26
27
  isProfileWebpageUrlEnabled: boolean;
28
+ serveJsonAtBaseSubscription: boolean;
27
29
  happAnnounce: string | null;
28
30
  happRouting: string | null;
29
31
  expiredUsersRemarks: string[];
@@ -37,6 +39,7 @@ export declare namespace GetSubscriptionSettingsCommand {
37
39
  supportLink: string;
38
40
  profileUpdateInterval: number;
39
41
  isProfileWebpageUrlEnabled: boolean;
42
+ serveJsonAtBaseSubscription: boolean;
40
43
  happAnnounce: string | null;
41
44
  happRouting: string | null;
42
45
  expiredUsersRemarks: string[];
@@ -52,6 +55,7 @@ export declare namespace GetSubscriptionSettingsCommand {
52
55
  supportLink: string;
53
56
  profileUpdateInterval: number;
54
57
  isProfileWebpageUrlEnabled: boolean;
58
+ serveJsonAtBaseSubscription: boolean;
55
59
  happAnnounce: string | null;
56
60
  happRouting: string | null;
57
61
  expiredUsersRemarks: string[];
@@ -67,6 +71,7 @@ export declare namespace GetSubscriptionSettingsCommand {
67
71
  supportLink: string;
68
72
  profileUpdateInterval: number;
69
73
  isProfileWebpageUrlEnabled: boolean;
74
+ serveJsonAtBaseSubscription: boolean;
70
75
  happAnnounce: string | null;
71
76
  happRouting: string | null;
72
77
  expiredUsersRemarks: string[];
@@ -1 +1 @@
1
- {"version":3,"file":"get-subscription-settings.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-settings/get-subscription-settings.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,8BAA8B,CAAC;IACrC,MAAM,GAAG,kCAA8C,CAAC;IACxD,MAAM,OAAO,kCAAM,CAAC;IAEpB,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAEzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
1
+ {"version":3,"file":"get-subscription-settings.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-settings/get-subscription-settings.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,8BAA8B,CAAC;IACrC,MAAM,GAAG,kCAA8C,CAAC;IACxD,MAAM,OAAO,kCAAM,CAAC;IAEpB,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAEzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
@@ -8,6 +8,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
8
8
  supportLink: z.ZodOptional<z.ZodString>;
9
9
  profileUpdateInterval: z.ZodOptional<z.ZodNumber>;
10
10
  isProfileWebpageUrlEnabled: z.ZodOptional<z.ZodBoolean>;
11
+ serveJsonAtBaseSubscription: z.ZodOptional<z.ZodBoolean>;
11
12
  happAnnounce: z.ZodOptional<z.ZodNullable<z.ZodString>>;
12
13
  happRouting: z.ZodOptional<z.ZodNullable<z.ZodString>>;
13
14
  expiredUsersRemarks: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
@@ -19,6 +20,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
19
20
  supportLink?: string | undefined;
20
21
  profileUpdateInterval?: number | undefined;
21
22
  isProfileWebpageUrlEnabled?: boolean | undefined;
23
+ serveJsonAtBaseSubscription?: boolean | undefined;
22
24
  happAnnounce?: string | null | undefined;
23
25
  happRouting?: string | null | undefined;
24
26
  expiredUsersRemarks?: string[] | undefined;
@@ -30,6 +32,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
30
32
  supportLink?: string | undefined;
31
33
  profileUpdateInterval?: number | undefined;
32
34
  isProfileWebpageUrlEnabled?: boolean | undefined;
35
+ serveJsonAtBaseSubscription?: boolean | undefined;
33
36
  happAnnounce?: string | null | undefined;
34
37
  happRouting?: string | null | undefined;
35
38
  expiredUsersRemarks?: string[] | undefined;
@@ -44,6 +47,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
44
47
  supportLink: z.ZodString;
45
48
  profileUpdateInterval: z.ZodNumber;
46
49
  isProfileWebpageUrlEnabled: z.ZodBoolean;
50
+ serveJsonAtBaseSubscription: z.ZodBoolean;
47
51
  happAnnounce: z.ZodNullable<z.ZodString>;
48
52
  happRouting: z.ZodNullable<z.ZodString>;
49
53
  expiredUsersRemarks: z.ZodArray<z.ZodString, "many">;
@@ -59,6 +63,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
59
63
  supportLink: string;
60
64
  profileUpdateInterval: number;
61
65
  isProfileWebpageUrlEnabled: boolean;
66
+ serveJsonAtBaseSubscription: boolean;
62
67
  happAnnounce: string | null;
63
68
  happRouting: string | null;
64
69
  expiredUsersRemarks: string[];
@@ -72,6 +77,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
72
77
  supportLink: string;
73
78
  profileUpdateInterval: number;
74
79
  isProfileWebpageUrlEnabled: boolean;
80
+ serveJsonAtBaseSubscription: boolean;
75
81
  happAnnounce: string | null;
76
82
  happRouting: string | null;
77
83
  expiredUsersRemarks: string[];
@@ -87,6 +93,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
87
93
  supportLink: string;
88
94
  profileUpdateInterval: number;
89
95
  isProfileWebpageUrlEnabled: boolean;
96
+ serveJsonAtBaseSubscription: boolean;
90
97
  happAnnounce: string | null;
91
98
  happRouting: string | null;
92
99
  expiredUsersRemarks: string[];
@@ -102,6 +109,7 @@ export declare namespace UpdateSubscriptionSettingsCommand {
102
109
  supportLink: string;
103
110
  profileUpdateInterval: number;
104
111
  isProfileWebpageUrlEnabled: boolean;
112
+ serveJsonAtBaseSubscription: boolean;
105
113
  happAnnounce: string | null;
106
114
  happRouting: string | null;
107
115
  expiredUsersRemarks: string[];
@@ -1 +1 @@
1
- {"version":3,"file":"update-subscription-settings.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-settings/update-subscription-settings.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,iCAAiC,CAAC;IACxC,MAAM,GAAG,qCAAiD,CAAC;IAC3D,MAAM,OAAO,qCAAM,CAAC;IAEpB,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAmBxB,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"}
1
+ {"version":3,"file":"update-subscription-settings.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-settings/update-subscription-settings.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,iCAAiC,CAAC;IACxC,MAAM,GAAG,qCAAiD,CAAC;IAC3D,MAAM,OAAO,qCAAM,CAAC;IAEpB,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAoBxB,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"}
@@ -14,6 +14,7 @@ var UpdateSubscriptionSettingsCommand;
14
14
  supportLink: zod_1.z.optional(zod_1.z.string()),
15
15
  profileUpdateInterval: zod_1.z.optional(zod_1.z.number().int()),
16
16
  isProfileWebpageUrlEnabled: zod_1.z.optional(zod_1.z.boolean()),
17
+ serveJsonAtBaseSubscription: zod_1.z.optional(zod_1.z.boolean()),
17
18
  happAnnounce: zod_1.z.optional(zod_1.z
18
19
  .string()
19
20
  .max(200, { message: 'Announce must be less than 200 characters' })
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
2
  export declare namespace GetSubscriptionTemplateCommand {
3
- const url: (subscriptionType: string) => string;
3
+ const url: (templateType: string) => string;
4
4
  const TSQ_url: string;
5
5
  const RequestSchema: z.ZodObject<{
6
6
  templateType: z.ZodNativeEnum<{
@@ -9,11 +9,12 @@ export declare namespace GetSubscriptionTemplateCommand {
9
9
  readonly SINGBOX_LEGACY: "SINGBOX_LEGACY";
10
10
  readonly MIHOMO: "MIHOMO";
11
11
  readonly XRAY_JSON: "XRAY_JSON";
12
+ readonly CLASH: "CLASH";
12
13
  }>;
13
14
  }, "strip", z.ZodTypeAny, {
14
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
15
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
15
16
  }, {
16
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
17
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
17
18
  }>;
18
19
  type Request = z.infer<typeof RequestSchema>;
19
20
  const ResponseSchema: z.ZodObject<{
@@ -25,31 +26,32 @@ export declare namespace GetSubscriptionTemplateCommand {
25
26
  readonly SINGBOX_LEGACY: "SINGBOX_LEGACY";
26
27
  readonly MIHOMO: "MIHOMO";
27
28
  readonly XRAY_JSON: "XRAY_JSON";
29
+ readonly CLASH: "CLASH";
28
30
  }>;
29
31
  templateJson: z.ZodNullable<z.ZodUnknown>;
30
32
  encodedTemplateYaml: z.ZodNullable<z.ZodString>;
31
33
  }, "strip", z.ZodTypeAny, {
32
34
  uuid: string;
33
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
35
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
34
36
  encodedTemplateYaml: string | null;
35
37
  templateJson?: unknown;
36
38
  }, {
37
39
  uuid: string;
38
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
40
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
39
41
  encodedTemplateYaml: string | null;
40
42
  templateJson?: unknown;
41
43
  }>;
42
44
  }, "strip", z.ZodTypeAny, {
43
45
  response: {
44
46
  uuid: string;
45
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
47
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
46
48
  encodedTemplateYaml: string | null;
47
49
  templateJson?: unknown;
48
50
  };
49
51
  }, {
50
52
  response: {
51
53
  uuid: string;
52
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
54
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
53
55
  encodedTemplateYaml: string | null;
54
56
  templateJson?: unknown;
55
57
  };
@@ -1 +1 @@
1
- {"version":3,"file":"get-template.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-template/get-template.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,8BAA8B,CAAC;IACrC,MAAM,GAAG,sCAA0C,CAAC;IACpD,MAAM,OAAO,QAAuB,CAAC;IAErC,MAAM,aAAa;;;;;;;;;;;;MAExB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAOzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
1
+ {"version":3,"file":"get-template.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-template/get-template.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,8BAA8B,CAAC;IACrC,MAAM,GAAG,kCAA0C,CAAC;IACpD,MAAM,OAAO,QAAuB,CAAC;IAErC,MAAM,aAAa;;;;;;;;;;;;;MAExB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAOzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
@@ -9,15 +9,16 @@ export declare namespace UpdateSubscriptionTemplateCommand {
9
9
  readonly SINGBOX_LEGACY: "SINGBOX_LEGACY";
10
10
  readonly MIHOMO: "MIHOMO";
11
11
  readonly XRAY_JSON: "XRAY_JSON";
12
+ readonly CLASH: "CLASH";
12
13
  }>;
13
14
  templateJson: z.ZodOptional<z.ZodObject<{}, "passthrough", z.ZodTypeAny, z.objectOutputType<{}, z.ZodTypeAny, "passthrough">, z.objectInputType<{}, z.ZodTypeAny, "passthrough">>>;
14
15
  encodedTemplateYaml: z.ZodOptional<z.ZodString>;
15
16
  }, "strip", z.ZodTypeAny, {
16
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
17
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
17
18
  templateJson?: z.objectOutputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
18
19
  encodedTemplateYaml?: string | undefined;
19
20
  }, {
20
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
21
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
21
22
  templateJson?: z.objectInputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
22
23
  encodedTemplateYaml?: string | undefined;
23
24
  }>;
@@ -31,31 +32,32 @@ export declare namespace UpdateSubscriptionTemplateCommand {
31
32
  readonly SINGBOX_LEGACY: "SINGBOX_LEGACY";
32
33
  readonly MIHOMO: "MIHOMO";
33
34
  readonly XRAY_JSON: "XRAY_JSON";
35
+ readonly CLASH: "CLASH";
34
36
  }>;
35
37
  templateJson: z.ZodNullable<z.ZodUnknown>;
36
38
  encodedTemplateYaml: z.ZodNullable<z.ZodString>;
37
39
  }, "strip", z.ZodTypeAny, {
38
40
  uuid: string;
39
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
41
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
40
42
  encodedTemplateYaml: string | null;
41
43
  templateJson?: unknown;
42
44
  }, {
43
45
  uuid: string;
44
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
46
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
45
47
  encodedTemplateYaml: string | null;
46
48
  templateJson?: unknown;
47
49
  }>;
48
50
  }, "strip", z.ZodTypeAny, {
49
51
  response: {
50
52
  uuid: string;
51
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
53
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
52
54
  encodedTemplateYaml: string | null;
53
55
  templateJson?: unknown;
54
56
  };
55
57
  }, {
56
58
  response: {
57
59
  uuid: string;
58
- templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON";
60
+ templateType: "STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH";
59
61
  encodedTemplateYaml: string | null;
60
62
  templateJson?: unknown;
61
63
  };
@@ -1 +1 @@
1
- {"version":3,"file":"update-template.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-template/update-template.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,iCAAiC,CAAC;IACxC,MAAM,GAAG,+CAAiD,CAAC;IAC3D,MAAM,OAAO,+CAAM,CAAC;IAEpB,MAAM,aAAa;;;;;;;;;;;;;;;;;;MAIxB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAOzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
1
+ {"version":3,"file":"update-template.command.d.ts","sourceRoot":"","sources":["../../../../commands/subscription-template/update-template.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,yBAAiB,iCAAiC,CAAC;IACxC,MAAM,GAAG,+CAAiD,CAAC;IAC3D,MAAM,OAAO,+CAAM,CAAC;IAEpB,MAAM,aAAa;;;;;;;;;;;;;;;;;;;MAIxB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAOzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
@@ -104,7 +104,7 @@ var CreateUserCommand;
104
104
  .optional(),
105
105
  description: zod_1.z.string().optional(),
106
106
  telegramId: zod_1.z.number().optional(),
107
- email: zod_1.z.string().optional(),
107
+ email: zod_1.z.string().email('Invalid email format').optional(),
108
108
  activateAllInbounds: zod_1.z.boolean().optional(),
109
109
  });
110
110
  CreateUserCommand.ResponseSchema = zod_1.z.object({
@@ -214,4 +214,4 @@ export declare namespace DisableUserCommand {
214
214
  }>;
215
215
  type Response = z.infer<typeof ResponseSchema>;
216
216
  }
217
- //# sourceMappingURL=disable-user.command.ts.d.ts.map
217
+ //# sourceMappingURL=disable-user.command.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"disable-user.command.d.ts","sourceRoot":"","sources":["../../../../commands/users/disable-user.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,yBAAiB,kBAAkB,CAAC;IACzB,MAAM,GAAG,0BAA8B,CAAC;IACxC,MAAM,OAAO,QAAe,CAAC;IAE7B,MAAM,aAAa;;;;;;MAExB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAKzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
@@ -10,7 +10,7 @@ var GetUserByEmailCommand;
10
10
  GetUserByEmailCommand.url = api_1.REST_API.USERS.GET_BY_EMAIL;
11
11
  GetUserByEmailCommand.TSQ_url = GetUserByEmailCommand.url(':email');
12
12
  GetUserByEmailCommand.RequestSchema = zod_1.z.object({
13
- email: zod_1.z.string(),
13
+ email: zod_1.z.string().email(),
14
14
  });
15
15
  GetUserByEmailCommand.ResponseSchema = zod_1.z.object({
16
16
  response: zod_1.z.array(users_schema_1.UsersSchema.extend({
@@ -1,7 +1,7 @@
1
1
  export * from './bulk';
2
2
  export * from './create-user.command';
3
3
  export * from './delete-user.command';
4
- export * from './disable-user.command.ts';
4
+ export * from './disable-user.command';
5
5
  export * from './enable-user.command';
6
6
  export * from './get-all-users-v2.command';
7
7
  export * from './get-user-by-email.command';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../commands/users/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,uBAAuB,CAAC;AACtC,cAAc,uBAAuB,CAAC;AACtC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,uBAAuB,CAAC;AACtC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,kCAAkC,CAAC;AACjD,cAAc,yCAAyC,CAAC;AACxD,cAAc,mCAAmC,CAAC;AAClD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,oCAAoC,CAAC;AACnD,cAAc,uBAAuB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../commands/users/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,uBAAuB,CAAC;AACtC,cAAc,uBAAuB,CAAC;AACtC,cAAc,wBAAwB,CAAC;AACvC,cAAc,uBAAuB,CAAC;AACtC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,kCAAkC,CAAC;AACjD,cAAc,yCAAyC,CAAC;AACxD,cAAc,mCAAmC,CAAC;AAClD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,oCAAoC,CAAC;AACnD,cAAc,uBAAuB,CAAC"}
@@ -17,7 +17,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./bulk"), exports);
18
18
  __exportStar(require("./create-user.command"), exports);
19
19
  __exportStar(require("./delete-user.command"), exports);
20
- __exportStar(require("./disable-user.command.ts"), exports);
20
+ __exportStar(require("./disable-user.command"), exports);
21
21
  __exportStar(require("./enable-user.command"), exports);
22
22
  __exportStar(require("./get-all-users-v2.command"), exports);
23
23
  __exportStar(require("./get-user-by-email.command"), exports);
@@ -51,7 +51,7 @@ var UpdateUserCommand;
51
51
  .optional(),
52
52
  description: zod_1.z.string().optional(),
53
53
  telegramId: zod_1.z.number().optional(),
54
- email: zod_1.z.string().optional(),
54
+ email: zod_1.z.string().email('Invalid email format').optional(),
55
55
  });
56
56
  UpdateUserCommand.ResponseSchema = zod_1.z.object({
57
57
  response: models_1.UsersSchema.extend({
@@ -321,7 +321,7 @@ export declare const ERRORS: {
321
321
  };
322
322
  readonly CONFIG_VALIDATION_ERROR: {
323
323
  readonly code: "A061";
324
- readonly message: "";
324
+ readonly message: "Config validation error";
325
325
  readonly httpCode: 500;
326
326
  readonly withMessage: (message: string) => {
327
327
  code: string;
@@ -300,7 +300,7 @@ exports.ERRORS = {
300
300
  },
301
301
  CONFIG_VALIDATION_ERROR: {
302
302
  code: 'A061',
303
- message: '',
303
+ message: 'Config validation error',
304
304
  httpCode: 500,
305
305
  withMessage: (message) => ({
306
306
  code: 'A061',
@@ -1,2 +1,3 @@
1
+ export * from './request-template-type.constant';
1
2
  export * from './template-type.constant';
2
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../constants/subscription-template/template-type/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../constants/subscription-template/template-type/index.ts"],"names":[],"mappings":"AAAA,cAAc,kCAAkC,CAAC;AACjD,cAAc,0BAA0B,CAAC"}
@@ -14,4 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./request-template-type.constant"), exports);
17
18
  __exportStar(require("./template-type.constant"), exports);
@@ -0,0 +1,12 @@
1
+ export declare const REQUEST_TEMPLATE_TYPE: {
2
+ readonly STASH: "stash";
3
+ readonly SINGBOX: "singbox";
4
+ readonly SINGBOX_LEGACY: "singbox-legacy";
5
+ readonly MIHOMO: "mihomo";
6
+ readonly XRAY_JSON: "json";
7
+ readonly CLASH: "clash";
8
+ };
9
+ export type TRequestTemplateType = [keyof typeof REQUEST_TEMPLATE_TYPE][number];
10
+ export declare const REQUEST_TEMPLATE_TYPE_VALUES: ("stash" | "singbox" | "singbox-legacy" | "mihomo" | "json" | "clash")[];
11
+ export type TRequestTemplateTypeKeys = (typeof REQUEST_TEMPLATE_TYPE)[keyof typeof REQUEST_TEMPLATE_TYPE];
12
+ //# sourceMappingURL=request-template-type.constant.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"request-template-type.constant.d.ts","sourceRoot":"","sources":["../../../../../constants/subscription-template/template-type/request-template-type.constant.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,qBAAqB;;;;;;;CAOxB,CAAC;AAEX,MAAM,MAAM,oBAAoB,GAAG,CAAC,MAAM,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAChF,eAAO,MAAM,4BAA4B,0EAAuC,CAAC;AACjF,MAAM,MAAM,wBAAwB,GAChC,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,OAAO,qBAAqB,CAAC,CAAC"}
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.REQUEST_TEMPLATE_TYPE_VALUES = exports.REQUEST_TEMPLATE_TYPE = void 0;
4
+ exports.REQUEST_TEMPLATE_TYPE = {
5
+ STASH: 'stash',
6
+ SINGBOX: 'singbox',
7
+ SINGBOX_LEGACY: 'singbox-legacy',
8
+ MIHOMO: 'mihomo',
9
+ XRAY_JSON: 'json',
10
+ CLASH: 'clash',
11
+ };
12
+ exports.REQUEST_TEMPLATE_TYPE_VALUES = Object.values(exports.REQUEST_TEMPLATE_TYPE);
@@ -4,7 +4,8 @@ export declare const SUBSCRIPTION_TEMPLATE_TYPE: {
4
4
  readonly SINGBOX_LEGACY: "SINGBOX_LEGACY";
5
5
  readonly MIHOMO: "MIHOMO";
6
6
  readonly XRAY_JSON: "XRAY_JSON";
7
+ readonly CLASH: "CLASH";
7
8
  };
8
9
  export type TSubscriptionTemplateType = [keyof typeof SUBSCRIPTION_TEMPLATE_TYPE][number];
9
- export declare const SUBSCRIPTION_TEMPLATE_TYPE_VALUES: ("STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON")[];
10
+ export declare const SUBSCRIPTION_TEMPLATE_TYPE_VALUES: ("STASH" | "SINGBOX" | "SINGBOX_LEGACY" | "MIHOMO" | "XRAY_JSON" | "CLASH")[];
10
11
  //# sourceMappingURL=template-type.constant.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"template-type.constant.d.ts","sourceRoot":"","sources":["../../../../../constants/subscription-template/template-type/template-type.constant.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,0BAA0B;;;;;;CAM7B,CAAC;AAEX,MAAM,MAAM,yBAAyB,GAAG,CAAC,MAAM,OAAO,0BAA0B,CAAC,CAAC,MAAM,CAAC,CAAC;AAC1F,eAAO,MAAM,iCAAiC,qEAA4C,CAAC"}
1
+ {"version":3,"file":"template-type.constant.d.ts","sourceRoot":"","sources":["../../../../../constants/subscription-template/template-type/template-type.constant.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,0BAA0B;;;;;;;CAO7B,CAAC;AAEX,MAAM,MAAM,yBAAyB,GAAG,CAAC,MAAM,OAAO,0BAA0B,CAAC,CAAC,MAAM,CAAC,CAAC;AAC1F,eAAO,MAAM,iCAAiC,+EAA4C,CAAC"}
@@ -7,5 +7,6 @@ exports.SUBSCRIPTION_TEMPLATE_TYPE = {
7
7
  SINGBOX_LEGACY: 'SINGBOX_LEGACY',
8
8
  MIHOMO: 'MIHOMO',
9
9
  XRAY_JSON: 'XRAY_JSON',
10
+ CLASH: 'CLASH',
10
11
  };
11
12
  exports.SUBSCRIPTION_TEMPLATE_TYPE_VALUES = Object.values(exports.SUBSCRIPTION_TEMPLATE_TYPE);
@@ -5,6 +5,7 @@ export declare const SubscriptionSettingsSchema: z.ZodObject<{
5
5
  supportLink: z.ZodString;
6
6
  profileUpdateInterval: z.ZodNumber;
7
7
  isProfileWebpageUrlEnabled: z.ZodBoolean;
8
+ serveJsonAtBaseSubscription: z.ZodBoolean;
8
9
  happAnnounce: z.ZodNullable<z.ZodString>;
9
10
  happRouting: z.ZodNullable<z.ZodString>;
10
11
  expiredUsersRemarks: z.ZodArray<z.ZodString, "many">;
@@ -20,6 +21,7 @@ export declare const SubscriptionSettingsSchema: z.ZodObject<{
20
21
  supportLink: string;
21
22
  profileUpdateInterval: number;
22
23
  isProfileWebpageUrlEnabled: boolean;
24
+ serveJsonAtBaseSubscription: boolean;
23
25
  happAnnounce: string | null;
24
26
  happRouting: string | null;
25
27
  expiredUsersRemarks: string[];
@@ -33,6 +35,7 @@ export declare const SubscriptionSettingsSchema: z.ZodObject<{
33
35
  supportLink: string;
34
36
  profileUpdateInterval: number;
35
37
  isProfileWebpageUrlEnabled: boolean;
38
+ serveJsonAtBaseSubscription: boolean;
36
39
  happAnnounce: string | null;
37
40
  happRouting: string | null;
38
41
  expiredUsersRemarks: string[];
@@ -1 +1 @@
1
- {"version":3,"file":"subscription-settings.schema.d.ts","sourceRoot":"","sources":["../../../models/subscription-settings.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuBrC,CAAC"}
1
+ {"version":3,"file":"subscription-settings.schema.d.ts","sourceRoot":"","sources":["../../../models/subscription-settings.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4BrC,CAAC"}
@@ -6,8 +6,12 @@ exports.SubscriptionSettingsSchema = zod_1.z.object({
6
6
  uuid: zod_1.z.string().uuid(),
7
7
  profileTitle: zod_1.z.string(),
8
8
  supportLink: zod_1.z.string(),
9
- profileUpdateInterval: zod_1.z.number().int(),
9
+ profileUpdateInterval: zod_1.z
10
+ .number()
11
+ .int()
12
+ .min(1, 'Profile update interval must be greater than 0'),
10
13
  isProfileWebpageUrlEnabled: zod_1.z.boolean(),
14
+ serveJsonAtBaseSubscription: zod_1.z.boolean(),
11
15
  happAnnounce: zod_1.z.string().nullable(),
12
16
  happRouting: zod_1.z.string().nullable(),
13
17
  expiredUsersRemarks: zod_1.z.array(zod_1.z.string()),
@@ -44,7 +44,7 @@ exports.UsersSchema = zod_1.z.object({
44
44
  ssPassword: zod_1.z.string(),
45
45
  description: zod_1.z.nullable(zod_1.z.string()),
46
46
  telegramId: zod_1.z.nullable(zod_1.z.number()),
47
- email: zod_1.z.nullable(zod_1.z.string()),
47
+ email: zod_1.z.nullable(zod_1.z.string().email()),
48
48
  createdAt: zod_1.z
49
49
  .string()
50
50
  .datetime()
@@ -4,5 +4,6 @@ exports.SUBSCRIPTION_ROUTES = exports.SUBSCRIPTION_CONTROLLER = void 0;
4
4
  exports.SUBSCRIPTION_CONTROLLER = 'sub';
5
5
  exports.SUBSCRIPTION_ROUTES = {
6
6
  GET: '',
7
+ GET_OUTLINE: '/outline',
7
8
  GET_INFO: '/info',
8
9
  };
@@ -95,6 +95,7 @@ exports.REST_API = {
95
95
  },
96
96
  SUBSCRIPTION: {
97
97
  GET: (shortUuid) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_ROUTES.GET}/${shortUuid}`,
98
+ GET_OUTLINE: (shortUuid) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_ROUTES.GET_OUTLINE}/${shortUuid}/`,
98
99
  GET_INFO: (shortUuid) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_CONTROLLER}/${shortUuid}${CONTROLLERS.SUBSCRIPTION_ROUTES.GET_INFO}`,
99
100
  },
100
101
  HOSTS: {
@@ -112,7 +113,7 @@ exports.REST_API = {
112
113
  NODES_STATISTIC: `${exports.ROOT}/${CONTROLLERS.SYSTEM_CONTROLLER}/${CONTROLLERS.SYSTEM_ROUTES.STATISTIC.NODES}`,
113
114
  },
114
115
  SUBSCRIPTION_TEMPLATE: {
115
- GET_INFO: (subscriptionType) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_ROUTES.GET_TEMPLATE}/${subscriptionType}`,
116
+ GET_INFO: (templateType) => `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_ROUTES.GET_TEMPLATE}/${templateType}`,
116
117
  UPDATE_TEMPLATE: `${exports.ROOT}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_CONTROLLER}/${CONTROLLERS.SUBSCRIPTION_TEMPLATE_ROUTES.UPDATE_TEMPLATE}`,
117
118
  },
118
119
  SUBSCRIPTION_SETTINGS: {
@@ -2,8 +2,8 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.GetOneHostCommand = void 0;
4
4
  const zod_1 = require("zod");
5
+ const models_1 = require("../../models");
5
6
  const api_1 = require("../../api");
6
- const __1 = require("../..");
7
7
  var GetOneHostCommand;
8
8
  (function (GetOneHostCommand) {
9
9
  GetOneHostCommand.url = api_1.REST_API.HOSTS.GET_ONE;
@@ -12,6 +12,6 @@ var GetOneHostCommand;
12
12
  uuid: zod_1.z.string().uuid(),
13
13
  });
14
14
  GetOneHostCommand.ResponseSchema = zod_1.z.object({
15
- response: __1.HostsSchema,
15
+ response: models_1.HostsSchema,
16
16
  });
17
17
  })(GetOneHostCommand || (exports.GetOneHostCommand = GetOneHostCommand = {}));
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetOutlineSubscriptionByShortUuidCommand = void 0;
4
+ const zod_1 = require("zod");
5
+ const api_1 = require("../../api");
6
+ var GetOutlineSubscriptionByShortUuidCommand;
7
+ (function (GetOutlineSubscriptionByShortUuidCommand) {
8
+ GetOutlineSubscriptionByShortUuidCommand.url = api_1.REST_API.SUBSCRIPTION.GET;
9
+ GetOutlineSubscriptionByShortUuidCommand.TSQ_url = GetOutlineSubscriptionByShortUuidCommand.url(':shortUuid');
10
+ GetOutlineSubscriptionByShortUuidCommand.RequestSchema = zod_1.z.object({
11
+ shortUuid: zod_1.z.string(),
12
+ type: zod_1.z.optional(zod_1.z.string()),
13
+ encodedTag: zod_1.z.optional(zod_1.z.string()),
14
+ });
15
+ })(GetOutlineSubscriptionByShortUuidCommand || (exports.GetOutlineSubscriptionByShortUuidCommand = GetOutlineSubscriptionByShortUuidCommand = {}));
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetSubscriptionByShortUuidByClientTypeCommand = void 0;
4
+ const zod_1 = require("zod");
5
+ const constants_1 = require("../../constants");
6
+ const api_1 = require("../../api");
7
+ var GetSubscriptionByShortUuidByClientTypeCommand;
8
+ (function (GetSubscriptionByShortUuidByClientTypeCommand) {
9
+ GetSubscriptionByShortUuidByClientTypeCommand.url = api_1.REST_API.SUBSCRIPTION.GET;
10
+ GetSubscriptionByShortUuidByClientTypeCommand.TSQ_url = GetSubscriptionByShortUuidByClientTypeCommand.url(':shortUuid');
11
+ GetSubscriptionByShortUuidByClientTypeCommand.RequestSchema = zod_1.z.object({
12
+ shortUuid: zod_1.z.string(),
13
+ clientType: zod_1.z.nativeEnum(constants_1.REQUEST_TEMPLATE_TYPE),
14
+ });
15
+ })(GetSubscriptionByShortUuidByClientTypeCommand || (exports.GetSubscriptionByShortUuidByClientTypeCommand = GetSubscriptionByShortUuidByClientTypeCommand = {}));
@@ -9,7 +9,5 @@ var GetSubscriptionByShortUuidCommand;
9
9
  GetSubscriptionByShortUuidCommand.TSQ_url = GetSubscriptionByShortUuidCommand.url(':shortUuid');
10
10
  GetSubscriptionByShortUuidCommand.RequestSchema = zod_1.z.object({
11
11
  shortUuid: zod_1.z.string(),
12
- type: zod_1.z.optional(zod_1.z.string()),
13
- encodedTag: zod_1.z.optional(zod_1.z.string()),
14
12
  });
15
13
  })(GetSubscriptionByShortUuidCommand || (exports.GetSubscriptionByShortUuidCommand = GetSubscriptionByShortUuidCommand = {}));
@@ -14,5 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./get-outline-subscription-by-short-uuid.command"), exports);
18
+ __exportStar(require("./get-subscription-by-short-uuid-by-client-type.command"), exports);
17
19
  __exportStar(require("./get-subscription-by-short-uuid.command"), exports);
18
20
  __exportStar(require("./get-subscription-info-by-short-uuid.command"), exports);
@@ -14,6 +14,7 @@ var UpdateSubscriptionSettingsCommand;
14
14
  supportLink: zod_1.z.optional(zod_1.z.string()),
15
15
  profileUpdateInterval: zod_1.z.optional(zod_1.z.number().int()),
16
16
  isProfileWebpageUrlEnabled: zod_1.z.optional(zod_1.z.boolean()),
17
+ serveJsonAtBaseSubscription: zod_1.z.optional(zod_1.z.boolean()),
17
18
  happAnnounce: zod_1.z.optional(zod_1.z
18
19
  .string()
19
20
  .max(200, { message: 'Announce must be less than 200 characters' })
@@ -104,7 +104,7 @@ var CreateUserCommand;
104
104
  .optional(),
105
105
  description: zod_1.z.string().optional(),
106
106
  telegramId: zod_1.z.number().optional(),
107
- email: zod_1.z.string().optional(),
107
+ email: zod_1.z.string().email('Invalid email format').optional(),
108
108
  activateAllInbounds: zod_1.z.boolean().optional(),
109
109
  });
110
110
  CreateUserCommand.ResponseSchema = zod_1.z.object({
@@ -10,7 +10,7 @@ var GetUserByEmailCommand;
10
10
  GetUserByEmailCommand.url = api_1.REST_API.USERS.GET_BY_EMAIL;
11
11
  GetUserByEmailCommand.TSQ_url = GetUserByEmailCommand.url(':email');
12
12
  GetUserByEmailCommand.RequestSchema = zod_1.z.object({
13
- email: zod_1.z.string(),
13
+ email: zod_1.z.string().email(),
14
14
  });
15
15
  GetUserByEmailCommand.ResponseSchema = zod_1.z.object({
16
16
  response: zod_1.z.array(users_schema_1.UsersSchema.extend({
@@ -17,7 +17,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./bulk"), exports);
18
18
  __exportStar(require("./create-user.command"), exports);
19
19
  __exportStar(require("./delete-user.command"), exports);
20
- __exportStar(require("./disable-user.command.ts"), exports);
20
+ __exportStar(require("./disable-user.command"), exports);
21
21
  __exportStar(require("./enable-user.command"), exports);
22
22
  __exportStar(require("./get-all-users-v2.command"), exports);
23
23
  __exportStar(require("./get-user-by-email.command"), exports);
@@ -51,7 +51,7 @@ var UpdateUserCommand;
51
51
  .optional(),
52
52
  description: zod_1.z.string().optional(),
53
53
  telegramId: zod_1.z.number().optional(),
54
- email: zod_1.z.string().optional(),
54
+ email: zod_1.z.string().email('Invalid email format').optional(),
55
55
  });
56
56
  UpdateUserCommand.ResponseSchema = zod_1.z.object({
57
57
  response: models_1.UsersSchema.extend({
@@ -300,7 +300,7 @@ exports.ERRORS = {
300
300
  },
301
301
  CONFIG_VALIDATION_ERROR: {
302
302
  code: 'A061',
303
- message: '',
303
+ message: 'Config validation error',
304
304
  httpCode: 500,
305
305
  withMessage: (message) => ({
306
306
  code: 'A061',
@@ -14,4 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./request-template-type.constant"), exports);
17
18
  __exportStar(require("./template-type.constant"), exports);
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.REQUEST_TEMPLATE_TYPE_VALUES = exports.REQUEST_TEMPLATE_TYPE = void 0;
4
+ exports.REQUEST_TEMPLATE_TYPE = {
5
+ STASH: 'stash',
6
+ SINGBOX: 'singbox',
7
+ SINGBOX_LEGACY: 'singbox-legacy',
8
+ MIHOMO: 'mihomo',
9
+ XRAY_JSON: 'json',
10
+ CLASH: 'clash',
11
+ };
12
+ exports.REQUEST_TEMPLATE_TYPE_VALUES = Object.values(exports.REQUEST_TEMPLATE_TYPE);
@@ -7,5 +7,6 @@ exports.SUBSCRIPTION_TEMPLATE_TYPE = {
7
7
  SINGBOX_LEGACY: 'SINGBOX_LEGACY',
8
8
  MIHOMO: 'MIHOMO',
9
9
  XRAY_JSON: 'XRAY_JSON',
10
+ CLASH: 'CLASH',
10
11
  };
11
12
  exports.SUBSCRIPTION_TEMPLATE_TYPE_VALUES = Object.values(exports.SUBSCRIPTION_TEMPLATE_TYPE);
@@ -6,8 +6,12 @@ exports.SubscriptionSettingsSchema = zod_1.z.object({
6
6
  uuid: zod_1.z.string().uuid(),
7
7
  profileTitle: zod_1.z.string(),
8
8
  supportLink: zod_1.z.string(),
9
- profileUpdateInterval: zod_1.z.number().int(),
9
+ profileUpdateInterval: zod_1.z
10
+ .number()
11
+ .int()
12
+ .min(1, 'Profile update interval must be greater than 0'),
10
13
  isProfileWebpageUrlEnabled: zod_1.z.boolean(),
14
+ serveJsonAtBaseSubscription: zod_1.z.boolean(),
11
15
  happAnnounce: zod_1.z.string().nullable(),
12
16
  happRouting: zod_1.z.string().nullable(),
13
17
  expiredUsersRemarks: zod_1.z.array(zod_1.z.string()),
@@ -44,7 +44,7 @@ exports.UsersSchema = zod_1.z.object({
44
44
  ssPassword: zod_1.z.string(),
45
45
  description: zod_1.z.nullable(zod_1.z.string()),
46
46
  telegramId: zod_1.z.nullable(zod_1.z.number()),
47
- email: zod_1.z.nullable(zod_1.z.string()),
47
+ email: zod_1.z.nullable(zod_1.z.string().email()),
48
48
  createdAt: zod_1.z
49
49
  .string()
50
50
  .datetime()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remnawave/backend-contract",
3
- "version": "0.3.20",
3
+ "version": "0.3.23",
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.",
@@ -1 +0,0 @@
1
- {"version":3,"file":"disable-user.command.ts.d.ts","sourceRoot":"","sources":["../../../../commands/users/disable-user.command.ts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,yBAAiB,kBAAkB,CAAC;IACzB,MAAM,GAAG,0BAA8B,CAAC;IACxC,MAAM,OAAO,QAAe,CAAC;IAE7B,MAAM,aAAa;;;;;;MAExB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAKzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}