@rozoai/intent-pay 0.0.42 → 0.0.43-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/README.md +28 -36
  2. package/build/components/DaimoPayButton/index.d.ts +1 -129
  3. package/build/components/DaimoPayButton/types.d.ts +138 -0
  4. package/build/hooks/useDepositAddressOptions.d.ts +3 -7
  5. package/build/hooks/usePaymentState.d.ts +3 -4
  6. package/build/hooks/useSolanaDestination.d.ts +2 -0
  7. package/build/hooks/useSupportedChains.d.ts +4 -4
  8. package/build/hooks/useWalletPaymentOptions.d.ts +18 -0
  9. package/build/index.d.ts +4 -1
  10. package/build/package.json.js +2 -2
  11. package/build/payment/paymentFsm.d.ts +7 -8
  12. package/build/src/components/Common/OrderHeader/index.js +2 -2
  13. package/build/src/components/Common/OrderHeader/index.js.map +1 -1
  14. package/build/src/components/Common/TokenChainLogo/index.js.map +1 -1
  15. package/build/src/components/DaimoPayButton/index.js +94 -40
  16. package/build/src/components/DaimoPayButton/index.js.map +1 -1
  17. package/build/src/components/Pages/Solana/PayWithSolanaToken/index.js +60 -81
  18. package/build/src/components/Pages/Solana/PayWithSolanaToken/index.js.map +1 -1
  19. package/build/src/components/Pages/Stellar/PayWithStellarToken/index.js +2 -2
  20. package/build/src/components/Pages/Stellar/PayWithStellarToken/index.js.map +1 -1
  21. package/build/src/components/Pages/WaitingDepositAddress/index.js +5 -28
  22. package/build/src/components/Pages/WaitingDepositAddress/index.js.map +1 -1
  23. package/build/src/hooks/useDepositAddressOptions.js +35 -47
  24. package/build/src/hooks/useDepositAddressOptions.js.map +1 -1
  25. package/build/src/hooks/usePaymentState.js +42 -34
  26. package/build/src/hooks/usePaymentState.js.map +1 -1
  27. package/build/src/hooks/useSolanaDestination.js +4 -0
  28. package/build/src/hooks/useSolanaDestination.js.map +1 -1
  29. package/build/src/hooks/useStellarPaymentOptions.js +1 -1
  30. package/build/src/hooks/useStellarPaymentOptions.js.map +1 -1
  31. package/build/src/hooks/useSupportedChains.js +14 -11
  32. package/build/src/hooks/useSupportedChains.js.map +1 -1
  33. package/build/src/hooks/useWalletPaymentOptions.js +19 -2
  34. package/build/src/hooks/useWalletPaymentOptions.js.map +1 -1
  35. package/build/src/index.js +1 -0
  36. package/build/src/index.js.map +1 -1
  37. package/build/src/payment/paymentEffects.js +73 -97
  38. package/build/src/payment/paymentEffects.js.map +1 -1
  39. package/build/src/payment/paymentFsm.js.map +1 -1
  40. package/build/src/types/chainAddress.js +79 -0
  41. package/build/src/types/chainAddress.js.map +1 -0
  42. package/build/types/chainAddress.d.ts +27 -0
  43. package/package.json +10 -11
  44. package/src/index.ts +64 -0
package/README.md CHANGED
@@ -5,7 +5,7 @@ Onboard users from any chain, any coin into your app with one click and maximize
5
5
 
6
6
  ## Features
7
7
 
8
- - 🌱 Instant cross-chain payments — Accept payment from 1000+ tokens on multiple chains. Payments complete in less than 5 seconds. We handle the swapping
8
+ - 🌱 Instant cross-chain payments — Accept payment from 1000+ tokens on multiple chains. Payments complete in less than 1 minute. We handle the swapping
9
9
  and bridging so that your customers don't have to.
10
10
  - 💡 Pay with a single transaction - No more wallet round-trips to make approval, swap, or bridging transactions. Your customers pay with a single transfer transaction.
11
11
  - ⚡️ Fully permissionless - Rozo Pay never custodies funds and funds can never be stuck in a contract. Payments can be permissionlessly completed by anyone.
@@ -20,7 +20,7 @@ Onboard users from any chain, any coin into your app with one click and maximize
20
20
 
21
21
  **Solana Wallets:** Phantom, Backpack, Solflare
22
22
 
23
- **Stellar Wallets:** Via Stellar SDK integration
23
+ **Stellar Wallets:** Albedo, Freighter, Hot Wallet, etc. (Refer to: <https://stellarwalletskit.dev/#compatible-wallets>)
24
24
 
25
25
  **Mobile Wallets:** All above wallets with mobile app support and deep-linking
26
26
 
@@ -28,30 +28,36 @@ Onboard users from any chain, any coin into your app with one click and maximize
28
28
 
29
29
  **Currently Active in Wallet Payment Options:**
30
30
 
31
- - Base
32
- - Polygon
33
- - BSC
34
- - Solana
35
- - Stellar
31
+ - **Base** (Chain ID: 8453) - USDC
32
+ - **Polygon** (Chain ID: 137) - USDC
33
+ - **Ethereum** (Chain ID: 1) - USDC
34
+ - **BSC** (Chain ID: 56) - USDT _(conditional: enabled for MugglePay appId related)_
35
+ - **Worldchain** (Chain ID: 480) - USDC _(conditional: enabled for World appId related)_
36
+ - **Solana** (Chain ID: 900) - USDC
37
+ - **Stellar** (Chain ID: 1500) - USDC/XLM
36
38
 
37
39
  **Full Supported Chain Network:**
38
40
 
39
- - **EVM Chains:** Ethereum (1), Arbitrum (42161), Base (8453), Polygon (137), Optimism (10), BSC (56), Linea (59144), WorldChain (480), Mantle (5000), Celo (42220)
40
- - **Non-EVM:** Solana, Stellar
41
+ The SDK has full infrastructure support for the following chains, though not all are currently active in wallet payment options:
42
+
43
+ - **EVM Chains:** Arbitrum (42161), Base (8453), BSC (56), Ethereum (1), Polygon (137), Worldchain (480)
44
+ - **Non-EVM Chains:** Solana (900), Stellar (1500)
41
45
 
42
46
  ### Supported Tokens
43
47
 
44
48
  **Currently Active in Wallet Payment Options:**
45
49
 
46
- - Base USDC
47
- - Polygon USDC
48
- - BSC USDT
49
- - Solana USDC
50
- - Stellar USDC
50
+ - **Base USDC** - `0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913`
51
+ - **Polygon USDC** - `0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174`
52
+ - **Ethereum USDC** - `0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48`
53
+ - **BSC USDT** - `0x55d398326f99059fF775485246999027B3197955`
54
+ - **Worldchain USDC** - `0x79A02482A880bCE3F13e09Da970dC34db4CD24d1`
55
+ - **Solana USDC** - `EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v`
56
+ - **Stellar USDC** - `GA5ZSEJYB37JRC5AVCIA5MOP4RHTM335X2KGX3IHOJAPP5RE34K4KZVN`
51
57
 
52
58
  **Full Token Support Per Chain:**
53
59
 
54
- Each supported chain includes native tokens (ETH, MATIC, SOL, XLM), wrapped versions (WETH, WMATIC), stablecoins (USDC, USDT, DAI), and major tokens (WBTC, etc.). The SDK automatically handles token discovery and liquidity routing.
60
+ The SDK currently supports USDC as the primary payment token across all active chains. Additional token support includes USDT on BSC (conditional) and XLM on Stellar. The SDK automatically handles cross-chain routing and bridging for supported tokens.
55
61
 
56
62
  ### External Payment Options
57
63
 
@@ -65,11 +71,11 @@ and much more...
65
71
 
66
72
  ## Documentation
67
73
 
68
- You can find the full Rozo Pay documentation [here](https://pay.rozoai.com).
74
+ You can find the full Rozo Pay documentation at [pay.rozoai.com](https://docs.rozo.ai).
69
75
 
70
76
  ## Examples
71
77
 
72
- Check out [example](https://github.com/RozoAI/intent-pay/tree/master/examples/nextjs-app)
78
+ Check out the [Next.js example app](https://github.com/RozoAI/intent-pay/tree/master/examples/nextjs-app)
73
79
 
74
80
  ## Demo
75
81
 
@@ -82,16 +88,16 @@ Clone the repository and build the SDK in `dev` mode:
82
88
  ```sh
83
89
  git clone https://github.com/RozoAI/intent-pay.git
84
90
  cd pay/packages/connectkit
85
- bun i
86
- bun run dev
91
+ pnpm i
92
+ pnpm run dev
87
93
  ```
88
94
 
89
95
  The rollup bundler will now watch file changes in the background. Try using one of the examples for testing:
90
96
 
91
97
  ```sh
92
98
  cd examples/nextjs
93
- bun i
94
- bun run dev
99
+ pnpm i
100
+ pnpm run dev
95
101
  ```
96
102
 
97
103
  Any changes will be reflected on the Pay button in the example app.
@@ -120,24 +126,10 @@ Daimo Pay SDK is a fork of [Connectkit](https://github.com/family/connectkit) de
120
126
 
121
127
  ## How to release `connectkit` package
122
128
 
123
- ## Setup
124
-
125
- Make sure `bun` is installed.
126
-
127
- ```sh
128
- bun -v
129
- ```
130
-
131
- If not, install it.
132
-
133
- ```sh
134
- npm install -g bun
135
- ```
136
-
137
129
  ## Release
138
130
 
139
131
  ```sh
140
- bun run release
132
+ pnpm run release
141
133
  ```
142
134
 
143
135
  Choose the version on the prompt.
@@ -1,132 +1,4 @@
1
- import { ReactElement } from "react";
2
- import { ExternalPaymentOptionsString, PaymentBouncedEvent, PaymentCompletedEvent, PaymentPayoutCompletedEvent, PaymentStartedEvent, RozoPayOrderView, RozoPayUserMetadata } from "@rozoai/intent-common";
3
- import { Address, Hex } from "viem";
4
- import { CustomTheme, Mode, Theme } from "../../types";
5
- /** Payment details and status. */
6
- export type RozoPayment = RozoPayOrderView;
7
- /** Props for RozoPayButton. */
8
- export type PayButtonPaymentProps = {
9
- /**
10
- * Your public app ID. Specify either (payId) or (appId + parameters).
11
- */
12
- appId: string;
13
- /**
14
- * Destination chain ID.
15
- */
16
- toChain: number;
17
- /**
18
- * The destination token to send, completing payment. Must be an ERC-20
19
- * token or the zero address, indicating the native token / ETH.
20
- */
21
- toToken: Address;
22
- /**
23
- * The amount of destination token to send (transfer or approve).
24
- * If not provided, the user will be prompted to enter an amount.
25
- */
26
- toUnits?: string;
27
- /**
28
- * The destination address to transfer to, or contract to call.
29
- */
30
- toAddress: Address;
31
- /**
32
- * The destination stellar address to transfer to.
33
- */
34
- toStellarAddress?: string;
35
- /**
36
- * The destination solana address to transfer to.
37
- */
38
- toSolanaAddress?: string;
39
- /**
40
- * Optional calldata to call an arbitrary function on `toAddress`.
41
- */
42
- toCallData?: Hex;
43
- /**
44
- * The intent verb, such as "Pay", "Deposit", or "Purchase".
45
- */
46
- intent?: string;
47
- /**
48
- * Payment options. By default, all are enabled.
49
- */
50
- paymentOptions?: ExternalPaymentOptionsString[];
51
- /**
52
- * Preferred chain IDs. Assets on these chains will appear first.
53
- */
54
- preferredChains?: number[];
55
- /**
56
- * Preferred tokens. These appear first in the token list.
57
- */
58
- preferredTokens?: {
59
- chain: number;
60
- address: Address;
61
- }[];
62
- /**
63
- * Only allow payments on these EVM chains.
64
- */
65
- evmChains?: number[];
66
- /**
67
- * External ID. E.g. a correlation ID.
68
- */
69
- externalId?: string;
70
- /**
71
- * Developer metadata. E.g. correlation ID.
72
- * */
73
- metadata?: RozoPayUserMetadata;
74
- /**
75
- * The address to refund to if the payment bounces.
76
- */
77
- refundAddress?: Address;
78
- } | {
79
- /** The payment ID, generated via the Rozo Pay API. Replaces params above. */
80
- payId: string;
81
- /** Payment options. By default, all are enabled. */
82
- paymentOptions?: ExternalPaymentOptionsString[];
83
- };
84
- type PayButtonCommonProps = PayButtonPaymentProps & {
85
- /** Called when user sends payment and transaction is seen on chain */
86
- onPaymentStarted?: (event: PaymentStartedEvent) => void;
87
- /** Called when destination transfer or call completes successfully */
88
- onPaymentCompleted?: (event: PaymentCompletedEvent) => void;
89
- /** Called when destination call reverts and funds are refunded */
90
- onPaymentBounced?: (event: PaymentBouncedEvent) => void;
91
- /** Called when payout completes */
92
- onPayoutCompleted?: (event: PaymentPayoutCompletedEvent) => void;
93
- /** Called when the modal is opened. */
94
- onOpen?: () => void;
95
- /** Called when the modal is closed. */
96
- onClose?: () => void;
97
- /** Open the modal by default. */
98
- defaultOpen?: boolean;
99
- /** Automatically close the modal after a successful payment. */
100
- closeOnSuccess?: boolean;
101
- /** Reset the payment after a successful payment. */
102
- resetOnSuccess?: boolean;
103
- /** Go directly to tokens in already-connected Ethereum and Solana wallet(s).
104
- * Don't let the user pick any other payment method. Used in embedded flows.*/
105
- connectedWalletOnly?: boolean;
106
- /** Custom message to display on confirmation page. */
107
- confirmationMessage?: string;
108
- /** Redirect URL to return to the app. E.g. after Coinbase, Binance, RampNetwork. */
109
- redirectReturnUrl?: string;
110
- /** Optional configuration to show processing pay out loading when payment completed */
111
- showProcessingPayout?: boolean;
112
- };
113
- export type RozoPayButtonProps = PayButtonCommonProps & {
114
- /** Light mode, dark mode, or auto. */
115
- mode?: Mode;
116
- /** Named theme. See docs for options. */
117
- theme?: Theme;
118
- /** Custom theme. See docs for options. */
119
- customTheme?: CustomTheme;
120
- /** Disable interaction. */
121
- disabled?: boolean;
122
- };
123
- export type RozoPayButtonCustomProps = PayButtonCommonProps & {
124
- /** Custom renderer */
125
- children: (renderProps: {
126
- show: () => void;
127
- hide: () => void;
128
- }) => ReactElement;
129
- };
1
+ import { RozoPayButtonCustomProps, RozoPayButtonProps } from "./types";
130
2
  /**
131
3
  * A button that shows the Rozo Pay checkout. Replaces the traditional
132
4
  * Connect Wallet » approve » execute sequence with a single action.
@@ -0,0 +1,138 @@
1
+ import { ExternalPaymentOptionsString, PaymentBouncedEvent, PaymentCompletedEvent, PaymentPayoutCompletedEvent, PaymentStartedEvent, RozoPayUserMetadata } from "@rozoai/intent-common";
2
+ import { ReactElement } from "react";
3
+ import { Address } from "viem";
4
+ import { CustomTheme, Mode, Theme } from "../../types";
5
+ /** Chain-specific props for EVM chains (Base, Ethereum, Polygon) */
6
+ type EvmChainProps = {
7
+ /**
8
+ * The destination address to transfer to, or contract to call.
9
+ * Must be a valid EVM address in 0x... format.
10
+ */
11
+ toAddress: Address;
12
+ /**
13
+ * The destination token to send, completing payment.
14
+ * Must be an ERC-20 token address or the zero address (0x0000000000000000000000000000000000000000)
15
+ * for native token (ETH, MATIC, etc).
16
+ */
17
+ toToken: Address;
18
+ };
19
+ /** Chain-specific props for non-EVM chains (Solana, Stellar) */
20
+ type NonEvmChainProps = {
21
+ /**
22
+ * The destination address to transfer to.
23
+ * - For Solana (900): Base58 encoded address (32-44 characters)
24
+ * - For Stellar (1500): Account address starting with 'G' (56 characters)
25
+ */
26
+ toAddress: string;
27
+ /**
28
+ * The destination token to send, completing payment.
29
+ * - For Solana: Token mint address or "native" for SOL
30
+ * - For Stellar: Asset code (e.g., "USDC", "XLM") or "native"
31
+ */
32
+ toToken: string;
33
+ };
34
+ /** Common props shared by all chain types */
35
+ type CommonPaymentProps = {
36
+ /**
37
+ * Your public app ID. Specify either (payId) or (appId + parameters).
38
+ */
39
+ appId: string;
40
+ /**
41
+ * Destination chain ID for non-EVM chains.
42
+ * - Base: 8453
43
+ * - Ethereum: 1
44
+ * - Polygon: 137
45
+ * - Solana: 900
46
+ * - Stellar: 1500
47
+ */
48
+ toChain: number;
49
+ /**
50
+ * The amount of destination token to send (transfer or approve).
51
+ * If not provided, the user will be prompted to enter an amount.
52
+ */
53
+ toUnits?: string;
54
+ /**
55
+ * The intent verb, such as "Pay", "Deposit", or "Purchase".
56
+ */
57
+ intent?: string;
58
+ /**
59
+ * Payment options. By default, all are enabled.
60
+ */
61
+ paymentOptions?: ExternalPaymentOptionsString[];
62
+ /**
63
+ * Preferred chain IDs. Assets on these chains will appear first.
64
+ */
65
+ preferredChains?: number[];
66
+ /**
67
+ * Preferred tokens. These appear first in the token list.
68
+ */
69
+ preferredTokens?: {
70
+ chain: number;
71
+ address: Address | string;
72
+ }[];
73
+ /**
74
+ * Only allow payments on these EVM chains.
75
+ */
76
+ /**
77
+ * External ID. E.g. a correlation ID.
78
+ */
79
+ externalId?: string;
80
+ /**
81
+ * Developer metadata. E.g. correlation ID.
82
+ */
83
+ metadata?: RozoPayUserMetadata;
84
+ };
85
+ /** Props for RozoPayButton - discriminated union based on chain type */
86
+ export type PayButtonPaymentProps = (CommonPaymentProps & EvmChainProps) | (CommonPaymentProps & NonEvmChainProps) | {
87
+ /** The payment ID, generated via the Rozo Pay API. Replaces params above. */
88
+ payId: string;
89
+ /** Payment options. By default, all are enabled. */
90
+ paymentOptions?: ExternalPaymentOptionsString[];
91
+ };
92
+ type PayButtonCommonProps = PayButtonPaymentProps & {
93
+ /** Called when user sends payment and transaction is seen on chain */
94
+ onPaymentStarted?: (event: PaymentStartedEvent) => void;
95
+ /** Called when destination transfer or call completes successfully */
96
+ onPaymentCompleted?: (event: PaymentCompletedEvent) => void;
97
+ /** Called when destination call reverts and funds are refunded */
98
+ onPaymentBounced?: (event: PaymentBouncedEvent) => void;
99
+ /** Called when payout completes */
100
+ onPayoutCompleted?: (event: PaymentPayoutCompletedEvent) => void;
101
+ /** Called when the modal is opened. */
102
+ onOpen?: () => void;
103
+ /** Called when the modal is closed. */
104
+ onClose?: () => void;
105
+ /** Open the modal by default. */
106
+ defaultOpen?: boolean;
107
+ /** Automatically close the modal after a successful payment. */
108
+ closeOnSuccess?: boolean;
109
+ /** Reset the payment after a successful payment. */
110
+ resetOnSuccess?: boolean;
111
+ /** Go directly to tokens in already-connected Ethereum and Solana wallet(s).
112
+ * Don't let the user pick any other payment method. Used in embedded flows.*/
113
+ connectedWalletOnly?: boolean;
114
+ /** Custom message to display on confirmation page. */
115
+ confirmationMessage?: string;
116
+ /** Redirect URL to return to the app. E.g. after Coinbase, Binance, RampNetwork. */
117
+ redirectReturnUrl?: string;
118
+ /** Optional configuration to show processing pay out loading when payment completed */
119
+ showProcessingPayout?: boolean;
120
+ };
121
+ export type RozoPayButtonProps = PayButtonCommonProps & {
122
+ /** Light mode, dark mode, or auto. */
123
+ mode?: Mode;
124
+ /** Named theme. See docs for options. */
125
+ theme?: Theme;
126
+ /** Custom theme. See docs for options. */
127
+ customTheme?: CustomTheme;
128
+ /** Disable interaction. */
129
+ disabled?: boolean;
130
+ };
131
+ export type RozoPayButtonCustomProps = PayButtonCommonProps & {
132
+ /** Custom renderer */
133
+ children: (renderProps: {
134
+ show: () => void;
135
+ hide: () => void;
136
+ }) => ReactElement;
137
+ };
138
+ export {};
@@ -1,10 +1,5 @@
1
- import { DepositAddressPaymentOptions, RozoPayOrderMode } from "@rozoai/intent-common";
1
+ import { DepositAddressPaymentOptionMetadata, RozoPayOrderMode } from "@rozoai/intent-common";
2
2
  import { TrpcClient } from "../utils/trpc";
3
- export interface DepositAddressOption {
4
- id: DepositAddressPaymentOptions;
5
- logoURI: string | React.ReactNode;
6
- minimumUsd: number;
7
- }
8
3
  export interface UseDepositAddressOptionsParams {
9
4
  trpc: TrpcClient;
10
5
  usdRequired: number | undefined;
@@ -12,7 +7,7 @@ export interface UseDepositAddressOptionsParams {
12
7
  appId?: string;
13
8
  }
14
9
  export interface UseDepositAddressOptionsReturn {
15
- options: DepositAddressOption[];
10
+ options: DepositAddressPaymentOptionMetadata[];
16
11
  loading: boolean;
17
12
  error: string | null;
18
13
  }
@@ -26,6 +21,7 @@ export interface UseDepositAddressOptionsReturn {
26
21
  * Currently supported chains:
27
22
  * - Base (Chain ID: 8453) - Primary EVM chain
28
23
  * - Polygon (Chain ID: 137) - Secondary EVM chain
24
+ * - Ethereum (Chain ID: 1) - Ethereum mainnet
29
25
  * - BSC (Chain ID: 56) - Conditional support for MP app IDs
30
26
  */
31
27
  export declare function useDepositAddressOptions({ trpc, usdRequired, mode, appId, }: UseDepositAddressOptionsParams): UseDepositAddressOptionsReturn;
@@ -1,7 +1,6 @@
1
- import { DepositAddressPaymentOptionData, DepositAddressPaymentOptionMetadata, DepositAddressPaymentOptions, ExternalPaymentOptionMetadata, ExternalPaymentOptions, ExternalPaymentOptionsString, WalletPaymentOption } from "@rozoai/intent-common";
1
+ import { DepositAddressPaymentOptionData, DepositAddressPaymentOptionMetadata, DepositAddressPaymentOptions, ExternalPaymentOptionMetadata, ExternalPaymentOptions, ExternalPaymentOptionsString, PaymentResponse, WalletPaymentOption } from "@rozoai/intent-common";
2
2
  import { Hex } from "viem";
3
- import { PaymentResponseData } from "@rozoai/intent-common";
4
- import { PayButtonPaymentProps } from "../components/DaimoPayButton";
3
+ import { PayButtonPaymentProps } from "../components/DaimoPayButton/types";
5
4
  import { ROUTES } from "../constants/routes";
6
5
  import { PaymentEvent, PayParams } from "../payment/paymentFsm";
7
6
  import { Store } from "../stateStore";
@@ -100,7 +99,7 @@ export interface PaymentState {
100
99
  solanaPubKey: string | undefined;
101
100
  stellarPubKey: string | undefined;
102
101
  orderUsdAmount: number | undefined;
103
- createPayment: (option: WalletPaymentOption, store: Store<PaymentState, PaymentEvent>) => Promise<PaymentResponseData | undefined>;
102
+ createPayment: (option: WalletPaymentOption, store: Store<PaymentState, PaymentEvent>) => Promise<PaymentResponse | undefined>;
104
103
  }
105
104
  export declare function usePaymentState({ trpc, lockPayParams, setRoute, log, redirectReturnUrl, }: {
106
105
  trpc: TrpcClient;
@@ -3,6 +3,8 @@ import { PayParams } from "../payment/paymentFsm";
3
3
  * Return type for the useSolanaDestination hook
4
4
  */
5
5
  interface SolanaDestinationResult {
6
+ /** Whether the payout destination is Solana */
7
+ readonly isPayOutToSolana: boolean;
6
8
  /** The middleware address to use for the transaction */
7
9
  readonly destinationAddress: string | undefined;
8
10
  /** Whether this is a Solana payment (Pay In Solana scenarios) */
@@ -6,10 +6,10 @@ import { Token } from "@rozoai/intent-common";
6
6
  * with dynamic logic for including BSC/Worldchain based on appId or preferences.
7
7
  *
8
8
  * CURRENTLY SUPPORTED CHAINS/TOKENS:
9
- * - Base (8453) - USDC
10
- * - Polygon (137) - USDC
11
- * - BSC (56) - USDT (only for MugglePay apps/pref)
12
- * - Worldchain (20240101) - USDC (only for World apps/pref)
9
+ * - All chains/tokens from supportedChains and supportedTokens (from @rozoai/intent-common)
10
+ * - Includes: Arbitrum, Avalanche, Base, Ethereum, Gnosis, Optimism, Polygon, Solana, Stellar
11
+ * - BSC (56) - USDT (only for MugglePay apps - appId includes "MP")
12
+ * - Worldchain (480) - USDC (only for World apps or if in preferredChains)
13
13
  *
14
14
  * @param {string} appId - The Rozo appId; can affect which chains are enabled.
15
15
  * @param {number[]} [preferredChains=[]] - Preferred chain IDs (may enable Worldchain).
@@ -1,6 +1,24 @@
1
1
  import { WalletPaymentOption } from "@rozoai/intent-common";
2
2
  import { PayParams } from "../payment/paymentFsm";
3
3
  import { TrpcClient } from "../utils/trpc";
4
+ /**
5
+ * Wallet payment options. User picks one.
6
+ *
7
+ * This hook manages wallet-based payment options by:
8
+ * 1. Fetching available payment options from the API based on user's wallet balance
9
+ * 2. Filtering to only show currently supported chains and tokens
10
+ *
11
+ * CURRENTLY SUPPORTED CHAINS & TOKENS IN WALLET PAYMENT OPTIONS:
12
+ * - Base (Chain ID: 8453) - USDC
13
+ * - Polygon (Chain ID: 137) - USDC
14
+ * - Ethereum (Chain ID: 1) - USDC
15
+ * - BSC (Chain ID: 56) - USDT (when MugglePay app, BSC preferred, or user has BSC USDT balance, even if disabled)
16
+ * - Rozo Solana - USDC (native Solana USDC)
17
+ * - Rozo Stellar - USDC/XLM (native Stellar tokens)
18
+ *
19
+ * Note: The SDK supports many more chains/tokens (see pay-common/src/chain.ts and token.ts)
20
+ * but wallet payment options are currently filtered to the above for optimal user experience.
21
+ */
4
22
  export declare function useWalletPaymentOptions({ trpc, address, usdRequired, destChainId, preferredChains, preferredTokens, evmChains, isDepositFlow, payParams, log, }: {
5
23
  trpc: TrpcClient;
6
24
  address: string | undefined;
package/build/index.d.ts CHANGED
@@ -2,7 +2,8 @@ export type * as Types from "./types";
2
2
  export { version } from "../package.json";
3
3
  export { default as getDefaultConfig } from "./defaultConfig";
4
4
  export { RozoPayProvider } from "./provider/DaimoPayProvider";
5
- export { RozoPayButton, RozoPayButtonCustomProps, RozoPayButtonProps, RozoPayment, } from "./components/DaimoPayButton";
5
+ export { RozoPayButton } from "./components/DaimoPayButton";
6
+ export type { RozoPayButtonCustomProps, RozoPayButtonProps, } from "./components/DaimoPayButton/types";
6
7
  export { useRozoPay } from "./hooks/useDaimoPay";
7
8
  export { useRozoPayStatus } from "./hooks/useDaimoPayStatus";
8
9
  export { useRozoPayUI } from "./hooks/useDaimoPayUI";
@@ -11,6 +12,8 @@ export { default as ChainIcon } from "./components/Common/Chain";
11
12
  export { wallets } from "./wallets";
12
13
  export * from "./utils/exports";
13
14
  export * from "./types";
15
+ export { EVM_CHAIN_IDS, getChainTypeName, isEvmChain, isSolanaChain, isStellarChain, isValidEvmAddress, isValidSolanaAddress, isValidStellarAddress, NON_EVM_CHAIN_IDS, validateAddressForChain, } from "./types/chainAddress";
16
+ export type { EvmChainId, NonEvmChainId, SupportedChainId, } from "./types/chainAddress";
14
17
  export { usePayContext } from "./hooks/usePayContext";
15
18
  export { PayContext as RozoPayContext } from "./provider/PayContext";
16
19
  export { useRozoConnectStellar } from "./provider/StellarContextProvider";
@@ -1,5 +1,5 @@
1
1
  var name = "@rozoai/intent-pay";
2
- var version = "0.0.42";
2
+ var version = "0.0.43-beta.2";
3
3
  var author = "RozoAI";
4
4
  var homepage = "https://github.com/RozoAI/intent-pay";
5
5
  var license = "BSD-2-Clause";
@@ -49,7 +49,7 @@ var dependencies = {
49
49
  "@albedo-link/intent": "^0.13.0",
50
50
  "@reown/appkit": "^1.7.0",
51
51
  "@rollup/plugin-typescript": "^12.1.2",
52
- "@rozoai/intent-common": "0.0.31",
52
+ "@rozoai/intent-common": "0.0.32-beta.3",
53
53
  "@solana/spl-token": "^0.4.13",
54
54
  "@solana/wallet-adapter-base": "^0.9.23",
55
55
  "@solana/wallet-adapter-react": "^0.15.35",
@@ -6,20 +6,20 @@ export interface PayParams {
6
6
  appId: string;
7
7
  /** Destination chain ID. */
8
8
  toChain: number;
9
- /** The destination token to send. */
10
- toToken: Address;
9
+ /** The destination token to send. Address for EVM, string for non-EVM. */
10
+ toToken: Address | string;
11
11
  /**
12
12
  * The amount of the token to send.
13
13
  * If not provided, the user will be prompted to enter an amount.
14
14
  */
15
15
  toUnits?: string;
16
- /** The final address to transfer to or contract to call. */
17
- toAddress: Address;
16
+ /** The final EVM address to transfer to or contract to call. */
17
+ toAddress?: Address;
18
18
  /** The final stellar address to transfer to. */
19
19
  toStellarAddress?: string;
20
20
  /** The final solana address to transfer to. */
21
21
  toSolanaAddress?: string;
22
- /** Calldata for final call, or empty data for transfer. */
22
+ /** Calldata for final call, or empty data for transfer. EVM only. */
23
23
  toCallData?: Hex;
24
24
  /** The intent verb, such as Pay, Deposit, or Purchase. Default: Pay */
25
25
  intent?: string;
@@ -30,7 +30,7 @@ export interface PayParams {
30
30
  /** Preferred tokens. These appear first in the token list. */
31
31
  preferredTokens?: {
32
32
  chain: number;
33
- address: Address;
33
+ address: Address | string;
34
34
  }[];
35
35
  /** Only allow payments on these EVM chains. */
36
36
  evmChains?: number[];
@@ -38,7 +38,7 @@ export interface PayParams {
38
38
  externalId?: string;
39
39
  /** Developer metadata. E.g. correlation ID. */
40
40
  metadata?: RozoPayUserMetadata;
41
- /** The address to refund to if the payment bounces or a refund is requested. */
41
+ /** The address to refund to if the payment bounces or a refund is requested. EVM only. */
42
42
  refundAddress?: Address;
43
43
  /** Optional configuration to show processing pay out loading when payment completed */
44
44
  showProcessingPayout?: boolean;
@@ -136,7 +136,6 @@ type PayParamsData = {
136
136
  toStellarAddress?: string;
137
137
  toSolanaAddress?: string;
138
138
  toAddress?: string;
139
- rozoAppId?: string;
140
139
  metadata?: RozoPayUserMetadata;
141
140
  };
142
141
  /**
@@ -3,7 +3,7 @@ import { getAddressContraction } from '@rozoai/intent-common';
3
3
  import { useWallet } from '@solana/wallet-adapter-react';
4
4
  import { motion } from 'framer-motion';
5
5
  import { useAccount } from 'wagmi';
6
- import { Solana, Stellar, Base, Polygon, BinanceSmartChain, Worldchain } from '../../../assets/chains.js';
6
+ import { Solana, Stellar, Base, Polygon, Ethereum, BinanceSmartChain, Worldchain } from '../../../assets/chains.js';
7
7
  import defaultTheme from '../../../constants/defaultTheme.js';
8
8
  import { ROUTES } from '../../../constants/routes.js';
9
9
  import { useRozoPay } from '../../../hooks/useDaimoPay.js';
@@ -58,13 +58,13 @@ const OrderHeader = ({ minified = false, show = "all", excludeLogos = [], }) =>
58
58
  };
59
59
  function CoinLogos({ $size = 24, $exclude = [], appId, }) {
60
60
  const logos = [
61
- // <Ethereum key="eth" />,
62
61
  // <Tron key="tron" />,
63
62
  // <USDC key="usdc" />,
64
63
  // <Optimism key="optimism" />,
65
64
  // <Arbitrum key="arbitrum" />,
66
65
  jsx(Base, {}, "base"),
67
66
  jsx(Polygon, {}, "polygon"),
67
+ jsx(Ethereum, {}, "ethereum"),
68
68
  ];
69
69
  if (appId?.includes("MP")) {
70
70
  logos.push(jsx(BinanceSmartChain, {}, "bsc"));
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../../src/components/Common/OrderHeader/index.tsx"],"sourcesContent":[null],"names":["_jsx","_jsxs","_Fragment"],"mappings":";;;;;;;;;;;;;;AAqBA;AACa,MAAA,WAAW,GAAG,CAAC,EAC1B,QAAQ,GAAG,KAAK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AA;aACrC,CAAC,KAAK,KAAK,KAAK,CAAC,OAAO,IAAI,CAAC,CAAA;AAC/B,SAAA,EAAA,CAAC,KAAK,KAAK,KAAK,CAAC,KAAK,CAAA;AACrB,UAAA,EAAA,CAAC,KAAK,KAAK,KAAK,CAAC,KAAK,CAAA;;;;;;;CAOjC,CAAC;AAEF,MAAM,KAAK,GAAG,MAAM,CAAC,MAAM,CAAC,GAAG,CAAC,CAAA,CAAA;;;;CAI/B,CAAC;AAEF,MAAM,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAAA,CAAA;;;;;CAKnC;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../../src/components/Common/OrderHeader/index.tsx"],"sourcesContent":[null],"names":["_jsx","_jsxs","_Fragment"],"mappings":";;;;;;;;;;;;;;AAsBA;AACa,MAAA,WAAW,GAAG,CAAC,EAC1B,QAAQ,GAAG,KAAK,EAChB,IAAI,GAAG,KAAK,EACZ,YAAY,GAAG,EAAE,GAKlB,KAAI;IACH,MAAM,EAAE,YAAY,EAAE,KAAK,EAAE,GAAG,aAAa,EAAE,CAAC;AAChD,IAAA,MAAM,EAAE,WAAW,EAAE,cAAc,EAAE,OAAO,EAAE,SAAS,EAAE,GAAG,UAAU,EAAE,CAAC;AACzE,IAAA,MAAM,EACJ,SAAS,EAAE,iBAAiB,EAC5B,SAAS,EACT,MAAM,EAAE,YAAY,GACrB,GAAG,SAAS,EAAE,CAAC;AAChB,IAAA,MAAM,EAAE,aAAa,EAAE,GAAG,YAAY,CAAC;AACvC,IAAA,MAAM,EACJ,WAAW,EAAE,kBAAkB,EAC/B,SAAS,EAAE,gBAAgB,EAC3B,SAAS,EAAE,gBAAgB,GAC5B,GAAG,UAAU,EAAE,CAAC;AACjB,IAAA,MAAM,EAAE,KAAK,EAAE,GAAG,UAAU,EAAE,CAAC;AAE/B,IAAA,MAAM,oBAAoB,GACxB,aAAa,KAAK,OAAO,GAAG,qBAAqB,CAAC,OAAO,CAAC,GAAG,QAAQ,CA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