import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire"; import type { CallContext, CallOptions } from "nice-grpc-common"; import { User } from "../../../common/protocol/user"; import { TypedMessage } from "../../../common/serial/typed_message"; import { InboundHandlerConfig, OutboundHandlerConfig } from "../../../core/config"; export declare const protobufPackage = "xray.app.proxyman.command"; export interface AddUserOperation { $type: "xray.app.proxyman.command.AddUserOperation"; user: User | undefined; } export interface RemoveUserOperation { $type: "xray.app.proxyman.command.RemoveUserOperation"; email: string; } export interface AddInboundRequest { $type: "xray.app.proxyman.command.AddInboundRequest"; inbound: InboundHandlerConfig | undefined; } export interface AddInboundResponse { $type: "xray.app.proxyman.command.AddInboundResponse"; } export interface RemoveInboundRequest { $type: "xray.app.proxyman.command.RemoveInboundRequest"; tag: string; } export interface RemoveInboundResponse { $type: "xray.app.proxyman.command.RemoveInboundResponse"; } export interface AlterInboundRequest { $type: "xray.app.proxyman.command.AlterInboundRequest"; tag: string; operation: TypedMessage | undefined; } export interface AlterInboundResponse { $type: "xray.app.proxyman.command.AlterInboundResponse"; } export interface ListInboundsRequest { $type: "xray.app.proxyman.command.ListInboundsRequest"; isOnlyTags: boolean; } export interface ListInboundsResponse { $type: "xray.app.proxyman.command.ListInboundsResponse"; inbounds: InboundHandlerConfig[]; } export interface GetInboundUserRequest { $type: "xray.app.proxyman.command.GetInboundUserRequest"; tag: string; email: string; } export interface GetInboundUserResponse { $type: "xray.app.proxyman.command.GetInboundUserResponse"; users: User[]; } export interface GetInboundUsersCountResponse { $type: "xray.app.proxyman.command.GetInboundUsersCountResponse"; count: number; } export interface AddOutboundRequest { $type: "xray.app.proxyman.command.AddOutboundRequest"; outbound: OutboundHandlerConfig | undefined; } export interface AddOutboundResponse { $type: "xray.app.proxyman.command.AddOutboundResponse"; } export interface RemoveOutboundRequest { $type: "xray.app.proxyman.command.RemoveOutboundRequest"; tag: string; } export interface RemoveOutboundResponse { $type: "xray.app.proxyman.command.RemoveOutboundResponse"; } export interface AlterOutboundRequest { $type: "xray.app.proxyman.command.AlterOutboundRequest"; tag: string; operation: TypedMessage | undefined; } export interface AlterOutboundResponse { $type: "xray.app.proxyman.command.AlterOutboundResponse"; } export interface ListOutboundsRequest { $type: "xray.app.proxyman.command.ListOutboundsRequest"; } export interface ListOutboundsResponse { $type: "xray.app.proxyman.command.ListOutboundsResponse"; outbounds: OutboundHandlerConfig[]; } export interface Config { $type: "xray.app.proxyman.command.Config"; } export declare const AddUserOperation: MessageFns; export declare const RemoveUserOperation: MessageFns; export declare const AddInboundRequest: MessageFns; export declare const AddInboundResponse: MessageFns; export declare const RemoveInboundRequest: MessageFns; export declare const RemoveInboundResponse: MessageFns; export declare const AlterInboundRequest: MessageFns; export declare const AlterInboundResponse: MessageFns; export declare const ListInboundsRequest: MessageFns; export declare const ListInboundsResponse: MessageFns; export declare const GetInboundUserRequest: MessageFns; export declare const GetInboundUserResponse: MessageFns; export declare const GetInboundUsersCountResponse: MessageFns; export declare const AddOutboundRequest: MessageFns; export declare const AddOutboundResponse: MessageFns; export declare const RemoveOutboundRequest: MessageFns; export declare const RemoveOutboundResponse: MessageFns; export declare const AlterOutboundRequest: MessageFns; export declare const AlterOutboundResponse: MessageFns; export declare const ListOutboundsRequest: MessageFns; export declare const ListOutboundsResponse: MessageFns; export declare const Config: MessageFns; export type HandlerServiceDefinition = typeof HandlerServiceDefinition; export declare const HandlerServiceDefinition: { readonly name: "HandlerService"; readonly fullName: "xray.app.proxyman.command.HandlerService"; readonly methods: { readonly addInbound: { readonly name: "AddInbound"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly removeInbound: { readonly name: "RemoveInbound"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly alterInbound: { readonly name: "AlterInbound"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly listInbounds: { readonly name: "ListInbounds"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly getInboundUsers: { readonly name: "GetInboundUsers"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly getInboundUsersCount: { readonly name: "GetInboundUsersCount"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly addOutbound: { readonly name: "AddOutbound"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly removeOutbound: { readonly name: "RemoveOutbound"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly alterOutbound: { readonly name: "AlterOutbound"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; readonly listOutbounds: { readonly name: "ListOutbounds"; readonly requestType: MessageFns; readonly requestStream: false; readonly responseType: MessageFns; readonly responseStream: false; readonly options: {}; }; }; }; export interface HandlerServiceImplementation { addInbound(request: AddInboundRequest, context: CallContext & CallContextExt): Promise>; removeInbound(request: RemoveInboundRequest, context: CallContext & CallContextExt): Promise>; alterInbound(request: AlterInboundRequest, context: CallContext & CallContextExt): Promise>; listInbounds(request: ListInboundsRequest, context: CallContext & CallContextExt): Promise>; getInboundUsers(request: GetInboundUserRequest, context: CallContext & CallContextExt): Promise>; getInboundUsersCount(request: GetInboundUserRequest, context: CallContext & CallContextExt): Promise>; addOutbound(request: AddOutboundRequest, context: CallContext & CallContextExt): Promise>; removeOutbound(request: RemoveOutboundRequest, context: CallContext & CallContextExt): Promise>; alterOutbound(request: AlterOutboundRequest, context: CallContext & CallContextExt): Promise>; listOutbounds(request: ListOutboundsRequest, context: CallContext & CallContextExt): Promise>; } export interface HandlerServiceClient { addInbound(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; removeInbound(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; alterInbound(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; listInbounds(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; getInboundUsers(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; getInboundUsersCount(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; addOutbound(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; removeOutbound(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; alterOutbound(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; listOutbounds(request: DeepPartial, options?: CallOptions & CallOptionsExt): Promise; } type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined; export type DeepPartial = T extends Builtin ? T : T extends globalThis.Array ? globalThis.Array> : T extends ReadonlyArray ? ReadonlyArray> : T extends {} ? { [K in Exclude]?: DeepPartial; } : Partial; export interface MessageFns { readonly $type: V; encode(message: T, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): T; fromJSON(object: any): T; toJSON(message: T): unknown; create(base?: DeepPartial): T; fromPartial(object: DeepPartial): T; } export {}; //# sourceMappingURL=command.d.ts.map