damm-sdk 1.3.0 → 1.3.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 (36) hide show
  1. package/dist/index.cjs +19383 -16277
  2. package/dist/index.cjs.map +68 -41
  3. package/dist/index.js +49514 -41635
  4. package/dist/index.js.map +125 -57
  5. package/dist/integrations/index.d.ts +3 -1
  6. package/dist/integrations/index.d.ts.map +1 -1
  7. package/dist/integrations/iporFusion/index.d.ts +2 -0
  8. package/dist/integrations/iporFusion/index.d.ts.map +1 -0
  9. package/dist/integrations/iporFusion/ipor.fusion.abi.d.ts +103 -0
  10. package/dist/integrations/iporFusion/ipor.fusion.abi.d.ts.map +1 -0
  11. package/dist/integrations/iporFusion/ipor.fusion.d.ts +32 -0
  12. package/dist/integrations/iporFusion/ipor.fusion.d.ts.map +1 -0
  13. package/dist/integrations/originArm/index.d.ts +2 -0
  14. package/dist/integrations/originArm/index.d.ts.map +1 -0
  15. package/dist/integrations/originArm/origin.arm.abi.d.ts +108 -0
  16. package/dist/integrations/originArm/origin.arm.abi.d.ts.map +1 -0
  17. package/dist/integrations/originArm/origin.arm.d.ts +41 -0
  18. package/dist/integrations/originArm/origin.arm.d.ts.map +1 -0
  19. package/dist/integrations/syrup/index.d.ts +0 -1
  20. package/dist/integrations/syrup/index.d.ts.map +1 -1
  21. package/dist/integrations/syrup/syrup.vault.abi.d.ts +6 -62
  22. package/dist/integrations/syrup/syrup.vault.abi.d.ts.map +1 -1
  23. package/dist/integrations/syrup/syrup.vault.d.ts +0 -9
  24. package/dist/integrations/syrup/syrup.vault.d.ts.map +1 -1
  25. package/package.json +1 -1
  26. package/src/integrations/index.ts +3 -1
  27. package/src/integrations/iporFusion/index.ts +1 -0
  28. package/src/integrations/iporFusion/ipor.fusion.abi.ts +55 -0
  29. package/src/integrations/iporFusion/ipor.fusion.ts +93 -0
  30. package/src/integrations/originArm/index.ts +1 -0
  31. package/src/integrations/originArm/origin.arm.abi.ts +64 -0
  32. package/src/integrations/originArm/origin.arm.ts +144 -0
  33. package/src/integrations/syrup/index.ts +0 -1
  34. package/src/integrations/syrup/syrup.vault.abi.ts +6 -49
  35. package/src/integrations/syrup/syrup.vault.ts +2 -30
  36. package/src/lib/contractsRegistry.json +2 -1
@@ -11,9 +11,11 @@ export * from "./morphoBlue";
11
11
  export * from "./erc20";
12
12
  export * from "./slipstream";
13
13
  export * from "./morphoVault";
14
- export * from "./syrup";
15
14
  export * from "./merkl";
16
15
  export * from "./oft";
17
16
  export * from "./cctp";
18
17
  export * from "./erc721";
18
+ export * from "./iporFusion";
19
+ export * from "./originArm";
20
+ export * from "./syrup";
19
21
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/integrations/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/integrations/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./ipor.fusion";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/integrations/iporFusion/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC"}
@@ -0,0 +1,103 @@
1
+ declare const _default: readonly [{
2
+ readonly inputs: readonly [{
3
+ readonly internalType: "uint256";
4
+ readonly name: "assets";
5
+ readonly type: "uint256";
6
+ }, {
7
+ readonly internalType: "address";
8
+ readonly name: "receiver";
9
+ readonly type: "address";
10
+ }];
11
+ readonly name: "deposit";
12
+ readonly outputs: readonly [{
13
+ readonly internalType: "uint256";
14
+ readonly name: "shares";
15
+ readonly type: "uint256";
16
+ }];
17
+ readonly stateMutability: "nonpayable";
18
+ readonly type: "function";
19
+ }, {
20
+ readonly inputs: readonly [{
21
+ readonly internalType: "uint256";
22
+ readonly name: "assets";
23
+ readonly type: "uint256";
24
+ }, {
25
+ readonly internalType: "address";
26
+ readonly name: "receiver";
27
+ readonly type: "address";
28
+ }, {
29
+ readonly internalType: "address";
30
+ readonly name: "owner";
31
+ readonly type: "address";
32
+ }];
33
+ readonly name: "withdraw";
34
+ readonly outputs: readonly [{
35
+ readonly internalType: "uint256";
36
+ readonly name: "shares";
37
+ readonly type: "uint256";
38
+ }];
39
+ readonly stateMutability: "nonpayable";
40
+ readonly type: "function";
41
+ }, {
42
+ readonly inputs: readonly [{
43
+ readonly internalType: "uint256";
44
+ readonly name: "shares";
45
+ readonly type: "uint256";
46
+ }, {
47
+ readonly internalType: "address";
48
+ readonly name: "receiver";
49
+ readonly type: "address";
50
+ }, {
51
+ readonly internalType: "address";
52
+ readonly name: "owner";
53
+ readonly type: "address";
54
+ }];
55
+ readonly name: "redeem";
56
+ readonly outputs: readonly [{
57
+ readonly internalType: "uint256";
58
+ readonly name: "assets";
59
+ readonly type: "uint256";
60
+ }];
61
+ readonly stateMutability: "nonpayable";
62
+ readonly type: "function";
63
+ }, {
64
+ readonly inputs: readonly [];
65
+ readonly name: "asset";
66
+ readonly outputs: readonly [{
67
+ readonly internalType: "address";
68
+ readonly name: "";
69
+ readonly type: "address";
70
+ }];
71
+ readonly stateMutability: "view";
72
+ readonly type: "function";
73
+ }, {
74
+ readonly inputs: readonly [{
75
+ readonly internalType: "address";
76
+ readonly name: "account";
77
+ readonly type: "address";
78
+ }];
79
+ readonly name: "balanceOf";
80
+ readonly outputs: readonly [{
81
+ readonly internalType: "uint256";
82
+ readonly name: "";
83
+ readonly type: "uint256";
84
+ }];
85
+ readonly stateMutability: "view";
86
+ readonly type: "function";
87
+ }, {
88
+ readonly inputs: readonly [{
89
+ readonly internalType: "uint256";
90
+ readonly name: "shares";
91
+ readonly type: "uint256";
92
+ }];
93
+ readonly name: "convertToAssets";
94
+ readonly outputs: readonly [{
95
+ readonly internalType: "uint256";
96
+ readonly name: "assets";
97
+ readonly type: "uint256";
98
+ }];
99
+ readonly stateMutability: "view";
100
+ readonly type: "function";
101
+ }];
102
+ export default _default;
103
+ //# sourceMappingURL=ipor.fusion.abi.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ipor.fusion.abi.d.ts","sourceRoot":"","sources":["../../../src/integrations/iporFusion/ipor.fusion.abi.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAsDW"}
@@ -0,0 +1,32 @@
1
+ import type { Address } from "viem";
2
+ import type { HexString, Unwrapable, Call } from "../../types";
3
+ export type DepositIporFusionArgs = Readonly<{
4
+ assets: bigint;
5
+ receiver: Address;
6
+ }>;
7
+ export declare const DepositIporFusionCalldata: ({ assets, receiver }: DepositIporFusionArgs) => HexString;
8
+ export declare const depositIporFusionTrx: ({ args, vaultAddress, }: {
9
+ args: DepositIporFusionArgs;
10
+ vaultAddress: Address;
11
+ }) => Unwrapable<Call>;
12
+ export type WithdrawIporFusionArgs = Readonly<{
13
+ assets: bigint;
14
+ receiver: Address;
15
+ owner: Address;
16
+ }>;
17
+ export declare const WithdrawIporFusionCalldata: ({ assets, receiver, owner }: WithdrawIporFusionArgs) => HexString;
18
+ export declare const withdrawIporFusionTrx: ({ args, vaultAddress, }: {
19
+ args: WithdrawIporFusionArgs;
20
+ vaultAddress: Address;
21
+ }) => Unwrapable<Call>;
22
+ export type RedeemIporFusionArgs = Readonly<{
23
+ shares: bigint;
24
+ receiver: Address;
25
+ owner: Address;
26
+ }>;
27
+ export declare const RedeemIporFusionCalldata: ({ shares, receiver, owner }: RedeemIporFusionArgs) => HexString;
28
+ export declare const redeemIporFusionTrx: ({ args, vaultAddress, }: {
29
+ args: RedeemIporFusionArgs;
30
+ vaultAddress: Address;
31
+ }) => Unwrapable<Call>;
32
+ //# sourceMappingURL=ipor.fusion.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ipor.fusion.d.ts","sourceRoot":"","sources":["../../../src/integrations/iporFusion/ipor.fusion.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAS/D,MAAM,MAAM,qBAAqB,GAAG,QAAQ,CAAC;IACzC,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,CAAC;CACrB,CAAC,CAAC;AAEH,eAAO,MAAM,yBAAyB,yBAA0B,qBAAqB,KAAG,SAEvF,CAAC;AAEF,eAAO,MAAM,oBAAoB;UAIvB,qBAAqB;kBACb,OAAO;MACrB,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,sBAAsB,GAAG,QAAQ,CAAC;IAC1C,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,EAAE,OAAO,CAAC;CAClB,CAAC,CAAC;AAEH,eAAO,MAAM,0BAA0B,gCAAiC,sBAAsB,KAAG,SAEhG,CAAC;AAEF,eAAO,MAAM,qBAAqB;UAIxB,sBAAsB;kBACd,OAAO;MACrB,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,oBAAoB,GAAG,QAAQ,CAAC;IACxC,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,EAAE,OAAO,CAAC;CAClB,CAAC,CAAC;AAEH,eAAO,MAAM,wBAAwB,gCAAiC,oBAAoB,KAAG,SAE5F,CAAC;AAEF,eAAO,MAAM,mBAAmB;UAItB,oBAAoB;kBACZ,OAAO;MACrB,WAAW,IAAI,CAOlB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./origin.arm";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/integrations/originArm/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC"}
@@ -0,0 +1,108 @@
1
+ export declare const OriginArmVaultAbi: readonly [{
2
+ readonly inputs: readonly [{
3
+ readonly internalType: "uint256";
4
+ readonly name: "assets";
5
+ readonly type: "uint256";
6
+ }];
7
+ readonly name: "deposit";
8
+ readonly outputs: readonly [{
9
+ readonly internalType: "uint256";
10
+ readonly name: "shares";
11
+ readonly type: "uint256";
12
+ }];
13
+ readonly stateMutability: "nonpayable";
14
+ readonly type: "function";
15
+ }, {
16
+ readonly inputs: readonly [{
17
+ readonly internalType: "uint256";
18
+ readonly name: "shares";
19
+ readonly type: "uint256";
20
+ }];
21
+ readonly name: "requestRedeem";
22
+ readonly outputs: readonly [{
23
+ readonly internalType: "uint256";
24
+ readonly name: "requestId";
25
+ readonly type: "uint256";
26
+ }];
27
+ readonly stateMutability: "nonpayable";
28
+ readonly type: "function";
29
+ }, {
30
+ readonly inputs: readonly [{
31
+ readonly internalType: "uint256";
32
+ readonly name: "requestId";
33
+ readonly type: "uint256";
34
+ }];
35
+ readonly name: "claimRedeem";
36
+ readonly outputs: readonly [{
37
+ readonly internalType: "uint256";
38
+ readonly name: "assets";
39
+ readonly type: "uint256";
40
+ }];
41
+ readonly stateMutability: "nonpayable";
42
+ readonly type: "function";
43
+ }, {
44
+ readonly inputs: readonly [];
45
+ readonly name: "asset";
46
+ readonly outputs: readonly [{
47
+ readonly internalType: "address";
48
+ readonly name: "";
49
+ readonly type: "address";
50
+ }];
51
+ readonly stateMutability: "view";
52
+ readonly type: "function";
53
+ }, {
54
+ readonly inputs: readonly [{
55
+ readonly internalType: "address";
56
+ readonly name: "account";
57
+ readonly type: "address";
58
+ }];
59
+ readonly name: "balanceOf";
60
+ readonly outputs: readonly [{
61
+ readonly internalType: "uint256";
62
+ readonly name: "";
63
+ readonly type: "uint256";
64
+ }];
65
+ readonly stateMutability: "view";
66
+ readonly type: "function";
67
+ }, {
68
+ readonly inputs: readonly [{
69
+ readonly internalType: "uint256";
70
+ readonly name: "shares";
71
+ readonly type: "uint256";
72
+ }];
73
+ readonly name: "convertToAssets";
74
+ readonly outputs: readonly [{
75
+ readonly internalType: "uint256";
76
+ readonly name: "assets";
77
+ readonly type: "uint256";
78
+ }];
79
+ readonly stateMutability: "view";
80
+ readonly type: "function";
81
+ }];
82
+ export declare const OriginArmStethZapperAbi: readonly [{
83
+ readonly inputs: readonly [];
84
+ readonly name: "deposit";
85
+ readonly outputs: readonly [{
86
+ readonly internalType: "uint256";
87
+ readonly name: "shares";
88
+ readonly type: "uint256";
89
+ }];
90
+ readonly stateMutability: "payable";
91
+ readonly type: "function";
92
+ }];
93
+ export declare const OriginArmUniversalZapperAbi: readonly [{
94
+ readonly inputs: readonly [{
95
+ readonly internalType: "address";
96
+ readonly name: "arm";
97
+ readonly type: "address";
98
+ }];
99
+ readonly name: "deposit";
100
+ readonly outputs: readonly [{
101
+ readonly internalType: "uint256";
102
+ readonly name: "shares";
103
+ readonly type: "uint256";
104
+ }];
105
+ readonly stateMutability: "payable";
106
+ readonly type: "function";
107
+ }];
108
+ //# sourceMappingURL=origin.arm.abi.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"origin.arm.abi.d.ts","sourceRoot":"","sources":["../../../src/integrations/originArm/origin.arm.abi.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2CpB,CAAC;AAEX,eAAO,MAAM,uBAAuB;;;;;;;;;;EAQ1B,CAAC;AAEX,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;EAQ9B,CAAC"}
@@ -0,0 +1,41 @@
1
+ import type { Address } from "viem";
2
+ import type { HexString, Unwrapable, Call } from "../../types";
3
+ export type DepositOriginArmWethArgs = Readonly<{
4
+ assets: bigint;
5
+ }>;
6
+ export declare const DepositOriginArmWethCalldata: ({ assets }: DepositOriginArmWethArgs) => HexString;
7
+ export declare const depositOriginArmWethTrx: ({ args, vaultAddress, }: {
8
+ args: DepositOriginArmWethArgs;
9
+ vaultAddress: Address;
10
+ }) => Unwrapable<Call>;
11
+ export declare const DepositOriginArmEthViaZapperCalldata: () => HexString;
12
+ export declare const depositOriginArmEthViaZapperTrx: ({ zapperAddress, value, }: {
13
+ zapperAddress: Address;
14
+ value: bigint;
15
+ }) => Unwrapable<Call>;
16
+ export type DepositOriginArmEthViaUniversalZapperArgs = Readonly<{
17
+ arm: Address;
18
+ }>;
19
+ export declare const DepositOriginArmEthViaUniversalZapperCalldata: ({ arm, }: DepositOriginArmEthViaUniversalZapperArgs) => HexString;
20
+ export declare const depositOriginArmEthViaUniversalZapperTrx: ({ args, zapperAddress, value, }: {
21
+ args: DepositOriginArmEthViaUniversalZapperArgs;
22
+ zapperAddress: Address;
23
+ value: bigint;
24
+ }) => Unwrapable<Call>;
25
+ export type RequestRedeemOriginArmArgs = Readonly<{
26
+ shares: bigint;
27
+ }>;
28
+ export declare const RequestRedeemOriginArmCalldata: ({ shares }: RequestRedeemOriginArmArgs) => HexString;
29
+ export declare const requestRedeemOriginArmTrx: ({ args, vaultAddress, }: {
30
+ args: RequestRedeemOriginArmArgs;
31
+ vaultAddress: Address;
32
+ }) => Unwrapable<Call>;
33
+ export type ClaimRedeemOriginArmArgs = Readonly<{
34
+ requestId: bigint;
35
+ }>;
36
+ export declare const ClaimRedeemOriginArmCalldata: ({ requestId }: ClaimRedeemOriginArmArgs) => HexString;
37
+ export declare const claimRedeemOriginArmTrx: ({ args, vaultAddress, }: {
38
+ args: ClaimRedeemOriginArmArgs;
39
+ vaultAddress: Address;
40
+ }) => Unwrapable<Call>;
41
+ //# sourceMappingURL=origin.arm.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"origin.arm.d.ts","sourceRoot":"","sources":["../../../src/integrations/originArm/origin.arm.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAW/D,MAAM,MAAM,wBAAwB,GAAG,QAAQ,CAAC;IAC5C,MAAM,EAAE,MAAM,CAAC;CAClB,CAAC,CAAC;AAEH,eAAO,MAAM,4BAA4B,eAAgB,wBAAwB,KAAG,SAEnF,CAAC;AAEF,eAAO,MAAM,uBAAuB;UAI1B,wBAAwB;kBAChB,OAAO;MACrB,WAAW,IAAI,CAOlB,CAAC;AAMF,eAAO,MAAM,oCAAoC,QAAO,SAEvD,CAAC;AAEF,eAAO,MAAM,+BAA+B;mBAIzB,OAAO;WACf,MAAM;MACb,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,yCAAyC,GAAG,QAAQ,CAAC;IAC7D,GAAG,EAAE,OAAO,CAAC;CAChB,CAAC,CAAC;AAEH,eAAO,MAAM,6CAA6C,aAEvD,yCAAyC,KAAG,SAE9C,CAAC;AAEF,eAAO,MAAM,wCAAwC;UAK3C,yCAAyC;mBAChC,OAAO;WACf,MAAM;MACb,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,0BAA0B,GAAG,QAAQ,CAAC;IAC9C,MAAM,EAAE,MAAM,CAAC;CAClB,CAAC,CAAC;AAEH,eAAO,MAAM,8BAA8B,eAAgB,0BAA0B,KAAG,SAEvF,CAAC;AAEF,eAAO,MAAM,yBAAyB;UAI5B,0BAA0B;kBAClB,OAAO;MACrB,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,wBAAwB,GAAG,QAAQ,CAAC;IAC5C,SAAS,EAAE,MAAM,CAAC;CACrB,CAAC,CAAC;AAEH,eAAO,MAAM,4BAA4B,kBAAmB,wBAAwB,KAAG,SAEtF,CAAC;AAEF,eAAO,MAAM,uBAAuB;UAI1B,wBAAwB;kBAChB,OAAO;MACrB,WAAW,IAAI,CAOlB,CAAC"}
@@ -1,3 +1,2 @@
1
1
  export * from "./syrup.vault";
2
- export { default as SyrupVaultAbi } from "./syrup.vault.abi";
3
2
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/integrations/syrup/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,mBAAmB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/integrations/syrup/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC"}
@@ -1,17 +1,17 @@
1
1
  declare const _default: readonly [{
2
2
  readonly inputs: readonly [{
3
3
  readonly internalType: "uint256";
4
- readonly name: "assets_";
4
+ readonly name: "assets";
5
5
  readonly type: "uint256";
6
6
  }, {
7
7
  readonly internalType: "address";
8
- readonly name: "receiver_";
8
+ readonly name: "receiver";
9
9
  readonly type: "address";
10
10
  }];
11
11
  readonly name: "deposit";
12
12
  readonly outputs: readonly [{
13
13
  readonly internalType: "uint256";
14
- readonly name: "shares_";
14
+ readonly name: "shares";
15
15
  readonly type: "uint256";
16
16
  }];
17
17
  readonly stateMutability: "nonpayable";
@@ -19,77 +19,21 @@ declare const _default: readonly [{
19
19
  }, {
20
20
  readonly inputs: readonly [{
21
21
  readonly internalType: "uint256";
22
- readonly name: "assets_";
22
+ readonly name: "shares";
23
23
  readonly type: "uint256";
24
24
  }, {
25
25
  readonly internalType: "address";
26
- readonly name: "owner_";
27
- readonly type: "address";
28
- }];
29
- readonly name: "requestWithdraw";
30
- readonly outputs: readonly [{
31
- readonly internalType: "uint256";
32
- readonly name: "escrowedShares_";
33
- readonly type: "uint256";
34
- }];
35
- readonly stateMutability: "nonpayable";
36
- readonly type: "function";
37
- }, {
38
- readonly inputs: readonly [{
39
- readonly internalType: "uint256";
40
- readonly name: "shares_";
41
- readonly type: "uint256";
42
- }, {
43
- readonly internalType: "address";
44
- readonly name: "owner_";
26
+ readonly name: "owner";
45
27
  readonly type: "address";
46
28
  }];
47
29
  readonly name: "requestRedeem";
48
30
  readonly outputs: readonly [{
49
31
  readonly internalType: "uint256";
50
- readonly name: "escrowedShares_";
32
+ readonly name: "escrowedShares";
51
33
  readonly type: "uint256";
52
34
  }];
53
35
  readonly stateMutability: "nonpayable";
54
36
  readonly type: "function";
55
- }, {
56
- readonly inputs: readonly [];
57
- readonly name: "asset";
58
- readonly outputs: readonly [{
59
- readonly internalType: "address";
60
- readonly name: "";
61
- readonly type: "address";
62
- }];
63
- readonly stateMutability: "view";
64
- readonly type: "function";
65
- }, {
66
- readonly inputs: readonly [{
67
- readonly internalType: "address";
68
- readonly name: "";
69
- readonly type: "address";
70
- }];
71
- readonly name: "balanceOf";
72
- readonly outputs: readonly [{
73
- readonly internalType: "uint256";
74
- readonly name: "";
75
- readonly type: "uint256";
76
- }];
77
- readonly stateMutability: "view";
78
- readonly type: "function";
79
- }, {
80
- readonly inputs: readonly [{
81
- readonly internalType: "uint256";
82
- readonly name: "shares_";
83
- readonly type: "uint256";
84
- }];
85
- readonly name: "convertToAssets";
86
- readonly outputs: readonly [{
87
- readonly internalType: "uint256";
88
- readonly name: "assets_";
89
- readonly type: "uint256";
90
- }];
91
- readonly stateMutability: "view";
92
- readonly type: "function";
93
37
  }];
94
38
  export default _default;
95
39
  //# sourceMappingURL=syrup.vault.abi.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"syrup.vault.abi.d.ts","sourceRoot":"","sources":["../../../src/integrations/syrup/syrup.vault.abi.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAgEW"}
1
+ {"version":3,"file":"syrup.vault.abi.d.ts","sourceRoot":"","sources":["../../../src/integrations/syrup/syrup.vault.abi.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAqBW"}
@@ -9,15 +9,6 @@ export declare const depositSyrupVaultTrx: ({ args, syrupVaultAddress, }: {
9
9
  args: DepositSyrupVaultArgs;
10
10
  syrupVaultAddress: Address;
11
11
  }) => Unwrapable<Call>;
12
- export type RequestWithdrawSyrupVaultArgs = Readonly<{
13
- assets: bigint;
14
- owner: Address;
15
- }>;
16
- export declare const RequestWithdrawSyrupVaultCalldata: ({ assets, owner }: RequestWithdrawSyrupVaultArgs) => HexString;
17
- export declare const requestWithdrawSyrupVaultTrx: ({ args, syrupVaultAddress, }: {
18
- args: RequestWithdrawSyrupVaultArgs;
19
- syrupVaultAddress: Address;
20
- }) => Unwrapable<Call>;
21
12
  export type RequestRedeemSyrupVaultArgs = Readonly<{
22
13
  shares: bigint;
23
14
  owner: Address;
@@ -1 +1 @@
1
- {"version":3,"file":"syrup.vault.d.ts","sourceRoot":"","sources":["../../../src/integrations/syrup/syrup.vault.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAS/D,MAAM,MAAM,qBAAqB,GAAG,QAAQ,CAAC;IACzC,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,CAAC;CACrB,CAAC,CAAC;AAEH,eAAO,MAAM,yBAAyB,yBAA0B,qBAAqB,KAAG,SAEvF,CAAC;AAEF,eAAO,MAAM,oBAAoB;UAIvB,qBAAqB;uBACR,OAAO;MAC1B,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,6BAA6B,GAAG,QAAQ,CAAC;IACjD,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,OAAO,CAAC;CAClB,CAAC,CAAC;AAEH,eAAO,MAAM,iCAAiC,sBAAuB,6BAA6B,KAAG,SAEpG,CAAC;AAEF,eAAO,MAAM,4BAA4B;UAI/B,6BAA6B;uBAChB,OAAO;MAC1B,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,2BAA2B,GAAG,QAAQ,CAAC;IAC/C,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,OAAO,CAAC;CAClB,CAAC,CAAC;AAEH,eAAO,MAAM,+BAA+B,sBAAuB,2BAA2B,KAAG,SAEhG,CAAC;AAEF,eAAO,MAAM,0BAA0B;UAI7B,2BAA2B;uBACd,OAAO;MAC1B,WAAW,IAAI,CAOlB,CAAC"}
1
+ {"version":3,"file":"syrup.vault.d.ts","sourceRoot":"","sources":["../../../src/integrations/syrup/syrup.vault.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAS/D,MAAM,MAAM,qBAAqB,GAAG,QAAQ,CAAC;IACzC,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,CAAC;CACrB,CAAC,CAAC;AAEH,eAAO,MAAM,yBAAyB,yBAA0B,qBAAqB,KAAG,SAEvF,CAAC;AAEF,eAAO,MAAM,oBAAoB;UAIvB,qBAAqB;uBACR,OAAO;MAC1B,WAAW,IAAI,CAOlB,CAAC;AAMF,MAAM,MAAM,2BAA2B,GAAG,QAAQ,CAAC;IAC/C,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,OAAO,CAAC;CAClB,CAAC,CAAC;AAEH,eAAO,MAAM,+BAA+B,sBAAuB,2BAA2B,KAAG,SAEhG,CAAC;AAEF,eAAO,MAAM,0BAA0B;UAI7B,2BAA2B;uBACd,OAAO;MAC1B,WAAW,IAAI,CAOlB,CAAC"}
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "main": "./dist/index.cjs",
5
5
  "types": "./dist/index.d.ts",
6
6
  "type": "module",
7
- "version": "1.3.0",
7
+ "version": "1.3.2",
8
8
  "files": [
9
9
  "dist",
10
10
  "src",
@@ -11,8 +11,10 @@ export * from "./morphoBlue";
11
11
  export * from "./erc20";
12
12
  export * from "./slipstream";
13
13
  export * from "./morphoVault";
14
- export * from "./syrup";
15
14
  export * from "./merkl";
16
15
  export * from "./oft";
17
16
  export * from "./cctp";
18
17
  export * from "./erc721";
18
+ export * from "./iporFusion";
19
+ export * from "./originArm";
20
+ export * from "./syrup";
@@ -0,0 +1 @@
1
+ export * from "./ipor.fusion";
@@ -0,0 +1,55 @@
1
+ export default [
2
+ {
3
+ inputs: [
4
+ { internalType: "uint256", name: "assets", type: "uint256" },
5
+ { internalType: "address", name: "receiver", type: "address" },
6
+ ],
7
+ name: "deposit",
8
+ outputs: [{ internalType: "uint256", name: "shares", type: "uint256" }],
9
+ stateMutability: "nonpayable",
10
+ type: "function",
11
+ },
12
+ {
13
+ inputs: [
14
+ { internalType: "uint256", name: "assets", type: "uint256" },
15
+ { internalType: "address", name: "receiver", type: "address" },
16
+ { internalType: "address", name: "owner", type: "address" },
17
+ ],
18
+ name: "withdraw",
19
+ outputs: [{ internalType: "uint256", name: "shares", type: "uint256" }],
20
+ stateMutability: "nonpayable",
21
+ type: "function",
22
+ },
23
+ {
24
+ inputs: [
25
+ { internalType: "uint256", name: "shares", type: "uint256" },
26
+ { internalType: "address", name: "receiver", type: "address" },
27
+ { internalType: "address", name: "owner", type: "address" },
28
+ ],
29
+ name: "redeem",
30
+ outputs: [{ internalType: "uint256", name: "assets", type: "uint256" }],
31
+ stateMutability: "nonpayable",
32
+ type: "function",
33
+ },
34
+ {
35
+ inputs: [],
36
+ name: "asset",
37
+ outputs: [{ internalType: "address", name: "", type: "address" }],
38
+ stateMutability: "view",
39
+ type: "function",
40
+ },
41
+ {
42
+ inputs: [{ internalType: "address", name: "account", type: "address" }],
43
+ name: "balanceOf",
44
+ outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
45
+ stateMutability: "view",
46
+ type: "function",
47
+ },
48
+ {
49
+ inputs: [{ internalType: "uint256", name: "shares", type: "uint256" }],
50
+ name: "convertToAssets",
51
+ outputs: [{ internalType: "uint256", name: "assets", type: "uint256" }],
52
+ stateMutability: "view",
53
+ type: "function",
54
+ },
55
+ ] as const;
@@ -0,0 +1,93 @@
1
+ import { ethers } from "ethers";
2
+ import IporFusionAbi from "./ipor.fusion.abi";
3
+ import type { Address } from "viem";
4
+ import type { HexString, Unwrapable, Call } from "../../types";
5
+ import { createCall } from "../../types";
6
+
7
+ const iporFusionInterface = new ethers.utils.Interface(IporFusionAbi);
8
+
9
+ // ============================================================================
10
+ // Deposit (ERC4626)
11
+ // ============================================================================
12
+
13
+ export type DepositIporFusionArgs = Readonly<{
14
+ assets: bigint;
15
+ receiver: Address;
16
+ }>;
17
+
18
+ export const DepositIporFusionCalldata = ({ assets, receiver }: DepositIporFusionArgs): HexString => {
19
+ return iporFusionInterface.encodeFunctionData("deposit", [assets, receiver]) as HexString;
20
+ };
21
+
22
+ export const depositIporFusionTrx = ({
23
+ args,
24
+ vaultAddress,
25
+ }: {
26
+ args: DepositIporFusionArgs;
27
+ vaultAddress: Address;
28
+ }): Unwrapable<Call> => {
29
+ return createCall({
30
+ operation: 0,
31
+ to: vaultAddress,
32
+ value: 0n,
33
+ data: DepositIporFusionCalldata(args),
34
+ });
35
+ };
36
+
37
+ // ============================================================================
38
+ // Withdraw (ERC4626) - Assets-based withdrawal
39
+ // ============================================================================
40
+
41
+ export type WithdrawIporFusionArgs = Readonly<{
42
+ assets: bigint;
43
+ receiver: Address;
44
+ owner: Address;
45
+ }>;
46
+
47
+ export const WithdrawIporFusionCalldata = ({ assets, receiver, owner }: WithdrawIporFusionArgs): HexString => {
48
+ return iporFusionInterface.encodeFunctionData("withdraw", [assets, receiver, owner]) as HexString;
49
+ };
50
+
51
+ export const withdrawIporFusionTrx = ({
52
+ args,
53
+ vaultAddress,
54
+ }: {
55
+ args: WithdrawIporFusionArgs;
56
+ vaultAddress: Address;
57
+ }): Unwrapable<Call> => {
58
+ return createCall({
59
+ operation: 0,
60
+ to: vaultAddress,
61
+ value: 0n,
62
+ data: WithdrawIporFusionCalldata(args),
63
+ });
64
+ };
65
+
66
+ // ============================================================================
67
+ // Redeem (ERC4626) - Shares-based withdrawal
68
+ // ============================================================================
69
+
70
+ export type RedeemIporFusionArgs = Readonly<{
71
+ shares: bigint;
72
+ receiver: Address;
73
+ owner: Address;
74
+ }>;
75
+
76
+ export const RedeemIporFusionCalldata = ({ shares, receiver, owner }: RedeemIporFusionArgs): HexString => {
77
+ return iporFusionInterface.encodeFunctionData("redeem", [shares, receiver, owner]) as HexString;
78
+ };
79
+
80
+ export const redeemIporFusionTrx = ({
81
+ args,
82
+ vaultAddress,
83
+ }: {
84
+ args: RedeemIporFusionArgs;
85
+ vaultAddress: Address;
86
+ }): Unwrapable<Call> => {
87
+ return createCall({
88
+ operation: 0,
89
+ to: vaultAddress,
90
+ value: 0n,
91
+ data: RedeemIporFusionCalldata(args),
92
+ });
93
+ };
@@ -0,0 +1 @@
1
+ export * from "./origin.arm";