Setup
Verify (check) or set up (apply) the sql-server read-only MCP server: Node.js, config schema, server copy, and per-environment registration.
от melodic-software★ 34 звезды на GitHub
Установить Setup в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Setup
What this sets up
A registration is one stdio server that serves, from one config file, the allow-list of
environments its repeated --environment arguments name (design:
ADR 0086).
The plugin ships no server in its own .mcp.json; this skill installs a copy of the server into
${CLAUDE_PLUGIN_DATA}/server (why that directory: "Upstream record" below), and registers it
under a name you choose.
The read-only database principal you create is the guarantee. A registration on a login that can
write is not read-only, whatever the reject list does. This skill creates no principal and no
config file; it checks the ones you made. Config shape and examples:
${CLAUDE_PLUGIN_ROOT}/README.md "Config"; Azure SQL Database:
${CLAUDE_PLUGIN_ROOT}/reference/azure-sql-database.md.
Arguments: the action (check when absent), --config <path> (required; ask for it once when
missing), and --environment <name> to check only the named environment of the config. Every action is safe to
rerun. When the user asks for project scope, refuse it in your first reply, before any step, with
the reason apply step 3 gives, so a run that stops early still answers it.
check (read-only)
Run, from the project directory:
node "${CLAUDE_SKILL_DIR}/scripts/check-setup.mjs" --config <path> --data-dir "${CLAUDE_PLUGIN_DATA}" [--environment <name>]Report every row it prints in a PASS/FAIL/INFO table, with one remediation line per FAIL. Done when the table holds every row. Exit 1 means a FAIL row; exit 2 is a usage error to fix and rerun.
Remediations:
nodeFAIL, install Node.js at the version the row names.configFAIL, edit the file at the place the message names (a literal password becomes{ "env": "<VARIABLE>" }; a config inside the project directory moves outside it).server copyorserver dependenciesFAIL, runapply. Anauthrow that says a variable is not set is INFO: set it in the environment Claude Code starts in, never in the config or the repository.Registrations. For each environment, run
claude mcp get sql-<environment>(or the name the user chose) and report INFO with what it shows, or "not registered". Done when each environment has a registration row.Grants. For each registered environment whose
querytool is in your tool list, call it once per database in the environment's list withSELECT permission_name FROM fn_my_permissions(NULL, 'DATABASE')and once withSELECT s.name, p.permission_name FROM sys.schemas AS s CROSS APPLY fn_my_permissions(s.name, 'SCHEMA') AS p. Report FAIL for a permission that starts withINSERT,UPDATE,DELETE,EXECUTE,ALTERorCREATE, or isCONTROL,TAKE OWNERSHIPorIMPERSONATE, with the remediation "remove that grant from the principal"; list the rest as INFO. With no such tool, report INFO "grants not checked: register the environment and rerun check in a fresh session". This covers grants at database and schema scope in the listed databases only: a grant on a single object, or in another database on the server, does not show. Done when each registered environment has a grants row.
Modify nothing in check.
apply
Run
check. Stop on anodeorconfigFAIL and report it:applycannot fix either.Install the server copy. Run:
node "${CLAUDE_SKILL_DIR}/scripts/install-server.mjs" --data-dir "${CLAUDE_PLUGIN_DATA}"It copies the server into
${CLAUDE_PLUGIN_DATA}/serverand runsnpm cithere, or printsunchanged:when that copy already holds this version and its dependencies. Done when it printsinstalled:orunchanged:and exits 0; on exit 1, report its error and stop.Register. Rerun
checkand show eachregister <environment>row's command. Each one registerssql-<environment>at user scope; the name is yours to change, and so is--scope local. Refuse--scope project: a registration lives only where the agent cannot edit it, and the repository is not such a place. Credentials are registered by reference (--env 'NAME=${NAME}'), never by value; theclaude mcp getreadback below and the grants call incheckstep 4 are what confirm a credential arrived. The commands are for a POSIX shell. Skip an environment whose registration row already shows the same command and arguments, and report it as already in place; when that row shows different ones, show both and leave the change to the user. Run each other command only after the user confirms it (ADR 0086 section 3 asks for that confirmation, soapplynever registers unattended), then runclaude mcp get <name>and report what it shows. Done when every confirmed registration has aclaude mcp getreadback.
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
- scripts/check-setup.mjs
- scripts/install-server.mjs
FAQ
Что делает скилл Setup?
Verify (check) or set up (apply) the sql-server read-only MCP server: Node.js, config schema, server copy, and per-environment registration.
Как установить скилл Setup?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл Setup запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
doc-coauthoring
AnthropicGuide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision…
academy-guide
AnthropicStop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials…
internal-comms
AnthropicA set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill…
skill-development
AnthropicThis skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill…