Skip to content

MCP tool: workspace_inspect — drill-down into component structure #119

@TomProkop

Description

@TomProkop

Summary

New MCP tool for inspecting internal structure of a single workspace component. For forms: show tab→section→control tree with datafieldname. For entities: show attributes with types.

API

workspace_inspect

Params:
  path:    string?  — path to workspace (default: cwd)
  type:    string   — Form, Entity, View, SecurityRole, ...
  id:      string   — identifier (formId, entityLogicalName, viewId)
  depth:   int?     — max tree depth (default: full)

Returns (Form example):
  formId, formType, entityLogicalName, displayName,
  body:
    tabs: [{
      id, name, label,
      sections: [{
        id, name, label,
        controls: [{id, datafieldname, classid}]
      }]
    }]

Returns (Entity example):
  logicalName, displayName, primaryAttribute,
  attributes: [{logicalName, type, displayName, isRequired}]

Implementation notes

  • Load workspace via XmlWorkspaceReader
  • For forms: traverse MergeableNode tree, output structured representation
  • For entities: enumerate EntityMetadata.Attributes
  • Output: structured JSON for MCP, human-readable tree for CLI

No dependencies in platform-metadata

Uses existing read-only API.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions