Skip to content

Conversation

joaquim-verges
Copy link
Member

@joaquim-verges joaquim-verges commented Oct 9, 2025


PR-Codex overview

This PR focuses on enhancing the payment functionality in the thirdweb package by introducing an optional recipientAddress parameter in the x402 settlePayment method, allowing payments to be directed to a different address from the facilitator.

Detailed summary

  • Added optional recipientAddress parameter to x402 settlePayment.
  • Updated documentation for payTo to clarify its purpose.
  • Modified decodePaymentRequest to include recipientAddress in the output.

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Summary by CodeRabbit

  • New Features
    • Optional recipientAddress for settle payment, allowing payouts to a different recipient.
    • Exposed new in-app wallet types for account conditions and limits.
  • Refactor
    • Payment argument signatures updated to include an optional recipient address.
  • Documentation
    • Updated parameter descriptions to reflect the new recipient address field.

Copy link

changeset-bot bot commented Oct 9, 2025

🦋 Changeset detected

Latest commit: e8f9793

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 4 packages
Name Type
thirdweb Patch
@thirdweb-dev/nebula Patch
@thirdweb-dev/wagmi-adapter Patch
wagmi-inapp Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

vercel bot commented Oct 9, 2025

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

Project Deployment Preview Comments Updated (UTC)
docs-v2 Ready Ready Preview Comment Oct 9, 2025 9:02pm
nebula Ready Ready Preview Comment Oct 9, 2025 9:02pm
thirdweb_playground Canceled Canceled Oct 9, 2025 9:02pm
thirdweb-www Ready Ready Preview Comment Oct 9, 2025 9:02pm
wallet-ui Canceled Canceled Oct 9, 2025 9:02pm

@github-actions github-actions bot added packages SDK Involves changes to the thirdweb SDK labels Oct 9, 2025
Copy link
Member Author


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • merge-queue - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@joaquim-verges joaquim-verges changed the title [x402] Add recipientAddress to payment request and replace deprecated payTo [SDK] Add x402 recipientAddress to payment request and replace deprecated payTo Oct 9, 2025
@joaquim-verges joaquim-verges marked this pull request as ready for review October 9, 2025 18:02
@joaquim-verges joaquim-verges requested review from a team as code owners October 9, 2025 18:02
@joaquim-verges joaquim-verges force-pushed the _x402_Add_recipientAddress_to_payment_request_and_replace_deprecated_payTo branch from b15a72c to 3bb4d0b Compare October 9, 2025 18:02
Copy link
Contributor

coderabbitai bot commented Oct 9, 2025

Walkthrough

Adds an optional recipientAddress surface to x402 payment handling: PaymentArgs.payTo comment updated; decodePaymentRequest maps payTo into extra.recipientAddress; SettlePayment signature accepts an optional recipientAddress. Also adds two changeset entries and exports two types from the in-app wallet export.

Changes

Cohort / File(s) Summary of changes
Changesets
.changeset/loud-apples-poke.md, .changeset/lucky-meals-join.md
Adds two changeset entries: one noting x402 SettlePayment now accepts an optional recipientAddress; another patch-style entry (no API change).
x402 common decoding
packages/thirdweb/src/x402/common.ts
decodePaymentRequest now reads payTo from function args and includes it as recipientAddress in the decoded requirement’s extra payload. No control-flow or error handling changes.
x402 types (comment update)
packages/thirdweb/src/x402/types.ts
Updates the comment for payTo?: string to: “Optional recipient address to receive the payment if different from your facilitator address”. Field remains optional and unchanged structurally.
Public API / exports (in-app wallet)
packages/thirdweb/src/exports/wallets/in-app.ts
Adds exports for Condition and LimitType (from ../../extensions/erc7702/account/types.js) to the public exports. No runtime logic changes.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  participant Client
  participant Decoder as decodePaymentRequest
  participant API as x402.SettlePayment
  Note right of Decoder #D3F3E0: map `payTo` → `extra.recipientAddress` (new)
  Client->>Decoder: call with payment args (may include `payTo`)
  Decoder-->>Client: decoded requirement (includes extra.recipientAddress if present)
  Client->>API: call SettlePayment(..., recipientAddress?)
  API-->>Client: settlement result
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description Check ⚠️ Warning The pull request description retains the scaffolded template in comments and provides a PR-Codex overview, but it omits any filled-in title in the required “[SDK/Dashboard/Portal] Feature/Fix: …” format, as well as the “Notes for the reviewer” and “How to test” sections mandated by the repository template, so it does not conform to the expected structure. Please replace the commented template with actual content: include a title matching “[SDK] Feature/Fix: Concise title,” add a “Notes for the reviewer” section with any important context, and provide a “How to test” section detailing steps or tests to verify the changes.
✅ Passed checks (2 passed)
Check name Status Explanation
Title Check ✅ Passed The title succinctly summarizes the primary API change by highlighting the addition of the x402 recipientAddress parameter and notes the replacement of the deprecated payTo field in a clear and concise manner.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch _x402_Add_recipientAddress_to_payment_request_and_replace_deprecated_payTo

Warning

Review ran into problems

🔥 Problems

Errors were encountered while retrieving linked issues.

Errors (1)
  • TEAM-0000: Entity not found: Issue - Could not find referenced Issue.

Git: Failed to clone repository. Please run the @coderabbitai full review command to re-trigger a full review. If the issue persists, set path_filters to include or exclude specific files.


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

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
packages/thirdweb/src/x402/common.ts (1)

120-123: Consider validating and normalizing the recipient address.

The recipientAddress is added to the extra payload without validation or normalization, which differs from how other addresses are handled in this file (e.g., getAddress() is used on lines 108 and 110).

Consider applying these improvements:

  1. Normalize the address format for consistency with other addresses in the code
  2. Conditionally add to extra to avoid including undefined properties
     extra: {
-      recipientAddress,
+      ...(recipientAddress ? { recipientAddress: getAddress(recipientAddress) } : {}),
       ...((asset as ERC20TokenAmount["asset"]).eip712 ?? {}),
     },

This ensures:

  • Address format consistency (checksummed addresses)
  • Cleaner payload when recipientAddress is not provided
  • Early validation of address format (throws if invalid)
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 080d7f2 and 3bb4d0b.

📒 Files selected for processing (3)
  • .changeset/loud-apples-poke.md (1 hunks)
  • packages/thirdweb/src/x402/common.ts (2 hunks)
  • packages/thirdweb/src/x402/types.ts (1 hunks)
🧰 Additional context used
📓 Path-based instructions (5)
**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

**/*.{ts,tsx}: Write idiomatic TypeScript with explicit function declarations and return types
Limit each file to one stateless, single-responsibility function for clarity
Re-use shared types from @/types or local types.ts barrels
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Choose composition over inheritance; leverage utility types (Partial, Pick, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose

**/*.{ts,tsx}: Use explicit function declarations and explicit return types in TypeScript
Limit each file to one stateless, single‑responsibility function
Re‑use shared types from @/types where applicable
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Prefer composition over inheritance; use utility types (Partial, Pick, etc.)
Lazy‑import optional features and avoid top‑level side‑effects to reduce bundle size

Files:

  • packages/thirdweb/src/x402/types.ts
  • packages/thirdweb/src/x402/common.ts
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (CLAUDE.md)

Load heavy dependencies inside async paths to keep initial bundle lean (lazy loading)

Files:

  • packages/thirdweb/src/x402/types.ts
  • packages/thirdweb/src/x402/common.ts
**/types.ts

📄 CodeRabbit inference engine (AGENTS.md)

Provide and re‑use local type barrels in a types.ts file

Files:

  • packages/thirdweb/src/x402/types.ts
packages/thirdweb/**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

packages/thirdweb/**/*.{ts,tsx}: Every public symbol must have comprehensive TSDoc with at least one compiling @example and a custom tag (@beta, @internal, @experimental, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose
Lazy‑load heavy dependencies inside async paths (e.g., const { jsPDF } = await import("jspdf"))

Files:

  • packages/thirdweb/src/x402/types.ts
  • packages/thirdweb/src/x402/common.ts
.changeset/*.md

📄 CodeRabbit inference engine (AGENTS.md)

.changeset/*.md: Each change in packages/* must include a changeset for the appropriate package
Version bump rules: patch for non‑API changes; minor for new/modified public API

Files:

  • .changeset/loud-apples-poke.md
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: E2E Tests (pnpm, esbuild)
  • GitHub Check: Unit Tests
  • GitHub Check: E2E Tests (pnpm, vite)
  • GitHub Check: E2E Tests (pnpm, webpack)
  • GitHub Check: Size
  • GitHub Check: Build Packages
  • GitHub Check: Lint Packages
  • GitHub Check: Analyze (javascript)
🔇 Additional comments (2)
.changeset/loud-apples-poke.md (1)

1-5: LGTM!

The changeset follows the proper format and correctly documents a patch version bump for the API addition.

packages/thirdweb/src/x402/types.ts (1)

37-38: Add comprehensive TSDoc with an example.

The inline comment is helpful, but coding guidelines require comprehensive TSDoc with at least one compiling @example for every public symbol in the thirdweb package.

As per coding guidelines for packages/thirdweb/**/*.{ts,tsx}:

Every public symbol must have comprehensive TSDoc with at least one compiling @example and a custom tag (@beta, @internal, @experimental, etc.)

Consider adding TSDoc in this format:

-  /** Optional recipient address to receive the payment if different from your facilitator address */
-  recipientAddress?: string;
+  /**
+   * Optional recipient address to receive the payment if different from your facilitator address.
+   * When specified, the facilitator will forward the payment to this address after processing.
+   *
+   * @example
+   * ```ts
+   * const result = await settlePayment({
+   *   // ... other required fields
+   *   recipientAddress: "0x1234567890123456789012345678901234567890",
+   * });
+   * ```
+   *
+   * @public
+   */
+  recipientAddress?: string;

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
packages/thirdweb/src/x402/common.ts (1)

120-124: Consider conditionally including recipientAddress in the extra object.

When recipientAddress is undefined, the current implementation will create an explicit undefined property in the extra object. Consider conditionally including it only when defined to keep the payload cleaner.

Apply this diff to conditionally include recipientAddress:

     extra: {
-      recipientAddress,
+      ...(recipientAddress && { recipientAddress }),
       ...((asset as ERC20TokenAmount["asset"]).eip712 ?? {}),
     },
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 080d7f2 and 3bb4d0b.

📒 Files selected for processing (3)
  • .changeset/loud-apples-poke.md (1 hunks)
  • packages/thirdweb/src/x402/common.ts (2 hunks)
  • packages/thirdweb/src/x402/types.ts (1 hunks)
🧰 Additional context used
📓 Path-based instructions (5)
.changeset/*.md

📄 CodeRabbit inference engine (AGENTS.md)

.changeset/*.md: Each change in packages/* must include a changeset for the appropriate package
Version bump rules: patch for non‑API changes; minor for new/modified public API

Files:

  • .changeset/loud-apples-poke.md
**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

**/*.{ts,tsx}: Write idiomatic TypeScript with explicit function declarations and return types
Limit each file to one stateless, single-responsibility function for clarity
Re-use shared types from @/types or local types.ts barrels
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Choose composition over inheritance; leverage utility types (Partial, Pick, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose

**/*.{ts,tsx}: Use explicit function declarations and explicit return types in TypeScript
Limit each file to one stateless, single‑responsibility function
Re‑use shared types from @/types where applicable
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Prefer composition over inheritance; use utility types (Partial, Pick, etc.)
Lazy‑import optional features and avoid top‑level side‑effects to reduce bundle size

Files:

  • packages/thirdweb/src/x402/common.ts
  • packages/thirdweb/src/x402/types.ts
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (CLAUDE.md)

Load heavy dependencies inside async paths to keep initial bundle lean (lazy loading)

Files:

  • packages/thirdweb/src/x402/common.ts
  • packages/thirdweb/src/x402/types.ts
packages/thirdweb/**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

packages/thirdweb/**/*.{ts,tsx}: Every public symbol must have comprehensive TSDoc with at least one compiling @example and a custom tag (@beta, @internal, @experimental, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose
Lazy‑load heavy dependencies inside async paths (e.g., const { jsPDF } = await import("jspdf"))

Files:

  • packages/thirdweb/src/x402/common.ts
  • packages/thirdweb/src/x402/types.ts
**/types.ts

📄 CodeRabbit inference engine (AGENTS.md)

Provide and re‑use local type barrels in a types.ts file

Files:

  • packages/thirdweb/src/x402/types.ts
🔇 Additional comments (3)
packages/thirdweb/src/x402/common.ts (1)

47-47: LGTM! Correct destructuring of the new parameter.

The destructuring of recipientAddress from the input arguments is correctly implemented.

.changeset/loud-apples-poke.md (1)

1-5: LGTM! Appropriate patch-level changeset.

The changeset correctly uses a patch version bump for adding an optional parameter, which is backward compatible. The description is clear and concise.

packages/thirdweb/src/x402/types.ts (1)

37-38: Confirm payTo removal impact on external clients

No references to payTo were found in the codebase. Please verify that removing this property won’t break downstream integrations.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
packages/thirdweb/src/x402/common.ts (1)

35-39: Update TSDoc to reflect the new recipientAddress parameter.

The function comment does not mention the recipientAddress parameter. Per coding guidelines, public symbols should have comprehensive TSDoc that documents all parameters.

Apply this diff to update the TSDoc:

 /**
  * Decodes a payment request and returns the payment requirements, selected payment requirements, and decoded payment
  * @param args
+ * @param args.recipientAddress - Optional recipient address to receive the payment if different from the facilitator address
  * @returns The payment requirements, selected payment requirements, and decoded payment
  */
🧹 Nitpick comments (1)
packages/thirdweb/src/x402/common.ts (1)

40-52: Validate and normalize recipientAddress with getAddress
Wrap the extracted recipientAddress in the existing getAddress utility before adding it to extra (e.g. recipientAddress: getAddress(recipientAddress)).

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 080d7f2 and 3bb4d0b.

📒 Files selected for processing (3)
  • .changeset/loud-apples-poke.md (1 hunks)
  • packages/thirdweb/src/x402/common.ts (2 hunks)
  • packages/thirdweb/src/x402/types.ts (1 hunks)
🧰 Additional context used
📓 Path-based instructions (5)
**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

**/*.{ts,tsx}: Write idiomatic TypeScript with explicit function declarations and return types
Limit each file to one stateless, single-responsibility function for clarity
Re-use shared types from @/types or local types.ts barrels
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Choose composition over inheritance; leverage utility types (Partial, Pick, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose

**/*.{ts,tsx}: Use explicit function declarations and explicit return types in TypeScript
Limit each file to one stateless, single‑responsibility function
Re‑use shared types from @/types where applicable
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Prefer composition over inheritance; use utility types (Partial, Pick, etc.)
Lazy‑import optional features and avoid top‑level side‑effects to reduce bundle size

Files:

  • packages/thirdweb/src/x402/types.ts
  • packages/thirdweb/src/x402/common.ts
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (CLAUDE.md)

Load heavy dependencies inside async paths to keep initial bundle lean (lazy loading)

Files:

  • packages/thirdweb/src/x402/types.ts
  • packages/thirdweb/src/x402/common.ts
**/types.ts

📄 CodeRabbit inference engine (AGENTS.md)

Provide and re‑use local type barrels in a types.ts file

Files:

  • packages/thirdweb/src/x402/types.ts
packages/thirdweb/**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

packages/thirdweb/**/*.{ts,tsx}: Every public symbol must have comprehensive TSDoc with at least one compiling @example and a custom tag (@beta, @internal, @experimental, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose
Lazy‑load heavy dependencies inside async paths (e.g., const { jsPDF } = await import("jspdf"))

Files:

  • packages/thirdweb/src/x402/types.ts
  • packages/thirdweb/src/x402/common.ts
.changeset/*.md

📄 CodeRabbit inference engine (AGENTS.md)

.changeset/*.md: Each change in packages/* must include a changeset for the appropriate package
Version bump rules: patch for non‑API changes; minor for new/modified public API

Files:

  • .changeset/loud-apples-poke.md
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: E2E Tests (pnpm, esbuild)
  • GitHub Check: Unit Tests
  • GitHub Check: E2E Tests (pnpm, vite)
  • GitHub Check: E2E Tests (pnpm, webpack)
  • GitHub Check: Size
  • GitHub Check: Build Packages
  • GitHub Check: Lint Packages
  • GitHub Check: Analyze (javascript)
🔇 Additional comments (3)
packages/thirdweb/src/x402/types.ts (1)

37-38: LGTM! Clear deprecation and replacement.

The replacement of payTo with recipientAddress is well-documented and maintains backward compatibility through optional typing. The documentation clearly explains the parameter's purpose.

.changeset/loud-apples-poke.md (1)

1-5: Consider whether this qualifies as a minor version bump.

The coding guidelines state: "patch for non-API changes; minor for new/modified public API." While the new recipientAddress parameter is optional and backward-compatible, it does modify the public API surface.

Additionally, the description could mention that this change deprecates the payTo property in favor of recipientAddress, providing a more complete picture of the API evolution.

Based on coding guidelines.

packages/thirdweb/src/x402/common.ts (1)

101-124: Clarify payTo vs recipientAddress usage The code assigns payTo to the facilitator and nests recipientAddress in extra, but I couldn’t locate where each is processed. Please confirm that funds are sent to payTo for processing and then forwarded to recipientAddress, and add a brief comment explaining their distinct roles.

Copy link
Contributor

github-actions bot commented Oct 9, 2025

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 64.51 KB (0%) 1.3 s (0%) 290 ms (+108.54% 🔺) 1.6 s
thirdweb (cjs) 365.79 KB (0%) 7.4 s (0%) 1.6 s (+6.16% 🔺) 8.9 s
thirdweb (minimal + tree-shaking) 5.73 KB (0%) 115 ms (0%) 83 ms (+516.25% 🔺) 198 ms
thirdweb/chains (tree-shaking) 526 B (0%) 11 ms (0%) 94 ms (+2051.38% 🔺) 105 ms
thirdweb/react (minimal + tree-shaking) 19.13 KB (0%) 383 ms (0%) 98 ms (+876.16% 🔺) 480 ms

Copy link

codecov bot commented Oct 9, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 55.02%. Comparing base (080d7f2) to head (3bb4d0b).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #8226   +/-   ##
=======================================
  Coverage   55.02%   55.02%           
=======================================
  Files         919      919           
  Lines       60583    60583           
  Branches     4126     4127    +1     
=======================================
+ Hits        33333    33338    +5     
+ Misses      27146    27142    -4     
+ Partials      104      103    -1     
Flag Coverage Δ
packages 55.02% <ø> (+<0.01%) ⬆️
see 3 files with indirect coverage changes
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 3bb4d0b and 68069e9.

📒 Files selected for processing (5)
  • .changeset/loud-apples-poke.md (1 hunks)
  • .changeset/lucky-meals-join.md (1 hunks)
  • packages/thirdweb/src/exports/wallets/in-app.ts (1 hunks)
  • packages/thirdweb/src/x402/common.ts (3 hunks)
  • packages/thirdweb/src/x402/types.ts (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • .changeset/lucky-meals-join.md
🚧 Files skipped from review as they are similar to previous changes (2)
  • packages/thirdweb/src/x402/types.ts
  • packages/thirdweb/src/x402/common.ts
🧰 Additional context used
📓 Path-based instructions (5)
.changeset/*.md

📄 CodeRabbit inference engine (AGENTS.md)

.changeset/*.md: Each change in packages/* must include a changeset for the appropriate package
Version bump rules: patch for non‑API changes; minor for new/modified public API

Files:

  • .changeset/loud-apples-poke.md
**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

**/*.{ts,tsx}: Write idiomatic TypeScript with explicit function declarations and return types
Limit each file to one stateless, single-responsibility function for clarity
Re-use shared types from @/types or local types.ts barrels
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Choose composition over inheritance; leverage utility types (Partial, Pick, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose

**/*.{ts,tsx}: Use explicit function declarations and explicit return types in TypeScript
Limit each file to one stateless, single‑responsibility function
Re‑use shared types from @/types where applicable
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Prefer composition over inheritance; use utility types (Partial, Pick, etc.)
Lazy‑import optional features and avoid top‑level side‑effects to reduce bundle size

Files:

  • packages/thirdweb/src/exports/wallets/in-app.ts
packages/thirdweb/src/exports/**

📄 CodeRabbit inference engine (CLAUDE.md)

packages/thirdweb/src/exports/**: Export everything via exports/ directory, grouped by feature in the SDK public API
Every public symbol must have comprehensive TSDoc with at least one @example block that compiles and custom annotation tags (@beta, @internal, @experimental)

Files:

  • packages/thirdweb/src/exports/wallets/in-app.ts
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (CLAUDE.md)

Load heavy dependencies inside async paths to keep initial bundle lean (lazy loading)

Files:

  • packages/thirdweb/src/exports/wallets/in-app.ts
packages/thirdweb/**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

packages/thirdweb/**/*.{ts,tsx}: Every public symbol must have comprehensive TSDoc with at least one compiling @example and a custom tag (@beta, @internal, @experimental, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose
Lazy‑load heavy dependencies inside async paths (e.g., const { jsPDF } = await import("jspdf"))

Files:

  • packages/thirdweb/src/exports/wallets/in-app.ts
🧠 Learnings (2)
📚 Learning: 2025-07-18T19:19:55.613Z
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T19:19:55.613Z
Learning: Applies to packages/thirdweb/src/wallets/** : Unified `Wallet` and `Account` interfaces in wallet architecture

Applied to files:

  • packages/thirdweb/src/exports/wallets/in-app.ts
📚 Learning: 2025-07-18T19:19:55.613Z
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T19:19:55.613Z
Learning: Applies to packages/thirdweb/src/wallets/** : EIP-1193, EIP-5792, EIP-7702 standard support in wallet modules

Applied to files:

  • packages/thirdweb/src/exports/wallets/in-app.ts
🔇 Additional comments (1)
packages/thirdweb/src/exports/wallets/in-app.ts (1)

3-22: All new ERC7702 signer exports include proper TSDoc with @example and custom tags.

@joaquim-verges joaquim-verges force-pushed the _x402_Add_recipientAddress_to_payment_request_and_replace_deprecated_payTo branch from 68069e9 to e8f9793 Compare October 9, 2025 20:43
@joaquim-verges joaquim-verges merged commit 0082e99 into main Oct 9, 2025
17 of 21 checks passed
@joaquim-verges joaquim-verges deleted the _x402_Add_recipientAddress_to_payment_request_and_replace_deprecated_payTo branch October 9, 2025 20:51
@joaquim-verges joaquim-verges mentioned this pull request Oct 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

packages SDK Involves changes to the thirdweb SDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant