Loading...
Loading...
Use Convex Components to add isolated backend features and compose component APIs. Use for installing components, calling component APIs, authoring components, and handling component-specific constraints (Id types, env vars, pagination, auth). Use proactively when users mention components, workpool, workflow, agent component, or reusable backend modules. Examples: - user: "Install the Agent component" → add convex.config.ts + use() + components API - user: "Call component functions" → ctx.runQuery(components.foo.bar, args) - user: "Build a component" → defineComponent, schema, _generated, packaging - user: "Expose component API to clients" → re-export functions with auth
npx skill4agent add igorwarzocha/opencode-workflows convex-componentsnpm i @convex-dev/<component>convex/convex.config.tsimport { defineApp } from "convex/server";app.use(component)app.use(component, { name: "custom" })npx convex devcomponents.<name>convex/_generated/apictx.runQuery/Mutation/Actioncomponents.<name>.<fn>components.<name>Idstringv.id("table")_generatedcomponentsprocess.envconvex/http.tsctx.auth.paginate()convex-helpersusePaginatedQueryconvex.config.tsschema.ts_generateddefineComponent("name")component.use(...)convex/components/@pkg/convex.config.js@pkg/_generated/component.js@pkg/testcreateFunctionHandle(api.foo.bar)v.string()FunctionHandleconvex-test@pkg/test