Agent skill

Cheatsheet Variables

by mendixlabs in mendixlabs/mxcli

One-page reference for declaring and assigning variables in MDL microflows — every type, with the exact syntax.

Apache-2.0Auto-check passed

Install Cheatsheet Variables

skills CLI
$ npx skills add mendixlabs/mxcli --skill cheatsheet-variables -a claude-code

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

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

At a glance

One-page reference for declaring and assigning variables in MDL microflows — every type, with the exact syntax.

  • Works in 5 steps: Primitives… → Objects (entities): Never declare an… → Lists: Never declare a list — same… → …
  • Writing a declare and unsure of the spelling
  • SKILL.md covers Declaration Syntax, Key Rules, Common Mistakes and Special Values, plus 2 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Cheatsheet Variables is an agent skill from mendixlabs/mxcli. One-page reference for declaring and assigning variables in MDL microflows — every type, with the exact syntax. Use when writing a declare and unsure of the spelling, or when a declaration error needs fixing fast.

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

  • Writing a declare and unsure of the spelling
  • A declaration error needs fixing fast

Example prompts

  • “/cheatsheet-variables”

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. Primitives (String/Integer/Long/Decimal/Boolean/DateTime/Enumeration): Use declare $var type = value; — these are the only types declare…
  2. Objects (entities): Never declare an object. Mendix forbids the Create Variable activity from holding an object (CE0053/CE0038, plus…
  3. Lists: Never declare a list — same Create Variable restriction (CE0053/CE0038, flagged as MDL040). Get the list from a microflow…
  4. SET requires DECLARE: Always declare primitive variables before using SET.
  5. Parameters are pre-declared: Microflow parameters don't need DECLARE (and a parameter may be an object/list type — that restriction is…

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 mdl).

    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

Cheatsheet Variables loads about 1.2k tokens when it runs. Until then it costs about 59 tokens; SKILL.md has 319 words of instructions outside code blocks.

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

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). 319 words, ~1,217 tokens.

Download SKILL.mdSave it as .claude/skills/cheatsheet-variables/SKILL.md (or your agent's skills folder).
name
cheatsheet-variables
description
One-page reference for declaring and assigning variables in MDL microflows — every type, with the exact syntax. Use when writing a `declare` and unsure of the spelling, or when a declaration error needs fixing fast.

MDL Variable Cheatsheet

Quick reference for variable declarations in MDL microflows.

Declaration Syntax

TypeSyntaxExample
Stringdeclare $name string = 'value';declare $message string = '';
Integerdeclare $name integer = 0;declare $count integer = 0;
Booleandeclare $name boolean = true;declare $IsValid boolean = true;
Decimaldeclare $name decimal = 0.0;declare $Amount decimal = 0;
DateTimedeclare $name datetime = [%CurrentDateTime%];declare $Now datetime = [%CurrentDateTime%];
Enumerationdeclare $name Enumeration(Module.Enum) = Module.Enum.Value;declare $s Enumeration(Sales.Status) = Sales.Status.Open;
Object (Entity)Do not declare — use a parameter, retrieve, create, or loop iterator$Customer = create Sales.Customer (Name = $n);
ListDo not declare — use a parameter, retrieve, or create list$Orders = create list of Sales.Order;

Key Rules

  1. Primitives (String/Integer/Long/Decimal/Boolean/DateTime/Enumeration): Use declare $var type = value; — these are the only types declare (a Create Variable activity) accepts.
  2. Objects (entities): Never declare an object. Mendix forbids the Create Variable activity from holding an object (CE0053/CE0038, plus CE7247 on a later set; flagged as MDL043 by mxcli check) — bare or initialized. Get the object from a microflow parameter, a retrieve … first, $var = create Module.Entity(...), or a loop iterator. There is no "empty object variable" and no aliasing activity — reuse the variable you already have.
  3. Lists: Never declare a list — same Create Variable restriction (CE0053/CE0038, flagged as MDL040). Get the list from a microflow parameter, a retrieve, or $var = create list of Module.Entity;
  4. SET requires DECLARE: Always declare primitive variables before using SET.
  5. Parameters are pre-declared: Microflow parameters don't need DECLARE (and a parameter may be an object/list type — that restriction is only on declare).

Common Mistakes

Object (Entity) "Declaration" — there is no such thing
mdl
-- WRONG: declaring an object — Mendix rejects it (CE0053/CE0038, MDL043)
declare $Product Module.Product;            -- bare form is invalid
declare $Product Module.Product = $In;      -- aliasing a parameter is invalid
declare $Product as Module.Product;         -- the AS keyword is also a parse error

-- CORRECT: get the object from a source that produces one
$Product = create Module.Product (Name = $n);     -- create
retrieve $Product from Module.Product where Code = $c first;  -- retrieve
-- or accept it as a parameter, or use a loop iterator: loop $Product in $Products ...
SET Without DECLARE
mdl
-- WRONG: Variable not declared
if $value > 10 then
  set $message = 'High';  -- ERROR!
end if;

-- CORRECT: Declare first
declare $message string = '';
if $value > 10 then
  set $message = 'High';
end if;
Lists (never declared)
mdl
-- WRONG: declaring a list — Mendix rejects it (CE0053/CE0038, MDL040)
declare $Items list of Module.Item = empty;

-- CORRECT: build the list without declare
$Items = create list of Module.Item;          -- empty list to accumulate into
retrieve $Items from Module.Item where ...;    -- or populate from the database
-- or accept it as a parameter: create microflow M.Process ($Items: list of Module.Item) ...

Special Values

ValueUsage
emptyNull/empty value for any type
[%CurrentDateTime%]Current date and time
[%CurrentUser%]Currently logged in user object
true / falseBoolean literals

Parameter vs Variable

mdl
mdl 1;
create microflow Module.Example (
  $Input: string,              -- Parameter: auto-declared
  $entity: Module.Customer     -- Parameter: auto-declared
)
returns boolean
begin
  -- Parameters $Input and $Entity are already available

  declare $Result boolean = true;  -- Local primitive: must declare
  -- Need a local object? Don't declare it — create/retrieve it:
  $Order = create Module.Order (Reference = $Input);  -- or retrieve … first

  return $Result;
end;

Variable Scope

  • Parameters: Available throughout the microflow
  • DECLARE variables: Available from declaration point forward
  • Loop variables: Only available inside the loop body
mdl
loop $item in $ItemList
begin
  -- $Item is available here (derived from list type)
  set $count = $count + 1;
end loop;
-- $Item is NOT available here

© 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/cheatsheet-variables of mendixlabs/mxcli.

Open the folder on GitHubat commit a924d11

Compare with similar skills

Cheatsheet Variables 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.

Cheatsheet Variables compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Cheatsheet Variables this skillmendixlabs/mxcli128—~1.2kAutomated safety check: PassApache-2.0
Declarative Agentsgithub/awesome-copilot40k1 repos~1.2kAutomated safety check: PassMIT
GitHub Issue Bulk Assignercodewhale-hq/Codewhale41k—~953Automated safety check: PassMIT
MCP Create Declarative Agentgithub/awesome-copilot40k2 repos~2kAutomated safety check: NotesMIT
Imperative To Declarative Fletflet-dev/flet17k—~829Automated safety check: PassApache-2.0
Testing API For Mass Assignment Vulnerabilitymukul975/Anthropic-Cybersecurity-Skills34k—~4kAutomated safety check: PassApache-2.0

Similar skills

  • Declarative Agents

    github/awesome-copilot

    Official

    Complete development kit for Microsoft 365 Copilot declarative agents with three comprehensive workflows (basic, advanced, validation), TypeSpec support, and Microsoft 365 Agents Toolkit integration

    40k GitHub starsUsed in 1 repo~1.2k tokens
    Documents & OfficeAuto-check passed
  • GitHub Issue Bulk Assigner

    codewhale-hq/Codewhale

    Moves a list of GitHub issues into a milestone or assigns them to owners with the gh CLI, checking each one before and after the change.

    41k GitHub stars~953 tokensUpdated today
    DevelopmentAuto-check passed
  • MCP Create Declarative Agent

    github/awesome-copilot

    Official

    Skill converted from mcp-create-declarative-agent.prompt.md. An agent skill from github/awesome-copilot.

    40k GitHub starsUsed in 2 repos~2k tokens
    Agent WorkflowsAuto-check: notes
  • Convert an imperative Flet Python app in which controls are mutated and then page.update is called to declarative style using flet.component, flet.observable and state hooks.

    17k GitHub stars~829 tokensUpdated today
    Auto-check passed
  • Testing API For Mass Assignment Vulnerability

    mukul975/Anthropic-Cybersecurity-Skills

    Tests APIs for mass assignment (auto-binding), OWASP API3:2023, by identifying writable endpoints, adding undocumented fields to request bodies (role, isAdmin, price, balance), and checking whether…

    34k GitHub stars~4k tokensUpdated 1 mo ago
    SecurityAuto-check passed
  • Add, audit, or update @nubjs/types declarations for Nub runtime APIs.

    4.4k GitHub stars~2.4k tokensUpdated today
    Auto-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 Cheatsheet Variables

What does Cheatsheet Variables do?

One-page reference for declaring and assigning variables in MDL microflows — every type, with the exact syntax. Cheatsheet Variables is an agent skill from mendixlabs/mxcli. One-page reference for declaring and assigning variables in MDL microflows — every type, with the exact syntax.

When should I use Cheatsheet Variables?

Cheatsheet Variables fits situations like: writing a declare and unsure of the spelling; A declaration error needs fixing fast.

How do I install Cheatsheet Variables in Claude Code?

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

How do I install Cheatsheet Variables in Codex?

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

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

What does Cheatsheet Variables need to run?

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

Does Cheatsheet Variables 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 Cheatsheet Variables 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 Cheatsheet Variables use?

Cheatsheet Variables 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 Cheatsheet Variables use?

About 1.2k tokens (SKILL.md is roughly 4.9k 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 Cheatsheet Variables?

Skills that share tags, products or a category with Cheatsheet Variables: Declarative Agents (github/awesome-copilot, 40k stars), GitHub Issue Bulk Assigner (codewhale-hq/Codewhale, 41k stars), MCP Create Declarative Agent (github/awesome-copilot, 40k stars) and Imperative To Declarative Flet (flet-dev/flet, 17k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Cheatsheet Variables?

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.