feat(config): Protocol type

This commit is contained in:
web@ppanel
2024-12-07 17:15:13 +07:00
parent 0327b73708
commit a3b45b455d
6 changed files with 8016 additions and 2695 deletions
+19 -2
View File
@@ -104,6 +104,7 @@ declare namespace API {
user: number;
node: number;
country: number;
protocol: string[];
};
type GetSubscriptionResponse = {
@@ -216,6 +217,17 @@ declare namespace API {
data?: Record<string, any>;
};
type SecurityConfig = {
server_address?: string;
server_name?: string;
server_port?: number;
fingerprint?: string;
private_key?: string;
public_key?: string;
short_id?: string;
allow_insecure?: boolean;
};
type SendCodeRequest = {
email: string;
type: number;
@@ -328,6 +340,11 @@ declare namespace API {
updated_at: number;
};
type TLSConfig = {
server_name?: string;
allow_insecure?: boolean;
};
type TosConfig = {
tos_content: string;
};
@@ -436,7 +453,7 @@ declare namespace API {
network: string;
transport: Record<string, any>;
security: string;
security_config: Record<string, any>;
security_config: SecurityConfig;
xtls: string;
enable_relay: boolean;
relay_host: string;
@@ -447,7 +464,7 @@ declare namespace API {
host: string;
port: number;
enable_tls: boolean;
tls_config: Record<string, any>;
tls_config: TLSConfig;
network: string;
transport: Record<string, any>;
enable_relay: boolean;