Skip to main content
Glama
TrackLine
by TrackLine

hosts_create

Create new hosts in Remnawave VPN panels by specifying addresses, ports, security configurations, and assigning nodes for network management.

Instructions

Create a new host in Remnawave

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
remarkYesHost remark/name
addressYesHost address
portYesHost port
configProfileUuidYesConfig profile UUID
configProfileInboundUuidYesConfig profile inbound UUID
pathNoURL path
sniNoSNI (Server Name Indication)
hostNoHost header
alpnNoALPN protocol
fingerprintNoTLS fingerprint
isDisabledNoCreate in disabled state
securityLayerNoSecurity layer
tagNoHost tag
serverDescriptionNoServer description
nodesNoArray of node UUIDs to assign

Implementation Reference

  • Handler function for the hosts_create tool which constructs the body and calls client.createHost.
    async (params) => {
        try {
            const body: Record<string, unknown> = {
                remark: params.remark,
                address: params.address,
                port: params.port,
                inbound: {
                    configProfileUuid: params.configProfileUuid,
                    configProfileInboundUuid:
                        params.configProfileInboundUuid,
                },
            };
            if (params.path !== undefined) body.path = params.path;
            if (params.sni !== undefined) body.sni = params.sni;
            if (params.host !== undefined) body.host = params.host;
            if (params.alpn !== undefined) body.alpn = params.alpn;
            if (params.fingerprint !== undefined)
                body.fingerprint = params.fingerprint;
            if (params.isDisabled !== undefined)
                body.isDisabled = params.isDisabled;
            if (params.securityLayer !== undefined)
                body.securityLayer = params.securityLayer;
            if (params.tag !== undefined) body.tag = params.tag;
            if (params.serverDescription !== undefined)
                body.serverDescription = params.serverDescription;
            if (params.nodes !== undefined) body.nodes = params.nodes;
    
            const result = await client.createHost(body);
            return toolResult(result);
        } catch (e) {
            return toolError(e);
        }
    },
  • Zod schema definition for the inputs of hosts_create tool.
    {
        remark: z.string().describe('Host remark/name'),
        address: z.string().describe('Host address'),
        port: z.number().describe('Host port'),
        configProfileUuid: z
            .string()
            .describe('Config profile UUID'),
        configProfileInboundUuid: z
            .string()
            .describe('Config profile inbound UUID'),
        path: z.string().optional().describe('URL path'),
        sni: z.string().optional().describe('SNI (Server Name Indication)'),
        host: z.string().optional().describe('Host header'),
        alpn: z
            .enum(['h3', 'h2', 'http/1.1', 'h2,http/1.1', 'h3,h2,http/1.1', 'h3,h2'])
            .optional()
            .describe('ALPN protocol'),
        fingerprint: z
            .enum([
                'chrome',
                'firefox',
                'safari',
                'ios',
                'android',
                'edge',
                'qq',
                'random',
                'randomized',
            ])
            .optional()
            .describe('TLS fingerprint'),
        isDisabled: z
            .boolean()
            .optional()
            .describe('Create in disabled state'),
        securityLayer: z
            .enum(['DEFAULT', 'TLS', 'NONE'])
            .optional()
            .describe('Security layer'),
        tag: z.string().optional().describe('Host tag'),
        serverDescription: z
            .string()
            .optional()
            .describe('Server description'),
        nodes: z
            .array(z.string())
            .optional()
            .describe('Array of node UUIDs to assign'),
    },
  • Registration of the hosts_create tool.
    server.tool(
        'hosts_create',
        'Create a new host in Remnawave',

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/TrackLine/mcp-remnawave'

If you have feedback or need assistance with the MCP directory API, please join our Discord server