@long2ice/relayx-backend 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (88) hide show
  1. package/README.md +13 -0
  2. package/dist/app.d.ts +8592 -0
  3. package/dist/bullmq/index.d.ts +1 -0
  4. package/dist/bullmq/jobs.d.ts +34 -0
  5. package/dist/bullmq/queue.d.ts +6 -0
  6. package/dist/bullmq/queuedash.d.ts +12 -0
  7. package/dist/bullmq/worker.d.ts +1 -0
  8. package/dist/config.d.ts +16 -0
  9. package/dist/db.d.ts +3 -0
  10. package/dist/generated/prisma/zod/index.d.ts +2289 -0
  11. package/dist/index.d.ts +1 -0
  12. package/dist/middlewares/auth.d.ts +3 -0
  13. package/dist/middlewares/ip.d.ts +2 -0
  14. package/dist/middlewares/license.d.ts +2 -0
  15. package/dist/middlewares/plan.d.ts +2 -0
  16. package/dist/routes/admin/license.d.ts +90 -0
  17. package/dist/routes/admin/node.d.ts +919 -0
  18. package/dist/routes/admin/node_group.d.ts +2115 -0
  19. package/dist/routes/admin/pay.d.ts +261 -0
  20. package/dist/routes/admin/plan.d.ts +198 -0
  21. package/dist/routes/admin/plan_coupon.d.ts +92 -0
  22. package/dist/routes/admin/stats.d.ts +77 -0
  23. package/dist/routes/admin/system_config.d.ts +68 -0
  24. package/dist/routes/admin/ticket.d.ts +113 -0
  25. package/dist/routes/admin/topup.d.ts +88 -0
  26. package/dist/routes/admin/topup_activity.d.ts +84 -0
  27. package/dist/routes/admin/tunnel.d.ts +566 -0
  28. package/dist/routes/admin/user.d.ts +299 -0
  29. package/dist/routes/admin/user_plan.d.ts +109 -0
  30. package/dist/routes/bot.d.ts +13 -0
  31. package/dist/routes/dns_provider.d.ts +240 -0
  32. package/dist/routes/health.d.ts +3 -0
  33. package/dist/routes/in_node_group_dns.d.ts +132 -0
  34. package/dist/routes/license.d.ts +50 -0
  35. package/dist/routes/node.d.ts +148 -0
  36. package/dist/routes/node_group.d.ts +1498 -0
  37. package/dist/routes/pay.d.ts +34 -0
  38. package/dist/routes/plan.d.ts +148 -0
  39. package/dist/routes/plan_coupon.d.ts +22 -0
  40. package/dist/routes/system_config.d.ts +87 -0
  41. package/dist/routes/ticket.d.ts +129 -0
  42. package/dist/routes/topup.d.ts +93 -0
  43. package/dist/routes/tunnel.d.ts +742 -0
  44. package/dist/routes/user.d.ts +293 -0
  45. package/dist/schemas/context.d.ts +9 -0
  46. package/dist/schemas/license.d.ts +7 -0
  47. package/dist/schemas/request.d.ts +1181 -0
  48. package/dist/schemas/response.d.ts +2439 -0
  49. package/dist/schemas/socket.io.d.ts +33 -0
  50. package/dist/schemas/tunnel.d.ts +10 -0
  51. package/dist/services/dns/cloudflare.d.ts +12 -0
  52. package/dist/services/dns/huawei.d.ts +12 -0
  53. package/dist/services/dns/index.d.ts +4 -0
  54. package/dist/services/dns/interface.d.ts +8 -0
  55. package/dist/services/dns_provider.d.ts +46 -0
  56. package/dist/services/email.d.ts +11 -0
  57. package/dist/services/fernet.d.ts +2 -0
  58. package/dist/services/in_node_group_dns.d.ts +65 -0
  59. package/dist/services/license.d.ts +87 -0
  60. package/dist/services/logger.d.ts +7 -0
  61. package/dist/services/node.d.ts +39 -0
  62. package/dist/services/node_group.d.ts +75 -0
  63. package/dist/services/notify.d.ts +44 -0
  64. package/dist/services/order.d.ts +3 -0
  65. package/dist/services/pay.d.ts +6 -0
  66. package/dist/services/plan.d.ts +119 -0
  67. package/dist/services/plan_coupon.d.ts +16 -0
  68. package/dist/services/redis.d.ts +59 -0
  69. package/dist/services/stackauth.d.ts +25 -0
  70. package/dist/services/sysinfo.d.ts +7 -0
  71. package/dist/services/system_config.d.ts +7 -0
  72. package/dist/services/telegram.d.ts +8 -0
  73. package/dist/services/ticket.d.ts +134 -0
  74. package/dist/services/topup.d.ts +37 -0
  75. package/dist/services/topup_activity.d.ts +21 -0
  76. package/dist/services/tunnel.d.ts +1235 -0
  77. package/dist/services/user.d.ts +25 -0
  78. package/dist/socket-io/events.d.ts +13 -0
  79. package/dist/socket-io/handlers/disconnect.d.ts +2 -0
  80. package/dist/socket-io/handlers/listen.d.ts +3 -0
  81. package/dist/socket-io/handlers/register.d.ts +2 -0
  82. package/dist/socket-io/handlers/sysinfo.d.ts +2 -0
  83. package/dist/socket-io/index.d.ts +3 -0
  84. package/dist/socket-io/utils.d.ts +8 -0
  85. package/dist/utils/date.d.ts +1 -0
  86. package/dist/utils/ip.d.ts +2 -0
  87. package/dist/utils/uuid.d.ts +1 -0
  88. package/package.json +82 -0
@@ -0,0 +1 @@
1
+ import "reflect-metadata";
@@ -0,0 +1,3 @@
1
+ import { Context, Next } from "hono";
2
+ export declare const adminRequired: (c: Context, next: Next) => Promise<void>;
3
+ export declare const authRequired: (c: Context, next: Next) => Promise<void | Response>;
@@ -0,0 +1,2 @@
1
+ import { Context, Next } from "hono";
2
+ export declare const getRequestIP: (c: Context, next: Next) => Promise<void>;
@@ -0,0 +1,2 @@
1
+ import { Context, Next } from "hono";
2
+ export declare const businessLicenseRequired: (c: Context, next: Next) => Promise<void>;
@@ -0,0 +1,2 @@
1
+ import { Context, Next } from "hono";
2
+ export declare const planRequired: (c: Context, next: Next) => Promise<void>;
@@ -0,0 +1,90 @@
1
+ import { Variables } from "../../schemas/context";
2
+ import { CouponValidCycle, LicenseType } from "../../services/license";
3
+ declare const app: import("hono/hono-base").HonoBase<{
4
+ Variables: Variables;
5
+ }, {
6
+ "/pay": {
7
+ $get: {
8
+ input: {};
9
+ output: {
10
+ payments: {
11
+ id: number;
12
+ method: string;
13
+ name: string;
14
+ percent_fee: number;
15
+ type: string | null;
16
+ }[];
17
+ price: {
18
+ personal: {
19
+ month: number;
20
+ lifetime: number;
21
+ enable_year: boolean;
22
+ };
23
+ business: {
24
+ month: number;
25
+ lifetime: number;
26
+ enable_year: boolean;
27
+ };
28
+ };
29
+ } | null;
30
+ outputFormat: "json";
31
+ status: import("hono/utils/http-status").ContentfulStatusCode;
32
+ };
33
+ };
34
+ } & {
35
+ "/": {
36
+ $put: {
37
+ input: {
38
+ json: {
39
+ site_url: string;
40
+ };
41
+ };
42
+ output: null;
43
+ outputFormat: "body";
44
+ status: 204;
45
+ };
46
+ };
47
+ } & {
48
+ "/": {
49
+ $post: {
50
+ input: {
51
+ json: {
52
+ payment_id: number;
53
+ type: LicenseType;
54
+ redirect_url: string;
55
+ cycle: CouponValidCycle;
56
+ pay_type: string | null;
57
+ coupon?: string | undefined;
58
+ };
59
+ };
60
+ output: {
61
+ pay_url: string;
62
+ };
63
+ outputFormat: "json";
64
+ status: import("hono/utils/http-status").ContentfulStatusCode;
65
+ };
66
+ };
67
+ } & {
68
+ "/history": {
69
+ $get: {
70
+ input: {};
71
+ output: {
72
+ id: number;
73
+ price: number;
74
+ status: "pending" | "success" | "cancelled";
75
+ type: "personal" | "business";
76
+ expired_at: string;
77
+ created_at: string;
78
+ order_id: string;
79
+ coupon: {
80
+ code: string;
81
+ type: "percentage" | "fixed";
82
+ value: number;
83
+ } | null;
84
+ }[] | null;
85
+ outputFormat: "json";
86
+ status: import("hono/utils/http-status").ContentfulStatusCode;
87
+ };
88
+ };
89
+ }, "/">;
90
+ export default app;