diff --git a/agent-resources/cli.mdx b/agent-resources/cli.mdx index 6aeb7d366..3e8ea76fb 100644 --- a/agent-resources/cli.mdx +++ b/agent-resources/cli.mdx @@ -9,15 +9,36 @@ You can find the Github Repository [here](https://github.com/upstash/cli). # Installation ```bash -npm i -g @upstash/cli +npm i -g upstash ``` +Or run any command without installing, for example `npx upstash redis list`. + For agents, install the [Upstash Skill](/agent-resources/skills) instead. It bundles Upstash docs with the `upstash` CLI so your agent can implement and debug against your resources without filling up its context window: ```bash npx skills add upstash/skills ``` +# Connect your AI agent + +One command wires Upstash into the coding agents on your machine: + +```bash +npx upstash +``` + +Run with no arguments in a terminal, `upstash` starts `upstash setup`. From an agent or a script, call `upstash setup` explicitly; a bare `upstash` only prints the help there. In a terminal it asks where to install (all projects or just this one) and which agents to set up, with detected agents pre-selected, then shows the plan before changing anything. Claude Code, Codex, Cursor, and Gemini CLI get the Upstash plugin (skills plus the remote MCP server). VS Code, GitHub Copilot CLI, and OpenCode get the remote MCP server in their config plus the Upstash skill. The MCP server signs in with OAuth on first use; setup never writes an API key into an agent's config. + +```bash +upstash setup --claude --cursor -y # pick agents, no prompts +upstash setup --project # this repo instead of your user config +upstash setup --mode mcp # MCP + skill everywhere, no plugins +upstash setup --dry-run # show what would change +``` + +Rerunning `setup` updates what it installed. + # Free Redis without an account If you are an AI agent and need a Redis DB to use or experiment with, you don't need an Upstash account: diff --git a/agent-resources/overview.mdx b/agent-resources/overview.mdx index 437325870..a95a5796f 100644 --- a/agent-resources/overview.mdx +++ b/agent-resources/overview.mdx @@ -6,7 +6,17 @@ description: "Connect your AI coding agent to Upstash." import { AgentGrid } from "/snippets/agent-tools.jsx"; -Upstash ships Skills, a CLI, an MCP server, and llms.txt so your agent can build on and manage Redis, QStash, Workflow, Vector, Search, and Box. Pick your agent to get set up in a minute. +Upstash ships Skills, a CLI, an MCP server, and llms.txt so your agent can build on and manage Redis, QStash, Workflow, Vector, Search, and Box. Set them all up with one command, or pick your agent for step-by-step instructions. + +# Set up with one command + +Run this in your terminal: + +```bash +npx upstash +``` + +It detects Claude Code, Codex, Cursor, Gemini CLI, VS Code, GitHub Copilot CLI, and OpenCode, and lets you pick which to set up. Each one gets the Upstash [MCP server](/agent-resources/mcp) and [skills](/agent-resources/skills): as the Upstash plugin where the agent supports plugins, otherwise written into its config. The MCP server signs in with OAuth on first use. See the [CLI page](/agent-resources/cli#connect-your-ai-agent) for flags. # Pick your agent @@ -31,7 +41,7 @@ Don't see your agent? See the [full list of agents](/agent-resources/clients). -# Quick start +# Set up by hand Install the Upstash skill. It includes the `upstash` CLI reference, so this one step is enough for most workflows: diff --git a/agent-resources/skills.mdx b/agent-resources/skills.mdx index a2ace47b2..dc0b30422 100644 --- a/agent-resources/skills.mdx +++ b/agent-resources/skills.mdx @@ -138,4 +138,4 @@ Add `--global` (`-g`) to make the skills available in every project instead of j # Managing resources -The combined `upstash` skill includes the full `@upstash/cli` command reference, so your agent can create databases, publish QStash messages, query Vector indexes, and more straight from the shell. See the [CLI page](/agent-resources/cli) for credentials and command details. +The combined `upstash` skill includes the full `upstash` CLI command reference, so your agent can create databases, publish QStash messages, query Vector indexes, and more straight from the shell. See the [CLI page](/agent-resources/cli) for credentials and command details. diff --git a/introduction.mdx b/introduction.mdx index 4c6eaa27f..c9941a498 100644 --- a/introduction.mdx +++ b/introduction.mdx @@ -8,10 +8,21 @@ import { Hero, PromptToolIcons, SectionHead, ProductGrid, UtilityGrid, Community
+
+ $ npx upstash +
+ +```bash +npx upstash +``` + +
+ Agent Setup +
- Set up Upstash in my coding agent using the official Upstash instructions, and run the commands yourself instead of asking me to. If you are Claude Code, install the Upstash plugin — it bundles the Upstash skills (https://upstash.com/docs/agent-resources/skills) and the remote MCP server over OAuth — by running `claude plugin marketplace add upstash/skills` then `claude plugin install upstash@upstash`, and tell me to run `/reload-plugins`. If you are OpenAI Codex, install the same plugin with `codex plugin marketplace add upstash/skills` then `codex plugin add upstash@upstash`. For any other agent, install the skills with `npx -y skills add upstash/skills --global`, then add the remote MCP server https://mcp.upstash.com/mcp to your MCP config (it authenticates over OAuth on first use); see https://upstash.com/docs/agent-resources/clients for the exact location. When done, verify the skills and MCP server are installed and tell me whether a restart is needed. + Set up Upstash in my coding agent using the official Upstash instructions, and run the commands yourself instead of asking me to. Run `npx -y upstash setup --yes` with the flag for the agent you are (`--claude`, `--codex`, `--cursor`, `--gemini`, `--vscode`, `--copilot` or `--opencode`). It installs the Upstash plugin where your agent supports plugins, and otherwise adds the remote MCP server https://mcp.upstash.com/mcp plus the Upstash skills (https://upstash.com/docs/agent-resources/skills); the MCP server authenticates over OAuth on first use. If you are not one of those agents, install the skills with `npx -y skills add upstash/skills --global` and add the remote MCP server to your MCP config; see https://upstash.com/docs/agent-resources/clients for the exact location. When done, tell me what was installed and whether I need to restart or reload (in Claude Code, `/reload-plugins`).
diff --git a/llms-full.txt b/llms-full.txt index d76d6baeb..b517af4d2 100644 --- a/llms-full.txt +++ b/llms-full.txt @@ -56,15 +56,36 @@ You can find the Github Repository [here](https://github.com/upstash/cli). # Installation ```bash -npm i -g @upstash/cli +npm i -g upstash ``` +Or run any command without installing, for example `npx upstash redis list`. + For agents, install the [Upstash Skill](/docs/agent-resources/skills) instead. It bundles Upstash docs with the `upstash` CLI so your agent can implement and debug against your resources without filling up its context window: ```bash npx skills add upstash/skills ``` +# Connect your AI agent + +One command wires Upstash into the coding agents on your machine: + +```bash +npx upstash +``` + +Run with no arguments in a terminal, `upstash` starts `upstash setup`. From an agent or a script, call `upstash setup` explicitly; a bare `upstash` only prints the help there. In a terminal it asks where to install (all projects or just this one) and which agents to set up, with detected agents pre-selected, then shows the plan before changing anything. Claude Code, Codex, Cursor, and Gemini CLI get the Upstash plugin (skills plus the remote MCP server). VS Code, GitHub Copilot CLI, and OpenCode get the remote MCP server in their config plus the Upstash skill. The MCP server signs in with OAuth on first use; setup never writes an API key into an agent's config. + +```bash +upstash setup --claude --cursor -y # pick agents, no prompts +upstash setup --project # this repo instead of your user config +upstash setup --mode mcp # MCP + skill everywhere, no plugins +upstash setup --dry-run # show what would change +``` + +Rerunning `setup` updates what it installed. + # Free Redis without an account If you are an AI agent and need a Redis DB to use or experiment with, you don't need an Upstash account: @@ -1332,7 +1353,17 @@ Source: https://upstash.com/docs/agent-resources/overview import { AgentGrid } from "/snippets/agent-tools.jsx"; -Upstash ships Skills, a CLI, an MCP server, and llms.txt so your agent can build on and manage Redis, QStash, Workflow, Vector, Search, and Box. Pick your agent to get set up in a minute. +Upstash ships Skills, a CLI, an MCP server, and llms.txt so your agent can build on and manage Redis, QStash, Workflow, Vector, Search, and Box. Set them all up with one command, or pick your agent for step-by-step instructions. + +# Set up with one command + +Run this in your terminal: + +```bash +npx upstash +``` + +It detects Claude Code, Codex, Cursor, Gemini CLI, VS Code, GitHub Copilot CLI, and OpenCode, and lets you pick which to set up. Each one gets the Upstash [MCP server](/docs/agent-resources/mcp) and [skills](/docs/agent-resources/skills): as the Upstash plugin where the agent supports plugins, otherwise written into its config. The MCP server signs in with OAuth on first use. See the [CLI page](/docs/agent-resources/cli#connect-your-ai-agent) for flags. # Pick your agent @@ -1357,7 +1388,7 @@ Don't see your agent? See the [full list of agents](/docs/agent-resources/client -# Quick start +# Set up by hand Install the Upstash skill. It includes the `upstash` CLI reference, so this one step is enough for most workflows: @@ -1547,7 +1578,7 @@ Add `--global` (`-g`) to make the skills available in every project instead of j # Managing resources -The combined `upstash` skill includes the full `@upstash/cli` command reference, so your agent can create databases, publish QStash messages, query Vector indexes, and more straight from the shell. See the [CLI page](/docs/agent-resources/cli) for credentials and command details. +The combined `upstash` skill includes the full `upstash` CLI command reference, so your agent can create databases, publish QStash messages, query Vector indexes, and more straight from the shell. See the [CLI page](/docs/agent-resources/cli) for credentials and command details. # Disable Production Pack Source: https://upstash.com/docs/api-reference/qstash/disable-production-pack @@ -15353,10 +15384,21 @@ import { Hero, PromptToolIcons, SectionHead, ProductGrid, UtilityGrid, Community
+
+ $ npx upstash +
+ +```bash +npx upstash +``` + +
+ Agent Setup +
- Set up Upstash in my coding agent using the official Upstash instructions, and run the commands yourself instead of asking me to. If you are Claude Code, install the Upstash plugin — it bundles the Upstash skills (https://upstash.com/docs/agent-resources/skills) and the remote MCP server over OAuth — by running `claude plugin marketplace add upstash/skills` then `claude plugin install upstash@upstash`, and tell me to run `/reload-plugins`. If you are OpenAI Codex, install the same plugin with `codex plugin marketplace add upstash/skills` then `codex plugin add upstash@upstash`. For any other agent, install the skills with `npx -y skills add upstash/skills --global`, then add the remote MCP server https://mcp.upstash.com/mcp to your MCP config (it authenticates over OAuth on first use); see https://upstash.com/docs/agent-resources/clients for the exact location. When done, verify the skills and MCP server are installed and tell me whether a restart is needed. + Set up Upstash in my coding agent using the official Upstash instructions, and run the commands yourself instead of asking me to. Run `npx -y upstash setup --yes` with the flag for the agent you are (`--claude`, `--codex`, `--cursor`, `--gemini`, `--vscode`, `--copilot` or `--opencode`). It installs the Upstash plugin where your agent supports plugins, and otherwise adds the remote MCP server https://mcp.upstash.com/mcp plus the Upstash skills (https://upstash.com/docs/agent-resources/skills); the MCP server authenticates over OAuth on first use. If you are not one of those agents, install the skills with `npx -y skills add upstash/skills --global` and add the remote MCP server to your MCP config; see https://upstash.com/docs/agent-resources/clients for the exact location. When done, tell me what was installed and whether I need to restart or reload (in Claude Code, `/reload-plugins`).
diff --git a/snippets/agent-setup.jsx b/snippets/agent-setup.jsx index a12aab3bb..2fac1b831 100644 --- a/snippets/agent-setup.jsx +++ b/snippets/agent-setup.jsx @@ -1,28 +1,26 @@ -// "Set up your coding agent" card for product landing pages. Links to /agent-resources/overview. -// Usage: +// "Building with an AI coding agent?" card for product landing pages: `npx upstash` +// installs the Upstash MCP server and skills, with links to both pages. +// Usage: (`product` is accepted for existing pages; the command covers every product). // Everything lives inside the exported component: Mintlify does not expose non-exported top-level consts to snippet components. -export const AgentSetup = ({ product }) => { - const desc = product - ? `Connect the Upstash MCP server and the ${product} skill to Claude Code, Cursor, Codex, and other agents.` - : "Connect the Upstash MCP server and skills to Claude Code, Cursor, Codex, and other agents."; - - return ( - -
- -
-
-
Building with an AI coding agent?
-
{desc}
+export const AgentSetup = () => ( +
+); diff --git a/snippets/landing.jsx b/snippets/landing.jsx index 5ee0b2103..332ed2c86 100644 --- a/snippets/landing.jsx +++ b/snippets/landing.jsx @@ -1,3 +1,6 @@ +// Hero for the docs home. The actions passed as children are the `npx upstash` +// command box (a real code block, so the renderer's own copy button handles the +// click) and the setup prompt; the hint under them says what the command does. export const Hero = ({ children }) => (

Build with Upstash

@@ -5,12 +8,11 @@ export const Hero = ({ children }) => ( Serverless data, messaging, and AI infrastructure for developers. Scale to zero, pay per request.

-
- - Agent Setup - - {children} -
+
{children}
+

+ Run it in your terminal to add the Upstash MCP server and skills to Claude Code, Codex, Cursor, and + other agents. +

); diff --git a/style.css b/style.css index c2b89f3ca..7f8fc4ee3 100644 --- a/style.css +++ b/style.css @@ -147,6 +147,88 @@ html[data-current-path="/introduction"] #content-area { .dark .u-action--primary:hover { background: #e4e4e7; } +/* `npx upstash` command box, after Context7's: "$ npx upstash [copy] | Agent Setup". + The text is plain markup; the copy button is a real fenced code block with + everything but its copy chip hidden, so the renderer's own button (and its + copied state) does the copying. Docs7 renders .code-block > .code-surface > + .relative > (.code-chip + .code-scroll). */ +.u-command { + display: inline-flex; + align-items: center; + gap: 0.75rem; + height: 2.625rem; + padding: 0 1.125rem 0 1.125rem; + border: 1px solid #e5e5e5; + border-radius: 2.5rem; + background: #fafafa; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06); +} +.dark .u-command { + border-color: rgba(255, 255, 255, 0.16); + background: rgba(255, 255, 255, 0.06); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); +} +/* Only the code block's copy button shows; the command text above is ours. */ +.u-command__copy, +.u-command__copy > * { + margin: 0 !important; +} +.u-command__copy .code-block, +.u-command__copy .code-surface { + margin: 0 !important; + padding: 0 !important; + border: 0 !important; + background: transparent !important; + box-shadow: none !important; +} +.u-command__copy .code-scroll, +.u-command__copy pre { + display: none !important; +} +.u-command__copy .code-chip { + position: static !important; + background: transparent !important; + backdrop-filter: none !important; +} +.u-command__text { + font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, monospace); + font-size: 0.9375rem; + color: #262626; + white-space: nowrap; +} +.dark .u-command__text { + color: #f4f4f5; +} +.u-command__dollar { + color: #10b981; +} +.u-command__link { + padding-left: 0.75rem; + border-left: 1px solid #e5e5e5; + font-size: 0.9375rem; + line-height: 1.25rem; + color: #262626 !important; + text-decoration: underline; + text-underline-offset: 0.3rem; + text-decoration-color: rgba(0, 0, 0, 0.3); + white-space: nowrap; +} +.u-command__link:hover { + text-decoration-color: currentColor; +} +.dark .u-command__link { + border-left-color: rgba(255, 255, 255, 0.16); + color: #f4f4f5 !important; + text-decoration-color: rgba(255, 255, 255, 0.4); +} +.u-hero p.u-hero__hint { + margin-top: 0.75rem; + font-size: 0.875rem; + color: #8a8a8a; +} +.dark .u-hero p.u-hero__hint { + color: #8b8b8b; +} .u-prompt-action .prompt { position: absolute; inset: 0;