@net-protocol/bazaar 0.1.0 → 0.1.1

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.
@@ -93,6 +93,37 @@ interface Erc20Offer {
93
93
  /** Decoded Seaport order components */
94
94
  orderComponents?: SeaportOrderComponents;
95
95
  }
96
+ /**
97
+ * ERC20 listing information
98
+ */
99
+ interface Erc20Listing {
100
+ /** Seller's address */
101
+ maker: `0x${string}`;
102
+ /** ERC20 token address being sold */
103
+ tokenAddress: `0x${string}`;
104
+ /** Amount of tokens being sold */
105
+ tokenAmount: bigint;
106
+ /** Total price in wei (native currency) */
107
+ priceWei: bigint;
108
+ /** Price per token in wei (priceWei / tokenAmount) */
109
+ pricePerTokenWei: bigint;
110
+ /** Total price in native currency (formatted) */
111
+ price: number;
112
+ /** Price per token in native currency (formatted) */
113
+ pricePerToken: number;
114
+ /** Currency symbol (e.g., "eth", "hype") */
115
+ currency: string;
116
+ /** Expiration timestamp in seconds */
117
+ expirationDate: number;
118
+ /** Seaport order hash */
119
+ orderHash: `0x${string}`;
120
+ /** Order status */
121
+ orderStatus: SeaportOrderStatus;
122
+ /** Raw message data for fulfillment */
123
+ messageData: `0x${string}`;
124
+ /** Decoded Seaport order components */
125
+ orderComponents?: SeaportOrderComponents;
126
+ }
96
127
  /**
97
128
  * Seaport item types
98
129
  */
@@ -230,6 +261,17 @@ interface GetErc20OffersOptions {
230
261
  /** Maximum number of messages to fetch (default: 200) */
231
262
  maxMessages?: number;
232
263
  }
264
+ /**
265
+ * Options for fetching ERC20 listings
266
+ */
267
+ interface GetErc20ListingsOptions {
268
+ /** ERC20 token address to filter by */
269
+ tokenAddress: `0x${string}`;
270
+ /** Exclude listings from this address */
271
+ excludeMaker?: `0x${string}`;
272
+ /** Maximum number of messages to fetch (default: 200) */
273
+ maxMessages?: number;
274
+ }
233
275
  /**
234
276
  * Transaction configuration for write operations
235
277
  */
@@ -244,4 +286,4 @@ interface WriteTransactionConfig {
244
286
  abi: readonly unknown[];
245
287
  }
246
288
 
247
- export { type CollectionOffer as C, type Erc20Offer as E, type GetListingsOptions as G, ItemType as I, type Listing as L, OrderType as O, type SeaportOrderComponents as S, type WriteTransactionConfig as W, type GetCollectionOffersOptions as a, type GetErc20OffersOptions as b, type SeaportSubmission as c, type SeaportOrderParameters as d, type SeaportOrderStatusInfo as e, SeaportOrderStatus as f, type OfferItem as g, type ConsiderationItem as h, type CreateListingParams as i, type CreateCollectionOfferParams as j };
289
+ export { type CollectionOffer as C, type Erc20Offer as E, type GetListingsOptions as G, ItemType as I, type Listing as L, OrderType as O, type SeaportOrderComponents as S, type WriteTransactionConfig as W, type GetCollectionOffersOptions as a, type GetErc20OffersOptions as b, type GetErc20ListingsOptions as c, type Erc20Listing as d, type SeaportSubmission as e, type SeaportOrderParameters as f, type SeaportOrderStatusInfo as g, SeaportOrderStatus as h, type OfferItem as i, type ConsiderationItem as j, type CreateListingParams as k, type CreateCollectionOfferParams as l };
@@ -93,6 +93,37 @@ interface Erc20Offer {
93
93
  /** Decoded Seaport order components */
94
94
  orderComponents?: SeaportOrderComponents;
95
95
  }
96
+ /**
97
+ * ERC20 listing information
98
+ */
99
+ interface Erc20Listing {
100
+ /** Seller's address */
101
+ maker: `0x${string}`;
102
+ /** ERC20 token address being sold */
103
+ tokenAddress: `0x${string}`;
104
+ /** Amount of tokens being sold */
105
+ tokenAmount: bigint;
106
+ /** Total price in wei (native currency) */
107
+ priceWei: bigint;
108
+ /** Price per token in wei (priceWei / tokenAmount) */
109
+ pricePerTokenWei: bigint;
110
+ /** Total price in native currency (formatted) */
111
+ price: number;
112
+ /** Price per token in native currency (formatted) */
113
+ pricePerToken: number;
114
+ /** Currency symbol (e.g., "eth", "hype") */
115
+ currency: string;
116
+ /** Expiration timestamp in seconds */
117
+ expirationDate: number;
118
+ /** Seaport order hash */
119
+ orderHash: `0x${string}`;
120
+ /** Order status */
121
+ orderStatus: SeaportOrderStatus;
122
+ /** Raw message data for fulfillment */
123
+ messageData: `0x${string}`;
124
+ /** Decoded Seaport order components */
125
+ orderComponents?: SeaportOrderComponents;
126
+ }
96
127
  /**
97
128
  * Seaport item types
98
129
  */
@@ -230,6 +261,17 @@ interface GetErc20OffersOptions {
230
261
  /** Maximum number of messages to fetch (default: 200) */
231
262
  maxMessages?: number;
232
263
  }
264
+ /**
265
+ * Options for fetching ERC20 listings
266
+ */
267
+ interface GetErc20ListingsOptions {
268
+ /** ERC20 token address to filter by */
269
+ tokenAddress: `0x${string}`;
270
+ /** Exclude listings from this address */
271
+ excludeMaker?: `0x${string}`;
272
+ /** Maximum number of messages to fetch (default: 200) */
273
+ maxMessages?: number;
274
+ }
233
275
  /**
234
276
  * Transaction configuration for write operations
235
277
  */
@@ -244,4 +286,4 @@ interface WriteTransactionConfig {
244
286
  abi: readonly unknown[];
245
287
  }
246
288
 
247
- export { type CollectionOffer as C, type Erc20Offer as E, type GetListingsOptions as G, ItemType as I, type Listing as L, OrderType as O, type SeaportOrderComponents as S, type WriteTransactionConfig as W, type GetCollectionOffersOptions as a, type GetErc20OffersOptions as b, type SeaportSubmission as c, type SeaportOrderParameters as d, type SeaportOrderStatusInfo as e, SeaportOrderStatus as f, type OfferItem as g, type ConsiderationItem as h, type CreateListingParams as i, type CreateCollectionOfferParams as j };
289
+ export { type CollectionOffer as C, type Erc20Offer as E, type GetListingsOptions as G, ItemType as I, type Listing as L, OrderType as O, type SeaportOrderComponents as S, type WriteTransactionConfig as W, type GetCollectionOffersOptions as a, type GetErc20OffersOptions as b, type GetErc20ListingsOptions as c, type Erc20Listing as d, type SeaportSubmission as e, type SeaportOrderParameters as f, type SeaportOrderStatusInfo as g, SeaportOrderStatus as h, type OfferItem as i, type ConsiderationItem as j, type CreateListingParams as k, type CreateCollectionOfferParams as l };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@net-protocol/bazaar",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "NFT marketplace SDK for Net Protocol - listings, collection offers, and ERC20 offers via Seaport",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",