Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
HOSTNoHTTP bind address127.0.0.1
PORTNoHTTP bind port8000
LOG_LEVELNoLogging levelINFO
TRANSPORTNoTransport type: stdio, streamable-http, or ssestdio
MAX_SOCKETSNoMax concurrent sockets128
MAX_RECV_BYTESNoMax recv payload1048576
MAX_SEND_BYTESNoMax send payload1048576
CLEANUP_INTERVALNoCleanup scan interval5
SOCKET_IDLE_TIMEOUTNoIdle seconds before auto-close300
ALLOW_PRIVATE_NETWORKNoAllow RFC1918/loopback/ULA/etc.false

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
resolve_dnsA

Resolve a hostname into IPv4 (A) and IPv6 (AAAA) addresses. Address ordering follows the OS resolver. Use this before tcp_connect/udp_send because those tools require IP literals, not hostnames.

tcp_connectA

Create a TCP socket and connect to an IP:port. address must be an IPv4 or IPv6 literal (call resolve_dns first for hostnames). Returns socket_id for subsequent send/recv/close operations.

udp_openA

Create an unbound outbound UDP socket. Use udp_send to send datagrams and udp_recv to receive them. Returns socket_id.

list_socketsA

List open sockets and their metadata (state, remote/local endpoints, idle time, byte/packet counters). Pass socket_id as a string, list of strings, or omit/null for all sockets.

close_socketA

Close a socket and remove it from the registry. For TCP, reset=false performs a graceful FIN shutdown; reset=true attempts an abortive close (TCP RST). For UDP, reset is ignored.

tcp_sendA

Send bytes over a connected TCP socket. encoding=utf8 encodes data as UTF-8; encoding=base64 base64-decodes data first.

udp_sendC

Send a UDP datagram to address:port. address must be an IP literal. encoding=utf8 or base64 as with tcp_send.

socket_pollA

Check whether a socket currently has readable data. If timeout_seconds > 0, wait until readable or timeout. Most clients can rely on timeout support in tcp_recv/udp_recv instead.

tcp_recvA

Receive bytes from a TCP socket. timeout_seconds=0 (default) is non-blocking; >0 waits for at least one byte or timeout. Returns base64 (and text if valid UTF-8). bytes_received=0 with empty data indicates timeout or EOF (peer closed).

udp_recvA

Receive one or more UDP datagrams (up to max_packets). timeout_seconds=0 (default) is non-blocking; >0 waits for at least one packet. Each packet includes source address/port, length, base64 data, and optional text.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

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/cinit/mcp-socket'

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