alter-page

A way to make targeted changes to an existing page or reusable snippet by editing its widget tree in place.

In plain words
What is it for?
Use it to change labels or styles, add or remove fields and widgets, replace sections, or apply several related edits to one page.
Why use it?
It lets you change selected parts while preserving other widget types and properties instead of rebuilding the whole page.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/mendixlabs/mxcli/alter-page
Any agent
npx skills add mendixlabs/mxcli --skill alter-page
Clone the repo
git clone --depth 1 https://github.com/mendixlabs/mxcli

Made for: Claude Code, Codex.

Per session 69 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,575 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00069 $0.05575
Opus 5 $0.00034 $0.02788
Sonnet 5 $0.00014 $0.01115
Haiku 4.5 $0.00007 $0.00558

Measured yesterday against content hash c8095ef59749, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

alter-page scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/mendix/alter-page/SKILL.md · 525 lines

How it starts

The opening of the file, as written. The whole thing — 525 lines — stays where its author put it; the contents beside it link to each section on GitHub.

ALTER PAGE / ALTER SNIPPET - Modify Existing Pages and Snippets

Overview

ALTER PAGE and ALTER SNIPPET modify an existing page or snippet's widget tree in-place without requiring a full create or replace. Operations work directly on the raw BSON tree, preserving widget types and properties that MDL doesn't explicitly model.

When to Use

Scenario Use
Change a button caption, label, or style alter page with set
Add a field to an existing form alter page with insert
Remove unused widgets alter page with drop
Replace a footer or section alter page with replace
Several related changes on the same page alter page with multiple operations in one block
Same property across many pages (e.g., add Class to every Container) update widgets — see bulk-widget-updates
Rebuild entire page from scratch create or replace page
Create a new page create page

Rule of thumb:

  • alter page — targeted edits to one page. Combine multiple ops in one block when they belong together.
  • update widgets — cross-page bulk updates with WHERE filtering and DRY RUN.
  • create or replace page — redefining the full page structure.

Syntax

alter page Module.PageName {
  operation1;
  operation2;
  ...
};

alter snippet Module.SnippetName {
  operation1;
  operation2;
  ...
};

Multiple operations can be combined in a single ALTER statement. They are applied sequentially; later operations see the page state produced by earlier ones, so you can set on a widget you just inserted.

-- Rename a column, add a sibling, drop an obsolete one — all in one block.
alter page MyMod.Product_Overview {
  set caption = 'Product Name' on dgProducts.Name;
  insert after dgProducts.Lifecycle {
    column NewCol (attribute: Sku, caption: 'SKU')
  };
  drop widget dgProducts.OldCol
};

For changes that should be applied across many pages (e.g., "add Class='card' to every Container in MyMod"), use UPDATE WIDGETS instead — see bulk-widget-updates.

Read the full file on GitHub · 525 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 525 lines · 69 tokens per session scan A c8095ef59749

Subscribe to this mod's changes

alter-page is a skill published in the GitHub repository mendixlabs/mxcli (115 stars, last pushed 2d ago), licensed Apache-2.0. It adds 69 tokens to every session and 5,575 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.