From streamnative-agent-skills
Configure and authenticate the `snctl` CLI for StreamNative Cloud. Use when the user asks to install snctl, log in, switch orgs/contexts, set up service-account credentials, export/activate tokens, or list available API resources. Does NOT cover creating clusters, identity resources, BYOC substrate, or data-plane operations.
How this skill is triggered — by the user, by Claude, or both
Slash command
/streamnative-agent-skills:cloud-coreThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
- The user asks to install, upgrade, or verify `snctl`.
snctl.snctl auth login, auth whoami, auth logout, or service-account activation/export.snctl context.snctl get / snctl describe output.snctl logs.Prefer StreamNative Cloud remote MCP when agent runtime exposes it; see references/remote-mcp.md. Use sncloud_context_*, sncloud_resource_catalog, sncloud_resource_schema, and sncloud_logs for remote context/discovery/log workflows. Use snctl fallback for local install/config/auth/token and service-account key export/activation.
If remote MCP is available, start with sncloud_context_whoami; use sncloud_context_available_clusters / sncloud_context_use_cluster for cluster-scoped work. After a successful cluster switch, output MCP_TOOLS_REFRESH_REQUIRED instance=<instanceName> cluster=<clusterName> and stop the current turn so the runner/runtime can refresh MCP tools before data-plane calls. If using snctl, run these commands and handle failures:
snctl version --client — if "command not found", open references/install.md and guide the user through install.snctl config get — if config is missing, guide the user through snctl config init.snctl auth whoami — if unauthenticated, open references/auth-flows.md and pick the right login path (user vs service account).Remote MCP server is public preview and disabled by default. Users must manually enable org-level MCP and each cluster-level MCP endpoint in StreamNative Cloud UI; newly created clusters keep cluster-level MCP disabled until UI enablement. Remote MCP org-level sessions expose StreamNative Cloud context, catalog/schema, domain control-plane, and feature-gated cluster tools; cluster tools require a fixed cluster endpoint or successful sncloud_context_use_cluster, which only works when cluster-level MCP is enabled for the target cluster. After sncloud_context_use_cluster succeeds, emit the exact sentinel MCP_TOOLS_REFRESH_REQUIRED instance=<instanceName> cluster=<clusterName> because selected cluster context changes the session-scoped tool surface; the runner/runtime must refresh/reconnect MCP tools and resume before data-plane tools are visible. snctl is a kubectl-flavored CLI that talks to StreamNative Cloud's control plane. Every action happens in the context of an organization (namespace-style scope) plus optionally a service context (a selected Pulsar instance/cluster for data-plane operations). Auth is OIDC-based for users; service-account auth uses a downloaded JSON key, exchanged for a short-lived token on each call. Output formats follow kubectl conventions (-o yaml|json|name|jsonpath=...).
# Install (macOS/Linux)
curl -fsSL https://downloads.streamnative.cloud/snctl/install.sh | sh
# Initialize config
snctl config init
# Log in as a user (opens browser)
snctl auth login
# Verify
snctl auth whoami
snctl config get
snctl config set --organization <org-name>
snctl config get
# Export a key for an existing service account
snctl auth export-service-account <sa-name> --organization <org> -O <org> --key-file ./sa.json
# Activate the key on the machine running the agent
snctl auth activate-service-account --key-file ./sa.json
# Verify
snctl auth whoami
Remote MCP route: sncloud_context_available_clusters → sncloud_context_use_cluster; after a successful sncloud_context_use_cluster, output exactly MCP_TOOLS_REFRESH_REQUIRED instance=<instanceName> cluster=<clusterName> and stop before invoking newly exposed cluster tools; reset with sncloud_context_reset when switching.
snctl route:
# List available contexts (instance/cluster pairs visible to the current identity)
snctl context
# Use a specific cluster
snctl context use <cluster-name>
snctl context current
Remote MCP route: use sncloud_resource_catalog for domain/kind inventory, then sncloud_resource_schema for manifest summaries/examples/runtime schema.
snctl route:
snctl api-resources
snctl api-resources -o wide
Remote MCP route: select cluster if needed, then use sncloud_logs.
snctl route:
snctl logs <pod-or-resource> --organization <org>
snctl auth get-token
-o yaml|json|name|jsonpath=... when the agent needs to parse output — never regex a plain-text table.--organization <org> explicitly for org-scoped scripted flows; do not rely on current context. Avoid kubectl-style -n in snctl smoke/docs because current snctl builds may reject it for Cloud resource commands.snctl delete, snctl revoke), state the exact resource to the user and require explicit confirmation before running.-o flag details and jsonpath recipes.dry_run=false apply/delete failures; read current resource state first, then retry only if safe/idempotent.sncloud_resources_* names.sncloud_context_use_cluster requires cluster-level MCP enabled on the target cluster; new clusters may not enable it automatically. After a successful cluster switch, emit MCP_TOOLS_REFRESH_REQUIRED instance=<instanceName> cluster=<clusterName> and wait for runner/runtime refresh because the session-scoped tool surface has changed. ToolSearch is not a refresh substitute. May need to refresh the tool page until cluster-level tools show up.snctl auth login opens a browser; on headless machines use --headless for device-code flow.~/.snctl/.snctl context use affects the local config only. For one-off calls prefer the --as-service-account / --use-service-account flags.snctl config set --organization changes the default org for all subsequent commands; verify with snctl config get before running destructive operations.snctl auth get-token are short-lived (~1h). Re-run on expiry; do not embed in long-lived scripts.Searches MemPalace before answering questions about past work, people, projects, or prior decisions. Returns verbatim stored content instead of guessing from model memory.
Guides Payload CMS config (payload.config.ts), collections, fields, hooks, access control, APIs. Debugs validation errors, security, relationships, queries, transactions, hook behavior.
Implements vector databases with Pinecone, Weaviate, Qdrant, Milvus, pgvector for semantic search, RAG, recommendations, and similarity systems. Optimizes embeddings, indexing, and hybrid search.
npx claudepluginhub streamnative/streamnative-agent-skills --plugin streamnative-agent-skills