Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
MCP_HOSTNoBind address for `MCP_TRANSPORT=http`.127.0.0.1
MCP_PORTNoBind port for `MCP_TRANSPORT=http`. The endpoint is `http://MCP_HOST:MCP_PORT/mcp`.8000
MCP_LOG_LEVELNo`DEBUG`, `INFO`, `WARNING`, `ERROR` or `CRITICAL`. Logs go to stderr.INFO
MCP_TRANSPORTNo`stdio`, or `http` for streamable HTTP.stdio
FLECS_REST_URLYesBase URL of the FLECS REST API, e.g. `http://localhost:27750`. A path prefix is allowed (for a reverse proxy); a query string is not. Required.
FLECS_REST_TIMEOUTNoRequest timeout in seconds (> 0).5
FLECS_REST_VERIFY_TLSNoVerify TLS certificates for `https://` URLs. Accepts `true/false`, `1/0`, `yes/no`, `on/off`.true
FLECS_REST_ALLOW_MUTATIONSNoRegister the MUTATION tools. They change the running application.false

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

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

Tools

Functions exposed to the LLM to take actions

NameDescription
flecs_get_world_infoA

[READ] Describe the connected FLECS world; call it first to test the link.

Returns:

  • rest_url: the FLECS REST API this server talks to.

  • build_info: FLECS version, compiler, enabled addons and build flags (flecs.core.BuildInfo), or null if unavailable.

  • world_summary: live counters such as entity, table, component and query counts, frame count, fps, target fps, time scale and uptime (flecs.stats.WorldSummary), or null if the stats module is not imported.

  • notes: why a section is null, if any.

Fails if the FLECS REST API cannot be reached.

flecs_get_entityA

[READ] Get one entity with its tags, relationship pairs and component values.

Returns the FLECS entity JSON: 'parent', 'name', 'tags' (list), 'pairs' (relationship -> target), 'components' (component -> value; null when the component has no reflection data) and, when requested, 'id', 'type_info', 'inherited', 'matches' and doc info. Names use full paths.

Errors when the entity does not exist. Use flecs_query to find entities.

flecs_get_componentA

[READ] Get the value of a single component of an entity.

Returns {entity, component, value}; 'value' is the component serialized by FLECS reflection (usually an object of members, e.g. {"x": 10, "y": 20}). Errors when the entity does not have the component, when the id is a tag (no data) or when it cannot be resolved.

flecs_queryA

[READ] Find entities with a query written in the FLECS query language.

Syntax cheat sheet (terms are comma separated and all must match):

  • 'Position, Velocity' entities with both components

  • 'Position, !Velocity' ... without Velocity

  • 'Position, ?Mass' Mass is optional

  • 'Planet || Moon' either tag

  • '(ChildOf, Sun)' children of entity Sun

  • '!(flecs.core.ChildOf, *)' root entities

  • '(Likes, *)' / '(Likes, $x)' wildcard / variable pair target

  • 'Position, Mass(up)' Mass on an ancestor (ChildOf)

  • 'SpaceShip, $this ~= "Uss"' name contains "Uss"

  • 'IsA(_, *)' instances of any prefab Use full paths (e.g. 'transform.Position') when names are ambiguous.

Returns {page, results, type_info?}. Each result has 'parent', 'name' and, depending on options, 'id', 'fields' ({values, ids, sources, is_set} per query term), 'vars' or, with table=true, 'tags'/'pairs'/'components'. page = {offset, limit, returned, may_have_more}; when may_have_more is true, call again with offset += limit. Invalid queries return the FLECS parser error (with position) so the query can be fixed.

flecs_run_named_queryA

[READ] Return what an existing named query, system or observer matches now.

Useful to check which entities a system processes. Same result format as flecs_query: {page, results, type_info?}.

flecs_explain_queryA

[READ] Explain how FLECS parses and plans a query, without returning results.

Returns 'query_info' (resolved terms: operator, source, traversal flags), 'field_info' (id, type and member schema per field), 'query_plan' (the FLECS query plan as text) and optionally 'query_profile'. Use it to debug queries that match nothing or match too much. Invalid queries return the FLECS parser error.

flecs_get_type_infoA

[READ] Get the reflection schema (members, types, units) of a component type.

Returns {component, has_reflection, schema}. 'schema' maps member names to [type, {unit, ...}] descriptors, e.g. {"x": ["float"], "y": ["float"]}. has_reflection is false (and schema null) when the type has no reflection data, in which case FLECS cannot serialize or set its value.

flecs_list_componentsA

[READ] List the component, tag and pair ids in use, with storage statistics.

Each entry has 'name', 'entity_count', 'entity_size', 'tables' (table ids), 'traits' (e.g. Exclusive, CanToggle, (OnDelete,Remove)), 'type' (size, alignment, which lifecycle hooks are set; absent for tags), 'sparse' (for sparse components) and 'memory' when the stats module is imported. Includes FLECS builtin ids and wildcard records. Returns {total, offset, limit, components}; total counts matches after filtering. Use flecs_get_type_info for a component's member schema.

flecs_list_queriesA

[READ] List named queries, systems and observers with evaluation statistics.

Each entry has 'name' (usable with flecs_run_named_query), 'kind' (Query, System or Observer), 'expr' (the query expression), 'results' and 'count' (current matches), 'eval_count', 'eval_time', 'eval_mode', 'cache_kind', 'batched', 'empty_tables', 'plan_size' and, when the stats module is imported, 'memory'. FLECS evaluates every query to produce this list, which can take a while in very large worlds. Returns {total, offset, limit, queries}.

flecs_get_world_statsA

[READ] Get world performance statistics from the FLECS stats module.

'metrics' maps names such as 'performance.fps', 'performance.frame_time', 'entities.count', 'tables.count', 'queries.system_count', 'commands.add_count' and 'memory.alloc_count' to {avg, min, max, brief}. Times are in seconds. Requires the FLECS application to import the stats module (FlecsStats); returns an explanatory error otherwise.

flecs_get_pipeline_statsA

[READ] Get per-system timing statistics from the FLECS stats module.

'entries' contains one object per system: 'name', 'disabled', 'time_spent' and (for non-task systems) 'matched_entity_count' and 'matched_table_count', each metric as {avg, min, max}. With a pipeline, sync points ('multi_threaded', 'immediate', 'time_spent', 'commands_enqueued') are interleaved in execution order. Times are in seconds. Requires the stats module (FlecsStats).

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription
flecs_build_infoFLECS build of the connected application: version, compiler, enabled addons and debug/sanitize/perf_trace flags (flecs.core.BuildInfo).

TDQS

A4/5.0

Scored across 11 tools

Disambiguation5/5

Each tool has a clearly distinct purpose: entity vs component retrieval, ad-hoc vs named query execution vs query explanation, world info vs stats vs pipeline stats, and list vs schema inspection. The descriptions explicitly clarify boundaries (e.g., use flecs_query to find entities, flecs_run_named_query for existing named queries), so misselection risk is low.

Naming Consistency4/5

All tools use the flecs_ prefix and snake_case, with a consistent verb_noun pattern in nearly every case (get_world_info, get_entity, list_components, run_named_query, etc.). The one minor deviation is flecs_query, which is verb-only rather than verb_noun, but overall the convention remains predictable.

Tool Count5/5

Eleven tools is well-scoped for a FLECS inspection server, covering world info, entities, components, queries, and statistics without redundancy. Each tool earns its place and the surface is neither thin nor bloated.

Completeness4/5

The read-only introspection surface is thorough: world info, entity/component retrieval, query execution, query explanation, type schemas, lists, and performance stats. However, mutation operations (e.g., creating entities, setting components, running systems) are absent, which could be a gap if the server is intended for more than read-only diagnostics.

Maintenance

ActivityMaintained
ResponsivenessNo issues