@paxoslabs/amplify-sdk 0.0.2 → 0.1.0-alpha.0
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.
- package/CHANGELOG.md +22 -1
- package/README.md +1 -1
- package/dist/{amplify-sdk-api-DPrRhynk.d.mts → amplify-sdk-api-Biol0OIp.d.mts} +1 -1
- package/dist/{amplify-sdk-api-B5hBTGrB.d.ts → amplify-sdk-api-DGRgEybp.d.ts} +1 -1
- package/dist/{chunk-IBNTWZ4S.js → chunk-B2QCI6ET.js} +13 -35
- package/dist/chunk-B2QCI6ET.js.map +1 -0
- package/dist/{chunk-WFCHKDDG.mjs → chunk-CUGK4ZBJ.mjs} +13 -35
- package/dist/chunk-CUGK4ZBJ.mjs.map +1 -0
- package/dist/{chunk-ANL3PE7L.js → chunk-DTFLXAZJ.js} +21 -46
- package/dist/chunk-DTFLXAZJ.js.map +1 -0
- package/dist/{chunk-NLLEYTJ6.js → chunk-GS7TDQXA.js} +8 -8
- package/dist/{chunk-NLLEYTJ6.js.map → chunk-GS7TDQXA.js.map} +1 -1
- package/dist/{chunk-774KTF7A.mjs → chunk-HI44AMLC.mjs} +4 -4
- package/dist/{chunk-774KTF7A.mjs.map → chunk-HI44AMLC.mjs.map} +1 -1
- package/dist/{chunk-BMN6KTOC.js → chunk-KYR6BFAE.js} +20 -20
- package/dist/{chunk-BMN6KTOC.js.map → chunk-KYR6BFAE.js.map} +1 -1
- package/dist/{chunk-K4DL2AII.js → chunk-LSNRG5Z2.js} +4 -4
- package/dist/{chunk-K4DL2AII.js.map → chunk-LSNRG5Z2.js.map} +1 -1
- package/dist/{chunk-OPOYGPSS.mjs → chunk-REKEQLQA.mjs} +3 -3
- package/dist/{chunk-OPOYGPSS.mjs.map → chunk-REKEQLQA.mjs.map} +1 -1
- package/dist/{chunk-SYVANMRO.mjs → chunk-VIULRHK6.mjs} +3 -3
- package/dist/{chunk-SYVANMRO.mjs.map → chunk-VIULRHK6.mjs.map} +1 -1
- package/dist/{chunk-LVJ44U7Z.mjs → chunk-ZILA73XN.mjs} +19 -44
- package/dist/chunk-ZILA73XN.mjs.map +1 -0
- package/dist/core.js +14 -14
- package/dist/core.mjs +4 -4
- package/dist/display.js +12 -12
- package/dist/display.js.map +1 -1
- package/dist/display.mjs +4 -4
- package/dist/display.mjs.map +1 -1
- package/dist/index.d.mts +235 -5
- package/dist/index.d.ts +235 -5
- package/dist/index.js +323 -147
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +231 -55
- package/dist/index.mjs.map +1 -1
- package/dist/utils.d.mts +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js +5 -5
- package/dist/utils.mjs +2 -2
- package/package.json +1 -1
- package/dist/chunk-ANL3PE7L.js.map +0 -1
- package/dist/chunk-IBNTWZ4S.js.map +0 -1
- package/dist/chunk-LVJ44U7Z.mjs.map +0 -1
- package/dist/chunk-WFCHKDDG.mjs.map +0 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Address, erc20Abi, Hex } from 'viem';
|
|
2
|
-
import { A as AmplifyVault, S as SupportedAsset, a as AssetFilterOptions, V as VaultFilterOptions, W as WithdrawSupportedAsset } from './amplify-sdk-api-
|
|
3
|
-
export { b as APIError } from './amplify-sdk-api-
|
|
1
|
+
import { Address, erc20Abi, ByteArray, Hex } from 'viem';
|
|
2
|
+
import { A as AmplifyVault, S as SupportedAsset, a as AssetFilterOptions, V as VaultFilterOptions, W as WithdrawSupportedAsset } from './amplify-sdk-api-Biol0OIp.mjs';
|
|
3
|
+
export { b as APIError } from './amplify-sdk-api-Biol0OIp.mjs';
|
|
4
4
|
export { g as getDepositExchangeRate, a as getWithdrawExchangeRate, i as isDepositSpendApproved, b as isWithdrawalSpendApproved } from './exchange-rate-BfPH_fQt.mjs';
|
|
5
5
|
import { Y as YieldType } from './config-B-u3VqEX.mjs';
|
|
6
6
|
import { C as ChainId } from './vault-config-BjSE7oL8.mjs';
|
|
@@ -509,6 +509,228 @@ interface ApproveDepositTokenTxData {
|
|
|
509
509
|
*/
|
|
510
510
|
declare function prepareApproveDepositTokenTxData({ yieldType, depositToken, approvalAmount, chainId, }: PrepareApproveDepositTokenTxParams): Promise<ApproveDepositTokenTxData>;
|
|
511
511
|
|
|
512
|
+
declare const CommunityCodeDepositorAbi: readonly [{
|
|
513
|
+
readonly type: "constructor";
|
|
514
|
+
readonly inputs: readonly [{
|
|
515
|
+
readonly name: "_teller";
|
|
516
|
+
readonly type: "address";
|
|
517
|
+
readonly internalType: "address";
|
|
518
|
+
}, {
|
|
519
|
+
readonly name: "_owner";
|
|
520
|
+
readonly type: "address";
|
|
521
|
+
readonly internalType: "address";
|
|
522
|
+
}];
|
|
523
|
+
readonly stateMutability: "nonpayable";
|
|
524
|
+
}, {
|
|
525
|
+
readonly type: "function";
|
|
526
|
+
readonly name: "authority";
|
|
527
|
+
readonly inputs: readonly [];
|
|
528
|
+
readonly outputs: readonly [{
|
|
529
|
+
readonly name: "";
|
|
530
|
+
readonly type: "address";
|
|
531
|
+
readonly internalType: "contract Authority";
|
|
532
|
+
}];
|
|
533
|
+
readonly stateMutability: "view";
|
|
534
|
+
}, {
|
|
535
|
+
readonly type: "function";
|
|
536
|
+
readonly name: "boringVault";
|
|
537
|
+
readonly inputs: readonly [];
|
|
538
|
+
readonly outputs: readonly [{
|
|
539
|
+
readonly name: "";
|
|
540
|
+
readonly type: "address";
|
|
541
|
+
readonly internalType: "address";
|
|
542
|
+
}];
|
|
543
|
+
readonly stateMutability: "view";
|
|
544
|
+
}, {
|
|
545
|
+
readonly type: "function";
|
|
546
|
+
readonly name: "deposit";
|
|
547
|
+
readonly inputs: readonly [{
|
|
548
|
+
readonly name: "depositAsset";
|
|
549
|
+
readonly type: "address";
|
|
550
|
+
readonly internalType: "contract ERC20";
|
|
551
|
+
}, {
|
|
552
|
+
readonly name: "depositAmount";
|
|
553
|
+
readonly type: "uint256";
|
|
554
|
+
readonly internalType: "uint256";
|
|
555
|
+
}, {
|
|
556
|
+
readonly name: "minimumMint";
|
|
557
|
+
readonly type: "uint256";
|
|
558
|
+
readonly internalType: "uint256";
|
|
559
|
+
}, {
|
|
560
|
+
readonly name: "to";
|
|
561
|
+
readonly type: "address";
|
|
562
|
+
readonly internalType: "address";
|
|
563
|
+
}, {
|
|
564
|
+
readonly name: "communityCode";
|
|
565
|
+
readonly type: "bytes";
|
|
566
|
+
readonly internalType: "bytes";
|
|
567
|
+
}];
|
|
568
|
+
readonly outputs: readonly [{
|
|
569
|
+
readonly name: "shares";
|
|
570
|
+
readonly type: "uint256";
|
|
571
|
+
readonly internalType: "uint256";
|
|
572
|
+
}];
|
|
573
|
+
readonly stateMutability: "nonpayable";
|
|
574
|
+
}, {
|
|
575
|
+
readonly type: "function";
|
|
576
|
+
readonly name: "depositNative";
|
|
577
|
+
readonly inputs: readonly [{
|
|
578
|
+
readonly name: "depositAmount";
|
|
579
|
+
readonly type: "uint256";
|
|
580
|
+
readonly internalType: "uint256";
|
|
581
|
+
}, {
|
|
582
|
+
readonly name: "minimumMint";
|
|
583
|
+
readonly type: "uint256";
|
|
584
|
+
readonly internalType: "uint256";
|
|
585
|
+
}, {
|
|
586
|
+
readonly name: "to";
|
|
587
|
+
readonly type: "address";
|
|
588
|
+
readonly internalType: "address";
|
|
589
|
+
}, {
|
|
590
|
+
readonly name: "communityCode";
|
|
591
|
+
readonly type: "bytes";
|
|
592
|
+
readonly internalType: "bytes";
|
|
593
|
+
}];
|
|
594
|
+
readonly outputs: readonly [{
|
|
595
|
+
readonly name: "shares";
|
|
596
|
+
readonly type: "uint256";
|
|
597
|
+
readonly internalType: "uint256";
|
|
598
|
+
}];
|
|
599
|
+
readonly stateMutability: "payable";
|
|
600
|
+
}, {
|
|
601
|
+
readonly type: "function";
|
|
602
|
+
readonly name: "depositNonce";
|
|
603
|
+
readonly inputs: readonly [];
|
|
604
|
+
readonly outputs: readonly [{
|
|
605
|
+
readonly name: "";
|
|
606
|
+
readonly type: "uint256";
|
|
607
|
+
readonly internalType: "uint256";
|
|
608
|
+
}];
|
|
609
|
+
readonly stateMutability: "view";
|
|
610
|
+
}, {
|
|
611
|
+
readonly type: "function";
|
|
612
|
+
readonly name: "owner";
|
|
613
|
+
readonly inputs: readonly [];
|
|
614
|
+
readonly outputs: readonly [{
|
|
615
|
+
readonly name: "";
|
|
616
|
+
readonly type: "address";
|
|
617
|
+
readonly internalType: "address";
|
|
618
|
+
}];
|
|
619
|
+
readonly stateMutability: "view";
|
|
620
|
+
}, {
|
|
621
|
+
readonly type: "function";
|
|
622
|
+
readonly name: "setAuthority";
|
|
623
|
+
readonly inputs: readonly [{
|
|
624
|
+
readonly name: "newAuthority";
|
|
625
|
+
readonly type: "address";
|
|
626
|
+
readonly internalType: "contract Authority";
|
|
627
|
+
}];
|
|
628
|
+
readonly outputs: readonly [];
|
|
629
|
+
readonly stateMutability: "nonpayable";
|
|
630
|
+
}, {
|
|
631
|
+
readonly type: "function";
|
|
632
|
+
readonly name: "teller";
|
|
633
|
+
readonly inputs: readonly [];
|
|
634
|
+
readonly outputs: readonly [{
|
|
635
|
+
readonly name: "";
|
|
636
|
+
readonly type: "address";
|
|
637
|
+
readonly internalType: "contract TellerWithMultiAssetSupport";
|
|
638
|
+
}];
|
|
639
|
+
readonly stateMutability: "view";
|
|
640
|
+
}, {
|
|
641
|
+
readonly type: "function";
|
|
642
|
+
readonly name: "transferOwnership";
|
|
643
|
+
readonly inputs: readonly [{
|
|
644
|
+
readonly name: "newOwner";
|
|
645
|
+
readonly type: "address";
|
|
646
|
+
readonly internalType: "address";
|
|
647
|
+
}];
|
|
648
|
+
readonly outputs: readonly [];
|
|
649
|
+
readonly stateMutability: "nonpayable";
|
|
650
|
+
}, {
|
|
651
|
+
readonly type: "event";
|
|
652
|
+
readonly name: "AuthorityUpdated";
|
|
653
|
+
readonly inputs: readonly [{
|
|
654
|
+
readonly name: "user";
|
|
655
|
+
readonly type: "address";
|
|
656
|
+
readonly indexed: true;
|
|
657
|
+
readonly internalType: "address";
|
|
658
|
+
}, {
|
|
659
|
+
readonly name: "newAuthority";
|
|
660
|
+
readonly type: "address";
|
|
661
|
+
readonly indexed: true;
|
|
662
|
+
readonly internalType: "contract Authority";
|
|
663
|
+
}];
|
|
664
|
+
readonly anonymous: false;
|
|
665
|
+
}, {
|
|
666
|
+
readonly type: "event";
|
|
667
|
+
readonly name: "DepositWithCommunityCode";
|
|
668
|
+
readonly inputs: readonly [{
|
|
669
|
+
readonly name: "depositor";
|
|
670
|
+
readonly type: "address";
|
|
671
|
+
readonly indexed: true;
|
|
672
|
+
readonly internalType: "address";
|
|
673
|
+
}, {
|
|
674
|
+
readonly name: "depositAsset";
|
|
675
|
+
readonly type: "address";
|
|
676
|
+
readonly indexed: true;
|
|
677
|
+
readonly internalType: "contract ERC20";
|
|
678
|
+
}, {
|
|
679
|
+
readonly name: "depositAmount";
|
|
680
|
+
readonly type: "uint256";
|
|
681
|
+
readonly indexed: false;
|
|
682
|
+
readonly internalType: "uint256";
|
|
683
|
+
}, {
|
|
684
|
+
readonly name: "minimumMint";
|
|
685
|
+
readonly type: "uint256";
|
|
686
|
+
readonly indexed: false;
|
|
687
|
+
readonly internalType: "uint256";
|
|
688
|
+
}, {
|
|
689
|
+
readonly name: "to";
|
|
690
|
+
readonly type: "address";
|
|
691
|
+
readonly indexed: true;
|
|
692
|
+
readonly internalType: "address";
|
|
693
|
+
}, {
|
|
694
|
+
readonly name: "depositHash";
|
|
695
|
+
readonly type: "bytes32";
|
|
696
|
+
readonly indexed: false;
|
|
697
|
+
readonly internalType: "bytes32";
|
|
698
|
+
}, {
|
|
699
|
+
readonly name: "communityCode";
|
|
700
|
+
readonly type: "bytes";
|
|
701
|
+
readonly indexed: false;
|
|
702
|
+
readonly internalType: "bytes";
|
|
703
|
+
}];
|
|
704
|
+
readonly anonymous: false;
|
|
705
|
+
}, {
|
|
706
|
+
readonly type: "event";
|
|
707
|
+
readonly name: "OwnershipTransferred";
|
|
708
|
+
readonly inputs: readonly [{
|
|
709
|
+
readonly name: "user";
|
|
710
|
+
readonly type: "address";
|
|
711
|
+
readonly indexed: true;
|
|
712
|
+
readonly internalType: "address";
|
|
713
|
+
}, {
|
|
714
|
+
readonly name: "newOwner";
|
|
715
|
+
readonly type: "address";
|
|
716
|
+
readonly indexed: true;
|
|
717
|
+
readonly internalType: "address";
|
|
718
|
+
}];
|
|
719
|
+
readonly anonymous: false;
|
|
720
|
+
}, {
|
|
721
|
+
readonly type: "error";
|
|
722
|
+
readonly name: "IncorrectNativeDepositAmount";
|
|
723
|
+
readonly inputs: readonly [];
|
|
724
|
+
}, {
|
|
725
|
+
readonly type: "error";
|
|
726
|
+
readonly name: "NativeWrapperAccountantDecimalsMismatch";
|
|
727
|
+
readonly inputs: readonly [];
|
|
728
|
+
}, {
|
|
729
|
+
readonly type: "error";
|
|
730
|
+
readonly name: "ZeroAddress";
|
|
731
|
+
readonly inputs: readonly [];
|
|
732
|
+
}];
|
|
733
|
+
|
|
512
734
|
declare const TellerAbi: readonly [{
|
|
513
735
|
readonly inputs: readonly [{
|
|
514
736
|
readonly internalType: "address";
|
|
@@ -1796,6 +2018,13 @@ interface DepositTxData {
|
|
|
1796
2018
|
args: [Address, bigint, bigint];
|
|
1797
2019
|
chainId: number;
|
|
1798
2020
|
}
|
|
2021
|
+
interface CommunityCodeDepositTxData {
|
|
2022
|
+
abi: typeof CommunityCodeDepositorAbi;
|
|
2023
|
+
address: Address;
|
|
2024
|
+
functionName: "deposit";
|
|
2025
|
+
args: [Address, bigint, bigint, Address, ByteArray];
|
|
2026
|
+
chainId: number;
|
|
2027
|
+
}
|
|
1799
2028
|
/**
|
|
1800
2029
|
* Parameters for prepareDepositTransactionData()
|
|
1801
2030
|
* Accepts yieldType, recipientAddress, depositToken, and chainId for automatic vault resolution
|
|
@@ -1814,6 +2043,7 @@ interface PrepareDepositTxDataParams {
|
|
|
1814
2043
|
depositAmount: string;
|
|
1815
2044
|
chainId: ChainId;
|
|
1816
2045
|
slippage?: number;
|
|
2046
|
+
partnerCode?: string;
|
|
1817
2047
|
}
|
|
1818
2048
|
/**
|
|
1819
2049
|
* Prepares the transaction data needed to deposit assets into a vault
|
|
@@ -1837,7 +2067,7 @@ interface PrepareDepositTxDataParams {
|
|
|
1837
2067
|
* @returns {Promise<DepositTransactionData>} Promise resolving to the prepared transaction data
|
|
1838
2068
|
* @throws {APIError} If vault cannot be resolved, asset not found, or contracts not configured
|
|
1839
2069
|
*/
|
|
1840
|
-
declare function prepareDepositTxData(params: PrepareDepositTxDataParams): Promise<DepositTxData>;
|
|
2070
|
+
declare function prepareDepositTxData(params: PrepareDepositTxDataParams): Promise<DepositTxData | CommunityCodeDepositTxData>;
|
|
1841
2071
|
|
|
1842
2072
|
/**
|
|
1843
2073
|
* @file Deposit with permit functionality for Nucleus vaults
|
|
@@ -3233,4 +3463,4 @@ interface WithdrawTxData {
|
|
|
3233
3463
|
*/
|
|
3234
3464
|
declare const prepareWithdrawTxData: ({ yieldType, wantAssetAddress, chainId, offerAmount, deadline, slippage, }: PrepareWithdrawTxDataParams) => Promise<WithdrawTxData>;
|
|
3235
3465
|
|
|
3236
|
-
export { AmplifyVault, type ApproveDepositTokenTxData, type ApproveWithdrawTokenTxData, AssetFilterOptions, type BulkWithdrawTxData, type DepositTxData, type EIP712Domain, type InitErrorCode, PERMIT_TYPES, type ParsedPermitSignature, type PermitSignatureData, type PrepareDepositPermitSignatureParams, type PrepareDepositWithPermitTxDataParams, type RequestHeaders, type SDKConfig, SupportedAsset, type UnencodedDepositWithPermitData, VaultFilterOptions, WithdrawSupportedAsset, type WithdrawTxData, YieldType, fetchSupportedAssets, fetchVaults, findVaultByConfig, getAssetsFromCache, getCache, getWithdrawSupportedAssets, initAmplifySDK, initializeCache, parsePermitSignature, prepareApproveDepositTokenTxData, prepareApproveWithdrawTxData, prepareBulkWithdrawTxData, prepareDepositPermitSignature, prepareDepositTxData, prepareDepositWithPermitTxData, prepareWithdrawTxData, refreshVaultCache };
|
|
3466
|
+
export { AmplifyVault, type ApproveDepositTokenTxData, type ApproveWithdrawTokenTxData, AssetFilterOptions, type BulkWithdrawTxData, type CommunityCodeDepositTxData, type DepositTxData, type EIP712Domain, type InitErrorCode, PERMIT_TYPES, type ParsedPermitSignature, type PermitSignatureData, type PrepareDepositPermitSignatureParams, type PrepareDepositWithPermitTxDataParams, type RequestHeaders, type SDKConfig, SupportedAsset, type UnencodedDepositWithPermitData, VaultFilterOptions, WithdrawSupportedAsset, type WithdrawTxData, YieldType, fetchSupportedAssets, fetchVaults, findVaultByConfig, getAssetsFromCache, getCache, getWithdrawSupportedAssets, initAmplifySDK, initializeCache, parsePermitSignature, prepareApproveDepositTokenTxData, prepareApproveWithdrawTxData, prepareBulkWithdrawTxData, prepareDepositPermitSignature, prepareDepositTxData, prepareDepositWithPermitTxData, prepareWithdrawTxData, refreshVaultCache };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Address, erc20Abi, Hex } from 'viem';
|
|
2
|
-
import { A as AmplifyVault, S as SupportedAsset, a as AssetFilterOptions, V as VaultFilterOptions, W as WithdrawSupportedAsset } from './amplify-sdk-api-
|
|
3
|
-
export { b as APIError } from './amplify-sdk-api-
|
|
1
|
+
import { Address, erc20Abi, ByteArray, Hex } from 'viem';
|
|
2
|
+
import { A as AmplifyVault, S as SupportedAsset, a as AssetFilterOptions, V as VaultFilterOptions, W as WithdrawSupportedAsset } from './amplify-sdk-api-DGRgEybp.js';
|
|
3
|
+
export { b as APIError } from './amplify-sdk-api-DGRgEybp.js';
|
|
4
4
|
export { g as getDepositExchangeRate, a as getWithdrawExchangeRate, i as isDepositSpendApproved, b as isWithdrawalSpendApproved } from './exchange-rate-Cp1ddpw4.js';
|
|
5
5
|
import { Y as YieldType } from './config-B-u3VqEX.js';
|
|
6
6
|
import { C as ChainId } from './vault-config-BNzhv3QV.js';
|
|
@@ -509,6 +509,228 @@ interface ApproveDepositTokenTxData {
|
|
|
509
509
|
*/
|
|
510
510
|
declare function prepareApproveDepositTokenTxData({ yieldType, depositToken, approvalAmount, chainId, }: PrepareApproveDepositTokenTxParams): Promise<ApproveDepositTokenTxData>;
|
|
511
511
|
|
|
512
|
+
declare const CommunityCodeDepositorAbi: readonly [{
|
|
513
|
+
readonly type: "constructor";
|
|
514
|
+
readonly inputs: readonly [{
|
|
515
|
+
readonly name: "_teller";
|
|
516
|
+
readonly type: "address";
|
|
517
|
+
readonly internalType: "address";
|
|
518
|
+
}, {
|
|
519
|
+
readonly name: "_owner";
|
|
520
|
+
readonly type: "address";
|
|
521
|
+
readonly internalType: "address";
|
|
522
|
+
}];
|
|
523
|
+
readonly stateMutability: "nonpayable";
|
|
524
|
+
}, {
|
|
525
|
+
readonly type: "function";
|
|
526
|
+
readonly name: "authority";
|
|
527
|
+
readonly inputs: readonly [];
|
|
528
|
+
readonly outputs: readonly [{
|
|
529
|
+
readonly name: "";
|
|
530
|
+
readonly type: "address";
|
|
531
|
+
readonly internalType: "contract Authority";
|
|
532
|
+
}];
|
|
533
|
+
readonly stateMutability: "view";
|
|
534
|
+
}, {
|
|
535
|
+
readonly type: "function";
|
|
536
|
+
readonly name: "boringVault";
|
|
537
|
+
readonly inputs: readonly [];
|
|
538
|
+
readonly outputs: readonly [{
|
|
539
|
+
readonly name: "";
|
|
540
|
+
readonly type: "address";
|
|
541
|
+
readonly internalType: "address";
|
|
542
|
+
}];
|
|
543
|
+
readonly stateMutability: "view";
|
|
544
|
+
}, {
|
|
545
|
+
readonly type: "function";
|
|
546
|
+
readonly name: "deposit";
|
|
547
|
+
readonly inputs: readonly [{
|
|
548
|
+
readonly name: "depositAsset";
|
|
549
|
+
readonly type: "address";
|
|
550
|
+
readonly internalType: "contract ERC20";
|
|
551
|
+
}, {
|
|
552
|
+
readonly name: "depositAmount";
|
|
553
|
+
readonly type: "uint256";
|
|
554
|
+
readonly internalType: "uint256";
|
|
555
|
+
}, {
|
|
556
|
+
readonly name: "minimumMint";
|
|
557
|
+
readonly type: "uint256";
|
|
558
|
+
readonly internalType: "uint256";
|
|
559
|
+
}, {
|
|
560
|
+
readonly name: "to";
|
|
561
|
+
readonly type: "address";
|
|
562
|
+
readonly internalType: "address";
|
|
563
|
+
}, {
|
|
564
|
+
readonly name: "communityCode";
|
|
565
|
+
readonly type: "bytes";
|
|
566
|
+
readonly internalType: "bytes";
|
|
567
|
+
}];
|
|
568
|
+
readonly outputs: readonly [{
|
|
569
|
+
readonly name: "shares";
|
|
570
|
+
readonly type: "uint256";
|
|
571
|
+
readonly internalType: "uint256";
|
|
572
|
+
}];
|
|
573
|
+
readonly stateMutability: "nonpayable";
|
|
574
|
+
}, {
|
|
575
|
+
readonly type: "function";
|
|
576
|
+
readonly name: "depositNative";
|
|
577
|
+
readonly inputs: readonly [{
|
|
578
|
+
readonly name: "depositAmount";
|
|
579
|
+
readonly type: "uint256";
|
|
580
|
+
readonly internalType: "uint256";
|
|
581
|
+
}, {
|
|
582
|
+
readonly name: "minimumMint";
|
|
583
|
+
readonly type: "uint256";
|
|
584
|
+
readonly internalType: "uint256";
|
|
585
|
+
}, {
|
|
586
|
+
readonly name: "to";
|
|
587
|
+
readonly type: "address";
|
|
588
|
+
readonly internalType: "address";
|
|
589
|
+
}, {
|
|
590
|
+
readonly name: "communityCode";
|
|
591
|
+
readonly type: "bytes";
|
|
592
|
+
readonly internalType: "bytes";
|
|
593
|
+
}];
|
|
594
|
+
readonly outputs: readonly [{
|
|
595
|
+
readonly name: "shares";
|
|
596
|
+
readonly type: "uint256";
|
|
597
|
+
readonly internalType: "uint256";
|
|
598
|
+
}];
|
|
599
|
+
readonly stateMutability: "payable";
|
|
600
|
+
}, {
|
|
601
|
+
readonly type: "function";
|
|
602
|
+
readonly name: "depositNonce";
|
|
603
|
+
readonly inputs: readonly [];
|
|
604
|
+
readonly outputs: readonly [{
|
|
605
|
+
readonly name: "";
|
|
606
|
+
readonly type: "uint256";
|
|
607
|
+
readonly internalType: "uint256";
|
|
608
|
+
}];
|
|
609
|
+
readonly stateMutability: "view";
|
|
610
|
+
}, {
|
|
611
|
+
readonly type: "function";
|
|
612
|
+
readonly name: "owner";
|
|
613
|
+
readonly inputs: readonly [];
|
|
614
|
+
readonly outputs: readonly [{
|
|
615
|
+
readonly name: "";
|
|
616
|
+
readonly type: "address";
|
|
617
|
+
readonly internalType: "address";
|
|
618
|
+
}];
|
|
619
|
+
readonly stateMutability: "view";
|
|
620
|
+
}, {
|
|
621
|
+
readonly type: "function";
|
|
622
|
+
readonly name: "setAuthority";
|
|
623
|
+
readonly inputs: readonly [{
|
|
624
|
+
readonly name: "newAuthority";
|
|
625
|
+
readonly type: "address";
|
|
626
|
+
readonly internalType: "contract Authority";
|
|
627
|
+
}];
|
|
628
|
+
readonly outputs: readonly [];
|
|
629
|
+
readonly stateMutability: "nonpayable";
|
|
630
|
+
}, {
|
|
631
|
+
readonly type: "function";
|
|
632
|
+
readonly name: "teller";
|
|
633
|
+
readonly inputs: readonly [];
|
|
634
|
+
readonly outputs: readonly [{
|
|
635
|
+
readonly name: "";
|
|
636
|
+
readonly type: "address";
|
|
637
|
+
readonly internalType: "contract TellerWithMultiAssetSupport";
|
|
638
|
+
}];
|
|
639
|
+
readonly stateMutability: "view";
|
|
640
|
+
}, {
|
|
641
|
+
readonly type: "function";
|
|
642
|
+
readonly name: "transferOwnership";
|
|
643
|
+
readonly inputs: readonly [{
|
|
644
|
+
readonly name: "newOwner";
|
|
645
|
+
readonly type: "address";
|
|
646
|
+
readonly internalType: "address";
|
|
647
|
+
}];
|
|
648
|
+
readonly outputs: readonly [];
|
|
649
|
+
readonly stateMutability: "nonpayable";
|
|
650
|
+
}, {
|
|
651
|
+
readonly type: "event";
|
|
652
|
+
readonly name: "AuthorityUpdated";
|
|
653
|
+
readonly inputs: readonly [{
|
|
654
|
+
readonly name: "user";
|
|
655
|
+
readonly type: "address";
|
|
656
|
+
readonly indexed: true;
|
|
657
|
+
readonly internalType: "address";
|
|
658
|
+
}, {
|
|
659
|
+
readonly name: "newAuthority";
|
|
660
|
+
readonly type: "address";
|
|
661
|
+
readonly indexed: true;
|
|
662
|
+
readonly internalType: "contract Authority";
|
|
663
|
+
}];
|
|
664
|
+
readonly anonymous: false;
|
|
665
|
+
}, {
|
|
666
|
+
readonly type: "event";
|
|
667
|
+
readonly name: "DepositWithCommunityCode";
|
|
668
|
+
readonly inputs: readonly [{
|
|
669
|
+
readonly name: "depositor";
|
|
670
|
+
readonly type: "address";
|
|
671
|
+
readonly indexed: true;
|
|
672
|
+
readonly internalType: "address";
|
|
673
|
+
}, {
|
|
674
|
+
readonly name: "depositAsset";
|
|
675
|
+
readonly type: "address";
|
|
676
|
+
readonly indexed: true;
|
|
677
|
+
readonly internalType: "contract ERC20";
|
|
678
|
+
}, {
|
|
679
|
+
readonly name: "depositAmount";
|
|
680
|
+
readonly type: "uint256";
|
|
681
|
+
readonly indexed: false;
|
|
682
|
+
readonly internalType: "uint256";
|
|
683
|
+
}, {
|
|
684
|
+
readonly name: "minimumMint";
|
|
685
|
+
readonly type: "uint256";
|
|
686
|
+
readonly indexed: false;
|
|
687
|
+
readonly internalType: "uint256";
|
|
688
|
+
}, {
|
|
689
|
+
readonly name: "to";
|
|
690
|
+
readonly type: "address";
|
|
691
|
+
readonly indexed: true;
|
|
692
|
+
readonly internalType: "address";
|
|
693
|
+
}, {
|
|
694
|
+
readonly name: "depositHash";
|
|
695
|
+
readonly type: "bytes32";
|
|
696
|
+
readonly indexed: false;
|
|
697
|
+
readonly internalType: "bytes32";
|
|
698
|
+
}, {
|
|
699
|
+
readonly name: "communityCode";
|
|
700
|
+
readonly type: "bytes";
|
|
701
|
+
readonly indexed: false;
|
|
702
|
+
readonly internalType: "bytes";
|
|
703
|
+
}];
|
|
704
|
+
readonly anonymous: false;
|
|
705
|
+
}, {
|
|
706
|
+
readonly type: "event";
|
|
707
|
+
readonly name: "OwnershipTransferred";
|
|
708
|
+
readonly inputs: readonly [{
|
|
709
|
+
readonly name: "user";
|
|
710
|
+
readonly type: "address";
|
|
711
|
+
readonly indexed: true;
|
|
712
|
+
readonly internalType: "address";
|
|
713
|
+
}, {
|
|
714
|
+
readonly name: "newOwner";
|
|
715
|
+
readonly type: "address";
|
|
716
|
+
readonly indexed: true;
|
|
717
|
+
readonly internalType: "address";
|
|
718
|
+
}];
|
|
719
|
+
readonly anonymous: false;
|
|
720
|
+
}, {
|
|
721
|
+
readonly type: "error";
|
|
722
|
+
readonly name: "IncorrectNativeDepositAmount";
|
|
723
|
+
readonly inputs: readonly [];
|
|
724
|
+
}, {
|
|
725
|
+
readonly type: "error";
|
|
726
|
+
readonly name: "NativeWrapperAccountantDecimalsMismatch";
|
|
727
|
+
readonly inputs: readonly [];
|
|
728
|
+
}, {
|
|
729
|
+
readonly type: "error";
|
|
730
|
+
readonly name: "ZeroAddress";
|
|
731
|
+
readonly inputs: readonly [];
|
|
732
|
+
}];
|
|
733
|
+
|
|
512
734
|
declare const TellerAbi: readonly [{
|
|
513
735
|
readonly inputs: readonly [{
|
|
514
736
|
readonly internalType: "address";
|
|
@@ -1796,6 +2018,13 @@ interface DepositTxData {
|
|
|
1796
2018
|
args: [Address, bigint, bigint];
|
|
1797
2019
|
chainId: number;
|
|
1798
2020
|
}
|
|
2021
|
+
interface CommunityCodeDepositTxData {
|
|
2022
|
+
abi: typeof CommunityCodeDepositorAbi;
|
|
2023
|
+
address: Address;
|
|
2024
|
+
functionName: "deposit";
|
|
2025
|
+
args: [Address, bigint, bigint, Address, ByteArray];
|
|
2026
|
+
chainId: number;
|
|
2027
|
+
}
|
|
1799
2028
|
/**
|
|
1800
2029
|
* Parameters for prepareDepositTransactionData()
|
|
1801
2030
|
* Accepts yieldType, recipientAddress, depositToken, and chainId for automatic vault resolution
|
|
@@ -1814,6 +2043,7 @@ interface PrepareDepositTxDataParams {
|
|
|
1814
2043
|
depositAmount: string;
|
|
1815
2044
|
chainId: ChainId;
|
|
1816
2045
|
slippage?: number;
|
|
2046
|
+
partnerCode?: string;
|
|
1817
2047
|
}
|
|
1818
2048
|
/**
|
|
1819
2049
|
* Prepares the transaction data needed to deposit assets into a vault
|
|
@@ -1837,7 +2067,7 @@ interface PrepareDepositTxDataParams {
|
|
|
1837
2067
|
* @returns {Promise<DepositTransactionData>} Promise resolving to the prepared transaction data
|
|
1838
2068
|
* @throws {APIError} If vault cannot be resolved, asset not found, or contracts not configured
|
|
1839
2069
|
*/
|
|
1840
|
-
declare function prepareDepositTxData(params: PrepareDepositTxDataParams): Promise<DepositTxData>;
|
|
2070
|
+
declare function prepareDepositTxData(params: PrepareDepositTxDataParams): Promise<DepositTxData | CommunityCodeDepositTxData>;
|
|
1841
2071
|
|
|
1842
2072
|
/**
|
|
1843
2073
|
* @file Deposit with permit functionality for Nucleus vaults
|
|
@@ -3233,4 +3463,4 @@ interface WithdrawTxData {
|
|
|
3233
3463
|
*/
|
|
3234
3464
|
declare const prepareWithdrawTxData: ({ yieldType, wantAssetAddress, chainId, offerAmount, deadline, slippage, }: PrepareWithdrawTxDataParams) => Promise<WithdrawTxData>;
|
|
3235
3465
|
|
|
3236
|
-
export { AmplifyVault, type ApproveDepositTokenTxData, type ApproveWithdrawTokenTxData, AssetFilterOptions, type BulkWithdrawTxData, type DepositTxData, type EIP712Domain, type InitErrorCode, PERMIT_TYPES, type ParsedPermitSignature, type PermitSignatureData, type PrepareDepositPermitSignatureParams, type PrepareDepositWithPermitTxDataParams, type RequestHeaders, type SDKConfig, SupportedAsset, type UnencodedDepositWithPermitData, VaultFilterOptions, WithdrawSupportedAsset, type WithdrawTxData, YieldType, fetchSupportedAssets, fetchVaults, findVaultByConfig, getAssetsFromCache, getCache, getWithdrawSupportedAssets, initAmplifySDK, initializeCache, parsePermitSignature, prepareApproveDepositTokenTxData, prepareApproveWithdrawTxData, prepareBulkWithdrawTxData, prepareDepositPermitSignature, prepareDepositTxData, prepareDepositWithPermitTxData, prepareWithdrawTxData, refreshVaultCache };
|
|
3466
|
+
export { AmplifyVault, type ApproveDepositTokenTxData, type ApproveWithdrawTokenTxData, AssetFilterOptions, type BulkWithdrawTxData, type CommunityCodeDepositTxData, type DepositTxData, type EIP712Domain, type InitErrorCode, PERMIT_TYPES, type ParsedPermitSignature, type PermitSignatureData, type PrepareDepositPermitSignatureParams, type PrepareDepositWithPermitTxDataParams, type RequestHeaders, type SDKConfig, SupportedAsset, type UnencodedDepositWithPermitData, VaultFilterOptions, WithdrawSupportedAsset, type WithdrawTxData, YieldType, fetchSupportedAssets, fetchVaults, findVaultByConfig, getAssetsFromCache, getCache, getWithdrawSupportedAssets, initAmplifySDK, initializeCache, parsePermitSignature, prepareApproveDepositTokenTxData, prepareApproveWithdrawTxData, prepareBulkWithdrawTxData, prepareDepositPermitSignature, prepareDepositTxData, prepareDepositWithPermitTxData, prepareWithdrawTxData, refreshVaultCache };
|