Terminal
Terminal/Skill
Audits an existing TypeScript or JavaScript codebase, including AI agent and eval loops, for work Inngest would make durable, then plans an incremental integration.
By Inngest
Works with
npx skills add inngest/inngest-skills --skill inngest-brownfield-auditUse this skill when asked to inspect an existing codebase, add Inngest "where it makes sense", migrate fragile background work, or find durability gaps before making changes.
This is an agent-first workflow. Do the audit from evidence in the repo, name the specific files and call sites that drove each conclusion, and make small integration moves that preserve current behavior.
Use this skill for requests like:
If the user is starting from scratch instead of a brownfield repo, use
inngest-setup, inngest-durable-functions, inngest-events,
inngest-steps, and, for AI workflows, the agent patterns in this skill. Use
inngest-agent-evals when the request includes scoring, sessions, experiments,
deferred scorers, Insights, or outcome-based evaluation.
Map the project shape.
package.json, workspace files, app/router structure, server entry
points, deployment config, and test scripts.Find existing Inngest usage.
inngest, createFunction, serve(, /api/inngest,
INNGEST_, step.run, step.sleep, step.waitForEvent,
step.sendEvent, step.invoke, step.ai, inngest.send, and
@inngest/realtime.Find durability gaps.
void someAsync(), un-awaited promises,
.then( chains, setTimeout, setInterval, detached jobs after HTTP
response, and background work in route handlers.cron, node-cron, agenda, bull,
bullmq, bee-queue, qstash, sqs, temporal, trigger.dev,
deployment cron config, and scheduled API routes.webhook.Classify each candidate.
Choose the smallest safe integration.
step.run one boundary at a time.Run commands that fit the repo. Prefer rg; keep output focused.
rg -n "inngest|createFunction|step\\.|serve\\(|/api/inngest|INNGEST_" .
rg -n "setTimeout|setInterval|Promise\\.all|void [a-zA-Z0-9_]+\\(|\\.then\\(" .
rg -n "cron|node-cron|schedule|bull|bullmq|bee-queue|agenda|qstash|sqs" .
rg -n "webhook|stripe|svix|clerk|github|shopify|slack|hubspot|linear" .
rg -n "retry|backoff|poll|status|timeout|429|rate limit|rate-limit" .
rg -n "openai|anthropic|ai\\.|generateText|streamText|tool|agent|embedding" .
When the repo is large, narrow searches to app source directories and exclude generated/vendor folders.
| Existing shape | Inngest fit | Primary primitives |
|---|---|---|
| HTTP handler does slow side effects before responding | Emit event, return fast | inngest.send, event trigger, step.run |
| Webhook must acknowledge quickly but process reliably | Verify signature, emit idempotent event | Event ID, step.run, retries |
| Cron job loses progress midway | Cron-triggered durable function | Cron trigger, page-level step.run, flow control |
| Polling loop waits for external async work | Durable wait or durable poll | step.waitForEvent, step.sleep, step.run |
| Large fan-out exceeds request/serverless limits | Split orchestration and item work | step.sendEvent, per-item function, concurrency |
| External API hits 429s | Move limits to function config | throttle, rateLimit, concurrency |
| Human review can take days | Persist the wait in Inngest | step.waitForEvent, timeout, realtime |
| AI agent/tool loop needs retry-safe progress | One step per tool/model boundary | step.ai, step.run, step.sleep, realtime |
| AI workflow needs production evals | Attach outcome signals to durable runs | meta.sessions, step.score, createScorer, defer, group.experiment |
| Existing queue only hides fragile work | Replace queue boundary gradually | Event trigger, idempotency, function-level retries |
Before editing, summarize findings in this compact shape:
Inngest audit:
- Existing Inngest: none / partial / healthy / risky
- Framework: <framework and evidence>
- Best first slice: <file + workflow>
- Why: <loss/timeout/retry/idempotency failure>
- Proposed primitives: <event, steps, flow control, waits, realtime>
- Idempotency key: <source of truth>
- Files likely touched: <short list>
- Tests/checks: <commands or focused cases>
Then implement unless the user asked for audit-only.
If Inngest is already present, verify:
id is a stable slug and is not derived from deploy-specific data.INNGEST_DEV=1; production uses
INNGEST_SIGNING_KEY./api/inngest.domain/noun.verb.inngest/realtime, not the v3
@inngest/realtime package.Use Inngest when an AI or agent workflow needs durable progress across model calls, tool calls, waits, approvals, or streaming UI updates.
Good candidates:
Recommended shape:
id.step.run.step.ai or step.run boundary.step.waitForEvent or step.waitForSignal with a timeout.step.realtime.publish between steps, or
inngest.realtime.publish inside an existing step.run.concurrency, throttle, or rateLimit, not
ad hoc in-process throttlers.Avoid:
setTimeout or a cron poller for follow-ups and approvals.Pick checks that prove the integration path: