From ops-suite
Execute read-only queries against databases. Connects to the target environment's database, runs SQL queries, and formats results. Use when asked about "query database", "db query", "SQL", "check data", "database lookup", "count records", "find rows".
npx claudepluginhub weorbitant/workbench-dev --plugin ops-suiteThis skill is limited to using the following tools:
Check if `/tmp/ops-suite-session/config.json` exists:
Provides UI/UX resources: 50+ styles, color palettes, font pairings, guidelines, charts for web/mobile across React, Next.js, Vue, Svelte, Tailwind, React Native, Flutter. Aids planning, building, reviewing interfaces.
Fetches up-to-date documentation from Context7 for libraries and frameworks like React, Next.js, Prisma. Use for setup questions, API references, and code examples.
Guides Payload CMS config (payload.config.ts), collections, fields, hooks, access control, APIs. Debugs validation errors, security, relationships, queries, transactions, hook behavior.
Check if /tmp/ops-suite-session/config.json exists:
config.yaml, parse it, and write to /tmp/ops-suite-session/config.json for other skills to reuse.
If neither exists, tell the user to copy config.example.yaml to config.yaml and fill in their values. Stop here.Extract:
database — determines which adapter to load (postgresql, mysql, mongodb)orchestrator — for port-forward commandsenvironments — connection detailsdeploy.local_ports — local ports for database connectionsAlso read the reference at references/query-examples.md (in this skill's directory) for common query patterns.
Read the adapter file at adapters/{database}.md (in this skill's directory).
If the adapter does not exist, tell the user that the database {database} is not yet supported and stop.
If $ARGUMENTS contains an environment name, use it. Otherwise ask the user.
Check if a port-forward is already active on the expected local port (deploy.local_ports.{env_name}).
If not active:
kubectl --context={env.context} port-forward svc/{env.services.database.name} {deploy.local_ports.{env_name}}:{env.services.database.port} -n {env.services.database.namespace || env.namespaces.infra} &
Retrieve or ask for credentials. Never hardcode credentials.
If $ARGUMENTS contains a natural language description:
If $ARGUMENTS contains raw SQL:
Constraints:
Use the adapter's query execution command.
The script at scripts/query.js (in this skill's directory) can be used as a helper for PostgreSQL.
Present results in a clear, readable format:
Environment: {env_name}
Database: {database_name}
Query: {sql_query}
Rows: {row_count}
Results:
| column_1 | column_2 | column_3 |
|----------|----------|----------|
| value | value | value |
Query time: {duration}ms
If results are too many to display, show the first 20 rows and provide the total count.
If a port-forward was started in this session, provide the cleanup command but do not kill it automatically (the user may want to run more queries).