@rabby-wallet/rabby-api 0.9.47 → 0.9.48-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.
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { AxiosAdapter, AxiosRequestConfig } from 'axios';
2
2
  import { RateLimitedAxiosInstance } from 'axios-rate-limit';
3
3
  import { InitOptions, RabbyApiPlugin } from './plugins/intf';
4
- import { AddrDescResponse, BridgeAggregator, ApprovalStatus, AssetItem, BasicDappInfo, CEXQuote, Cex, ChainListItem, ChainWithPendingCount, Collection, CollectionList, CollectionWithFloorPrice, ComplexProtocol, ContractCredit, DbkBridgeHistoryItem, ExplainTxResponse, ExplainTypedDataResponse, GasLevel, GetTxResponse, HistoryCurve, LatestExplainTxResponse, MempoolCheckDetail, NFTApprovalResponse, NFTItem, NodeStatus, NodeStatusDetail, ParseTextResponse, ParseTxResponse, ParseTypedDataResponse, PendingTxItem, Protocol, SecurityCheckResponse, ServerChain, SlippageStatus, Summary, SupportedChain, SwapTradeList, TokenApproval, TokenItem, TotalBalanceResponse, Tx, TxAllHistoryResult, TxHistoryResult, TxPushType, TxRequest, UsedChain, BridgeTokenPair, BridgeQuote, BridgeHistory, ContractInfo, GasAccountCheckResult, ParseCommonResponse, WithdrawListAddressItem, BuyCountryItem, BuyQuoteItem, BuyHistoryList, BuyPaymentMethod, GasAccountInfo, TokenEntityDetail, TokenItemWithEntity, ProjectItem, CopyTradeTokenListResponse, CopyTradeRecentBuyListResponse, CopyTradePnlListResponse, AppChainListResponse, CopyTradeTokenListV2Response, CopyTradeRecentBuyListV2Response, CopyTradeTokenItemV2, CopyTradeSameToken, DefaultRPCRes, TokenDetailWithPriceCurve, GiftEligibilityItem, UserFeedbackItem, PerpTopToken, KlineDataItem, TokenMarketInfo, TokenHolderInfo, TokenSupplyInfo, MarketSummary, MarketTradingHistoryItem, TokenHolderSummary, TokenHolderItem, CurrencyItem, PerpBridgeQuote, LiquidityPoolItem, LiquidityPoolHistoryItem } from './types';
4
+ import { AddrDescResponse, BridgeAggregator, ApprovalStatus, AssetItem, BasicDappInfo, CEXQuote, Cex, ChainListItem, ChainWithPendingCount, Collection, CollectionList, CollectionWithFloorPrice, ComplexProtocol, ContractCredit, DbkBridgeHistoryItem, ExplainTxResponse, ExplainTypedDataResponse, GasLevel, GetTxResponse, HistoryCurve, LatestExplainTxResponse, MempoolCheckDetail, NFTApprovalResponse, NFTItem, NodeStatus, NodeStatusDetail, ParseTextResponse, ParseTxResponse, ParseTypedDataResponse, PendingTxItem, Protocol, SecurityCheckResponse, ServerChain, SlippageStatus, Summary, SupportedChain, SwapTradeList, TokenApproval, TokenItem, TotalBalanceResponse, Tx, TxAllHistoryResult, TxHistoryResult, TxPushType, TxRequest, UsedChain, BridgeTokenPair, BridgeQuote, BridgeHistory, ContractInfo, GasAccountCheckResult, ParseCommonResponse, WithdrawListAddressItem, BuyCountryItem, BuyQuoteItem, BuyHistoryList, BuyPaymentMethod, GasAccountInfo, TokenEntityDetail, TokenItemWithEntity, ProjectItem, CopyTradeTokenListResponse, CopyTradeRecentBuyListResponse, CopyTradePnlListResponse, AppChainListResponse, CopyTradeTokenListV2Response, CopyTradeRecentBuyListV2Response, CopyTradeTokenItemV2, CopyTradeSameToken, DefaultRPCRes, TokenDetailWithPriceCurve, GiftEligibilityItem, UserFeedbackItem, PerpTopToken, KlineDataItem, TokenMarketInfo, TokenHolderInfo, TokenSupplyInfo, MarketSummary, MarketTradingHistoryItem, TokenHolderSummary, TokenHolderItem, CurrencyItem, PerpBridgeQuote, LiquidityPoolItem, LiquidityPoolHistoryItem, NFTDetail, NFTTradingConfig, PrepareAcceptNFTOfferResponse, PrepareListingNFTResponse, CreateListingNFTOfferResponse } from './types';
5
5
  interface OpenApiStore {
6
6
  host: string;
7
7
  testnetHost?: string;
@@ -1384,5 +1384,61 @@ export declare class OpenApiService {
1384
1384
  };
1385
1385
  data_list: LiquidityPoolHistoryItem[];
1386
1386
  }>;
1387
+ getNFTTradingConfig: () => Promise<NFTTradingConfig>;
1388
+ getNFTDetail: (params: {
1389
+ chain_id: string;
1390
+ id: string;
1391
+ user_addr: string;
1392
+ }) => Promise<NFTDetail>;
1393
+ getNFTCollectionFees: (params: {
1394
+ chain_id: string;
1395
+ collection_id: string;
1396
+ inner_id: string;
1397
+ }) => Promise<{
1398
+ marketplace_fees: {
1399
+ recipient: string;
1400
+ fee: number;
1401
+ required: boolean;
1402
+ }[];
1403
+ custom_royalties: {
1404
+ recipient: string;
1405
+ fee: number;
1406
+ required: boolean;
1407
+ }[];
1408
+ }>;
1409
+ prepareListingNFT: (postData: {
1410
+ maker: string;
1411
+ chain_id: string;
1412
+ collection_id: string;
1413
+ inner_id: string;
1414
+ wei_price: string;
1415
+ quantity?: number;
1416
+ marketplace_fees: {
1417
+ recipient: string;
1418
+ fee: number;
1419
+ }[];
1420
+ custom_royalties: {
1421
+ recipient: string;
1422
+ fee: number;
1423
+ }[];
1424
+ listing_time_at?: number;
1425
+ expiration_time_at?: number;
1426
+ currency: string;
1427
+ salt?: string;
1428
+ }) => Promise<PrepareListingNFTResponse>;
1429
+ createListingNFT: (postData: {
1430
+ chain_id: string;
1431
+ order: PrepareListingNFTResponse['data']['post']['body']['order'];
1432
+ signature: string;
1433
+ protocol_address?: string;
1434
+ }) => Promise<CreateListingNFTOfferResponse>;
1435
+ prepareAcceptNFTOffer: (postData: {
1436
+ chain_id: string;
1437
+ order_hash: string;
1438
+ fulfiller: string;
1439
+ collection_id: string;
1440
+ inner_id: string;
1441
+ quantity?: number;
1442
+ }) => Promise<PrepareAcceptNFTOfferResponse>;
1387
1443
  }
1388
1444
  export {};
package/dist/index.js CHANGED
@@ -1777,6 +1777,34 @@ export class OpenApiService {
1777
1777
  });
1778
1778
  return data;
1779
1779
  });
1780
+ this.getNFTTradingConfig = () => __awaiter(this, void 0, void 0, function* () {
1781
+ const { data } = yield this.request.get('/v1/nft/trading_config');
1782
+ return data;
1783
+ });
1784
+ this.getNFTDetail = (params) => __awaiter(this, void 0, void 0, function* () {
1785
+ const { data } = yield this.request.get('/v1/nft', {
1786
+ params,
1787
+ });
1788
+ return data;
1789
+ });
1790
+ this.getNFTCollectionFees = (params) => __awaiter(this, void 0, void 0, function* () {
1791
+ const { data } = yield this.request.get('/v1/nft/fee', {
1792
+ params,
1793
+ });
1794
+ return data;
1795
+ });
1796
+ this.prepareListingNFT = (postData) => __awaiter(this, void 0, void 0, function* () {
1797
+ const { data } = yield this.request.post('/v1/nft/order/listing/prepare', postData);
1798
+ return data;
1799
+ });
1800
+ this.createListingNFT = (postData) => __awaiter(this, void 0, void 0, function* () {
1801
+ const { data } = yield this.request.post('/v1/nft/order/listing/post', postData);
1802
+ return data;
1803
+ });
1804
+ this.prepareAcceptNFTOffer = (postData) => __awaiter(this, void 0, void 0, function* () {
1805
+ const { data } = yield this.request.post('/v1/nft/order/offer/accept/prepare', postData);
1806
+ return data;
1807
+ });
1780
1808
  if (store instanceof Promise) {
1781
1809
  store.then((resolvedStore) => {
1782
1810
  this.store = resolvedStore;
package/dist/types.d.ts CHANGED
@@ -411,6 +411,16 @@ export interface Collection {
411
411
  create_at: number;
412
412
  floor_price: number;
413
413
  is_scam: boolean;
414
+ opensea_floor_price?: {
415
+ price: number;
416
+ token: {
417
+ id: string;
418
+ symbol: string;
419
+ decimals: number;
420
+ price: number;
421
+ };
422
+ };
423
+ is_tradable?: boolean;
414
424
  }
415
425
  export interface CollectionList {
416
426
  id: string;
@@ -427,6 +437,8 @@ export interface CollectionList {
427
437
  floor_price: number;
428
438
  nft_list: NFTItem[];
429
439
  native_token: TokenItem;
440
+ is_hidden?: boolean;
441
+ is_tradable?: boolean;
430
442
  }
431
443
  export interface TxDisplayItem extends TxHistoryItem {
432
444
  projectDict: TxHistoryResult['project_dict'];
@@ -1813,4 +1825,756 @@ export declare type LiquidityPoolHistoryItem = {
1813
1825
  usd_value: number;
1814
1826
  }[];
1815
1827
  };
1828
+ export declare type NFTTradingConfig = Record<string, {
1829
+ currency: string[];
1830
+ seaport_v16_address: string;
1831
+ opensea_chain_id: string;
1832
+ opensea_fee_recipient: string;
1833
+ opensea_conduit_address: string;
1834
+ listing_currency: {
1835
+ symbol: string;
1836
+ token_id: string;
1837
+ };
1838
+ offer_currency: {
1839
+ symbol: string;
1840
+ token_id: string;
1841
+ };
1842
+ }>;
1843
+ export interface NFTDetail extends NFTItem {
1844
+ listing_order: {
1845
+ created_date: string;
1846
+ closing_date: string;
1847
+ listing_time: number;
1848
+ expiration_time: number;
1849
+ order_hash: string;
1850
+ protocol_data: {
1851
+ parameters: {
1852
+ offerer: string;
1853
+ offer: Array<{
1854
+ itemType: number;
1855
+ token: string;
1856
+ identifierOrCriteria: string;
1857
+ startAmount: string;
1858
+ endAmount: string;
1859
+ }>;
1860
+ consideration: Array<{
1861
+ itemType: number;
1862
+ token: string;
1863
+ identifierOrCriteria: string;
1864
+ startAmount: string;
1865
+ endAmount: string;
1866
+ recipient: string;
1867
+ }>;
1868
+ startTime: string;
1869
+ endTime: string;
1870
+ orderType: number;
1871
+ zone: string;
1872
+ zoneHash: string;
1873
+ salt: string;
1874
+ conduitKey: string;
1875
+ totalOriginalConsiderationItems: number;
1876
+ counter: number;
1877
+ };
1878
+ signature: null;
1879
+ };
1880
+ protocol_address: string;
1881
+ current_price: string;
1882
+ maker: {
1883
+ address: string;
1884
+ profile_img_url: null;
1885
+ config: null;
1886
+ };
1887
+ taker: null;
1888
+ maker_fees: any[];
1889
+ taker_fees: any[];
1890
+ side: 'ask' | 'bid';
1891
+ order_type: 'basic' | string;
1892
+ cancelled: boolean;
1893
+ finalized: boolean;
1894
+ marked_invalid: boolean;
1895
+ remaining_quantity: number;
1896
+ maker_asset_bundle: {
1897
+ assets: Array<{
1898
+ id: null;
1899
+ token_id: string;
1900
+ num_sales: null;
1901
+ background_color: null;
1902
+ image_url: string | null;
1903
+ image_preview_url: null;
1904
+ image_thumbnail_url: null;
1905
+ image_original_url: null;
1906
+ animation_url: null;
1907
+ animation_original_url: null;
1908
+ name: string;
1909
+ description: string | null;
1910
+ external_link: null;
1911
+ asset_contract: {
1912
+ address: string;
1913
+ chain_identifier: string;
1914
+ schema_name: 'ERC721' | 'ERC1155' | 'NATIVE' | string;
1915
+ asset_contract_type: 'non-fungible' | 'semi-fungible' | 'unknown';
1916
+ };
1917
+ permalink: string | null;
1918
+ collection: {
1919
+ collection: string;
1920
+ name: string;
1921
+ description: string;
1922
+ image_url: string;
1923
+ banner_image_url: string;
1924
+ owner: string;
1925
+ safelist_status: 'not_requested' | 'verified' | string;
1926
+ category: string;
1927
+ is_disabled: boolean;
1928
+ is_nsfw: boolean;
1929
+ trait_offers_enabled: boolean;
1930
+ collection_offers_enabled: boolean;
1931
+ opensea_url: string;
1932
+ project_url: string;
1933
+ wiki_url: string;
1934
+ discord_url: string;
1935
+ telegram_url: string;
1936
+ twitter_username: string;
1937
+ instagram_username: string;
1938
+ contracts: Array<{
1939
+ address: string;
1940
+ chain: string;
1941
+ }>;
1942
+ } | null;
1943
+ decimals: number | null;
1944
+ token_metadata: null;
1945
+ is_nsfw: boolean | null;
1946
+ owner: {
1947
+ address: string;
1948
+ profile_img_url: null;
1949
+ config: null;
1950
+ } | null;
1951
+ }>;
1952
+ maker: null;
1953
+ asset_contract: null;
1954
+ slug: null;
1955
+ name: null;
1956
+ description: null;
1957
+ external_link: null;
1958
+ permalink: null;
1959
+ seaport_sell_orders: null;
1960
+ };
1961
+ taker_asset_bundle: {
1962
+ assets: Array<{
1963
+ id: null;
1964
+ token_id: string;
1965
+ num_sales: null;
1966
+ background_color: null;
1967
+ image_url: string | null;
1968
+ image_preview_url: null;
1969
+ image_thumbnail_url: null;
1970
+ image_original_url: null;
1971
+ animation_url: null;
1972
+ animation_original_url: null;
1973
+ name: string;
1974
+ description: string | null;
1975
+ external_link: null;
1976
+ asset_contract: {
1977
+ address: string;
1978
+ chain_identifier: string;
1979
+ schema_name: 'ERC721' | 'ERC1155' | 'NATIVE' | string;
1980
+ asset_contract_type: 'non-fungible' | 'semi-fungible' | 'unknown';
1981
+ };
1982
+ permalink: string | null;
1983
+ collection: {
1984
+ collection: string;
1985
+ name: string;
1986
+ description: string;
1987
+ image_url: string;
1988
+ banner_image_url: string;
1989
+ owner: string;
1990
+ safelist_status: 'not_requested' | 'verified' | string;
1991
+ category: string;
1992
+ is_disabled: boolean;
1993
+ is_nsfw: boolean;
1994
+ trait_offers_enabled: boolean;
1995
+ collection_offers_enabled: boolean;
1996
+ opensea_url: string;
1997
+ project_url: string;
1998
+ wiki_url: string;
1999
+ discord_url: string;
2000
+ telegram_url: string;
2001
+ twitter_username: string;
2002
+ instagram_username: string;
2003
+ contracts: Array<{
2004
+ address: string;
2005
+ chain: string;
2006
+ }>;
2007
+ } | null;
2008
+ decimals: number | null;
2009
+ token_metadata: null;
2010
+ is_nsfw: boolean | null;
2011
+ owner: {
2012
+ address: string;
2013
+ profile_img_url: null;
2014
+ config: null;
2015
+ } | null;
2016
+ }>;
2017
+ maker: null;
2018
+ asset_contract: null;
2019
+ slug: null;
2020
+ name: null;
2021
+ description: null;
2022
+ external_link: null;
2023
+ permalink: null;
2024
+ seaport_sell_orders: null;
2025
+ };
2026
+ } | null;
2027
+ best_offer_order: {
2028
+ order_hash: string;
2029
+ chain: string;
2030
+ protocol_data: {
2031
+ parameters: {
2032
+ offerer: string;
2033
+ offer: Array<{
2034
+ itemType: number;
2035
+ token: string;
2036
+ identifierOrCriteria: string;
2037
+ startAmount: string;
2038
+ endAmount: string;
2039
+ }>;
2040
+ consideration: Array<{
2041
+ itemType: number;
2042
+ token: string;
2043
+ identifierOrCriteria: string;
2044
+ startAmount: string;
2045
+ endAmount: string;
2046
+ recipient: string;
2047
+ }>;
2048
+ startTime: string;
2049
+ endTime: string;
2050
+ orderType: number;
2051
+ zone: string;
2052
+ zoneHash: string;
2053
+ salt: string;
2054
+ conduitKey: string;
2055
+ totalOriginalConsiderationItems: number;
2056
+ counter: number;
2057
+ };
2058
+ signature: null;
2059
+ };
2060
+ protocol_address: string;
2061
+ remaining_quantity: number;
2062
+ criteria: {
2063
+ collection: {
2064
+ slug: string;
2065
+ };
2066
+ contract: {
2067
+ address: string;
2068
+ };
2069
+ trait: null;
2070
+ traits: null;
2071
+ encoded_token_ids: string;
2072
+ };
2073
+ price: {
2074
+ currency: string;
2075
+ decimals: number;
2076
+ value: string;
2077
+ };
2078
+ status: 'ACTIVE' | string;
2079
+ } | null;
2080
+ rarity: {
2081
+ strategy_id: 'openrarity' | string;
2082
+ strategy_version: string;
2083
+ rank: number;
2084
+ } | null;
2085
+ last_sale?: {
2086
+ event_type: 'sale' | string;
2087
+ event_timestamp: number;
2088
+ transaction: string;
2089
+ payment: {
2090
+ quantity: string;
2091
+ decimals: number;
2092
+ symbol: string;
2093
+ token_id: string;
2094
+ price: number;
2095
+ };
2096
+ seller: string;
2097
+ buyer: string;
2098
+ quantity: number;
2099
+ } | null;
2100
+ }
2101
+ export interface PrepareListingNFTResponse {
2102
+ data: {
2103
+ sign: {
2104
+ signatureKind: string;
2105
+ domain: {
2106
+ name: string;
2107
+ version: string;
2108
+ chainId: number;
2109
+ verifyingContract: string;
2110
+ };
2111
+ types: {
2112
+ EIP712Domain: Array<{
2113
+ name: string;
2114
+ type: string;
2115
+ }>;
2116
+ OrderComponents: Array<{
2117
+ name: string;
2118
+ type: string;
2119
+ }>;
2120
+ OfferItem: Array<{
2121
+ name: string;
2122
+ type: string;
2123
+ }>;
2124
+ ConsiderationItem: Array<{
2125
+ name: string;
2126
+ type: string;
2127
+ }>;
2128
+ };
2129
+ value: {
2130
+ offerer: string;
2131
+ zone: string;
2132
+ offer: Array<{
2133
+ itemType: number;
2134
+ token: string;
2135
+ identifierOrCriteria: string;
2136
+ startAmount: string;
2137
+ endAmount: string;
2138
+ }>;
2139
+ consideration: Array<{
2140
+ itemType: number;
2141
+ token: string;
2142
+ identifierOrCriteria: string;
2143
+ startAmount: string;
2144
+ endAmount: string;
2145
+ recipient: string;
2146
+ }>;
2147
+ orderType: number;
2148
+ startTime: string;
2149
+ endTime: string;
2150
+ zoneHash: string;
2151
+ salt: string;
2152
+ conduitKey: string;
2153
+ counter: string;
2154
+ };
2155
+ primaryType: string;
2156
+ };
2157
+ post: {
2158
+ endpoint: string;
2159
+ method: string;
2160
+ body: {
2161
+ order: {
2162
+ kind: string;
2163
+ data: {
2164
+ offerer: string;
2165
+ zone: string;
2166
+ offer: Array<{
2167
+ itemType: number;
2168
+ token: string;
2169
+ identifierOrCriteria: string;
2170
+ startAmount: string;
2171
+ endAmount: string;
2172
+ }>;
2173
+ consideration: Array<{
2174
+ itemType: number;
2175
+ token: string;
2176
+ identifierOrCriteria: string;
2177
+ startAmount: string;
2178
+ endAmount: string;
2179
+ recipient: string;
2180
+ }>;
2181
+ orderType: number;
2182
+ startTime: string;
2183
+ endTime: string;
2184
+ zoneHash: string;
2185
+ salt: string;
2186
+ conduitKey: string;
2187
+ counter: string;
2188
+ };
2189
+ };
2190
+ };
2191
+ };
2192
+ };
2193
+ }
2194
+ export interface PrepareAcceptNFTOfferResponse {
2195
+ data: {
2196
+ protocol: string;
2197
+ fulfillment_data: {
2198
+ transaction: {
2199
+ function: string;
2200
+ chain: number;
2201
+ to: string;
2202
+ value: number;
2203
+ input_data: {
2204
+ advancedOrder: {
2205
+ parameters: {
2206
+ offerer: string;
2207
+ zone: string;
2208
+ zoneHash: string;
2209
+ startTime: string;
2210
+ endTime: string;
2211
+ orderType: number;
2212
+ salt: string;
2213
+ conduitKey: string;
2214
+ totalOriginalConsiderationItems: number;
2215
+ offer: Array<{
2216
+ itemType: number;
2217
+ token: string;
2218
+ identifierOrCriteria: string;
2219
+ startAmount: string;
2220
+ endAmount: string;
2221
+ }>;
2222
+ consideration: Array<{
2223
+ itemType: number;
2224
+ token: string;
2225
+ identifierOrCriteria: string;
2226
+ startAmount: string;
2227
+ endAmount: string;
2228
+ recipient: string;
2229
+ }>;
2230
+ counter: number;
2231
+ };
2232
+ numerator: string;
2233
+ denominator: string;
2234
+ signature: string;
2235
+ extraData: string;
2236
+ };
2237
+ criteriaResolvers?: Array<{
2238
+ orderIndex: number;
2239
+ side: number;
2240
+ index: number;
2241
+ identifier: string;
2242
+ criteriaProof: string[];
2243
+ }>;
2244
+ fulfillerConduitKey?: string;
2245
+ recipient: string;
2246
+ } | {
2247
+ basicOrderParameters: {
2248
+ considerationToken: string;
2249
+ considerationIdentifier: string;
2250
+ considerationAmount: string;
2251
+ offerer: string;
2252
+ zone: string;
2253
+ offerToken: string;
2254
+ offerIdentifier: string;
2255
+ offerAmount: string;
2256
+ basicOrderType: number;
2257
+ startTime: string;
2258
+ endTime: string;
2259
+ zoneHash: string;
2260
+ salt: string;
2261
+ offererConduitKey: string;
2262
+ fulfillerConduitKey: string;
2263
+ totalOriginalAdditionalRecipients: number;
2264
+ additionalRecipients: Array<{
2265
+ amount: string;
2266
+ recipient: string;
2267
+ }>;
2268
+ signature: string;
2269
+ };
2270
+ } | {
2271
+ order: {
2272
+ parameters: {
2273
+ offerer: string;
2274
+ zone: string;
2275
+ zoneHash: string;
2276
+ startTime: string;
2277
+ endTime: string;
2278
+ orderType: number;
2279
+ salt: string;
2280
+ conduitKey: string;
2281
+ totalOriginalConsiderationItems: number;
2282
+ offer: Array<{
2283
+ itemType: number;
2284
+ token: string;
2285
+ identifierOrCriteria: string;
2286
+ startAmount: string;
2287
+ endAmount: string;
2288
+ }>;
2289
+ consideration: Array<{
2290
+ itemType: number;
2291
+ token: string;
2292
+ identifierOrCriteria: string;
2293
+ startAmount: string;
2294
+ endAmount: string;
2295
+ recipient: string;
2296
+ }>;
2297
+ counter: number;
2298
+ };
2299
+ signature: string;
2300
+ };
2301
+ fulfillerConduitKey?: string;
2302
+ recipient: string;
2303
+ } | {
2304
+ orders: Array<{
2305
+ parameters: {
2306
+ offerer: string;
2307
+ zone: string;
2308
+ zoneHash: string;
2309
+ startTime: string;
2310
+ endTime: string;
2311
+ orderType: number;
2312
+ salt: string;
2313
+ conduitKey: string;
2314
+ totalOriginalConsiderationItems: number;
2315
+ offer: Array<{
2316
+ itemType: number;
2317
+ token: string;
2318
+ identifierOrCriteria: string;
2319
+ startAmount: string;
2320
+ endAmount: string;
2321
+ }>;
2322
+ consideration: Array<{
2323
+ itemType: number;
2324
+ token: string;
2325
+ identifierOrCriteria: string;
2326
+ startAmount: string;
2327
+ endAmount: string;
2328
+ recipient: string;
2329
+ }>;
2330
+ counter: number;
2331
+ };
2332
+ signature: string;
2333
+ } | {
2334
+ parameters: {
2335
+ offerer: string;
2336
+ zone: string;
2337
+ zoneHash: string;
2338
+ startTime: string;
2339
+ endTime: string;
2340
+ orderType: number;
2341
+ salt: string;
2342
+ conduitKey: string;
2343
+ totalOriginalConsiderationItems: number;
2344
+ offer: Array<{
2345
+ itemType: number;
2346
+ token: string;
2347
+ identifierOrCriteria: string;
2348
+ startAmount: string;
2349
+ endAmount: string;
2350
+ }>;
2351
+ consideration: Array<{
2352
+ itemType: number;
2353
+ token: string;
2354
+ identifierOrCriteria: string;
2355
+ startAmount: string;
2356
+ endAmount: string;
2357
+ recipient: string;
2358
+ }>;
2359
+ counter: number;
2360
+ };
2361
+ numerator: string;
2362
+ denominator: string;
2363
+ signature: string;
2364
+ extraData: string;
2365
+ } | {
2366
+ considerationToken: string;
2367
+ considerationIdentifier: string;
2368
+ considerationAmount: string;
2369
+ offerer: string;
2370
+ zone: string;
2371
+ offerToken: string;
2372
+ offerIdentifier: string;
2373
+ offerAmount: string;
2374
+ basicOrderType: number;
2375
+ startTime: string;
2376
+ endTime: string;
2377
+ zoneHash: string;
2378
+ salt: string;
2379
+ offererConduitKey: string;
2380
+ fulfillerConduitKey: string;
2381
+ totalOriginalAdditionalRecipients: number;
2382
+ additionalRecipients: Array<{
2383
+ amount: string;
2384
+ recipient: string;
2385
+ }>;
2386
+ signature: string;
2387
+ }>;
2388
+ };
2389
+ };
2390
+ orders: Array<{
2391
+ parameters: {
2392
+ offerer: string;
2393
+ zone: string;
2394
+ zoneHash: string;
2395
+ startTime: string;
2396
+ endTime: string;
2397
+ orderType: number;
2398
+ salt: string;
2399
+ conduitKey: string;
2400
+ totalOriginalConsiderationItems: number;
2401
+ offer: Array<{
2402
+ itemType: number;
2403
+ token: string;
2404
+ identifierOrCriteria: string;
2405
+ startAmount: string;
2406
+ endAmount: string;
2407
+ }>;
2408
+ consideration: Array<{
2409
+ itemType: number;
2410
+ token: string;
2411
+ identifierOrCriteria: string;
2412
+ startAmount: string;
2413
+ endAmount: string;
2414
+ recipient: string;
2415
+ }>;
2416
+ counter: number;
2417
+ };
2418
+ signature: string;
2419
+ }>;
2420
+ };
2421
+ };
2422
+ }
2423
+ export interface CreateListingNFTOfferResponse {
2424
+ order: {
2425
+ created_date: string;
2426
+ closing_date: string;
2427
+ listing_time: number;
2428
+ expiration_time: number;
2429
+ order_hash: string;
2430
+ protocol_data: {
2431
+ parameters: {
2432
+ offerer: string;
2433
+ offer: Array<{
2434
+ itemType: number;
2435
+ token: string;
2436
+ identifierOrCriteria: string;
2437
+ startAmount: string;
2438
+ endAmount: string;
2439
+ }>;
2440
+ consideration: Array<{
2441
+ itemType: number;
2442
+ token: string;
2443
+ identifierOrCriteria: string;
2444
+ startAmount: string;
2445
+ endAmount: string;
2446
+ recipient: string;
2447
+ }>;
2448
+ startTime: string;
2449
+ endTime: string;
2450
+ orderType: number;
2451
+ zone: string;
2452
+ zoneHash: string;
2453
+ salt: string;
2454
+ conduitKey: string;
2455
+ totalOriginalConsiderationItems: number;
2456
+ counter: number;
2457
+ };
2458
+ signature: null;
2459
+ };
2460
+ protocol_address: string;
2461
+ current_price: string;
2462
+ maker: {
2463
+ address: string;
2464
+ profile_img_url: null;
2465
+ config: null;
2466
+ };
2467
+ taker: null;
2468
+ maker_fees: any[];
2469
+ taker_fees: any[];
2470
+ side: 'ask' | 'bid';
2471
+ order_type: 'basic' | string;
2472
+ cancelled: boolean;
2473
+ finalized: boolean;
2474
+ marked_invalid: boolean;
2475
+ remaining_quantity: number;
2476
+ maker_asset_bundle: {
2477
+ assets: Array<{
2478
+ id: null;
2479
+ token_id: string;
2480
+ num_sales: null;
2481
+ background_color: null;
2482
+ image_url: string | null;
2483
+ image_preview_url: null;
2484
+ image_thumbnail_url: null;
2485
+ image_original_url: null;
2486
+ animation_url: null;
2487
+ animation_original_url: null;
2488
+ name: string;
2489
+ description: string | null;
2490
+ external_link: null;
2491
+ asset_contract: {
2492
+ address: string;
2493
+ chain_identifier: string;
2494
+ schema_name: 'ERC721' | 'ERC1155' | 'NATIVE' | string;
2495
+ asset_contract_type: 'non-fungible' | 'semi-fungible' | 'unknown';
2496
+ };
2497
+ permalink: string | null;
2498
+ collection: {
2499
+ collection: string;
2500
+ name: string;
2501
+ description: string;
2502
+ image_url: string;
2503
+ banner_image_url: string;
2504
+ owner: string;
2505
+ safelist_status: 'not_requested' | 'verified' | string;
2506
+ category: string;
2507
+ is_disabled: boolean;
2508
+ is_nsfw: boolean;
2509
+ trait_offers_enabled: boolean;
2510
+ collection_offers_enabled: boolean;
2511
+ opensea_url: string;
2512
+ project_url: string;
2513
+ wiki_url: string;
2514
+ discord_url: string;
2515
+ telegram_url: string;
2516
+ twitter_username: string;
2517
+ instagram_username: string;
2518
+ contracts: Array<{
2519
+ address: string;
2520
+ chain: string;
2521
+ }>;
2522
+ } | null;
2523
+ decimals: number | null;
2524
+ token_metadata: null;
2525
+ is_nsfw: boolean | null;
2526
+ owner: {
2527
+ address: string;
2528
+ profile_img_url: null;
2529
+ config: null;
2530
+ } | null;
2531
+ }>;
2532
+ maker: null;
2533
+ asset_contract: null;
2534
+ slug: null;
2535
+ name: null;
2536
+ description: null;
2537
+ external_link: null;
2538
+ permalink: null;
2539
+ seaport_sell_orders: null;
2540
+ };
2541
+ taker_asset_bundle: {
2542
+ assets: Array<{
2543
+ id: null;
2544
+ token_id: string;
2545
+ num_sales: null;
2546
+ background_color: null;
2547
+ image_url: null;
2548
+ image_preview_url: null;
2549
+ image_thumbnail_url: null;
2550
+ image_original_url: null;
2551
+ animation_url: null;
2552
+ animation_original_url: null;
2553
+ name: string;
2554
+ description: null;
2555
+ external_link: null;
2556
+ asset_contract: {
2557
+ address: string;
2558
+ chain_identifier: string;
2559
+ schema_name: 'NATIVE' | string;
2560
+ asset_contract_type: 'unknown';
2561
+ };
2562
+ permalink: null;
2563
+ collection: null;
2564
+ decimals: number;
2565
+ token_metadata: null;
2566
+ is_nsfw: null;
2567
+ owner: null;
2568
+ }>;
2569
+ maker: null;
2570
+ asset_contract: null;
2571
+ slug: null;
2572
+ name: null;
2573
+ description: null;
2574
+ external_link: null;
2575
+ permalink: null;
2576
+ seaport_sell_orders: null;
2577
+ };
2578
+ };
2579
+ }
1816
2580
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rabby-wallet/rabby-api",
3
- "version": "0.9.47",
3
+ "version": "0.9.48-1",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [