Command Palette

Search for a command to run...

UnylyUnyly
Back to skills

magento-admin

FreeNo executable scriptsNot checked

Complete Magento 2 store administration via SSH key auth, REST API, GraphQL, and direct DB access. For server owners on their own infrastructure. SSH key auth…

nj070574-gifby nj070574-gif1,308 installs in other catalogs

About this skill

magento-admin v5.7 — Complete Magento 2 Administration

Overview

This skill gives an OpenClaw agent the ability to fully administer a Magento 2 store via SSH, REST API, GraphQL, and direct database access. It is designed for use by the server owner on their own infrastructure.

All credentials are supplied by you in your private config file and are used only to connect to your own server. Nothing is sent to third parties.

Security Notes

  • SSH key auth recommended over password auth where possible
  • All credentials are stored only in your private config, never in the skill itself
  • The skill connects only to the server you configure
  • Review all commands before enabling autonomous execution

Configuration

Set the following variables in the env block of your private openclaw.json (never in the skill itself, never in chat). Every command below uses them as placeholders that the agent substitutes at run time:

Variable Description Example
MAGENTO_HOST Server IP or hostname 10.0.1.50
MAGENTO_SSH_USER SSH username deploy
MAGENTO_SSH_KEY Path to SSH private key ~/.ssh/magento_deploy
MAGENTO_WEB_ROOT Magento path /var/www/html/magento2
MAGENTO_PHP PHP binary /usr/bin/php8.4
MAGENTO_WEB_USER Web server user www-data
MAGENTO_DB_NAME Database name magento_db
MAGENTO_DB_USER DB username magento_user
MAGENTO_DB_PASS DB password (your db password)
MAGENTO_BASE_URL Store URL https://store.example.com
MAGENTO_ADMIN_PATH Admin path admin
MAGENTO_ADMIN_USER Admin username admin
MAGENTO_ADMIN_PASS Admin password (your admin password)
MAGENTO_OS_URL OpenSearch URL http://127.0.0.1:9200
COMPOSER_PATH Composer binary /usr/local/bin/composer

Recommended: SSH Key Authentication

For better security, set up SSH key auth instead of password auth:



ssh -i ~/.ssh/magento_deploy -o StrictHostKeyChecking=yes MAGENTO_SSH_USER@MAGENTO_HOST "COMMAND"

Least-Privilege Recommendations

  • DB user: Create a dedicated MariaDB/MySQL user with SELECT, INSERT, UPDATE, DELETE on the Magento DB only — not GRANT or CREATE.
  • SSH user: Restrict passwordless sudo to specific binaries if possible (e.g. php, systemctl restart, redis-cli) rather than ALL.
  • REST API: MAGENTO_ADMIN_PASS is used only to obtain a short-lived session token via the Magento REST API. Consider creating a dedicated admin user with only the roles your agent needs.
  • SSH key: Use a dedicated key pair for the agent, not your personal key.

Input Handling & Injection Safety

The MAGENTO_* connection variables are trusted config. Everything else that goes into a command — order IDs, emails, SKUs, quantities, prices, usernames, module names, config paths, search terms, coupon codes, file paths — is an operand that may originate from a user request, and MUST be validated before it is substituted into any shell command, SQL statement, or URL.

Before substituting a value, check it against the expected shape and refuse (do not run the command) if it does not match:

Operand Allowed pattern Notes
Order increment ID / entity ID ^[0-9]+$ Numeric only
Email ^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}$ Single address
SKU ^[A-Za-z0-9._-]+$ No quotes/spaces/;
Qty / price ^[0-9]+(\.[0-9]+)?$ Numeric
Admin/customer username ^[A-Za-z0-9._@-]+$
Module name ^[A-Za-z0-9]+_[A-Za-z0-9]+$ Vendor_Module
Config path ^[a-z0-9]+(_[a-z0-9]+)*(/[a-z0-9]+(_[a-z0-9]+)*)+$ section/group/field
Index/cache type ID must be one of the documented IDs listed in this skill reject anything else
Composer package ^[A-Za-z0-9._-]+/[A-Za-z0-9._-]+(:\^?[0-9.]+)?$
Backup file path ^/opt/magento_backups/[A-Za-z0-9._-]+\.sql\.gz$ restore only from the backups dir

Rules:

  • Never interpolate raw free-form text into an SQL WHERE clause. The order, customer, and config lookups below take a validated ID/email/path only.
  • The generic "Run a specific SQL query" and "config:set" commands are owner-operated: run them only with an explicit, reviewed value from the store owner, never with text a chat user supplied verbatim.
  • If a required operand fails validation, stop and tell the user why rather than attempting to sanitise it yourself.

TLS / CA Certificate

REST and GraphQL calls use HTTPS. Handle the certificate like this:

  • If MAGENTO_CA_CERT is set, add --cacert "$MAGENTO_CA_CERT" to the curl call (needed for an internal/self-signed CA). The command examples below show this form.
  • If MAGENTO_CA_CERT is not set, omit the --cacert option entirely and rely on the system CA store (correct for a public cert, e.g. Let's Encrypt).
  • Never use curl -k / --insecure — that disables verification and is a genuine MITM risk, no
Full SKILL.md on ClawHub

Install magento-admin in Claude Code & Claude Desktop

Sign up to install this skill

Create a free account to reveal the install command and save the skill to your library.

  • Reveal the one-line install command
  • Save skills to your synced library
  • Get notified when skills update
Sign up freeI already have an account

Allowed tools

Tools this skill is permitted to call.

No restriction — this skill can use any tool.

FAQ

What does the magento-admin skill do?

Complete Magento 2 store administration via SSH key auth, REST API, GraphQL, and direct DB access. For server owners on their own infrastructure. SSH key auth and passwordless sudo required.

How do I install the magento-admin skill?

Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.

Does the magento-admin skill run scripts?

No, this skill is instructions only (SKILL.md) with no executable scripts.

Related skills

Compare magento-admin with