Skip to content

feat: Tanstack Intent Skills - #7252

Merged
Nick-Lucas merged 23 commits into
mainfrom
feat/ts-intent
Mar 20, 2026
Merged

Nick-Lucas merged 23 commits into
mainfrom
feat/ts-intent

Conversation

@Nick-Lucas

@Nick-Lucas Nick-Lucas commented Mar 15, 2026 •

Copy link
Copy Markdown
Contributor
  • Add package
  • Add generated skills and artifacts
  • docs: add AI agents installation instructions across multiple README files

Closes #

🎯 Changes

What changes are made in this PR? Is it a feature or a bug fix?

βœ… Checklist

  • I have followed the steps listed in the Contributing guide.
  • If necessary, I have added documentation related to the changes made.
  • I have added or updated the tests related to the changes made.

Summary by CodeRabbit

  • New Features

    • AI agent support: one-step install for tRPC "skills" to assist code generation.
  • Documentation

    • Many new and expanded skill guides plus a generated domain/skill catalog; AI Agents tips inserted across READMEs and docs.
  • Chores

    • Added an intent CLI/runtime dependency, package metadata for a CLI entry, updated gitignore, and CI workflows to validate and check skills.

@Nick-Lucas
Nick-Lucas requested review from a team as code owners March 15, 2026 19:13
Copilot AI review requested due to automatic review settings March 15, 2026 19:13
@vercel

vercel Bot commented Mar 15, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
next-prisma-starter Ready Ready Preview Mar 20, 2026 11:07pm
og-image Ready Ready Preview, Comment Mar 20, 2026 11:07pm

Request Review

@coderabbitai

coderabbitai Bot commented Mar 15, 2026 •

Copy link
Copy Markdown
Contributor

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▢️ Resume reviews
  • πŸ” Trigger review

Walkthrough

Adds a skills/metadata system and many SKILL.md documentation files, inserts "AI Agents" install hints across READMEs and docs, adds generated artifacts (domain_map, skill_spec, skill_tree), introduces the runtime dependency @tanstack/intent, package metadata (keywords/bin) across packages, and adds GitHub Actions workflows to validate and check skills.

Changes

Cohort / File(s) Summary
Repo root & top-level docs
/.gitignore, README.md
Allow packages/*/skills/ entries in gitignore and add top-level README "AI Agents" section.
Runtime dependency
package.json
Add runtime dependency @tanstack/intent.
Generated artifacts
_artifacts/domain_map.yaml, _artifacts/skill_spec.md, skills/_artifacts/skill_tree.yaml
Add large declarative artifacts describing domain map, skill spec, and skill tree (documentation/data only).
Package metadata & CLIs
packages/*/package.json (e.g., packages/client, packages/next, packages/server, packages/openapi, packages/tanstack-react-query, ...)
Add keywords: ["tanstack-intent"], add bin: { "intent": "./bin/intent.js" }, and expand files to include skills/bin while excluding !skills/_artifacts (metadata only).
Client docs & skills
packages/client/README.md, packages/client/skills/..., packages/client/skills/links/references/link-options.md
Insert AI Agents hint in client README and add multiple SKILL.md docs (client-setup, links, link-options, superjson).
Server docs & skills
packages/server/README.md, packages/server/skills/*
Insert AI Agents hint in server README and add many server SKILL.md docs (adapters, auth, caching, error-handling, middlewares, validators, subscriptions, non-json content, SOA, server-setup, server-side-calls, etc.).
Next.js package & skills
packages/next/README.md, packages/next/package.json, packages/next/skills/...
Add AI Agents README snippet, package metadata, and SKILL.md for Next.js App Router and Pages Router.
OpenAPI & React Query docs & skills
packages/openapi/README.md, packages/openapi/skills/openapi/SKILL.md, packages/tanstack-react-query/skills/...
Add AI Agents hint, OpenAPI SKILL.md, React Query setup and migration SKILL docs; update package metadata and bin entries.
Website docs updates
www/docs/**/**/*.mdx, www/docs/**/**/*.md
Insert "AI Agents" tip blocks recommending npx @tanstack/intent@latest install across multiple guides and adapter pages.
CI workflows
.github/workflows/validate-skills.yml, .github/workflows/check-skills.yml
Add workflows to validate skills on PRs and to check stale skills on release, invoking @tanstack/intent, parsing JSON, and creating review PRs when needed.

Sequence Diagram(s)

sequenceDiagram
    participant GH as GitHub Actions
    participant Repo as Repository
    participant Node as Node (runner)
    participant Intent as `@tanstack/intent` CLI
    participant GHAPI as GitHub API

    GH->>Repo: trigger (release / workflow_dispatch)
    GH->>Node: setup node
    Node->>Intent: install intent CLI
    Node->>Intent: run `intent stale --json` / `intent validate <dir>`
    Intent-->>Node: JSON results
    alt stale skills found
        Node->>GHAPI: create branch + commit
        Node->>GHAPI: create PR with summary + prompt
    else no stale skills
        Node->>GH: set outputs (none)
    end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Suggested reviewers

  • juliusmarminge
  • KATT

Poem

πŸ‡ I hopped through docs and artifacts bright,
Nibbled hints for agents late at night,
Skill trees sprout where routers play,
Intent installs show the way β€”
A joyful hop β€” new docs take flight!

πŸš₯ Pre-merge checks | βœ… 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive The PR description is incomplete. While it lists high-level changes (package addition, skills/artifacts, docs updates), it lacks details on motivation, affected areas, testing approach, and leaves the issue number blank and checklist unchecked. Fill in the referenced issue number, provide context on why these changes are needed, detail the scope of documentation updates, and indicate whether tests were added/updated for the new package.
βœ… Passed checks (2 passed)
Check name Status Explanation
Title check βœ… Passed The title 'feat: Tanstack Intent Skills' clearly identifies the main change: introduction of a new Tanstack Intent Skills feature, covering the package, skills, and documentation additions.
Docstring Coverage βœ… Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
πŸ§ͺ Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/ts-intent

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❀️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@railway-app

railway-app Bot commented Mar 15, 2026 •

Copy link
Copy Markdown

πŸš… Deployed to the trpc-pr-7252 environment in trpc-sse-and-websockets

Service Status Web Updated (UTC)
next-sse-chat πŸ•’ Building (View Logs) Web Mar 20, 2026 at 11:18 pm
next-prisma-websockets-starter πŸ•’ Building (View Logs) Mar 20, 2026 at 11:14 pm

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds TanStack Intent β€œskills” content across tRPC packages and documents how to install them for AI coding agents.

Changes:

  • Add generated skills/** content (SKILL.md + references) and generated _artifacts/* metadata.
  • Update multiple docs/READMEs to include AI agent installation instructions (npx @tanstack/intent@latest install).
  • Add @tanstack/intent to the repo dev dependencies and update package publish files lists to include skills/ (and bin/).

Reviewed changes

Copilot reviewed 51 out of 53 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
www/docs/server/adapters/standalone.md Add AI agents tip + install command
www/docs/server/adapters/fetch.mdx Add AI agents tip + install command
www/docs/server/adapters/fastify.md Add AI agents tip + install command
www/docs/server/adapters/express.md Add AI agents tip + install command
www/docs/server/adapters/aws-lambda.md Add AI agents tip + install command
www/docs/main/quickstart.mdx Add AI agents tip + install command
www/docs/client/vanilla/setup.mdx Add AI agents tip + install command
www/docs/client/tanstack-react-query/setup.mdx Add AI agents tip + install command
www/docs/client/react/setup.mdx Add AI agents tip + install command
www/docs/client/openapi.md Add AI agents tip + install command
www/docs/client/nextjs/pages-router/setup.mdx Add AI agents tip + install command
www/docs/client/nextjs/app-router/setup.mdx Add AI agents tip + install command
pnpm-lock.yaml Lockfile updates for new dependency/resolution changes
packages/tanstack-react-query/skills/react-query-setup/SKILL.md New skill content for TanStack React Query setup
packages/tanstack-react-query/skills/react-query-classic-migration/SKILL.md New skill content for migration from classic React Query
packages/tanstack-react-query/package.json Publish files list + keywords/bin additions
packages/tanstack-react-query/README.md Add AI agents section
packages/server/skills/validators/SKILL.md New validators skill content
packages/server/skills/trpc-router/SKILL.md New skill router entry-point content
packages/server/skills/subscriptions/SKILL.md New subscriptions skill content
packages/server/skills/service-oriented-architecture/SKILL.md New SOA skill content
packages/server/skills/server-side-calls/SKILL.md New server-side calls skill content
packages/server/skills/server-setup/SKILL.md New server setup skill content
packages/server/skills/non-json-content-types/SKILL.md New non-JSON content types skill content
packages/server/skills/middlewares/SKILL.md New middleware skill content
packages/server/skills/error-handling/SKILL.md New error handling skill content
packages/server/skills/caching/SKILL.md New caching skill content
packages/server/skills/auth/SKILL.md New auth skill content
packages/server/skills/adapter-standalone/SKILL.md New standalone adapter skill content
packages/server/skills/adapter-fetch/SKILL.md New fetch adapter skill content
packages/server/skills/adapter-fastify/SKILL.md New fastify adapter skill content
packages/server/skills/adapter-express/SKILL.md New express adapter skill content
packages/server/skills/adapter-aws-lambda/SKILL.md New aws-lambda adapter skill content
packages/server/package.json Publish files list + keywords/bin additions
packages/server/README.md Add AI agents section
packages/openapi/skills/openapi/SKILL.md New OpenAPI skill content
packages/openapi/README.md Add AI agents section
packages/next/skills/nextjs-pages-router/SKILL.md New Next.js Pages Router skill content
packages/next/skills/nextjs-app-router/SKILL.md New Next.js App Router skill content
packages/next/package.json Publish files list + keywords/bin additions
packages/next/README.md Add AI agents section
packages/client/skills/superjson/SKILL.md New SuperJSON skill content
packages/client/skills/links/references/link-options.md New link options reference
packages/client/skills/links/SKILL.md New links skill content
packages/client/skills/client-setup/SKILL.md New client setup skill content
packages/client/package.json Publish files list + keywords/bin additions
packages/client/README.md Add AI agents section
package.json Add @tanstack/intent dev dependency
_artifacts/skill_tree.yaml Generated skill tree index
_artifacts/skill_spec.md Generated skill spec/failure modes
README.md Add AI agents section
.gitignore Ensure packages/*/skills/ are not ignored
Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

πŸ’‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/client/package.json Resolved
Comment thread packages/next/package.json Resolved
Comment thread packages/server/package.json Resolved
Comment thread _artifacts/skill_tree.yaml Resolved

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 18

🧹 Nitpick comments (12)
packages/server/skills/error-handling/SKILL.md (1)

1-3: Rename this Markdown file to camelCase to match repo naming rules.

SKILL.md does not follow the configured camelCase naming convention for .md files. Consider renaming it to a camelCase filename and updating any references accordingly.

As per coding guidelines **/*.{ts,tsx,md,mdx}: "Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests)".

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/error-handling/SKILL.md` around lines 1 - 3, The file
name SKILL.md violates the repo camelCase rule; rename it to a camelCase
filename such as errorHandling.md or skillsErrorHandling.md, update any
references to SKILL.md (docs, README links, import/require strings, CI/glob
patterns) to the new name, and verify that tooling or MDX imports (if any) still
resolve correctly; commit the rename as a filesystem move so history is
preserved and run the repo lint/CI to confirm no remaining references to
SKILL.md.
packages/server/skills/subscriptions/SKILL.md (2)

364-364: Replace β€œSource: maintainer interview” with a stable, linkable reference.

Please cite an issue, discussion, RFC, or doc URL so this guidance stays auditable for future updates.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/subscriptions/SKILL.md` at line 364, The line in
SKILL.md that currently reads "Source: maintainer interview" should be replaced
with a stable, linkable reference (e.g., an issue, discussion, RFC, or
documentation URL) so the provenance is auditable; locate the string "Source:
maintainer interview" in SKILL.md and replace it with a full citation
(preferably a permalink to an issue/discussion/RFC) and include a short label
like "Source: [Issue `#1234`](https://...)" or "Source: RFC XYZ (https://...)" to
preserve readability and future traceability.

1-1: Filename is not camelCase under current repo guideline.

SKILL.md appears to violate the .md filename convention. If SKILL.md is required by generator/tooling, please document it as an explicit exception in the guideline.

As per coding guidelines, "**/*.{ts,tsx,md,mdx}: Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests)".

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/subscriptions/SKILL.md` at line 1, The file SKILL.md
violates the repo's camelCase filename rule; either rename the file to camelCase
(e.g., skill.md) and update any imports/tooling references that expect SKILL.md,
or if the uppercase name is required by a generator/tool, add an explicit
exception to the repo guideline mentioning
"packages/server/skills/subscriptions/SKILL.md" (or the SKILL.md convention) and
update documentation; locate the file by the unique symbol SKILL.md and ensure
all CI/tooling configs and any references are updated accordingly.
packages/next/skills/nextjs-app-router/SKILL.md (1)

32-48: Add language identifier to fenced code block.

The file structure tree should specify a language identifier for proper syntax highlighting and tooling support. Consider using text or plaintext.

πŸ“ Proposed fix
-```
+```text
 .
 β”œβ”€β”€ app
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/next/skills/nextjs-app-router/SKILL.md` around lines 32 - 48, The
fenced code block showing the project tree in SKILL.md lacks a language
identifier; update the opening triple-backtick for that block to include a
language such as text or plaintext (e.g., change ``` to ```text) so the file
tree (the block that begins with "." and the lines under β”œβ”€β”€ app and β”œβ”€β”€ trpc)
is properly highlighted and recognized by tooling.
packages/next/skills/nextjs-pages-router/SKILL.md (1)

27-43: Add language identifier to fenced code block.

The file structure tree should specify a language identifier for proper syntax highlighting and tooling support. Consider using text or plaintext.

πŸ“ Proposed fix
-```
+```text
 .
 β”œβ”€β”€ src
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/next/skills/nextjs-pages-router/SKILL.md` around lines 27 - 43,
Update the fenced code block in SKILL.md that contains the project tree by
adding a language identifier (e.g., "text" or "plaintext") to the opening triple
backticks so the block becomes ```text; this applies to the directory-tree block
shown under src/pages / src/server / src/utils to enable proper syntax
highlighting and tooling.
packages/server/skills/auth/SKILL.md (2)

316-316: Replace non-verifiable source with a stable reference

β€œSource: maintainer interview” is hard to audit and maintain. Prefer a durable public doc/issue/discussion link for this security recommendation.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/auth/SKILL.md` at line 316, The line "Source:
maintainer interview" in SKILL.md should be replaced with a durable, verifiable
reference; locate the string in packages/server/skills/auth/SKILL.md (the
security recommendation block where "Source: maintainer interview" appears) and
replace it with a public URL or citation (e.g., an issue, PR, official
changelog, advisory, or discussion) that documents the claim, or add an explicit
note describing why no public reference exists; ensure the replacement includes
the URL or reference title so auditors can verify the claim.

1-1: Rename file to follow camelCase naming convention

SKILL.md does not follow the repository filename convention for markdown files. Consider renaming to a camelCase filename (or document an explicit exception for skill manifests).

As per coding guidelines, **/*.{ts,tsx,md,mdx}: Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests).

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/auth/SKILL.md` at line 1, Rename the file SKILL.md to
a camelCase name (e.g., skill.md or authSkill.md) to match the repository
filename convention; update any references to SKILL.md (links, imports,
documentation pointers) to the new filename and ensure CI/linting no longer
flags the file; keep the same file content and only change the filename and
references to maintain compatibility.
www/docs/main/quickstart.mdx (1)

80-86: Deduplicate this AI tip into a shared docs partial.

Line 80 through Line 86 is clear, but this exact block is repeated across many docs in this PR. Consider extracting it into a shared MDX partial/component to avoid future drift when the command or wording changes.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@www/docs/main/quickstart.mdx` around lines 80 - 86, The AI tip block (":::tip
AI Agents ... npx `@tanstack/intent`@latest install :::") is duplicated across
docs; extract it into a shared MDX partial/component (e.g., create a partial
like AiAgentTip or docs/components/AiAgentTip.mdx) and replace each inline block
(including the occurrence in quickstart.mdx) with the shared import/usage (such
as <AiAgentTip /> or an MDX include), updating the docs build to import that
partial so future edits only require changing the single shared component.
_artifacts/domain_map.yaml (1)

1-17: Consider camelCase for file name.

Similar to skill_spec.md, the filename domain_map.yaml uses snake_case. If this is a generated artifact from tooling, the naming convention may be intentional. Otherwise, consider domainMap.yaml per coding guidelines.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@_artifacts/domain_map.yaml` around lines 1 - 17, The file name
domain_map.yaml uses snake_case; rename it to camelCase (domainMap.yaml) to
match the project's filename convention and the similar skill_spec.md ->
skillSpec.md pattern, updating any references to domain_map.yaml (e.g., CI
configs, import/consumers, deployment scripts) so they point to domainMap.yaml;
if this file is generated by tooling, instead adjust the generator configuration
to emit domainMap.yaml or add a small README note explaining the intentional
naming to avoid confusion.
packages/server/skills/adapter-express/SKILL.md (1)

74-74: Minor: Clarify Express typing.

The description states req (IncomingMessage) and res (ServerResponse), but per the source code, CreateExpressContextOptions is typed as NodeHTTPCreateContextFnOptions<express.Request, express.Response>. While Express types extend the Node.js base types, stating express.Request and express.Response would be more precise and helpful for developers expecting Express-specific properties like req.query or req.params.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/adapter-express/SKILL.md` at line 74, Update the
SKILL.md description to reference the actual Express types: change the mention
of "req (IncomingMessage) and res (ServerResponse)" to "req (express.Request)
and res (express.Response)" to match the typing of CreateExpressContextOptions
(NodeHTTPCreateContextFnOptions<express.Request, express.Response>) and make
Express-specific properties like req.query and req.params clear to readers.
_artifacts/skill_tree.yaml (1)

1-10: Consider camelCase for file name.

The filename skill_tree.yaml uses snake_case. Same consideration as other artifact files - if this is tooling-generated, the convention may be intentional.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@_artifacts/skill_tree.yaml` around lines 1 - 10, The file name
skill_tree.yaml uses snake_case; rename it to camelCase (e.g., skillTree.yaml)
and update all places that reference it (any build scripts, CI, docs, generated
metadata such as generated_from or other tooling configs) to point to the new
name; if generation tooling produces the snake_case, either adjust the generator
configuration to emit camelCase or add a post-generation rename step and update
any references to the file (look for mentions of "skill_tree.yaml" in repo and
in consumers that parse generated artifacts).
_artifacts/skill_spec.md (1)

1-7: Consider camelCase for file name.

The filename skill_spec.md uses snake_case. As per coding guidelines, .md files should use camelCase (e.g., skillSpec.md). However, if _artifacts/ follows a different convention for generated/tooling files, this may be intentional.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@_artifacts/skill_spec.md` around lines 1 - 7, Filename uses snake_case:
rename _artifacts/skill_spec.md to camelCase (skillSpec.md) to follow docs
conventions; update any references/imports/CI scripts that point to
"_artifacts/skill_spec.md" (search for "skill_spec.md") so they now point to
"skillSpec.md"; if _artifacts is a generated/tooling folder, instead
document/confirm the exception in contributing docs or adjust the generator to
emit camelCase filenames rather than renaming the file manually.
πŸ€– Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@_artifacts/skill_spec.md`:
- Around line 214-222: The count is inconsistent: the "Skill Inventory table"
shows auth with 5 failure modes but the "auth (5 failure modes)" section only
lists 4 entries; either update the Skill Inventory table to show "auth (4
failure modes)" or add the missing fifth failure mode entry to the "auth (5
failure modes)" section (ensuring the new entry follows the same table/format
and includes a unique mistake description, priority, and source).

In `@packages/client/package.json`:
- Around line 144-146: The package.json "bin" entry points to a non-existent
executable ("./bin/intent.js"); fix by either removing the "intent" key from the
"bin" map in packages/client/package.json or by adding the missing executable at
packages/client/bin/intent.js that exports the intended CLI (ensure it is
executable and has the proper shebang). Update the "bin" mapping or add the file
so consumers of `@trpc/client` get a valid executable.

In `@packages/client/skills/links/references/link-options.md`:
- Around line 83-89: The example using splitLink references httpSubscriptionLink
but the import list only includes splitLink, httpBatchLink, and httpLink; update
the import statement to also import httpSubscriptionLink so the snippet compiles
and matches usage (look for the import line that currently mentions splitLink,
httpBatchLink, httpLink and add httpSubscriptionLink) while keeping the rest of
the example (splitLink call, condition, true: httpSubscriptionLink({ url }),
false: httpBatchLink({ url })) unchanged.

In `@packages/next/package.json`:
- Around line 154-156: The package.json declares a CLI entry ("bin": { "intent":
"./bin/intent.js" }) but the bin/intent.js file is missing, and the packages
also list "bin" in their "files" arrays; either add the missing executable file
or remove the broken declaration: create a proper executable at bin/intent.js
with a node shebang and the CLI bootstrap (for packages next, client, server,
tanstack-react-query) or remove the "intent" entry from the "bin" field and
delete "bin" from the "files" array in each package.json so no broken CLI is
published. Ensure the unique identifiers β€” the "bin" field, the "intent" key,
and the "files" array β€” are consistently updated across all affected
package.json files.

In `@packages/openapi/skills/openapi/SKILL.md`:
- Around line 220-226: The example uses Document in the deserialize cast but
does not import it; add an import for Document from the bson package (import
type { Document } from 'bson';) at the top alongside the existing EJSON import
so the ejsonTransformer's deserialize: (value) => EJSON.deserialize(value as
Document) compiles correctly.

In `@packages/server/package.json`:
- Around line 237-239: The package.json "bin" entry named "intent" points to a
non-existent file ("./bin/intent.js") across multiple packages (symbol: "bin": {
"intent": "./bin/intent.js" } in packages/server, packages/client,
packages/next, packages/tanstack-react-query); fix by either adding the missing
executable at the referenced path (create ./bin/intent.js with the intended CLI
implementation and make it executable) or remove/replace the "intent" bin entry
with the correct path to the real CLI file (or remove the "intent" key entirely
if the package should not expose a bin), and ensure package.json scripts and any
references to the "intent" command are updated accordingly so consumers no
longer get a broken bin reference.

In `@packages/server/skills/adapter-fastify/SKILL.md`:
- Line 113: The WebSocket example calls server.listen({ port: 3000 }) without
awaiting or error handling; wrap the listen call in the same async IIFE pattern
used in the basic setup (use an async immediately-invoked function), await
server.listen({ port: 3000 }) inside a try block, and add a catch to log the
error (e.g., console.error or processLogger.error) and exit (process.exit(1)) so
unhandled promise rejections are avoided.

In `@packages/server/skills/adapter-standalone/SKILL.md`:
- Around line 132-134: The example uses tlsKey and tlsCert when calling
http2.createSecureServer (creating server) but those variables are not declared;
add declarations for tlsKey and tlsCert before the createSecureServer call
(e.g., load from disk or environment and assign the key and cert contents) so
the snippet is runnable, ensuring they are passed as the { key: tlsKey, cert:
tlsCert } object to createSecureServer; update the example around the
server/http2.createSecureServer block to show the source (fs or env) and
variable names tlsKey and tlsCert.

In `@packages/server/skills/auth/SKILL.md`:
- Around line 7-8: Remove "httpSubscriptionLink connectionParams" from the
initial SSE auth summary (the line listing "via httpBatchLink headers(),
WebSocket connectionParams, and SSE auth via cookies, EventSource polyfill
custom headers, or httpSubscriptionLink connectionParams") so the summary only
lists secure methods (e.g., httpBatchLink headers(), WebSocket connectionParams,
SSE via cookies, and EventSource polyfill custom headers); then add a brief
mention in the warnings/security section (where the HIGH risk is discussed)
noting that httpSubscriptionLink places connectionParams in the SSE URL query
string and is unsuitable for sensitive tokens. Target the phrase
"httpSubscriptionLink connectionParams" in SKILL.md and remove it from the
summary while ensuring it remains documented in the warnings/security block.

In `@packages/server/skills/caching/SKILL.md`:
- Around line 69-70: The cache-eligibility check using path.includes('public')
is too permissive and can misclassify routes; update the logic where allPublic
is computed (and the similar check later) to perform strict route-prefix
matchingβ€”e.g., ensure each path is normalized and then use startsWith('/public')
or a regex anchored to the path prefix instead of includes('public') so only
routes that actually begin with the public prefix are considered public; update
the variables/functions that compute allPublic (and the analogous check around
errors) to use this stricter test on paths.

In `@packages/server/skills/server-setup/SKILL.md`:
- Around line 191-192: Add explanatory comments above the lazy imports in
appRouter to show the two patterns: annotate greeting: lazy(() =>
import('./greeting.js')) with a short comment like "Option 1: short-hand when
the module exports exactly one router/default export" and annotate user: lazy(()
=> import('./user.js').then((m) => m.userRouter)) with a comment like "Option 2:
use .then to pick a named export when the module exports multiple routers";
update the router definition (appRouter) next to the greeting and user entries
so readers see when to use each lazy() import form.

In `@packages/server/skills/server-side-calls/SKILL.md`:
- Around line 131-132: The example calls caller.post.byId which isn't defined in
the documented router (the router only exposes add and list); fix by either
adding a byId procedure to the router (e.g., implement a post.byId procedure
that takes { id: string } and returns the post so caller.post.byId(...) works)
or change the example to use an existing procedure such as caller.post.list or
caller.post.add; update the doc's router snippet to include the new byId
procedure name and signature (or swap the call in the example to an existing
procedure) so the snippet is copy-paste runnable.

In `@packages/server/skills/service-oriented-architecture/SKILL.md`:
- Around line 122-133: The code retrieves link = servers[serverName] and calls
it without guarding against undefined; update the returned middleware (the
function that takes ctx and uses op.path, serverName, path) to check whether
servers[serverName] exists before invoking it β€” if undefined, throw or return a
clear routing error (e.g., "Unknown service: <serverName>") instead of calling
link; keep the existing context transformation (op.path slicing and reassigning)
and only call link(...) when the lookup succeeds.
- Around line 151-155: The type annotation on servers is incorrect:
ReturnType<typeof httpBatchLink> is the TRPCLink function type but you store the
results of calling httpBatchLink(runtime) (OperationLink instances). Remove the
explicit type annotation on servers so TypeScript infers the correct
Record<string, OperationLink> (or change it to Record<string,
ReturnType<ReturnType<typeof httpBatchLink>>> if you prefer an explicit type);
update the declaration that uses servers, referencing the symbols servers,
httpBatchLink, runtime, TRPCLink and OperationLink to ensure the assigned values
and the declared type match.

In `@packages/server/skills/subscriptions/SKILL.md`:
- Around line 7-8: Update the attribution in the skill description to correctly
state that wsLink and createWSClient come from `@trpc/client` while
applyWSSHandler comes from `@trpc/server/adapters/ws`; edit the text around the
symbols wsLink, createWSClient, and applyWSSHandler to split the sources
accordingly so it reads like: "wsLink, createWSClient from `@trpc/client`" and
"applyWSSHandler from `@trpc/server/adapters/ws`".

In `@packages/tanstack-react-query/package.json`:
- Around line 90-92: The package.json declares a CLI entry "intent":
"./bin/intent.js" but that file and the bin/ directory are missing; either
remove the "bin" block from packages/tanstack-react-query/package.json (and the
reference in the "files" array) or create the missing executable at
./bin/intent.js and ensure it's included in the published files: create
packages/tanstack-react-query/bin/intent.js with a proper node shebang, make it
executable, export the intended CLI behavior (matching project conventions), and
keep/update the "files" array so "./bin/intent.js" is packaged.

In `@packages/tanstack-react-query/skills/react-query-setup/SKILL.md`:
- Line 314: Update the phrasing in the sentence referring to useTRPC to replace
β€œinside of” with β€œinside” so it reads: "`useTRPC()` throws \"can only be used
inside a <TRPCProvider>\" if the component tree is not wrapped. Ensure
`TRPCProvider` is mounted above all components that call `useTRPC()`, typically
in your root `App` component." Locate the sentence mentioning `useTRPC()` and
`TRPCProvider` and make the small text change for improved readability.
- Around line 288-295: DirectCall currently calls the React hook useTRPCClient
inside an async function which violates hook rules; refactor DirectCall into a
React component that calls useTRPCClient at the top level (e.g., const client =
useTRPCClient()) and move the async work (client.user.byId.query({ id: '1' }))
into a useEffect or an event handler so the hook is not invoked inside an async
callback; ensure the top-level symbol DirectCall remains a component and that
client.user.byId.query is executed from the effect/handler instead of directly
in the async function.

---

Nitpick comments:
In `@_artifacts/domain_map.yaml`:
- Around line 1-17: The file name domain_map.yaml uses snake_case; rename it to
camelCase (domainMap.yaml) to match the project's filename convention and the
similar skill_spec.md -> skillSpec.md pattern, updating any references to
domain_map.yaml (e.g., CI configs, import/consumers, deployment scripts) so they
point to domainMap.yaml; if this file is generated by tooling, instead adjust
the generator configuration to emit domainMap.yaml or add a small README note
explaining the intentional naming to avoid confusion.

In `@_artifacts/skill_spec.md`:
- Around line 1-7: Filename uses snake_case: rename _artifacts/skill_spec.md to
camelCase (skillSpec.md) to follow docs conventions; update any
references/imports/CI scripts that point to "_artifacts/skill_spec.md" (search
for "skill_spec.md") so they now point to "skillSpec.md"; if _artifacts is a
generated/tooling folder, instead document/confirm the exception in contributing
docs or adjust the generator to emit camelCase filenames rather than renaming
the file manually.

In `@_artifacts/skill_tree.yaml`:
- Around line 1-10: The file name skill_tree.yaml uses snake_case; rename it to
camelCase (e.g., skillTree.yaml) and update all places that reference it (any
build scripts, CI, docs, generated metadata such as generated_from or other
tooling configs) to point to the new name; if generation tooling produces the
snake_case, either adjust the generator configuration to emit camelCase or add a
post-generation rename step and update any references to the file (look for
mentions of "skill_tree.yaml" in repo and in consumers that parse generated
artifacts).

In `@packages/next/skills/nextjs-app-router/SKILL.md`:
- Around line 32-48: The fenced code block showing the project tree in SKILL.md
lacks a language identifier; update the opening triple-backtick for that block
to include a language such as text or plaintext (e.g., change ``` to ```text) so
the file tree (the block that begins with "." and the lines under β”œβ”€β”€ app and
β”œβ”€β”€ trpc) is properly highlighted and recognized by tooling.

In `@packages/next/skills/nextjs-pages-router/SKILL.md`:
- Around line 27-43: Update the fenced code block in SKILL.md that contains the
project tree by adding a language identifier (e.g., "text" or "plaintext") to
the opening triple backticks so the block becomes ```text; this applies to the
directory-tree block shown under src/pages / src/server / src/utils to enable
proper syntax highlighting and tooling.

In `@packages/server/skills/adapter-express/SKILL.md`:
- Line 74: Update the SKILL.md description to reference the actual Express
types: change the mention of "req (IncomingMessage) and res (ServerResponse)" to
"req (express.Request) and res (express.Response)" to match the typing of
CreateExpressContextOptions (NodeHTTPCreateContextFnOptions<express.Request,
express.Response>) and make Express-specific properties like req.query and
req.params clear to readers.

In `@packages/server/skills/auth/SKILL.md`:
- Line 316: The line "Source: maintainer interview" in SKILL.md should be
replaced with a durable, verifiable reference; locate the string in
packages/server/skills/auth/SKILL.md (the security recommendation block where
"Source: maintainer interview" appears) and replace it with a public URL or
citation (e.g., an issue, PR, official changelog, advisory, or discussion) that
documents the claim, or add an explicit note describing why no public reference
exists; ensure the replacement includes the URL or reference title so auditors
can verify the claim.
- Line 1: Rename the file SKILL.md to a camelCase name (e.g., skill.md or
authSkill.md) to match the repository filename convention; update any references
to SKILL.md (links, imports, documentation pointers) to the new filename and
ensure CI/linting no longer flags the file; keep the same file content and only
change the filename and references to maintain compatibility.

In `@packages/server/skills/error-handling/SKILL.md`:
- Around line 1-3: The file name SKILL.md violates the repo camelCase rule;
rename it to a camelCase filename such as errorHandling.md or
skillsErrorHandling.md, update any references to SKILL.md (docs, README links,
import/require strings, CI/glob patterns) to the new name, and verify that
tooling or MDX imports (if any) still resolve correctly; commit the rename as a
filesystem move so history is preserved and run the repo lint/CI to confirm no
remaining references to SKILL.md.

In `@packages/server/skills/subscriptions/SKILL.md`:
- Line 364: The line in SKILL.md that currently reads "Source: maintainer
interview" should be replaced with a stable, linkable reference (e.g., an issue,
discussion, RFC, or documentation URL) so the provenance is auditable; locate
the string "Source: maintainer interview" in SKILL.md and replace it with a full
citation (preferably a permalink to an issue/discussion/RFC) and include a short
label like "Source: [Issue `#1234`](https://...)" or "Source: RFC XYZ
(https://...)" to preserve readability and future traceability.
- Line 1: The file SKILL.md violates the repo's camelCase filename rule; either
rename the file to camelCase (e.g., skill.md) and update any imports/tooling
references that expect SKILL.md, or if the uppercase name is required by a
generator/tool, add an explicit exception to the repo guideline mentioning
"packages/server/skills/subscriptions/SKILL.md" (or the SKILL.md convention) and
update documentation; locate the file by the unique symbol SKILL.md and ensure
all CI/tooling configs and any references are updated accordingly.

In `@www/docs/main/quickstart.mdx`:
- Around line 80-86: The AI tip block (":::tip AI Agents ... npx
`@tanstack/intent`@latest install :::") is duplicated across docs; extract it into
a shared MDX partial/component (e.g., create a partial like AiAgentTip or
docs/components/AiAgentTip.mdx) and replace each inline block (including the
occurrence in quickstart.mdx) with the shared import/usage (such as <AiAgentTip
/> or an MDX include), updating the docs build to import that partial so future
edits only require changing the single shared component.
πŸͺ„ Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
βš™οΈ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 9db8a62a-729e-4eab-bc9e-697a62ca128f

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between 929561d and dfeda8b.

β›” Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
πŸ“’ Files selected for processing (52)
  • .gitignore
  • README.md
  • _artifacts/domain_map.yaml
  • _artifacts/skill_spec.md
  • _artifacts/skill_tree.yaml
  • package.json
  • packages/client/README.md
  • packages/client/package.json
  • packages/client/skills/client-setup/SKILL.md
  • packages/client/skills/links/SKILL.md
  • packages/client/skills/links/references/link-options.md
  • packages/client/skills/superjson/SKILL.md
  • packages/next/README.md
  • packages/next/package.json
  • packages/next/skills/nextjs-app-router/SKILL.md
  • packages/next/skills/nextjs-pages-router/SKILL.md
  • packages/openapi/README.md
  • packages/openapi/skills/openapi/SKILL.md
  • packages/server/README.md
  • packages/server/package.json
  • packages/server/skills/adapter-aws-lambda/SKILL.md
  • packages/server/skills/adapter-express/SKILL.md
  • packages/server/skills/adapter-fastify/SKILL.md
  • packages/server/skills/adapter-fetch/SKILL.md
  • packages/server/skills/adapter-standalone/SKILL.md
  • packages/server/skills/auth/SKILL.md
  • packages/server/skills/caching/SKILL.md
  • packages/server/skills/error-handling/SKILL.md
  • packages/server/skills/middlewares/SKILL.md
  • packages/server/skills/non-json-content-types/SKILL.md
  • packages/server/skills/server-setup/SKILL.md
  • packages/server/skills/server-side-calls/SKILL.md
  • packages/server/skills/service-oriented-architecture/SKILL.md
  • packages/server/skills/subscriptions/SKILL.md
  • packages/server/skills/trpc-router/SKILL.md
  • packages/server/skills/validators/SKILL.md
  • packages/tanstack-react-query/README.md
  • packages/tanstack-react-query/package.json
  • packages/tanstack-react-query/skills/react-query-classic-migration/SKILL.md
  • packages/tanstack-react-query/skills/react-query-setup/SKILL.md
  • www/docs/client/nextjs/app-router/setup.mdx
  • www/docs/client/nextjs/pages-router/setup.mdx
  • www/docs/client/openapi.md
  • www/docs/client/react/setup.mdx
  • www/docs/client/tanstack-react-query/setup.mdx
  • www/docs/client/vanilla/setup.mdx
  • www/docs/main/quickstart.mdx
  • www/docs/server/adapters/aws-lambda.md
  • www/docs/server/adapters/express.md
  • www/docs/server/adapters/fastify.md
  • www/docs/server/adapters/fetch.mdx
  • www/docs/server/adapters/standalone.md

Comment thread _artifacts/skill_spec.md Resolved
Comment thread packages/client/package.json Resolved
Comment thread packages/next/package.json Resolved
@pkg-pr-new

pkg-pr-new Bot commented Mar 15, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

@trpc/client

npm i https://pkg.pr.new/@trpc/client@7252

@trpc/next

npm i https://pkg.pr.new/@trpc/next@7252

@trpc/openapi

npm i https://pkg.pr.new/@trpc/openapi@7252

@trpc/react-query

npm i https://pkg.pr.new/@trpc/react-query@7252

@trpc/server

npm i https://pkg.pr.new/@trpc/server@7252

@trpc/tanstack-react-query

npm i https://pkg.pr.new/@trpc/tanstack-react-query@7252

@trpc/upgrade

npm i https://pkg.pr.new/@trpc/upgrade@7252

commit: cab33f2

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 12

♻️ Duplicate comments (8)
packages/server/skills/caching/SKILL.md (1)

69-70: ⚠️ Potential issue | 🟠 Major

Use strict prefix matching for public-route cache eligibility.

includes('public') can misclassify non-public procedure paths and cause unintended caching. Use anchored prefix logic (e.g., startsWith('public.')) in both examples.

Proposed doc fix
-    const allPublic = paths && paths.every((path) => path.includes('public'));
+    const allPublic = paths?.every((path) => path.startsWith('public.')) ?? false;

Also applies to: 104-105

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/caching/SKILL.md` around lines 69 - 70, The check that
determines public-route cache eligibility uses loose matching paths.every((path)
=> path.includes('public')) which misclassifies routes; update the logic that
computes allPublic (and the analogous check at the other example) to use strict
anchored prefix matching such as checking path.startsWith('public.') or a regex
like /^public\./ so only procedures with the "public." prefix are considered
public; update the references to paths and allPublic (and the duplicate at the
second example) accordingly.
packages/server/skills/adapter-standalone/SKILL.md (1)

132-134: ⚠️ Potential issue | 🟑 Minor

Define TLS credential variables before creating the HTTP/2 server.

On Line 132, the snippet uses tlsKey/tlsCert but never defines them, so the example is not runnable as written.

Suggested patch
+import { readFileSync } from 'node:fs';
+
+const tlsKey = readFileSync('./certs/server.key');
+const tlsCert = readFileSync('./certs/server.crt');
+
 const server = http2.createSecureServer(
   { key: tlsKey, cert: tlsCert },
   (req, res) => {
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/adapter-standalone/SKILL.md` around lines 132 - 134,
The snippet uses tlsKey and tlsCert when calling http2.createSecureServer but
those variables are never defined; define and initialize tlsKey and tlsCert
before creating the server (for example, load them from files or generate/test
certs) and ensure the code that reads them runs prior to calling
http2.createSecureServer; update the example around the server variable and the
createSecureServer call to reference the newly-initialized tlsKey and tlsCert
variables so the snippet is runnable.
packages/server/skills/server-side-calls/SKILL.md (1)

131-132: ⚠️ Potential issue | 🟠 Major

byId call doesn’t match the documented router API

This example calls caller.post.byId(...), but the router shown earlier only defines add and list, so the snippet is not runnable as written.

Suggested doc fix
-    const post = await caller.post.byId({ id: req.query.id as string });
-    res.status(200).json({ data: { postTitle: post.title } });
+    const posts = await caller.post.list();
+    const post = posts.find((p) => p.id === String(req.query.id));
+    if (!post) {
+      res.status(404).json({ error: { message: 'Post not found' } });
+      return;
+    }
+    res.status(200).json({ data: { postTitle: post.title } });
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/server-side-calls/SKILL.md` around lines 131 - 132,
The example calls caller.post.byId(...) which doesn't exist on the documented
router (router only defines add and list); update the snippet to use an existing
router method (e.g., call caller.post.list(...) and pick the matching post by id
from the returned list, or use caller.post.add(...) if demonstrating creation),
or update the router to expose a byId procedure; specifically modify the code
that references caller.post.byId to instead call caller.post.list (or add a byId
procedure to the router) so the example matches the router's defined API.
packages/server/skills/subscriptions/SKILL.md (1)

7-8: ⚠️ Potential issue | 🟑 Minor

Fix incorrect import attribution in the skill description.

Line 7-Line 8 still attributes createWSClient to @trpc/server/adapters/ws. It should separate sources as:

  • wsLink, createWSClient from @trpc/client
  • applyWSSHandler from @trpc/server/adapters/ws
Suggested patch
-  reconnection recovery with lastEventId. WebSocket via wsLink, createWSClient,
-  applyWSSHandler from `@trpc/server/adapters/ws`. Configure SSE ping with
+  reconnection recovery with lastEventId. WebSocket via wsLink, createWSClient
+  from `@trpc/client`, and applyWSSHandler from `@trpc/server/adapters/ws`.
+  Configure SSE ping with
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/subscriptions/SKILL.md` around lines 7 - 8, Update the
import attribution in the skill description so the sources are correct: mention
that wsLink and createWSClient come from `@trpc/client` and that applyWSSHandler
comes from `@trpc/server/adapters/ws`; edit the text around the listed symbols
(wsLink, createWSClient, applyWSSHandler) in SKILL.md to reflect this separation
and ensure the description reads that wsLink/createWSClient are from
`@trpc/client` while applyWSSHandler is from `@trpc/server/adapters/ws`.
packages/openapi/skills/openapi/SKILL.md (1)

220-227: ⚠️ Potential issue | 🟠 Major

Missing Document type import in EJSON example.

Document is used in EJSON.deserialize(value as Document) but not imported, so this snippet won’t type-check as written.

Suggested fix
 import type { TRPCDataTransformer } from '@trpc/server';
 import { EJSON } from 'bson';
+import type { Document } from 'bson';
 
 export const ejsonTransformer: TRPCDataTransformer = {
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/openapi/skills/openapi/SKILL.md` around lines 220 - 227, The example
uses Document in EJSON.deserialize(value as Document) but never imports its
type; update the snippet for ejsonTransformer to import the Document type (e.g.
add "import type { Document } from 'bson'") and use that imported type in the
cast so the code type-checks, keeping the existing symbols ejsonTransformer and
EJSON.deserialize intact.
packages/next/package.json (1)

151-153: ⚠️ Potential issue | πŸ”΄ Critical

Verify the intent bin target is committed and publishable.

This manifest now declares intent: "./bin/intent.js". If packages/next/bin/intent.js is missing, the installed CLI entrypoint will be broken.

#!/bin/bash
set -euo pipefail

manifest="packages/next/package.json"
target="packages/next/bin/intent.js"

echo "bin.intent from ${manifest}:"
jq -r '.bin.intent // empty' "$manifest"

echo
if [ -f "$target" ]; then
  echo "OK: found $target"
else
  echo "MISSING: $target"
fi
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/next/package.json` around lines 151 - 153, The package manifest
declares a CLI bin "intent" pointing to "./bin/intent.js" but the file may be
missing; ensure the published package contains the executable at
packages/next/bin/intent.js or update the "bin.intent" entry in package.json to
the correct existing path. Locate the "bin" object in packages/next/package.json
and either add/commit the executable script at the referenced path (with
executable permissions and a proper shebang) or change the "intent" value to the
actual script that should be the CLI entrypoint (e.g., an existing file used by
the package).
packages/tanstack-react-query/skills/react-query-setup/SKILL.md (1)

287-290: ⚠️ Potential issue | 🟠 Major

Hooks example is invalid: useTRPCClient() is called inside an async function.

This teaches a React-hooks-invalid pattern. useTRPCClient() must be called at the top level of a component or custom hook.

Suggested doc snippet fix
-import { useTRPCClient } from '../utils/trpc';
-
-async function DirectCall() {
-  const client = useTRPCClient();
-  const result = await client.user.byId.query({ id: '1' });
-}
+import { useTRPCClient } from '../utils/trpc';
+
+function DirectCall() {
+  const client = useTRPCClient();
+
+  async function onClick() {
+    const result = await client.user.byId.query({ id: '1' });
+    console.log(result);
+  }
+
+  return <button onClick={() => void onClick()}>Fetch user</button>;
+}
#!/bin/bash
set -euo pipefail

rg -nP --multiline \
'async function\s+\w+\s*\([^)]*\)\s*\{[\s\S]*?\buseTRPCClient\s*\(' \
packages/tanstack-react-query/skills/react-query-setup/SKILL.md

Based on learnings: Applies to **/*.tsx : Follow React Hooks rules (React Compiler compatible patterns).

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/tanstack-react-query/skills/react-query-setup/SKILL.md` around lines
287 - 290, The snippet uses useTRPCClient() inside an async function DirectCall
which violates React Hooks rules; change the pattern so useTRPCClient is invoked
at the top level of a React component or a custom hook (e.g., move
useTRPCClient() into a component or a custom hook named useDirectCallClient) and
perform the async call (client.user.byId.query) inside an effect or an event
handler (useEffect or an onClick async handler) instead of inside the async
function that calls the hook. Ensure DirectCall becomes either a React component
or that the hook call is hoisted to a top-level custom hook so useTRPCClient is
never called conditionally or inside an async function body.
packages/tanstack-react-query/package.json (1)

87-89: ⚠️ Potential issue | πŸ”΄ Critical

Verify this intent CLI target exists before publish.

"intent": "./bin/intent.js" requires packages/tanstack-react-query/bin/intent.js to be present in the package contents; otherwise installs expose a broken command.

#!/bin/bash
set -euo pipefail

manifest="packages/tanstack-react-query/package.json"
target="packages/tanstack-react-query/bin/intent.js"

echo "bin.intent from ${manifest}:"
jq -r '.bin.intent // empty' "$manifest"

echo
if [ -f "$target" ]; then
  echo "OK: found $target"
else
  echo "MISSING: $target"
fi
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/tanstack-react-query/package.json` around lines 87 - 89, The
package.json declares a CLI bin "intent": "./bin/intent.js" but the target
script is missing from the package contents; either add the missing executable
script named bin/intent.js (with a proper shebang and executable bit) into the
package, or remove/update the "bin.intent" entry in package.json to point to an
existing script and ensure the file is included in the package (or listed in
"files" or publish pipeline). Verify the package.json "bin" mapping and the
exact script name "intent" match and run the provided check to confirm the
missing bin is resolved before publishing.
🧹 Nitpick comments (7)
packages/server/skills/error-handling/SKILL.md (1)

1-1: Rename SKILL.md to match the repository filename convention.

This Markdown filename is uppercase and does not follow the configured camelCase convention for *.md files.

As per coding guidelines "**/*.{ts,tsx,md,mdx}: Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests)".

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/error-handling/SKILL.md` at line 1, The file SKILL.md
uses an uppercase name and must be renamed to follow the repo's camelCase naming
rule; rename SKILL.md to skill.md using git mv to preserve history and update
any references to SKILL.md (imports, docs, README links, index lists, or CI/glob
patterns) so they point to skill.md; ensure any tooling or tests that match
"*.md" filenames still resolve after the rename and run the build/tests to
confirm nothing breaks.
packages/server/skills/subscriptions/SKILL.md (1)

393-393: Use a stable, linkable source instead of β€œmaintainer interview.”

Line 393 is hard to verify and weak for long-term maintenance. Prefer a concrete doc/issue/discussion URL in Source:.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/subscriptions/SKILL.md` at line 393, Replace the
ambiguous "Source: maintainer interview" at the Source: entry (around the line
containing Source:) with a stable, linkable reference: locate the Source: field
in packages/server/skills/subscriptions/SKILL.md and replace the text
"maintainer interview" with a concrete URL or identifier (e.g., a long-lived
issue, RFC, design doc, or discussion link) and include a short parenthetical
note indicating the date or author if needed for context.
packages/server/skills/adapter-aws-lambda/SKILL.md (1)

1-1: Rename SKILL.md to a camelCase filename.

This file name does not follow the repository filename convention for .md files.

As per coding guidelines: "**/*.{ts,tsx,md,mdx}: Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests)".

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/adapter-aws-lambda/SKILL.md` at line 1, Rename the
file SKILL.md to a camelCase name (for example skill.md or
adapterAwsLambdaSkill.md) so it follows the repository convention for .md
filenames; after renaming, update any references/imports or documentation links
that point to SKILL.md (search for "SKILL.md" in the repo) to the new filename
to avoid broken links.
packages/next/skills/nextjs-pages-router/SKILL.md (1)

1-1: Rename file to match markdown filename convention.

SKILL.md does not follow the camelCase filename rule for markdown files.

As per coding guidelines **/*.{ts,tsx,md,mdx}: Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests).

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/next/skills/nextjs-pages-router/SKILL.md` at line 1, The file
SKILL.md violates the repository's camelCase filename rule for markdown files;
rename SKILL.md to a camelCase name (for example nextjsPagesRouter.md or
nextjs-pages-router.md if dashes are allowed by project convention) so it
matches the pattern **/*.{ts,tsx,md,mdx} and update any references to SKILL.md
(imports, README links, package manifests) to point to the new filename; ensure
you do not use disallowed uppercase-only acronyms unless listed as exceptions.
packages/server/skills/validators/SKILL.md (2)

4-7: Consider adding an example for Standard Schema protocol.

The description mentions "Standard Schema protocol support" but no example demonstrates this feature. Adding a brief code snippet showing Standard Schema usage would make the documentation more complete and help users understand this capability.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/validators/SKILL.md` around lines 4 - 7, Add a short
example demonstrating the "Standard Schema protocol" usage in SKILL.md: show how
to define a standard schema object (e.g., an object with "type"/"properties" or
a minimal { validate: (data) => ... } contract), then pass it into the existing
.input()/.output() chain to validate requests and responses; reference the
.input(), .output() methods and indicate how the standard schema is adapted to
the validator (e.g., wrapped or mapped) so readers can see how to plug a
Standard Schema into the current validation flow.

1-1: File naming convention observation.

The file is named SKILL.md (all caps), which deviates from the camelCase convention for .md files. However, this appears to be an intentional naming pattern for the new skills/AI agents feature being introduced across the entire PR, similar to how README.md is conventionally capitalized. If this is established as a project convention for skill files, consider documenting it in the coding guidelines.

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/server/skills/validators/SKILL.md` at line 1, The SKILL.md filename
uses all-caps which differs from camelCase .md files; if this capitalization is
an intentional project convention for skill/agent metadata, update the coding
guidelines to document that SKILL.md (and any similar skill manifest files)
should be named in all caps and used consistently across the repo;
alternatively, if you prefer camelCase, rename SKILL.md to skill.md and update
any code or references that load or validate SKILL.md (search for β€œSKILL.md”,
skill loader functions, and README.md references) to reflect the chosen
convention.
packages/client/skills/superjson/SKILL.md (1)

1-282: Consider filename convention compliance.

The file is named SKILL.md (uppercase), which appears to deviate from the camelCase guideline for .md files. The guideline lists exceptions for acronyms like TRPC/RPC/HTTP/JSON, but SKILL is not listed.

However, this may be intentional as a special file type (similar to README.md, CHANGELOG.md conventions). Since this PR introduces the skills/metadata system with many SKILL.md files, please confirm whether SKILL.md should be added as an explicit exception to the naming guideline.

As per coding guidelines: "Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests)".

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/client/skills/superjson/SKILL.md` around lines 1 - 282, The SKILL.md
filename deviates from the camelCase guideline; either add "SKILL.md" as an
explicit exception in the repository's filename convention documentation (so the
new skills/metadata system is allowed), or rename the file and all other skill
files to a camelCase variant (e.g., skill.md or skillsMetadata.md) and update
any tooling/tests that validate filenames; locate references to "SKILL.md" in
the repo and the camelCase naming guideline text to apply the consistent fix.
πŸ€– Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/client/skills/superjson/SKILL.md`:
- Line 11: The file SKILL.md should be renamed to lowercase "skill.md" to match
the markdown naming convention; rename the file (SKILL.md -> skill.md) and
update any references or links to SKILL.md in the repo (docs, README, imports,
or CI) to point to skill.md so nothing breaks, leaving the existing frontmatter
(library_version: '11.13.4') and content unchanged.

In `@packages/next/skills/nextjs-pages-router/SKILL.md`:
- Around line 27-43: The fenced tree block in SKILL.md is missing a code fence
language tag; update the triple-backtick fence that surrounds the directory tree
(the block starting with ".β”œβ”€β”€ src") to include a language identifier (e.g.,
"text") so the block becomes ```text, ensuring markdownlint MD040 is satisfied.
- Around line 327-329: The CORS example is overly permissive: change the three
res.setHeader calls so they do not use wildcards; instead derive the allowed
origin from the incoming request origin (e.g., compare req.headers.origin
against a whitelist) and set Access-Control-Allow-Origin to that origin, set
Access-Control-Allow-Credentials to true if you use cookies/sessions, and
replace Access-Control-Allow-Headers: '*' with an explicit list (e.g.,
"Content-Type, Authorization, X-Requested-With, Accept") and keep
Access-Control-Allow-Methods to the needed verbs; update the preflight logic
that uses res.setHeader to validate origin against your configured
allowedOrigins and return 204 for OPTIONS when origin is not allowed.
- Around line 49-51: The install instruction in SKILL.md is missing the
superjson package required by the examples; update the npm install command (the
snippet that currently lists `@trpc/server` `@trpc/client` `@trpc/react-query`
`@trpc/next` `@tanstack/react-query` zod) to also include superjson so the
imports/transformer usage in getStaticProps and getServerSideProps (the examples
that import and use superjson as the transformer) will work when followed
verbatim.

In `@packages/openapi/skills/openapi/SKILL.md`:
- Line 262: Update the README text to use the correct two-argument signature for
the transformer helper: replace references to configureTRPCHeyApiClient({
transformer }) with the actual API form configureTRPCHeyApiClient(client, {
transformer }) so the client instance is passed as the first parameter; update
the mention on line referencing configureTRPCHeyApiClient in SKILL.md and ensure
other examples (the ones around the earlier mentions) consistently use
configureTRPCHeyApiClient(client, { transformer }) instead of the single-object
form.

In `@packages/server/skills/adapter-aws-lambda/SKILL.md`:
- Around line 143-151: The documentation currently presents httpBatchLink and
httpLink together under "Correct" which can imply using both; update SKILL.md to
present two explicit alternatives: Option A showing only httpBatchLink with its
comment (e.g., "Single catch-all resource (/ {proxy+})") and Option B showing
only httpLink with its comment (e.g., "Per-procedure resources with httpLink (no
batching)"), and add a short clarifying line that these are mutually exclusive
choices so readers pick one link implementation (reference the symbols
httpBatchLink and httpLink and the surrounding "Correct" section).

In `@packages/server/skills/adapter-fetch/SKILL.md`:
- Line 1: Update the camelCase filename guideline to explicitly list "SKILL.md"
as an allowed exception alongside existing acronyms (e.g., TRPC, RPC, HTTP,
JSON); edit the guideline text that enumerates allowed uppercase/acronym
filenames so it mentions SKILL.md and, where relevant, note that repository
skill discovery files named SKILL.md are intentional and should not be flagged
during reviews.

In `@packages/server/skills/trpc-router/SKILL.md`:
- Line 1: Rename the file named SKILL.md to a camelCase name (e.g., skill.md or
trpcSkill.md) to comply with the repo rule for .md filenames; update any
references or links that point to SKILL.md (search for "SKILL.md" in docs or
README) so they match the new camelCase filename and ensure the change preserves
existing content and links.

In `@packages/tanstack-react-query/skills/react-query-classic-migration/SKILL.md`:
- Line 33: Replace the placeholder CLI label `Migrate Hooks to xxxOptions API`
in SKILL.md with the exact option text shown by `npx `@trpc/upgrade`` (copy the
prompt string verbatim), ensuring the documentation matches the actual CLI
prompt; update the literal `Migrate Hooks to xxxOptions API` wherever it appears
in the file to the exact CLI option label.
- Line 174: Update the incorrect guidance to state that queryOptions(input?)
takes the tRPC procedure input as the first argument while
mutationOptions(options?) accepts TanStack Query mutation options
(onSuccess/onError/etc.) and does not take the mutation variables; mutation
variables are supplied later to mutate(...) (e.g., mutate({ name: 'Jerry' }));
adjust the text referencing queryOptions and mutationOptions to match the
example where mutationOptions() is called without arguments and input is passed
into mutate.
- Around line 71-75: The import and variable names in the provider example are
inconsistent: you're importing `trpc` (which doesn't exist in
`createTRPCContext` exports) and using an undefined `trpcClient` when rendering
`<TRPCProvider trpcClient={trpcClient} ...>`. Fix by importing only
`TRPCProvider` and `useTRPC` from the utils, and explicitly create a
`trpcClient` via the canonical `createTRPCClient<AppRouter>()` (or reference an
existing `trpcClient` factory) before passing it to `TRPCProvider`; ensure
`QueryClientProvider` still receives the `queryClient` variable used in the
snippet.

In `@packages/tanstack-react-query/skills/react-query-setup/SKILL.md`:
- Line 1: The file name SKILL.md violates the camelCase markdown naming rule;
rename SKILL.md to a camelCase filename (e.g., skill.md or reactQuerySkill.md)
and update any references to SKILL.md in the repo (imports, docs, CI configs) to
the new name, or alternatively add "SKILL.md" to your linting/guideline
exceptions configuration if the uppercase form is required by tooling; ensure
the change is reflected wherever the symbol "SKILL.md" is referenced so checks
and links continue to work.

---

Duplicate comments:
In `@packages/next/package.json`:
- Around line 151-153: The package manifest declares a CLI bin "intent" pointing
to "./bin/intent.js" but the file may be missing; ensure the published package
contains the executable at packages/next/bin/intent.js or update the
"bin.intent" entry in package.json to the correct existing path. Locate the
"bin" object in packages/next/package.json and either add/commit the executable
script at the referenced path (with executable permissions and a proper shebang)
or change the "intent" value to the actual script that should be the CLI
entrypoint (e.g., an existing file used by the package).

In `@packages/openapi/skills/openapi/SKILL.md`:
- Around line 220-227: The example uses Document in EJSON.deserialize(value as
Document) but never imports its type; update the snippet for ejsonTransformer to
import the Document type (e.g. add "import type { Document } from 'bson'") and
use that imported type in the cast so the code type-checks, keeping the existing
symbols ejsonTransformer and EJSON.deserialize intact.

In `@packages/server/skills/adapter-standalone/SKILL.md`:
- Around line 132-134: The snippet uses tlsKey and tlsCert when calling
http2.createSecureServer but those variables are never defined; define and
initialize tlsKey and tlsCert before creating the server (for example, load them
from files or generate/test certs) and ensure the code that reads them runs
prior to calling http2.createSecureServer; update the example around the server
variable and the createSecureServer call to reference the newly-initialized
tlsKey and tlsCert variables so the snippet is runnable.

In `@packages/server/skills/caching/SKILL.md`:
- Around line 69-70: The check that determines public-route cache eligibility
uses loose matching paths.every((path) => path.includes('public')) which
misclassifies routes; update the logic that computes allPublic (and the
analogous check at the other example) to use strict anchored prefix matching
such as checking path.startsWith('public.') or a regex like /^public\./ so only
procedures with the "public." prefix are considered public; update the
references to paths and allPublic (and the duplicate at the second example)
accordingly.

In `@packages/server/skills/server-side-calls/SKILL.md`:
- Around line 131-132: The example calls caller.post.byId(...) which doesn't
exist on the documented router (router only defines add and list); update the
snippet to use an existing router method (e.g., call caller.post.list(...) and
pick the matching post by id from the returned list, or use caller.post.add(...)
if demonstrating creation), or update the router to expose a byId procedure;
specifically modify the code that references caller.post.byId to instead call
caller.post.list (or add a byId procedure to the router) so the example matches
the router's defined API.

In `@packages/server/skills/subscriptions/SKILL.md`:
- Around line 7-8: Update the import attribution in the skill description so the
sources are correct: mention that wsLink and createWSClient come from
`@trpc/client` and that applyWSSHandler comes from `@trpc/server/adapters/ws`; edit
the text around the listed symbols (wsLink, createWSClient, applyWSSHandler) in
SKILL.md to reflect this separation and ensure the description reads that
wsLink/createWSClient are from `@trpc/client` while applyWSSHandler is from
`@trpc/server/adapters/ws`.

In `@packages/tanstack-react-query/package.json`:
- Around line 87-89: The package.json declares a CLI bin "intent":
"./bin/intent.js" but the target script is missing from the package contents;
either add the missing executable script named bin/intent.js (with a proper
shebang and executable bit) into the package, or remove/update the "bin.intent"
entry in package.json to point to an existing script and ensure the file is
included in the package (or listed in "files" or publish pipeline). Verify the
package.json "bin" mapping and the exact script name "intent" match and run the
provided check to confirm the missing bin is resolved before publishing.

In `@packages/tanstack-react-query/skills/react-query-setup/SKILL.md`:
- Around line 287-290: The snippet uses useTRPCClient() inside an async function
DirectCall which violates React Hooks rules; change the pattern so useTRPCClient
is invoked at the top level of a React component or a custom hook (e.g., move
useTRPCClient() into a component or a custom hook named useDirectCallClient) and
perform the async call (client.user.byId.query) inside an effect or an event
handler (useEffect or an onClick async handler) instead of inside the async
function that calls the hook. Ensure DirectCall becomes either a React component
or that the hook call is hoisted to a top-level custom hook so useTRPCClient is
never called conditionally or inside an async function body.

---

Nitpick comments:
In `@packages/client/skills/superjson/SKILL.md`:
- Around line 1-282: The SKILL.md filename deviates from the camelCase
guideline; either add "SKILL.md" as an explicit exception in the repository's
filename convention documentation (so the new skills/metadata system is
allowed), or rename the file and all other skill files to a camelCase variant
(e.g., skill.md or skillsMetadata.md) and update any tooling/tests that validate
filenames; locate references to "SKILL.md" in the repo and the camelCase naming
guideline text to apply the consistent fix.

In `@packages/next/skills/nextjs-pages-router/SKILL.md`:
- Line 1: The file SKILL.md violates the repository's camelCase filename rule
for markdown files; rename SKILL.md to a camelCase name (for example
nextjsPagesRouter.md or nextjs-pages-router.md if dashes are allowed by project
convention) so it matches the pattern **/*.{ts,tsx,md,mdx} and update any
references to SKILL.md (imports, README links, package manifests) to point to
the new filename; ensure you do not use disallowed uppercase-only acronyms
unless listed as exceptions.

In `@packages/server/skills/adapter-aws-lambda/SKILL.md`:
- Line 1: Rename the file SKILL.md to a camelCase name (for example skill.md or
adapterAwsLambdaSkill.md) so it follows the repository convention for .md
filenames; after renaming, update any references/imports or documentation links
that point to SKILL.md (search for "SKILL.md" in the repo) to the new filename
to avoid broken links.

In `@packages/server/skills/error-handling/SKILL.md`:
- Line 1: The file SKILL.md uses an uppercase name and must be renamed to follow
the repo's camelCase naming rule; rename SKILL.md to skill.md using git mv to
preserve history and update any references to SKILL.md (imports, docs, README
links, index lists, or CI/glob patterns) so they point to skill.md; ensure any
tooling or tests that match "*.md" filenames still resolve after the rename and
run the build/tests to confirm nothing breaks.

In `@packages/server/skills/subscriptions/SKILL.md`:
- Line 393: Replace the ambiguous "Source: maintainer interview" at the Source:
entry (around the line containing Source:) with a stable, linkable reference:
locate the Source: field in packages/server/skills/subscriptions/SKILL.md and
replace the text "maintainer interview" with a concrete URL or identifier (e.g.,
a long-lived issue, RFC, design doc, or discussion link) and include a short
parenthetical note indicating the date or author if needed for context.

In `@packages/server/skills/validators/SKILL.md`:
- Around line 4-7: Add a short example demonstrating the "Standard Schema
protocol" usage in SKILL.md: show how to define a standard schema object (e.g.,
an object with "type"/"properties" or a minimal { validate: (data) => ... }
contract), then pass it into the existing .input()/.output() chain to validate
requests and responses; reference the .input(), .output() methods and indicate
how the standard schema is adapted to the validator (e.g., wrapped or mapped) so
readers can see how to plug a Standard Schema into the current validation flow.
- Line 1: The SKILL.md filename uses all-caps which differs from camelCase .md
files; if this capitalization is an intentional project convention for
skill/agent metadata, update the coding guidelines to document that SKILL.md
(and any similar skill manifest files) should be named in all caps and used
consistently across the repo; alternatively, if you prefer camelCase, rename
SKILL.md to skill.md and update any code or references that load or validate
SKILL.md (search for β€œSKILL.md”, skill loader functions, and README.md
references) to reflect the chosen convention.
πŸͺ„ Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
βš™οΈ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 4443c015-f2c3-4df4-b6bb-7936a8af142d

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between dfeda8b and c6f08fe.

πŸ“’ Files selected for processing (41)
  • _artifacts/skill_spec.md
  • packages/client/package.json
  • packages/client/skills/client-setup/SKILL.md
  • packages/client/skills/links/SKILL.md
  • packages/client/skills/links/references/link-options.md
  • packages/client/skills/superjson/SKILL.md
  • packages/next/package.json
  • packages/next/skills/nextjs-app-router/SKILL.md
  • packages/next/skills/nextjs-pages-router/SKILL.md
  • packages/openapi/skills/openapi/SKILL.md
  • packages/server/package.json
  • packages/server/skills/adapter-aws-lambda/SKILL.md
  • packages/server/skills/adapter-express/SKILL.md
  • packages/server/skills/adapter-fastify/SKILL.md
  • packages/server/skills/adapter-fetch/SKILL.md
  • packages/server/skills/adapter-standalone/SKILL.md
  • packages/server/skills/auth/SKILL.md
  • packages/server/skills/caching/SKILL.md
  • packages/server/skills/error-handling/SKILL.md
  • packages/server/skills/middlewares/SKILL.md
  • packages/server/skills/non-json-content-types/SKILL.md
  • packages/server/skills/server-setup/SKILL.md
  • packages/server/skills/server-side-calls/SKILL.md
  • packages/server/skills/service-oriented-architecture/SKILL.md
  • packages/server/skills/subscriptions/SKILL.md
  • packages/server/skills/trpc-router/SKILL.md
  • packages/server/skills/validators/SKILL.md
  • packages/tanstack-react-query/package.json
  • packages/tanstack-react-query/skills/react-query-classic-migration/SKILL.md
  • packages/tanstack-react-query/skills/react-query-setup/SKILL.md
  • www/docs/client/nextjs/app-router/setup.mdx
  • www/docs/client/nextjs/pages-router/setup.mdx
  • www/docs/client/openapi.md
  • www/docs/client/react/setup.mdx
  • www/docs/client/tanstack-react-query/setup.mdx
  • www/docs/client/vanilla/setup.mdx
  • www/docs/server/adapters/aws-lambda.md
  • www/docs/server/adapters/express.md
  • www/docs/server/adapters/fastify.md
  • www/docs/server/adapters/fetch.mdx
  • www/docs/server/adapters/standalone.md
βœ… Files skipped from review due to trivial changes (3)
  • www/docs/client/nextjs/pages-router/setup.mdx
  • www/docs/client/nextjs/app-router/setup.mdx
  • www/docs/server/adapters/express.md
🚧 Files skipped from review as they are similar to previous changes (20)
  • www/docs/client/openapi.md
  • packages/client/package.json
  • packages/client/skills/links/references/link-options.md
  • packages/client/skills/links/SKILL.md
  • www/docs/client/tanstack-react-query/setup.mdx
  • packages/server/skills/server-setup/SKILL.md
  • packages/server/skills/service-oriented-architecture/SKILL.md
  • www/docs/server/adapters/fetch.mdx
  • packages/server/package.json
  • packages/client/skills/client-setup/SKILL.md
  • packages/server/skills/adapter-express/SKILL.md
  • packages/server/skills/auth/SKILL.md
  • packages/server/skills/adapter-fastify/SKILL.md
  • packages/server/skills/non-json-content-types/SKILL.md
  • www/docs/server/adapters/standalone.md
  • www/docs/client/vanilla/setup.mdx
  • packages/next/skills/nextjs-app-router/SKILL.md
  • packages/server/skills/middlewares/SKILL.md
  • www/docs/server/adapters/aws-lambda.md
  • _artifacts/skill_spec.md

Comment on lines +49 to +51
```sh
npm install @trpc/server @trpc/client @trpc/react-query @trpc/next @tanstack/react-query zod
```

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

# First, let's check the file size and then read the relevant sections
wc -l packages/next/skills/nextjs-pages-router/SKILL.md

Repository: trpc/trpc

Length of output: 106


🏁 Script executed:

# Read lines 45-55 to see the install command and context
sed -n '45,55p' packages/next/skills/nextjs-pages-router/SKILL.md

Repository: trpc/trpc

Length of output: 233


🏁 Script executed:

# Read lines 190-200 to check for superjson import/usage
sed -n '190,200p' packages/next/skills/nextjs-pages-router/SKILL.md

Repository: trpc/trpc

Length of output: 361


🏁 Script executed:

# Read lines 235-245 to check for superjson import/usage at line 242
sed -n '235,245p' packages/next/skills/nextjs-pages-router/SKILL.md

Repository: trpc/trpc

Length of output: 380


🏁 Script executed:

# Let me check how superjson is being used in the examples (beyond just imports)
# Check a bit more context around line 195
sed -n '195,210p' packages/next/skills/nextjs-pages-router/SKILL.md

Repository: trpc/trpc

Length of output: 455


🏁 Script executed:

# Check context around line 240
sed -n '240,255p' packages/next/skills/nextjs-pages-router/SKILL.md

Repository: trpc/trpc

Length of output: 488


Install command is incomplete for the provided examples.

Line 50 omits superjson, but both examples that follow import and use it as a transformer (Lines 195-203 for getStaticProps and Lines 242-251 for getServerSideProps). Following this setup verbatim will fail.

Suggested fix
-npm install `@trpc/server` `@trpc/client` `@trpc/react-query` `@trpc/next` `@tanstack/react-query` zod
+npm install `@trpc/server` `@trpc/client` `@trpc/react-query` `@trpc/next` `@tanstack/react-query` zod superjson
πŸ“ Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
```sh
npm install @trpc/server @trpc/client @trpc/react-query @trpc/next @tanstack/react-query zod
```
npm install `@trpc/server` `@trpc/client` `@trpc/react-query` `@trpc/next` `@tanstack/react-query` zod superjson
πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/next/skills/nextjs-pages-router/SKILL.md` around lines 49 - 51, The
install instruction in SKILL.md is missing the superjson package required by the
examples; update the npm install command (the snippet that currently lists
`@trpc/server` `@trpc/client` `@trpc/react-query` `@trpc/next` `@tanstack/react-query`
zod) to also include superjson so the imports/transformer usage in
getStaticProps and getServerSideProps (the examples that import and use
superjson as the transformer) will work when followed verbatim.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
packages/next/skills/nextjs-app-router/SKILL.md (1)

1-1: Rename SKILL.md to a camelCase filename to match repo convention.

This file name does not follow the camelCase naming rule for Markdown files.

As per coding guidelines: **/*.{ts,tsx,md,mdx}: Use camelCase for file names (with exceptions like TRPC/RPC/HTTP/JSON acronyms, .config.js, .d.ts, and tests).

πŸ€– Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/next/skills/nextjs-app-router/SKILL.md` at line 1, Rename the file
named SKILL.md to a camelCase filename to follow repo conventions (e.g.,
nextjsAppRouter.md or nextJsAppRouter.md), update any references/imports/usages
of "SKILL.md" accordingly, and ensure the new filename conforms to the
repository pattern for Markdown files.
πŸ€– Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/next/skills/nextjs-app-router/SKILL.md`:
- Around line 32-48: The fenced code block in SKILL.md (the ASCII tree under the
app/trpc/ etc. section) lacks a language tag; update the opening ``` to include
a language such as ```text (or ```bash) so markdownlint MD040 is satisfied and
editor tooling can apply proper renderingβ€”modify the fenced block that contains
the tree diagram in SKILL.md to start with ```text.

---

Nitpick comments:
In `@packages/next/skills/nextjs-app-router/SKILL.md`:
- Line 1: Rename the file named SKILL.md to a camelCase filename to follow repo
conventions (e.g., nextjsAppRouter.md or nextJsAppRouter.md), update any
references/imports/usages of "SKILL.md" accordingly, and ensure the new filename
conforms to the repository pattern for Markdown files.
πŸͺ„ Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
βš™οΈ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: d6a7f9fb-d6bd-4a4a-b50b-dd8f7ec054e2

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between c6f08fe and 3d2ac0d.

πŸ“’ Files selected for processing (3)
  • packages/client/skills/links/SKILL.md
  • packages/client/skills/links/references/link-options.md
  • packages/next/skills/nextjs-app-router/SKILL.md
🚧 Files skipped from review as they are similar to previous changes (2)
  • packages/client/skills/links/SKILL.md
  • packages/client/skills/links/references/link-options.md

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds TanStack Intent β€œskills” and related artifacts to the tRPC repo, plus documentation and CI workflows intended to support AI-agent-driven code generation.

Changes:

  • Added many SKILL.md guides across packages/*/skills plus generated artifacts under _artifacts/.
  • Added an β€œAI Agents” install snippet across multiple docs/READMEs.
  • Added GitHub Actions workflows to validate/check skills and trigger review dispatches; added intent bin stubs + tanstack-intent keywords to several packages.

Reviewed changes

Copilot reviewed 55 out of 62 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
www/docs/server/adapters/standalone.md Adds AI Agents tip with @tanstack/intent install command.
www/docs/server/adapters/fetch.mdx Adds AI Agents tip with @tanstack/intent install command.
www/docs/server/adapters/fastify.md Adds AI Agents tip with @tanstack/intent install command.
www/docs/server/adapters/express.md Adds AI Agents tip with @tanstack/intent install command.
www/docs/server/adapters/aws-lambda.md Adds AI Agents tip with @tanstack/intent install command.
www/docs/main/quickstart.mdx Adds AI Agents tip with @tanstack/intent install command.
www/docs/client/vanilla/setup.mdx Adds AI Agents tip with @tanstack/intent install command.
www/docs/client/tanstack-react-query/setup.mdx Adds AI Agents tip with @tanstack/intent install command.
www/docs/client/react/setup.mdx Adds AI Agents tip with @tanstack/intent install command.
www/docs/client/openapi.md Adds AI Agents tip with @tanstack/intent install command.
www/docs/client/nextjs/pages-router/setup.mdx Adds AI Agents tip with @tanstack/intent install command.
www/docs/client/nextjs/app-router/setup.mdx Adds AI Agents tip with @tanstack/intent install command.
packages/tanstack-react-query/skills/react-query-setup/SKILL.md New TanStack React Query setup skill content.
packages/tanstack-react-query/skills/react-query-classic-migration/SKILL.md New migration skill content.
packages/tanstack-react-query/package.json Adds tanstack-intent keyword + intent bin entry.
packages/tanstack-react-query/bin/intent.js Adds intent bin stub wrapper.
packages/tanstack-react-query/README.md Adds AI Agents section.
packages/server/skills/validators/SKILL.md New validators skill content.
packages/server/skills/trpc-router/SKILL.md New top-level skill router content.
packages/server/skills/subscriptions/SKILL.md New subscriptions skill content.
packages/server/skills/service-oriented-architecture/SKILL.md New SOA skill content.
packages/server/skills/server-side-calls/SKILL.md New server-side calls skill content.
packages/server/skills/server-setup/SKILL.md New server setup skill content.
packages/server/skills/non-json-content-types/SKILL.md New non-JSON content types skill content.
packages/server/skills/middlewares/SKILL.md New middleware skill content.
packages/server/skills/error-handling/SKILL.md New error-handling skill content.
packages/server/skills/caching/SKILL.md New caching skill content.
packages/server/skills/auth/SKILL.md New auth skill content.
packages/server/skills/adapter-standalone/SKILL.md New standalone adapter skill content.
packages/server/skills/adapter-fetch/SKILL.md New fetch adapter skill content.
packages/server/skills/adapter-fastify/SKILL.md New fastify adapter skill content.
packages/server/skills/adapter-express/SKILL.md New express adapter skill content.
packages/server/skills/adapter-aws-lambda/SKILL.md New aws-lambda adapter skill content.
packages/server/package.json Adds tanstack-intent keyword + intent bin entry.
packages/server/bin/intent.js Adds intent bin stub wrapper.
packages/server/README.md Adds AI Agents section.
packages/openapi/skills/openapi/SKILL.md New OpenAPI skill content.
packages/openapi/package.json Adds intent bin + includes skills/bin in published files + adds keyword.
packages/openapi/bin/intent.js Adds intent bin stub wrapper.
packages/openapi/README.md Adds AI Agents section.
packages/next/skills/nextjs-pages-router/SKILL.md New Next.js Pages Router skill content.
packages/next/skills/nextjs-app-router/SKILL.md New Next.js App Router skill content.
packages/next/package.json Adds tanstack-intent keyword + intent bin entry.
packages/next/bin/intent.js Adds intent bin stub wrapper.
packages/next/README.md Adds AI Agents section.
packages/client/skills/superjson/SKILL.md New SuperJSON skill content.
packages/client/skills/links/references/link-options.md New link options reference content.
packages/client/skills/links/SKILL.md New links skill content.
packages/client/skills/client-setup/SKILL.md New client setup skill content.
packages/client/package.json Adds tanstack-intent keyword + intent bin entry.
packages/client/bin/intent.js Adds intent bin stub wrapper.
packages/client/README.md Adds AI Agents section.
package.json Adds @tanstack/intent devDependency.
_artifacts/skill_tree.yaml Adds generated skill tree artifact.
_artifacts/skill_spec.md Adds generated skill spec artifact.
README.md Adds top-level AI Agents section.
.gitignore Ensures packages/*/skills/ and packages/*/bin/ aren’t ignored.
.github/workflows/validate-skills.yml Adds workflow to validate skills on PRs.
.github/workflows/notify-intent.yml Adds workflow to dispatch skill-review triggers on changes.
.github/workflows/check-skills.yml Adds workflow to check skill staleness and open a review PR.
Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

πŸ’‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/next/package.json Resolved
Comment thread packages/openapi/package.json Resolved
Comment thread .github/workflows/notify-intent.yml Resolved
Comment thread packages/server/package.json Resolved
Comment thread packages/client/package.json Resolved

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 57 out of 64 changed files in this pull request and generated 2 comments.

Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

πŸ’‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/openapi/package.json Resolved
Comment thread _artifacts/skill_tree.yaml Resolved

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 57 out of 64 changed files in this pull request and generated 12 comments.

Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

πŸ’‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/workflows/notify-intent.yml Resolved
Comment thread packages/server/package.json Resolved
Comment thread packages/client/package.json Resolved
Comment thread packages/next/package.json Resolved
Comment thread packages/openapi/package.json Resolved
Comment thread packages/client/package.json Resolved
Comment thread packages/next/package.json Resolved
Comment thread packages/openapi/package.json Resolved

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 58 out of 65 changed files in this pull request and generated no new comments.

Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

πŸ’‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 58 out of 65 changed files in this pull request and generated no new comments.

Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

πŸ’‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions

Copy link
Copy Markdown
Contributor

This pull request has been locked because we are very unlikely to see comments on closed issues. If you think, this PR is still necessary, create a new one with the same branch. Thank you.

This branch was successfully deployed

5 active deployments
Preview – www β€” cab33f29 Deployed Mar 20, 2026 by vercel[bot]
Preview – examples-todomvc β€” cab33f29 Deployed Mar 20, 2026 by vercel[bot]
Preview – next-prisma-starter β€” cab33f29 Deployed Mar 20, 2026 by vercel[bot]
Preview – og-image β€” cab33f29 Deployed Mar 20, 2026 by vercel[bot]
Preview – trpc-next-app-dir β€” cab33f29 Deployed Mar 20, 2026 by vercel[bot]
trpc-sse-and-websockets / trpc-pr-7252 β€” cab33f29 Deployed Mar 20, 2026 by railway-app[bot]
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants