@aave/client 4.0.0-next.43 → 4.0.0-next.45
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/dist/{AaveClient-CYavo882.d.cts → AaveClient-DaBi3jFp.d.cts} +11 -5
- package/dist/{AaveClient-BPNG2Fua.d.ts → AaveClient-DfMDhl-T.d.ts} +11 -5
- package/dist/actions/index.cjs.map +1 -1
- package/dist/actions/index.d.cts +10 -10
- package/dist/actions/index.d.ts +10 -10
- package/dist/actions/index.js +1 -1
- package/dist/{chunk-UCDF5T5C.js → chunk-G3SJ4NJN.js} +2 -2
- package/dist/{chunk-UCDF5T5C.js.map → chunk-G3SJ4NJN.js.map} +1 -1
- package/dist/{chunk-FL5D5Q7M.js → chunk-O65KFH4O.js} +2 -2
- package/dist/{chunk-FL5D5Q7M.js.map → chunk-O65KFH4O.js.map} +1 -1
- package/dist/ethers.d.cts +1 -1
- package/dist/ethers.d.ts +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/privy.d.cts +1 -1
- package/dist/privy.d.ts +1 -1
- package/dist/privy.js +1 -1
- package/dist/testing.d.ts +15 -7
- package/dist/testing.js +18 -18
- package/dist/testing.js.map +1 -1
- package/dist/thirdweb.d.cts +2 -2
- package/dist/thirdweb.d.ts +2 -2
- package/dist/thirdweb.js +1 -1
- package/dist/{types-4gDcMKeo.d.cts → types-BzGr7R2Y.d.cts} +9 -1
- package/dist/{types-4gDcMKeo.d.ts → types-BzGr7R2Y.d.ts} +9 -1
- package/dist/viem.d.cts +2 -2
- package/dist/viem.d.ts +2 -2
- package/dist/viem.js +1 -1
- package/package.json +4 -4
package/dist/thirdweb.d.cts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Chain, ExecutionPlan, ERC20PermitSignature } from '@aave/graphql';
|
|
2
2
|
import { ResultAsync } from '@aave/types';
|
|
3
3
|
import { Chain as Chain$1, ThirdwebClient, Engine } from 'thirdweb';
|
|
4
|
-
import { A as AaveClient } from './AaveClient-
|
|
5
|
-
import { E as ExecutionPlanHandler, S as SignTypedDataError, a as TypedDataHandler, b as TypedData } from './types-
|
|
4
|
+
import { A as AaveClient } from './AaveClient-DaBi3jFp.cjs';
|
|
5
|
+
import { E as ExecutionPlanHandler, S as SignTypedDataError, a as TypedDataHandler, b as TypedData } from './types-BzGr7R2Y.cjs';
|
|
6
6
|
import '@aave/core';
|
|
7
7
|
import '@urql/core';
|
|
8
8
|
|
package/dist/thirdweb.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Chain, ExecutionPlan, ERC20PermitSignature } from '@aave/graphql';
|
|
2
2
|
import { ResultAsync } from '@aave/types';
|
|
3
3
|
import { Chain as Chain$1, ThirdwebClient, Engine } from 'thirdweb';
|
|
4
|
-
import { A as AaveClient } from './AaveClient-
|
|
5
|
-
import { E as ExecutionPlanHandler, S as SignTypedDataError, a as TypedDataHandler, b as TypedData } from './types-
|
|
4
|
+
import { A as AaveClient } from './AaveClient-DfMDhl-T.js';
|
|
5
|
+
import { E as ExecutionPlanHandler, S as SignTypedDataError, a as TypedDataHandler, b as TypedData } from './types-BzGr7R2Y.js';
|
|
6
6
|
import '@aave/core';
|
|
7
7
|
import '@urql/core';
|
|
8
8
|
|
package/dist/thirdweb.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {a}from'./chunk-N4LXBTGY.js';import {f}from'./chunk-
|
|
1
|
+
import {a}from'./chunk-N4LXBTGY.js';import {f}from'./chunk-O65KFH4O.js';import {ValidationError,SigningError,UnexpectedError,TransactionError}from'@aave/core';import {chainId,okAsync,errAsync,ResultAsync,signatureFrom,txHash,invariant}from'@aave/types';import {defineChain,waitForReceipt,Engine}from'thirdweb';import {sepolia,mainnet}from'thirdweb/chains';function w(e){switch(e.chainId){case chainId(mainnet.id):return mainnet;case chainId(sepolia.id):return sepolia}return defineChain({id:e.chainId,name:e.name,nativeCurrency:{name:e.nativeInfo.name,symbol:e.nativeInfo.symbol,decimals:e.nativeInfo.decimals},rpcUrls:{default:{http:[e.rpcUrl]}},blockExplorers:{default:{name:`${e.name} Explorer`,url:e.explorerUrl}}})}function D(e,r){switch(r){case chainId(mainnet.id):return okAsync(mainnet);case chainId(sepolia.id):return okAsync(sepolia)}return f(e,{chainId:r},{batch:false}).andThen(n=>(invariant(n,`Chain ${r} is not supported`),okAsync(w(n))))}async function b(e,r,n){let a=await Engine.serverWallet({client:e,chain:r,address:n.from}).sendTransaction({type:"eip1559",chainId:r.id,to:n.to,value:BigInt(n.value),data:n.data});return txHash(a.transactionHash)}function o(e,r,n){return D(e,n.chainId).andThen(t=>ResultAsync.fromPromise(b(r,t,n),a=>SigningError.from(a)).andThen(a=>ResultAsync.fromPromise(waitForReceipt({client:r,chain:t,transactionHash:a}),s=>UnexpectedError.from(s))).andThen(a=>{let s=txHash(a.transactionHash);return a.status==="reverted"?errAsync(TransactionError.new({txHash:s,request:n})):okAsync({txHash:s,operations:n.operations})}))}function m(e,r,n){switch(n.__typename){case "TransactionRequest":return o(e,r,n);case "Erc20ApprovalRequired":return n.approvals.reduce((t,a)=>t.andThen(()=>o(e,r,a.byTransaction)),okAsync(void 0)).andThen(()=>o(e,r,n.originalTransaction));case "PreContractActionRequired":return o(e,r,n.transaction).andThen(()=>o(e,r,n.originalTransaction));case "InsufficientBalanceError":return errAsync(ValidationError.fromGqlNode(n))}}function F(e,r,n){return n?m(e,r,n):m.bind(null,e,r)}function _(e,r){return r().andThen(n=>{if(a(n)){let t=n.approvals[0].bySignature;return S(e,t).map(a=>({deadline:t.message.deadline,value:a})).andThen(a=>r(a))}return okAsync(n)})}function y(e,r){return ResultAsync.fromPromise(e.signTypedData({types:r.types,domain:r.domain,primaryType:r.primaryType,message:r.message}),n=>SigningError.from(n)).map(signatureFrom)}function S(e,r){return r===void 0?n=>y(e,n):y(e,r)}export{_ as permitWith,F as sendWith,S as signTypedDataWith,w as toThirdwebChain};//# sourceMappingURL=thirdweb.js.map
|
|
2
2
|
//# sourceMappingURL=thirdweb.js.map
|
|
@@ -13,6 +13,14 @@ type TransactionResult = {
|
|
|
13
13
|
* @internal
|
|
14
14
|
*/
|
|
15
15
|
declare function isHasProcessedKnownTransactionRequest(result: TransactionResult): result is HasProcessedKnownTransactionRequest;
|
|
16
|
+
type TransactionReceipt = {
|
|
17
|
+
__typename: 'TransactionReceipt';
|
|
18
|
+
txHash: TxHash;
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* @internal
|
|
22
|
+
*/
|
|
23
|
+
declare function transactionReceipt(txHash: TxHash): TransactionReceipt;
|
|
16
24
|
type SendWithError = CancelError | SigningError | TransactionError | ValidationError<InsufficientBalanceError> | UnexpectedError;
|
|
17
25
|
type ExecutionPlanHandler<T extends ExecutionPlan = ExecutionPlan> = (result: T) => ResultAsync<TransactionResult, SendWithError>;
|
|
18
26
|
type SignTypedDataError = CancelError | SigningError;
|
|
@@ -22,4 +30,4 @@ type SignTypedDataError = CancelError | SigningError;
|
|
|
22
30
|
type TypedData = PermitTypedData | SwapTypedData;
|
|
23
31
|
type TypedDataHandler = (data: TypedData) => ResultAsync<Signature, SignTypedDataError>;
|
|
24
32
|
|
|
25
|
-
export { type ExecutionPlanHandler as E, type SignTypedDataError as S, type TransactionResult as T, type TypedDataHandler as a, type TypedData as b, type
|
|
33
|
+
export { type ExecutionPlanHandler as E, type SignTypedDataError as S, type TransactionResult as T, type TypedDataHandler as a, type TypedData as b, type TransactionReceipt as c, type SendWithError as d, isHasProcessedKnownTransactionRequest as i, transactionReceipt as t };
|
|
@@ -13,6 +13,14 @@ type TransactionResult = {
|
|
|
13
13
|
* @internal
|
|
14
14
|
*/
|
|
15
15
|
declare function isHasProcessedKnownTransactionRequest(result: TransactionResult): result is HasProcessedKnownTransactionRequest;
|
|
16
|
+
type TransactionReceipt = {
|
|
17
|
+
__typename: 'TransactionReceipt';
|
|
18
|
+
txHash: TxHash;
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* @internal
|
|
22
|
+
*/
|
|
23
|
+
declare function transactionReceipt(txHash: TxHash): TransactionReceipt;
|
|
16
24
|
type SendWithError = CancelError | SigningError | TransactionError | ValidationError<InsufficientBalanceError> | UnexpectedError;
|
|
17
25
|
type ExecutionPlanHandler<T extends ExecutionPlan = ExecutionPlan> = (result: T) => ResultAsync<TransactionResult, SendWithError>;
|
|
18
26
|
type SignTypedDataError = CancelError | SigningError;
|
|
@@ -22,4 +30,4 @@ type SignTypedDataError = CancelError | SigningError;
|
|
|
22
30
|
type TypedData = PermitTypedData | SwapTypedData;
|
|
23
31
|
type TypedDataHandler = (data: TypedData) => ResultAsync<Signature, SignTypedDataError>;
|
|
24
32
|
|
|
25
|
-
export { type ExecutionPlanHandler as E, type SignTypedDataError as S, type TransactionResult as T, type TypedDataHandler as a, type TypedData as b, type
|
|
33
|
+
export { type ExecutionPlanHandler as E, type SignTypedDataError as S, type TransactionResult as T, type TypedDataHandler as a, type TypedData as b, type TransactionReceipt as c, type SendWithError as d, isHasProcessedKnownTransactionRequest as i, transactionReceipt as t };
|
package/dist/viem.d.cts
CHANGED
|
@@ -2,8 +2,8 @@ import { CancelError, SigningError, UnexpectedError, TransactionError } from '@a
|
|
|
2
2
|
import { Chain, TransactionRequest, ExecutionPlan, ERC20PermitSignature } from '@aave/graphql';
|
|
3
3
|
import { ResultAsync, TxHash } from '@aave/types';
|
|
4
4
|
import { Chain as Chain$1, WalletClient } from 'viem';
|
|
5
|
-
import { A as AaveClient } from './AaveClient-
|
|
6
|
-
import { T as TransactionResult, E as ExecutionPlanHandler, a as TypedDataHandler, b as TypedData, S as SignTypedDataError } from './types-
|
|
5
|
+
import { A as AaveClient } from './AaveClient-DaBi3jFp.cjs';
|
|
6
|
+
import { T as TransactionResult, E as ExecutionPlanHandler, a as TypedDataHandler, b as TypedData, S as SignTypedDataError } from './types-BzGr7R2Y.cjs';
|
|
7
7
|
import '@urql/core';
|
|
8
8
|
|
|
9
9
|
/**
|
package/dist/viem.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ import { CancelError, SigningError, UnexpectedError, TransactionError } from '@a
|
|
|
2
2
|
import { Chain, TransactionRequest, ExecutionPlan, ERC20PermitSignature } from '@aave/graphql';
|
|
3
3
|
import { ResultAsync, TxHash } from '@aave/types';
|
|
4
4
|
import { Chain as Chain$1, WalletClient } from 'viem';
|
|
5
|
-
import { A as AaveClient } from './AaveClient-
|
|
6
|
-
import { T as TransactionResult, E as ExecutionPlanHandler, a as TypedDataHandler, b as TypedData, S as SignTypedDataError } from './types-
|
|
5
|
+
import { A as AaveClient } from './AaveClient-DfMDhl-T.js';
|
|
6
|
+
import { T as TransactionResult, E as ExecutionPlanHandler, a as TypedDataHandler, b as TypedData, S as SignTypedDataError } from './types-BzGr7R2Y.js';
|
|
7
7
|
import '@urql/core';
|
|
8
8
|
|
|
9
9
|
/**
|
package/dist/viem.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export{c as ensureChain,i as permitWith,d as sendTransaction,g as sendWith,h as signTypedDataWith,a as toViemChain,e as transactionError,b as viemChainsFrom,f as waitForTransactionResult}from'./chunk-
|
|
1
|
+
export{c as ensureChain,i as permitWith,d as sendTransaction,g as sendWith,h as signTypedDataWith,a as toViemChain,e as transactionError,b as viemChainsFrom,f as waitForTransactionResult}from'./chunk-G3SJ4NJN.js';import'./chunk-N4LXBTGY.js';import'./chunk-O65KFH4O.js';//# sourceMappingURL=viem.js.map
|
|
2
2
|
//# sourceMappingURL=viem.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aave/client",
|
|
3
|
-
"version": "4.0.0-next.
|
|
3
|
+
"version": "4.0.0-next.45",
|
|
4
4
|
"description": "The official TypeScript client for the AaveKit API",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"aave",
|
|
@@ -87,9 +87,9 @@
|
|
|
87
87
|
"@urql/core": "^6.0.1",
|
|
88
88
|
"@urql/exchange-graphcache": "^8.1.0",
|
|
89
89
|
"graphql": "^16.11.0",
|
|
90
|
-
"@aave/core": "1.0.0-next.
|
|
91
|
-
"@aave/
|
|
92
|
-
"@aave/
|
|
90
|
+
"@aave/core": "1.0.0-next.17",
|
|
91
|
+
"@aave/types": "1.0.0-next.8",
|
|
92
|
+
"@aave/graphql": "1.0.0-next.31"
|
|
93
93
|
},
|
|
94
94
|
"devDependencies": {
|
|
95
95
|
"@bgd-labs/aave-address-book": "^4.25.3",
|