Skip to main content
Glama
Enterprise Architect MCP Server

Enterprise Architect MCP Server

by mm6502

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
EA_LOCALENoBCP 47 locale tag (e.g., 'sk', 'pl', 'hu', 'de') used for locale-aware name ordering in ea_get_scenarios. Defaults to the host system locale.
EA_QEA_PATHNoPath to the .qea file (or directory containing the newest .qea file) to open. If not provided, the server will prompt for a path when first queried.
EA_MCP_CONFIG_DIRNoDirectory where the server stores remembered answers and configuration. Defaults to platform-specific application data directory.

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 provides read-only access to a Sparx Enterprise Architect analysis model (.qea export).

Response shape contract:

  • Every response is structured JSON — no tool returns unstructured text, even for empty results.

  • Every collection carries totalMatched, returned, truncated (always present, even when truncated: false).

  • _meta.sourceTables lists which database tables the response draws from.

  • ea_get_diagram_elements returns per-collection metadata in _meta.elements and _meta.connectors (not top-level) because it returns two independent collections.

  • The enumeration tools (ea_search, ea_list_elements, ea_list_diagrams) return a window: they accept offset, echo it back, and order results deterministically. That order is stable but artificial — not alphabetical and not the analyst's tree order — so never infer meaning from adjacency.

  • When truncated: true, a continuation object provides the exact call that returns the next window. Following it repeatedly visits every matching row once and terminates; do not raise limit to fetch a large set in one call.

  • When far more rows match than one window holds, a breakdown object reports how they distribute. Every key in it is a parameter name and every value is an argument value, so a breakdown is an invitation to narrow the next call rather than page through the set. Each axis reports totalMatched/returned/truncated for its own list of distinct values, not for rows, and rows carrying no value on that axis are not counted — so the counts need not sum to the response's totalMatched.

  • Not-found errors (non-existent element/package/diagram ID) return isError: true with structured JSON — distinct from a valid empty result.

  • When reporting that something is absent from the model, cite totalMatched, truncated and _meta.sourceTables from the response that supports the claim. An empty result is not evidence of absence unless the subject is confirmed to exist.

Text fields (Note, Notes, notes) use EA's HTML dialect: lists (, , ), bold (), anchors (). No div/span/script. Structural escapes (< > &) are preserved. Embedded model links ($element://, $diagram://) appear as targets. Character entities (á etc.) are decoded to characters.

Use ea_* tools when the user asks about:

  • Business analysis, use cases, requirements, screens, classes, or domain model elements

  • Application architecture, components, interfaces, or their relationships

  • Use case scenarios / flows — all step attributes (trigger, uses, result, link) and scenario notes are returned

  • How elements relate to each other — connectors include feature-link resolution showing which attribute or operation each end attaches to

  • Package/module structure of the analysis model

  • Diagram contents — elements AND connectors (including implied connectors with both ends on the diagram)

  • Which diagrams an element appears on (returned by ea_get_element)

  • Constraints and business rules on elements (pre-conditions, post-conditions, invariants, process rules)

  • Resolving analyst references (GUIDs, names) to model nodes

  • What database tables and columns the model export contains

  • Which export file the server has open

Do NOT use ea_* tools for:

  • Azure DevOps work items, bugs, tasks, PRs, or repositories (use ado server instead)

  • Source code, builds, or deployments

Typical workflow: ea_search → ea_get_element → ea_get_connectors / ea_get_scenarios Reference resolution: ea_resolve (GUID or name) → ea_get_element or ea_get_diagram_elements Discovery: ea_list_diagrams to find diagrams, ea_get_schema to explore the model's tables Provenance: ea_get_model_info to identify the export file

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
ea_searchA

Search Enterprise Architect model elements by name, alias, notes, attribute names/notes, operation names/notes, or constraint notes. Matching is case- and diacritic-insensitive across European Latin alphabets and sees through entity-encoded text. requiredTerms is a list of terms every one of which must occur somewhere in an element's searchable text (conjunction) — terms need not share a field, but sharing one ranks higher; each term is matched as a contiguous substring exactly as a single term is, so a term carrying whitespace is a phrase and is never split. A one-entry list behaves exactly as a single search term always has. boostAnyOf is an optional list of further terms: a result also matching at least one of them ranks ahead of one that does not, but nothing is ever excluded on that basis — for narrowing to only elements matching an alternative too, use ea_search_and_any_of instead. When no element matches, termMatches reports, per supplied term, whether that term matched anywhere in the corpus at all — so a caller can tell which term emptied the result rather than re-guessing the whole call. Matching elements are returned in results, strongest match first, each with a decoded note preview and a truncation flag; equally strong matches fall back to the model's internal identity, a stable but artificial order. Each result also carries matches, the evidence for why it was returned: the field that matched, the id and name of the attribute, operation or constraint it came from, and a snippet of the author's own text around the match. Evidence is strongest-first and capped, and _meta.matches on the result reports how many matches were found and how many were withheld. The note preview centres on the match when the element's own note is what matched. packageScope restricts results to a package (given as its id or its name) and its descendants. Walk a large result set with offset rather than a larger limit; while rows remain, continuation names the next call. When far more elements match than one window can hold, breakdown reports how they distribute — by objectType, stereotype, or, unless already scoped, by packageScope (reported as the matching package's id, which the next call can pass straight back) — so the next call can narrow instead of paging.

ea_search_and_any_ofA

Search Enterprise Architect model elements the same way ea_search does, plus andAnyOf: a required-and-alternative filter. requiredTerms still works exactly as it does on ea_search (conjunction, contiguous substring, terms need not share a field). andAnyOf is an optional list of further terms; when supplied, a result must contain requiredTerms AND at least one andAnyOf term, so it can only ever narrow — it never returns a result requiredTerms alone would not. An empty andAnyOf array applies no filter. For promoting rather than narrowing, use ea_search instead, which offers the same alternatives idea as a rank boost. When no element matches the required terms at all, termMatches reports, per supplied term, whether it matched anywhere in the corpus. Matching elements are returned in results, strongest first, each with a decoded note preview, a truncation flag, and matches — the evidence for why it was returned, capped and strongest-first, with _meta.matches reporting how many were found and withheld. packageScope restricts results to a package and its descendants. Walk a large result set with offset; while rows remain, continuation names the next call. When far more elements match than one window can hold, breakdown reports how they distribute by objectType, stereotype, or packageScope.

ea_get_elementA

Get full details of an Enterprise Architect element by its ID, including its Note, attributes, operations, the diagrams it appears on, and its constraints. Attribute multiplicity supports a requiredness inference only when the element uses multiplicities contrastively; read _meta.attributes.multiplicityIsUniform before making that inference — when it is true the element's attributes carry no multiplicity contrast, so a value like 1..1 is not evidence of requiredness. Attributes and operations are capped inline: attributesTruncated/operationsTruncated say whether the returned list is partial, and attributesTotal/operationsTotal give the full counts, so never infer a count from the inline list alone.

ea_list_elementsA

List elements within a package, optionally filtered by object type. elements is a lightweight list (ID, type, name, alias, stereotype), grouped by element type and then ordered by the model's internal identity. That order is stable but artificial — neither alphabetical nor the analyst's tree order — so adjacency carries no meaning. Walk a large package with offset rather than a larger limit; while rows remain, continuation names the next call. When far more elements match than one window can hold, breakdown reports how many each type holds, so the next call can narrow by objectType instead of paging.

ea_get_connectorsA

Get all relationships (connectors) for a given element. connectors lists what the element is connected to and how (Realisation, Dependency, Association, etc.), each entry naming its source and dest ends. For Generalization connectors, source is always the specific (child) type and dest the general (parent) type — each end also carries a role making this explicit without needing to reason about direction. Filter by connectorType and direction to list an element's direct children (incoming Generalization) or direct parent(s) (outgoing Generalization) without a diagram. Feature links show which specific attribute or operation each end attaches to.

ea_get_package_treeA

Navigate the package hierarchy. Without parameters, returns top-level packages. With a packageId, returns that package's children up to the specified depth. Each node carries id, name, parentId, and elementCount.

ea_get_diagram_elementsA

Get all elements and connectors placed on a specific diagram: the diagram itself, plus elements and connectors. elements already includes free-text Note diagram objects, which often carry a legend or abbreviation definitions an agent would otherwise miss. Connectors include feature-link resolution showing which attribute or operation each end attaches to. The connector list is the union of explicit t_diagramlinks rows and implied connectors (both ends on the diagram).

ea_list_diagramsA

List diagrams in the model, optionally filtered by package, diagram type, and/or name substring. Each entry in results carries diagramId, name, type, packagePath, and eaGuid. Diagrams are ordered by the model's internal identity — stable but artificial, neither alphabetical nor the analyst's tree order — so adjacency carries no meaning. Walk a large result set with offset rather than a larger limit; while rows remain, continuation names the next call. When far more diagrams match than one window can hold, breakdown reports how many each type holds, so the next call can narrow by diagramType instead of paging.

ea_get_scenariosA

Get use case scenario flows for an element. scenarios holds the parsed flows; each has name, type, notes, and steps, and each step carries stepNumber plus its attributes (trigger, uses, result, state, link). Steps are numbered within each scenario. Scenarios ordered by type: Basic Path first, then Alternate, then Exception. A step's uses may name a business rule or constraint by code; that code is not independently searchable or resolvable — look it up among this same elementId's own constraints via ea_get_element, not by a separate lookup.

ea_get_schemaA

List the model's database tables in tables, or pass a tableName to get that table's columns and indexes instead. That form echoes the table name and adds rowidAlias — the INTEGER PRIMARY KEY aliasing SQLite's rowid, so the fastest lookup path, or null when the table has none — with rowidNote saying which case applies. Use this to discover what data the model holds beyond what the typed ea_* tools return. See ea_get_model_info for the export's identity.

ea_get_model_infoA

Report which .qea export file the server has open: fileName is the citable identity, alongside fileSizeBytes, lastModified, and the serverVersion that produced the answer. The full local path is also returned as resolvedPath, with resolvedPathNote explaining why it is environment detail rather than something to cite. configuration says where that path came from — source in words, sourceId as one of argument/environment/dotenv/remembered/prompt, and the configured value behind it — plus any skipped settings, each with the reason it could not be opened, and shadowed ones a higher-priority source outranked; configurationNote says how much of that is safe to repeat.

ea_resolveA

Resolve an analyst reference (braced GUID or plain name) to model candidates: the input is echoed as reference and the hits are in candidates. A braced GUID is matched exactly. A plain name is matched against the full name first; only if nothing matches exactly is the reference retried as a name prefix, which resolves analyst codes like UC_ABC_2079 or OA_ABC_2280 to elements named 'CODE: description'. An exact hit is returned alone and is never diluted by prefix hits. Each candidate reports its type (element, diagram, package), id, name, fullPackagePath, eaGuid, and a match field that is always present with value "guid", "exact", or "prefix" — a "prefix" candidate is an inexact match and must not be treated as a confirmed identity. Use the optional kind filter to narrow results.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A4/5.0

Scored across 12 tools

Disambiguation3/5

Most tools target clearly distinct resources (packages, elements, connectors, diagrams, scenarios, schema), but `ea_search` and `ea_search_and_any_of` are effectively the same operation with one extra filter, and their descriptions spend most of their length explaining how they differ from each other. That is a parameter variation surfaced as a separate tool, which invites misselection. `ea_get_element` vs `ea_list_elements` is distinguishable, but the search pair drags the set down.

Naming Consistency4/5

All names share the `ea_` prefix and follow a verb_noun pattern (`ea_get_element`, `ea_list_diagrams`, `ea_get_connectors`), which is highly predictable. Minor deviations: `ea_resolve` has no object noun, and `ea_search_and_any_of` encodes a parameter in the tool name rather than following the resource+action convention.

Tool Count4/5

Twelve tools is a well-scoped surface for a read-only model browser, and each maps to a real artifact type in the .qea model. The count would be a clean 5 if the two near-duplicate search tools were merged into one with an optional filter.

Completeness4/5

The surface covers the main exploration paths: package hierarchy, element search and detail, element listing, connectors, diagram listing and contents, scenario flows, raw schema access, reference resolution, and export identity. Gaps remain around tagged values, standalone constraint/attribute/operation lookups, and any write capability, though a read-only inspector scope makes the latter a defensible design choice.

Maintenance

ActivityNo data
ResponsivenessOutdated data