Skip to content
Back to skills

Convex Agent

ASecurity

Add an AI agent / RAG backend (@convex-dev/agent) to the Convex app.

  • 3 stars
  • 0 votes
  • 0 copies
  • 4 views
  • Added November 7, 2026
ai-agentsreactnodeapibackend

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned November 7, 2026

npx -y skills add evanharmon1/harmon-devkit --skill convex-agent --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Convex Agent?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Convex Agent
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/evanharmon1-convex-agent/badge)](https://www.skillsdirectory.com/skills/evanharmon1-convex-agent)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: convex-agent
description: "Add an AI agent / RAG backend (@convex-dev/agent) to the Convex app."
---

> Originally created by Convex (https://convex.dev) and redistributed under the Apache-2.0 License.
> See [UPSTREAM.md](UPSTREAM.md) for provenance and local modifications.

<!-- GENERATED from convex-agents content/capabilities/agent.json — do not edit by hand. -->

# Add an AI agent / RAG backend

Install @convex-dev/agent for durable threads, message history, tool-calls, and vector search/RAG — the backend for an in-app AI agent. Call models through the Convex AI Gateway by default: Convex holds the provider credentials, so there is no LLM key to obtain, store, or rotate.

## Workflow

1. Install @convex-dev/agent + @convex-dev/ai-sdk-provider; add the agent component to convex.config.ts.
2. Define the agent (tools, instructions) with `languageModel: convexGateway("provider/model")` — no API key needed (needs convex 1.45+ on a Convex Cloud deployment, paid plan).
3. Create threads + stream messages; persist history in Convex.
4. For RAG: embed docs into a vector index and retrieve in the tool. The gateway does not serve embeddings yet, so store the embedding provider's key via the `env` micro power.
5. Only if the gateway is unavailable (free plan, self-hosted, local backend): call the provider SDK with a key stored via the `env` micro power.

## Rules

- Default to the Convex AI Gateway (`convexGateway` from @convex-dev/ai-sdk-provider) for model calls; fall back to a provider key in Convex env only where the gateway is unavailable (free plan, self-hosted, local backend).
- Never expose a provider API key client-side; when one is needed (embeddings, gateway fallback), keep it in Convex env via the `env` micro power.
- Run model calls in actions ('use node' if the SDK needs it).
- Persist threads/messages in Convex for durability + reactivity.

Files in this skill

  • LICENSE.upstream10.7 KB
  • SKILL.md1.9 KB
  • UPSTREAM.md625 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.