Agent skill

Regular Expressions

by mendixlabs in mendixlabs/mxcli

Create and manage named regular-expression documents and bind them to attribute validation rules.

Apache-2.0Auto-check passed

Install Regular Expressions

skills CLI
$ npx skills add mendixlabs/mxcli --skill regular-expressions -a claude-code

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

GitHub CLI
$ gh skill install mendixlabs/mxcli regular-expressions --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/regular-expressions .claude/skills/regular-expressions && 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
regular-expressions
GitHub stars
128
Token cost
~1.6k tokens
SKILL.md length
716 words
Files
1
Skills in repo
75
Repo updated
First seen
Licence
Apache-2.0

At a glance

Create and manage named regular-expression documents and bind them to attribute validation rules.

  • Adding an email
  • SKILL.md covers When to Use This Skill, What a Mendix regular…, Writing the pattern and Go cannot check every legal…, plus 5 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md
  • Identifier pattern

What it does

Regular Expressions is an agent skill from mendixlabs/mxcli. Create and manage named regular-expression documents and bind them to attribute validation rules. Use when adding an email, phone or identifier pattern, changing a shared pattern, or working out why a regex cannot attach directly to an attribute.

Its SKILL.md is about 1.6k 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

  • Adding an email
  • Identifier pattern
  • Changing a shared pattern
  • Working out why a regex cannot attach directly to an attribute

Example prompts

  • “/regular-expressions”

What it can do on your machine

Read from SKILL.md and the folder at commit a924d11. 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

Regular Expressions loads about 1.6k tokens when it runs. Until then it costs about 67 tokens; SKILL.md has 716 words of instructions outside code blocks.

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

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 a924d11, republished under its Apache-2.0 licence (© mendixlabs). 716 words, ~1,644 tokens.

Download SKILL.mdSave it as .claude/skills/regular-expressions/SKILL.md (or your agent's skills folder).
name
regular-expressions
description
Create and manage named regular-expression documents and bind them to attribute validation rules. Use when adding an email, phone or identifier pattern, changing a shared pattern, or working out why a regex cannot attach directly to an attribute.

Regular Expressions

When to Use This Skill

Use this skill when the user wants to:

  • Add a named validation pattern (email, phone, identifier, postcode)
  • See or change the regexes a project already has
  • Understand why a regex cannot be attached to an attribute from MDL

What a Mendix regular expression is

A document, not a string on a rule. An attribute validation rule stores a reference to it by qualified name, so one pattern is shared by every attribute that validates against it. That is why it gets a create statement of its own.

sql
mdl 1;
list regular expressions;
list regular expressions in Val;
describe regular expression Val.EmailAddress;   -- re-executable MDL

/** A, not too restrictive, email address regular expression */
create regular expression Val.EmailAddress (
  Expression: '\w+((-|\+|\.)\w+)*@\w+([\.-]?\w+)*(\.\w{2,})+'
);

drop regular expression Val.EmailAddress;
PropertyMeaningDefault
Expressionthe pattern — required—
Documentationfree textnone
ExportLevelHidden or API (Public is a deprecated spelling of API, MDL-DEPR161)Hidden

Writing the pattern

The pattern is an ordinary MDL string:

  • Backslashes are NOT escape characters. Write \d, \w, \. exactly as Mendix should see them — do not double them.
  • A single quote is doubled, like any MDL string: '^it''s$'.
  • Commas, braces and pipes inside the pattern are fine — the whole thing is one quoted string.

Mendix validates with .NET's regex engine, which accepts constructs Go's RE2 does not — lookaround and backreferences most commonly. The Mendix Email Connector itself ships .*(?<!/)$.

mxcli stores such a pattern unchanged and describe adds:

-- note: uses .NET regex syntax that Go cannot compile (e.g. lookaround); not verifiable here

That is a note, not an error. Do not "fix" a pattern because mxcli could not compile it.

Binding a regex to an attribute

The pattern is a document; the binding is a validation rule on the entity:

sql
mdl 1;
create regular expression Val.EmailAddress (
  Expression: '^[^@\s]+@[^@\s]+\.[^@\s]+$'
);

create validation rule for Val.Person.Email
  regex Val.EmailAddress
  error message 'Enter a valid email address';

Create the pattern first. The rule stores a reference by qualified name, so a name that does not resolve is refused up front — otherwise the build reports CE0135 "No regular expression specified" and the attribute is unconstrained.

Ranges use the same statement. Bounds are inclusive and either may be omitted; Mendix has no strict < or >, so there is no exclusive form:

sql
mdl 1;
create validation rule for Val.Booking.Guests range from 1 to 100 error message '…';
create validation rule for Val.Product.Price  range from 0        error message '…';
create validation rule for Val.Order.Discount range to 100        error message '…';

Re-running a rule replaces the one of the same type on that attribute and leaves the others alone, so an attribute can carry a Required rule and a RegEx rule at once.

Required and Unique are not written with this statement — they are attribute constraints:

sql
mdl 1;
create entity Val.Person (
  Email: String(200) not null error message 'Email is required',
  Code:  String(20)  unique error message 'Code must be unique'
);

alter entity Val.Person modify attribute Email: String(200)
  not null error message 'Email is required';
What still cannot be authored

A range bounded by another attribute rather than a literal cannot be written in MDL, but it does survive a rewrite untouched — describe entity marks it with a comment rather than rendering it as something it isn't. Add or change one in Studio Pro.

MaxLength and EqualsTo rules cannot be represented at all. mxcli refuses to rewrite an entity carrying one (alter entity, create or modify entity) rather than silently downgrading it to a Required rule, which is what it used to do — the constraint would vanish and the build would still pass.

Show full SKILL.md (263 more words)Show less

Finding out who uses one

sql
list references to Val.EmailAddress;

lists the entities whose validation rules use that pattern — worth checking before you change a shared regex.

sql
select QualifiedName, Expression from CATALOG.REGULAR_EXPRESSIONS;

Common Mistakes

MistakeSymptomFix
Doubling backslashesThe stored pattern has \\d and matches nothingWrite \d once
Single quote left undoubledParse error'^it''s$'
Omitting Expressionhas no ExpressionIt is required
Treating the Go note as an errorA valid .NET pattern gets rewrittenThe note means "not verified", not "invalid"
Inline pattern in a rule (regex '^a+$')Parse errorThe rule takes a document name: regex Val.MyPattern
Rule created before the pattern"regular expression not found"create regular expression first
Expecting range > 0Parse errorMendix has only inclusive bounds: range from 0
  • mxcli syntax regular-expression — full syntax reference
  • mxcli syntax validation-rule — binding a pattern or a range to an attribute
  • mdl-entities — attributes and validation

Regular expressions (LIST/DESCRIBE/CREATE [OR MODIFY]/DROP REGULAR EXPRESSION)

named patterns that attribute validation rules reference by qualified name, which is why they are documents. modelsdk/gen is wrong about the pattern's key — it binds RegEx where every Studio Pro document stores Expression (generated/metamodel agrees with the documents), so both engines share one raw-BSON codec in mdl/regularexpressions; a reader keyed on gen's name returns an empty pattern for every real document. Pinned against five Studio Pro-authored documents (Email Connector 6.4.2, Community Commons 11.5.1). Mendix validates with .NET's engine, so a pattern Go's RE2 cannot compile (lookaround — the Email Connector ships one) is stored unchanged and reported "not verifiable", never "invalid". A validate edge into CATALOG.REFS makes list references to <regex> list the entities using it

© 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/regular-expressions of mendixlabs/mxcli.

Open the folder on GitHubat commit a924d11

Compare with similar skills

Regular Expressions 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.

Regular Expressions compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Regular Expressions this skillmendixlabs/mxcli128—~1.6kAutomated safety check: PassApache-2.0
Git Branch Namingmakeplane/plane60k—~594Automated safety check: PassAGPL-3.0
Naming Conventionsthedaviddias/Front-End-Checklist74k—~481Automated safety check: PassMIT
Button Namethedaviddias/Front-End-Checklist74k—~488Automated safety check: PassMIT
Select Namethedaviddias/Front-End-Checklist74k—~451Automated safety check: PassMIT
Naminggridaco/grida2.7k—~2.5kAutomated safety check: PassApache-2.0

Similar skills

  • Git Branch Naming

    makeplane/plane

    Names a new Git branch with a type prefix, the lowercased work item ID and a short kebab-case description, so the ID can be extracted later from the branch name.

    60k GitHub stars~594 tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Naming Conventions

    thedaviddias/Front-End-Checklist

    A skill your agent uses when reviewing stylesheets, component styles, and responsive behavior related to Use consistent CSS naming conventions.

    74k GitHub stars~481 tokensUpdated yesterday
    Frontend & DesignAuto-check passed
  • Button Name

    thedaviddias/Front-End-Checklist

    A skill your agent uses when reviewing rendered HTML, interactive components, or design-system patterns related to Provide accessible names for buttons.

    74k GitHub stars~488 tokensUpdated yesterday
    Frontend & DesignAuto-check passed
  • Select Name

    thedaviddias/Front-End-Checklist

    A skill your agent uses when reviewing rendered HTML, interactive components, or design-system patterns related to Provide accessible names for select elements.

    74k GitHub stars~451 tokensUpdated yesterday
    Frontend & DesignAuto-check passed
  • Naming

    gridaco/grida

    How to think about names in the Grida repo — not conventions, but what a name commits you to, reveals about the system, and costs to change.

    2.7k GitHub stars~2.5k tokensUpdated yesterday
    Auto-check passed
  • Speculative Naming

    sgl-project/sglang

    Naming conventions for SGLang speculative decoding identifiers.

    37k GitHub starsUsed in 2 repos~1.6k tokens
    DevOps & CloudAuto-check passed

More from mendixlabs/mxcli

All 75 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…

    128 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.

    128 GitHub stars~3k 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.

    128 GitHub starsUsed in 1 repo~2.2k tokens
    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.

    128 GitHub stars~1.4k tokensUpdated today
    Auto-check passed
  • Mock REST APIs

    mendixlabs/mxcli

    Stand up an HTTP endpoint you control instead of a live third-party API, and point the Mendix app at it — Prism from an OpenAPI contract, a constant swap, or a forward proxy.

    128 GitHub starsUsed in 1 repo~2.5k tokens
    Auto-check passed
  • REST Client

    mendixlabs/mxcli

    Call external REST APIs from Mendix — the three approaches (inline REST CALL, consumed REST client document, generated from OpenAPI) and how to choose.

    128 GitHub starsUsed in 1 repo~3.9k tokens
    Auto-check passed

Questions about Regular Expressions

What does Regular Expressions do?

Create and manage named regular-expression documents and bind them to attribute validation rules. Regular Expressions is an agent skill from mendixlabs/mxcli. Create and manage named regular-expression documents and bind them to attribute validation rules.

When should I use Regular Expressions?

Regular Expressions fits situations like: adding an email; identifier pattern; changing a shared pattern; working out why a regex cannot attach directly to an attribute.

How do I install Regular Expressions in Claude Code?

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

How do I install Regular Expressions in Codex?

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

Can I use Regular Expressions 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 regular-expressions -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/regular-expressions, .gemini/skills/regular-expressions, .github/skills/regular-expressions and .opencode/skills/regular-expressions in your project.

What does Regular Expressions need to run?

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

Does Regular Expressions 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 Regular Expressions 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 Regular Expressions use?

Regular Expressions 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 Regular Expressions use?

About 1.6k tokens (SKILL.md is roughly 6.6k 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 Regular Expressions?

Skills that share tags, products or a category with Regular Expressions: Git Branch Naming (makeplane/plane, 60k stars), Naming Conventions (thedaviddias/Front-End-Checklist, 74k stars), Button Name (thedaviddias/Front-End-Checklist, 74k stars) and Select Name (thedaviddias/Front-End-Checklist, 74k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Regular Expressions?

mendixlabs (a GitHub organization) maintains it in mendixlabs/mxcli, which has 128 GitHub stars. The repository holds 75 skills in this directory. The repository was last updated on October 7, 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.