Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions apps/portal/src/app/payments/faq/page.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,17 @@ health, price, and speed to guarantee the best path every time.
Yes, Payments is designed to be agnostic to wallet infrastructure. You can use it with any wallet service.
</Details>

<Details summary="How can I split the payment between multiple destination wallet addresses?">
You can use the thirdweb [Split contract](https://thirdweb.com/thirdweb.eth/Split) to handle this.

- Deploy the Split contract with the set of beneficiary addresses. (These are immutable and fixed at deploy time.)
- Set the Split contract address as the sale recipient in your configuration.
- Distribute the funds at any time by calling the distribute() function on the contract.
Copy link
Contributor

Choose a reason for hiding this comment

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

💡 Verification agent

🧩 Analysis chain

Distribution function name may differ for ERC20 vs native assets—avoid hardcoding distribute().

Split contracts typically have separate distribution methods for native tokens and ERC20 tokens. Calling out the token-specific path improves correctness.

Apply this diff:

-- Distribute the funds at any time by calling the distribute() function on the contract.
+- Distribute funds by calling the contract’s distribution function. For native tokens, call the distribute() function; for ERC20 tokens, use the token-specific distribution method.

If you want to verify the exact function names for the Thirdweb Split contract, please run this web query:


🌐 Web query:

What are the function names/signatures used by the thirdweb Split contract to distribute native assets and ERC20 tokens?

💡 Result:

Short answer — there are two overloaded distribute functions:

  • Native (network native token, e.g. ETH):

  • ERC‑20 token:

    • Solidity-style: function distribute(address token) external; (nonpayable)
    • SDK helper: distributeByToken({ tokenAddress }) — prepares a call to the contract's distribute(address) function. (portal.thirdweb.com, thirdweb.com)

If you want the exact ABI entry, the ERC‑20 variant is shown with inputs: (token: address) and stateMutability: "nonpayable" in the thirdweb docs. (portal.thirdweb.com)

Citations:


Clarify distribution methods for native vs ERC-20 tokens

The Thirdweb Split contract exposes two overloaded functions for fund distribution:

  • distribute() for native tokens
  • distribute(address token) for ERC-20 tokens (SDK helper: distributeByToken({ tokenAddress }))

Please update the copy in apps/portal/src/app/payments/faq/page.mdx as follows:

- Distribute the funds at any time by calling the distribute() function on the contract.
+ Distribute funds at any time:
+ - For native tokens, call `distribute()`.
+ - For ERC-20 tokens, call `distribute(address token)` (or use the SDK’s `distributeByToken({ tokenAddress })` helper).
📝 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
- Distribute the funds at any time by calling the distribute() function on the contract.
Distribute funds at any time:
- For native tokens, call `distribute()`.
- For ERC-20 tokens, call `distribute(address token)` (or use the SDK’s `distributeByToken({ tokenAddress })` helper).
🤖 Prompt for AI Agents
In apps/portal/src/app/payments/faq/page.mdx around line 31, the sentence about
distributing funds is ambiguous; update the copy to distinguish the two Split
contract overloads by stating that distribute() is for native tokens and
distribute(address token) (or SDK helper distributeByToken({ tokenAddress })) is
for ERC-20 tokens, replacing the current single line with a short clear
explanation of both methods and the SDK helper usage.


This will automatically split payments according to the allocation you defined during deployment.

</Details>

### Fees

<Details summary="What are the fees for Buy With Fiat?">
Expand Down
Loading