gondi 0.53.0 → 0.58.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/README.md +3 -2
- package/dist/index.mjs +581 -73
- package/dist/index.mjs.map +4 -4
- package/dist/src/clients/api/auth.d.ts +11 -1
- package/dist/src/clients/api/index.d.ts +582 -111
- package/dist/src/clients/api/sdk.d.ts +19 -0
- package/dist/src/clients/contracts/AllV4.d.ts +8 -0
- package/dist/src/clients/contracts/AllV5.d.ts +5 -0
- package/dist/src/clients/contracts/AllV6.d.ts +5 -0
- package/dist/src/clients/contracts/index.d.ts +27 -3
- package/dist/src/errors.d.ts +1 -23
- package/dist/src/generated/graphql/index.d.ts +957 -34
- package/dist/src/gondi.d.ts +602 -15
- package/dist/src/index.d.ts +1 -1
- package/dist/src/model.d.ts +22 -1
- package/dist/src/utils/steps.d.ts +8 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -104,6 +104,10 @@ export declare function getSdkApollo<C>(client: ApolloClient<C>, onStepChange?:
|
|
|
104
104
|
collectionIdBySlug(variables: import("../../generated/graphql").Exact<{
|
|
105
105
|
slug: import("../../generated/graphql").Scalars["String"];
|
|
106
106
|
}>, options?: {} | undefined): Promise<import("../../generated/graphql").CollectionIdBySlugQuery>;
|
|
107
|
+
collectionMarket(variables: import("../../generated/graphql").Exact<{
|
|
108
|
+
slug: import("../../generated/graphql").Scalars["String"];
|
|
109
|
+
currencyAddresses?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").Scalars["Address"]> | import("../../generated/graphql").Scalars["Address"]>;
|
|
110
|
+
}>, options?: {} | undefined): Promise<import("../../generated/graphql").CollectionMarketQuery>;
|
|
107
111
|
collectionStepsById(variables: import("../../generated/graphql").Exact<{
|
|
108
112
|
collectionId: import("../../generated/graphql").Scalars["Int"];
|
|
109
113
|
}>, options?: {} | undefined): Promise<import("../../generated/graphql").CollectionStepsByIdQuery>;
|
|
@@ -171,6 +175,21 @@ export declare function getSdkApollo<C>(client: ApolloClient<C>, onStepChange?:
|
|
|
171
175
|
nftId: import("../../generated/graphql").Scalars["Int"];
|
|
172
176
|
taker: import("../../generated/graphql").Scalars["Address"];
|
|
173
177
|
}>, options?: {} | undefined): Promise<import("../../generated/graphql").GetSaleCalldataQuery>;
|
|
178
|
+
listOrders(variables?: import("../../generated/graphql").Exact<{
|
|
179
|
+
side?: import("../../generated/graphql").InputMaybe<import("../../generated/graphql").OrderSide>;
|
|
180
|
+
collectionIds?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").Scalars["Int"]> | import("../../generated/graphql").Scalars["Int"]>;
|
|
181
|
+
traitIds?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").Scalars["Int"]> | import("../../generated/graphql").Scalars["Int"]>;
|
|
182
|
+
nfts?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").OrderForNft> | import("../../generated/graphql").OrderForNft>;
|
|
183
|
+
maker?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").Scalars["Address"]> | import("../../generated/graphql").Scalars["Address"]>;
|
|
184
|
+
excludeMaker?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").Scalars["Address"]> | import("../../generated/graphql").Scalars["Address"]>;
|
|
185
|
+
currencyAddresses?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").Scalars["Address"]> | import("../../generated/graphql").Scalars["Address"]>;
|
|
186
|
+
statuses?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").OrderStatusType> | import("../../generated/graphql").OrderStatusType>;
|
|
187
|
+
matchMode?: import("../../generated/graphql").OrderMatchMode;
|
|
188
|
+
orderTypes?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").CollectionOrderType> | import("../../generated/graphql").CollectionOrderType>;
|
|
189
|
+
sortBy?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").OrderSortInput> | import("../../generated/graphql").OrderSortInput>;
|
|
190
|
+
first?: import("../../generated/graphql").InputMaybe<import("../../generated/graphql").Scalars["Int"]>;
|
|
191
|
+
after?: import("../../generated/graphql").InputMaybe<import("../../generated/graphql").Scalars["String"]>;
|
|
192
|
+
}> | undefined, options?: {} | undefined): Promise<import("../../generated/graphql").ListOrdersQuery>;
|
|
174
193
|
previewItemLoanOfferCompetition(variables: import("../../generated/graphql").Exact<{
|
|
175
194
|
offerInput: import("../../generated/graphql").SingleNftOfferInput;
|
|
176
195
|
replacementIds?: import("../../generated/graphql").InputMaybe<Array<import("../../generated/graphql").Scalars["String"]> | import("../../generated/graphql").Scalars["String"]>;
|
|
@@ -27,6 +27,14 @@ export declare class AllV4 extends BaseContract<typeof auctionLoanLiquidatorABIV
|
|
|
27
27
|
address: Address;
|
|
28
28
|
publicClient?: PublicClient;
|
|
29
29
|
});
|
|
30
|
+
/**
|
|
31
|
+
* Whether this liquidator records an auction on the collateral; settling deletes it, which
|
|
32
|
+
* leaves a zero `startTime`.
|
|
33
|
+
*/
|
|
34
|
+
hasAuction({ collectionContractAddress, tokenId, }: {
|
|
35
|
+
collectionContractAddress: Address;
|
|
36
|
+
tokenId: bigint;
|
|
37
|
+
}): Promise<boolean>;
|
|
30
38
|
placeBid({ collectionContractAddress, tokenId, bid, }: {
|
|
31
39
|
collectionContractAddress: Address;
|
|
32
40
|
tokenId: bigint;
|
|
@@ -10,6 +10,11 @@ export declare class AllV5 extends BaseContract<typeof auctionLoanLiquidatorABIV
|
|
|
10
10
|
address: Address;
|
|
11
11
|
publicClient?: PublicClient;
|
|
12
12
|
});
|
|
13
|
+
/** Whether this liquidator records an auction on the collateral; settling clears the record. */
|
|
14
|
+
hasAuction({ collectionContractAddress, tokenId, }: {
|
|
15
|
+
collectionContractAddress: Address;
|
|
16
|
+
tokenId: bigint;
|
|
17
|
+
}): Promise<boolean>;
|
|
13
18
|
placeBid({ collectionContractAddress, tokenId, bid, auction, }: {
|
|
14
19
|
collectionContractAddress: Address;
|
|
15
20
|
tokenId: bigint;
|
|
@@ -9,6 +9,11 @@ export declare class AllV6 extends BaseContract<typeof auctionWithBuyoutLoanLiqu
|
|
|
9
9
|
address: Address;
|
|
10
10
|
publicClient?: PublicClient;
|
|
11
11
|
});
|
|
12
|
+
/** Whether this liquidator records an auction on the collateral; settling clears the record. */
|
|
13
|
+
hasAuction({ collectionContractAddress, tokenId, }: {
|
|
14
|
+
collectionContractAddress: Address;
|
|
15
|
+
tokenId: bigint;
|
|
16
|
+
}): Promise<boolean>;
|
|
12
17
|
placeBid({ collectionContractAddress, tokenId, bid, auction, }: {
|
|
13
18
|
collectionContractAddress: Address;
|
|
14
19
|
tokenId: bigint;
|
|
@@ -60,11 +60,35 @@ export declare class Contracts {
|
|
|
60
60
|
GenericContract(address: Address): BaseContract<Abi>;
|
|
61
61
|
Msl(address: Address): MslV6 | MslV5 | MslV4;
|
|
62
62
|
/**
|
|
63
|
-
*
|
|
64
|
-
* @param
|
|
63
|
+
* @param mslContractAddress The contract address of the MSL contract
|
|
64
|
+
* @param address The liquidator's address; defaults to the address book's current entry for
|
|
65
|
+
* the MSL version, which is not the liquidator of an auction started before a rotation
|
|
66
|
+
* (use `AllForCollateral` for those)
|
|
65
67
|
* @returns The corresponding AuctionLoanLiquidator contract
|
|
66
68
|
*/
|
|
67
|
-
All(mslContractAddress: Address): AllV4 | AllV5 | AllV6;
|
|
69
|
+
All(mslContractAddress: Address, address?: Address): AllV4 | AllV5 | AllV6;
|
|
70
|
+
/**
|
|
71
|
+
* The AuctionLoanLiquidator running the auction on a loan's collateral.
|
|
72
|
+
*
|
|
73
|
+
* An MSL can rotate its liquidator, so the address book only names the current one. The MSL
|
|
74
|
+
* transfers the ERC721 collateral to its liquidator when the auction starts, and the
|
|
75
|
+
* liquidator keeps it until the auction settles, so the collateral's owner is the liquidator
|
|
76
|
+
* of the running auction, before or after a rotation.
|
|
77
|
+
*
|
|
78
|
+
* Once the auction settles, or when the loan was foreclosed to the lender instead, the owner is
|
|
79
|
+
* an account that is not running an auction on it, so the owner must still record one: a write
|
|
80
|
+
* with no outputs simulates as a success against an account without code and would broadcast.
|
|
81
|
+
*
|
|
82
|
+
* @param mslContractAddress The contract address of the loan's MSL contract
|
|
83
|
+
* @param collectionContractAddress The collateral's collection
|
|
84
|
+
* @param tokenId The collateral's token id
|
|
85
|
+
* @throws When the collateral's owner records no auction on it
|
|
86
|
+
*/
|
|
87
|
+
AllForCollateral({ mslContractAddress, collectionContractAddress, tokenId, }: {
|
|
88
|
+
mslContractAddress: Address;
|
|
89
|
+
collectionContractAddress: Address;
|
|
90
|
+
tokenId: bigint;
|
|
91
|
+
}): Promise<AllV4 | AllV5 | AllV6>;
|
|
68
92
|
/**
|
|
69
93
|
* @param address The contract address of the PurchaseBundler contract
|
|
70
94
|
* @param mslContractAddress The contract address of the MSL contract
|
package/dist/src/errors.d.ts
CHANGED
|
@@ -1,26 +1,4 @@
|
|
|
1
|
-
import { Address
|
|
2
|
-
export declare class InterruptedSendTransactionStepError {
|
|
3
|
-
orderId: string;
|
|
4
|
-
to: Address;
|
|
5
|
-
callbackData: Hash;
|
|
6
|
-
value: bigint;
|
|
7
|
-
constructor({ orderId, to, callbackData, value, }: {
|
|
8
|
-
orderId: string;
|
|
9
|
-
to: Address;
|
|
10
|
-
callbackData: Hash;
|
|
11
|
-
value: bigint;
|
|
12
|
-
});
|
|
13
|
-
}
|
|
14
|
-
export declare class InterruptedSeaportSendTransactionStepError extends InterruptedSendTransactionStepError {
|
|
15
|
-
signature: Hash;
|
|
16
|
-
constructor({ orderId, to, callbackData, value, signature, }: {
|
|
17
|
-
orderId: string;
|
|
18
|
-
to: Address;
|
|
19
|
-
callbackData: Hash;
|
|
20
|
-
value: bigint;
|
|
21
|
-
signature: Hash;
|
|
22
|
-
});
|
|
23
|
-
}
|
|
1
|
+
import { Address } from 'viem';
|
|
24
2
|
/**
|
|
25
3
|
* Thrown before a loan is emitted or refinanced against an NFT the GONDI API flags (for example
|
|
26
4
|
* reported as stolen), or against a wrapper holding one. Lenders' collection offers cannot exclude
|