Agent skill

Master Detail Pages

by mendixlabs in mendixlabs/mxcli

The master-detail page pattern in MDL: a selectable list beside a detail form driven by SELECTION.

Apache-2.0Auto-check passed

Install Master Detail Pages

skills CLI
$ npx skills add mendixlabs/mxcli --skill master-detail-pages -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install mendixlabs/mxcli master-detail-pages --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/mendixlabs/mxcli.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/mendix/master-detail-pages .claude/skills/master-detail-pages && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
master-detail-pages
GitHub stars
129
Token cost
~1.8k tokens
SKILL.md length
484 words
Files
1
Skills in repo
72
Repo updated
First seen
Licence
Apache-2.0

At a glance

The master-detail page pattern in MDL: a selectable list beside a detail form driven by SELECTION.

  • Works in 3 steps: GALLERY Widget (Master List) → DataView with SELECTION Source → LISTVIEW Widget (Nested Data)
  • Building a selection-based screen rather than a plain list
  • SKILL.md covers Overview, MDL Syntax, Complete Example and Key Patterns, plus 3 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Master Detail Pages is an agent skill from mendixlabs/mxcli. The master-detail page pattern in MDL: a selectable list beside a detail form driven by SELECTION. Use when building a selection-based screen rather than a plain list or form.

Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

The repository describes itself as: Mendix cli tool, a headless way to work with Mendix projects. Enables Mendix projects for use with 3rd party agentic coding tools like Claude Code and Copilot. Includes a… The licence is Apache-2.0.

When your agent uses it

  • Building a selection-based screen rather than a plain list

Example prompts

  • “/master-detail-pages”

Workflow steps

3 steps, taken from the step headings in SKILL.md.

  1. GALLERY Widget (Master List)
  2. DataView with SELECTION Source
  3. LISTVIEW Widget (Nested Data)

What it can do on your machine

Read from SKILL.md and the folder at commit 5c321d0. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are sql).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Master Detail Pages loads about 1.8k tokens when it runs. Until then it costs about 49 tokens; SKILL.md has 484 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~49
When it runs · the whole SKILL.md, loaded when a task matches
~1.8k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from mendixlabs/mxcli at commit 5c321d0, republished under its Apache-2.0 licence (© mendixlabs). 484 words, ~1,763 tokens.

Download SKILL.mdSave it as .claude/skills/master-detail-pages/SKILL.md (or your agent's skills folder).
name
master-detail-pages
description
The master-detail page pattern in MDL: a selectable list beside a detail form driven by SELECTION. Use when building a selection-based screen rather than a plain list or form.

Master-Detail Pages

Overview

Master-Detail is a common UI pattern showing:

  • Master list (left): Selectable list of items (Gallery widget)
  • Detail form (right): Form showing selected item details (DataView with SELECTION source)

MDL Syntax

Basic Structure
sql
mdl 1;
create page Module.Entity_MasterDetail
(
  title: 'Entity Master-Detail',
  layout: Atlas_Core.Atlas_Default
)
{
  layoutgrid mainGrid {
    row {
      -- Master list (4 columns)
      column (desktopwidth: 4) {
        gallery entityList (datasource: database Module.Entity, selection: single) {
          template {
            dynamictext name (content: '{1}', contentparams: ({1} = Name), rendermode: H4)
          }
        }
      }

      -- Detail form (8 columns)
      column (desktopwidth: 8) {
        dataview entityDetail (datasource: selection entityList) {
          textbox txtName (label: 'Name', attribute: Name)

          footer {
            actionbutton btnSave (caption: 'Save', action: save changes, buttonstyle: success)
          }
        }
      }
    }
  }
};
Key Components
sql
gallery widgetName (
  datasource: database from Module.Entity sort by Name asc,
  selection: single|multiple|none
) {
  template template1 {
    -- Widgets for each item
    dynamictext name (content: '{1}', contentparams: ({1} = AttrName), rendermode: H4)
  }
}

Properties:

  • datasource: database from entity sort by attr asc|desc - Entity data source with optional sorting; sort by Assoc/Attr asc sorts over an association
  • selection: single - Selection mode (Single for master-detail)
  • Template content inside TEMPLATE widget (requires name)
2. DataView with SELECTION Source
sql
dataview widgetName (datasource: selection sourceWidgetName) {
  -- Form widgets
}

The selection source creates a binding to another widget's selection. When the user selects an item in the Gallery, the DataView displays that item.

3. LISTVIEW Widget (Nested Data)
sql
listview widgetName (datasource: database Module.Entity, PageSize: 10) {
  template template1 {
    -- Widgets for each associated item
  }
}

Used inside the detail form to show related/associated data.

Nested list by association (to-many): Use datasource: $currentObject/Module.Assoc (or the explicit datasource: association path form) on a list widget inside a parent DATAVIEW. Example: datagrid lines (datasource: $currentObject/Order_OrderLine) inside a dataview dv (datasource: database Order).

Referenced object by association (to-one) — "data from context": To show a single referenced object's attributes, use the same datasource: $currentObject/Module.Assoc on a nested DATAVIEW. Its children bind to the referenced (destination) entity. Example: an inner dataview dvEmployee (datasource: $currentObject/Expense_Employee) { textbox (attribute: Name) } inside a dataview dvExpense (datasource: $Expense) shows the Expense's Employee. (A DataView association source is stored as a Forms$DataViewSource with an association-navigating EntityRef — do not confuse it with the list-widget Forms$AssociationSource; that one is invalid on a DataView.)

Complete Example

sql
mdl 1;
create page CRM.Customer_MasterDetail
(
  title: 'Customer Management',
  layout: Atlas_Core.Atlas_Default
)
{
  layoutgrid mainGrid {
    row {
      column (desktopwidth: 4) {
        dynamictext heading (content: 'Customers', rendermode: H3)
        gallery customerList (datasource: database from CRM.Customer sort by Name asc, selection: single) {
          template {
            dynamictext name (content: '{1}', contentparams: ({1} = Name), rendermode: H4)
            dynamictext email (content: '{1}', contentparams: ({1} = Email))
          }
        }
      }

      column (desktopwidth: 8) {
        dataview customerDetail (datasource: selection customerList) {
          dynamictext detailHeading (content: 'Customer Details', rendermode: H3)
          textbox txtName (label: 'Name', attribute: Name)
          textbox txtEmail (label: 'Email', attribute: Email)
          textbox txtPhone (label: 'Phone', attribute: Phone)

          footer {
            actionbutton btnSave (caption: 'Save', action: save changes, buttonstyle: success)
            actionbutton btnCancel (caption: 'Cancel', action: cancel changes)
          }
        }
      }
    }
  }
};

Key Patterns

Selection Binding

The core of master-detail is the selection binding:

  1. Gallery has selection: single - enables single item selection
  2. DataView uses datasource: selection galleryName - listens to Gallery selection
  3. When user clicks an item in Gallery, DataView automatically updates
Show full SKILL.md (203 more words)Show less
Widget Names

The selection binding uses widget names to connect:

  • Gallery widget name: customerList
  • DataView references: datasource: selection customerList
Template Content with ContentParams

Inside Gallery templates, use contentparams to reference current item attributes:

sql
template template1 {
  dynamictext name (content: '{1}', contentparams: ({1} = Name), rendermode: H4)
  dynamictext email (content: '{1}', contentparams: ({1} = Email))
}

Syntax Summary

ElementSyntax
Page properties(title: 'title', layout: Module.Layout)
Widget nameRequired after type: gallery myGallery (...)
Database sourcedatasource: database from Module.Entity
Selection bindingdatasource: selection widgetName
Sort bydatasource: database from entity sort by Name asc
Sort over an associationdatasource: database from entity sort by Order_BillTo/City asc — one / per hop, last segment is the attribute. Name the hop when two associations reach the same entity; inference cannot tell them apart (mendixlabs/mxcli#1152)
Where filterdatasource: database from entity where [IsActive = true]
Selection modeselection: single
Attribute bindingattribute: attributename
Action bindingaction: save changes
Button stylebuttonstyle: success
Text contentcontent: 'text' with contentparams: ({1} = attr)
Render moderendermode: H4
Template contenttemplate template1 { ... }

Implementation Notes

  • Gallery is a pluggable widget (similar to DataGrid2)
  • Selection binding uses ListenTargetSource in the Model SDK
  • ListView is a built-in Mendix widget
  • All widget properties use explicit (key: value) syntax

© mendixlabs, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/mendix/master-detail-pages of mendixlabs/mxcli.

Open the folder on GitHubat commit 5c321d0

Compare with similar skills

Master Detail Pages next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Master Detail Pages compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Master Detail Pages this skillmendixlabs/mxcli129—~1.8kAutomated safety check: PassApache-2.0
Golang Patternsaffaan-m/ECC276k—~1.1kAutomated safety check: PassMIT
Kotlin Exposed Patternsaffaan-m/ECC276k4 repos~5.5kAutomated safety check: PassMIT
Dotnet Patternsaffaan-m/ECC276k1 repos~2.3kAutomated safety check: PassMIT
Fastapi Patternsaffaan-m/ECC276k—~2.3kAutomated safety check: PassMIT
Python Patternsaffaan-m/ECC276k—~2.3kAutomated safety check: PassMIT

Similar skills

  • Golang Patterns

    affaan-m/ECC

    Go-specific design patterns and best practices including functional options, small interfaces, dependency injection, concurrency patterns, error handling, and package organization.

    276k GitHub stars~1.1k tokensUpdated 4 days ago
    DevelopmentAuto-check passed
  • JetBrains Exposed ORM patterns including DSL queries, DAO pattern, transactions, HikariCP connection pooling, Flyway migrations, and repository pattern.

    276k GitHub starsUsed in 4 repos~5.5k tokens
    DatabasesAuto-check passed
  • Dotnet Patterns

    affaan-m/ECC

    Idiomatic C and .NET patterns, conventions, dependency injection, async/await, and best practices for building robust, maintainable .NET applications.

    276k GitHub starsUsed in 1 repo~2.3k tokens
    DevelopmentAuto-check passed
  • Fastapi Patterns

    affaan-m/ECC

    FastAPI patterns for async APIs, dependency injection, Pydantic request and response models, OpenAPI docs, tests, security, and production readiness.

    276k GitHub stars~2.3k tokensUpdated 4 days ago
    Backend & APIsAuto-check passed
  • Python Patterns

    affaan-m/ECC

    Python-specific design patterns and best practices including protocols, dataclasses, context managers, decorators, async/await, type hints, and package organization.

    276k GitHub stars~2.3k tokensUpdated 4 days ago
    DevelopmentAuto-check passed
  • Patterns

    sickn33/agentic-awesome-skills

    Reference document for monopoly patterns. An agent skill from sickn33/agentic-awesome-skills.

    47k GitHub starsUsed in 1 repo~2.6k tokens
    Backend & APIsAuto-check passed

More from mendixlabs/mxcli

All 72 skills in this repo
  • Mendix Odata Pushdown

    mendixlabs/mxcli

    Push OData query options into the SQL of a Mendix resource served by a read microflow, so $filter, $orderby, $top, $skip, $count and the key lookup reach the database instead of being silently…

    129 GitHub stars~2.5k tokensUpdated today
    Auto-check passed
  • Mendix Vega Charts

    mendixlabs/mxcli

    Chart a Mendix app with Vega-Lite through a pluggable widget that takes the specification and the data as separate properties, so the model emits rows and never assembles a chart payload.

    129 GitHub stars~3k tokensUpdated today
    Auto-check passed
  • Mendix Bulk Oql Dml

    mendixlabs/mxcli

    Run set-based INSERT, UPDATE and DELETE against Mendix entities through OQL statements, which the runtime supports and Studio Pro cannot author.

    129 GitHub stars~1.4k tokensUpdated today
    Auto-check passed
  • Agents

    mendixlabs/mxcli

    Author Mendix AI agent documents in MDL — Model, Knowledge Base, Consumed MCP Service and Agent, with variables, tools and multi-line prompts.

    129 GitHub stars~2.2k tokensUpdated today
    Auto-check passed
  • Analyze Runtime

    mendixlabs/mxcli

    Find out what a running Mendix app actually does — logs, Prometheus metrics, OpenTelemetry traces and the model catalog, joined across sources.

    129 GitHub stars~2.8k tokensUpdated today
    Auto-check passed
  • Assess Migration

    mendixlabs/mxcli

    Investigate an existing non-Mendix application (Java, .NET, Python, Node, PHP, …) and produce a structured migration assessment for Mendix.

    129 GitHub stars~3.6k tokensUpdated today
    Auto-check: notes

Questions about Master Detail Pages

What does Master Detail Pages do?

The master-detail page pattern in MDL: a selectable list beside a detail form driven by SELECTION. Master Detail Pages is an agent skill from mendixlabs/mxcli. The master-detail page pattern in MDL: a selectable list beside a detail form driven by SELECTION.

When should I use Master Detail Pages?

Master Detail Pages fits situations like: building a selection-based screen rather than a plain list.

How do I install Master Detail Pages in Claude Code?

Run `npx skills add mendixlabs/mxcli --skill master-detail-pages -a claude-code`. Or copy the skill folder (.claude/skills/mendix/master-detail-pages in mendixlabs/mxcli) into .claude/skills/master-detail-pages in your project. Claude Code loads it when a task matches its description.

How do I install Master Detail Pages in Codex?

Run `npx skills add mendixlabs/mxcli --skill master-detail-pages -a codex`. Or copy the skill folder (.claude/skills/mendix/master-detail-pages in mendixlabs/mxcli) into .agents/skills/master-detail-pages in your project. Codex loads it when a task matches its description.

Can I use Master Detail Pages in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add mendixlabs/mxcli --skill master-detail-pages -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/master-detail-pages, .gemini/skills/master-detail-pages, .github/skills/master-detail-pages and .opencode/skills/master-detail-pages in your project.

What does Master Detail Pages need to run?

SKILL.md names no scripts, command-line tools or credentials: Master Detail Pages is instructions for the agent only.

Does Master Detail Pages access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Master Detail Pages safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Master Detail Pages use?

Master Detail Pages is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Master Detail Pages use?

About 1.8k tokens (SKILL.md is roughly 7.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Master Detail Pages?

Skills that share tags, products or a category with Master Detail Pages: Golang Patterns (affaan-m/ECC, 276k stars), Kotlin Exposed Patterns (affaan-m/ECC, 276k stars), Dotnet Patterns (affaan-m/ECC, 276k stars) and Fastapi Patterns (affaan-m/ECC, 276k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Master Detail Pages?

mendixlabs (a GitHub organization) maintains it in mendixlabs/mxcli, which has 129 GitHub stars. The repository holds 72 skills in this directory. The repository was last updated on October 8, 2026.

Source: mendixlabs/mxcli on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.