@rabby-wallet/rabby-api 0.9.48-2 → 0.9.48-3

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, NFTDetail, NFTTradingConfig, PrepareAcceptNFTOfferResponse, PrepareListingNFTResponse, CreateListingNFTOfferResponse } 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, NFTListingResponse } from './types';
5
5
  interface OpenApiStore {
6
6
  host: string;
7
7
  testnetHost?: string;
@@ -1390,7 +1390,15 @@ export declare class OpenApiService {
1390
1390
  id: string;
1391
1391
  user_addr: string;
1392
1392
  }) => Promise<NFTDetail>;
1393
- getNFTCollectionFees: (params: {
1393
+ getNFTListingOrders: (params: {
1394
+ maker: string;
1395
+ chain_id: string;
1396
+ collection_id: string;
1397
+ inner_id: string;
1398
+ limit?: number;
1399
+ cursor?: string;
1400
+ }) => Promise<NFTListingResponse>;
1401
+ getNFTFees: (params: {
1394
1402
  chain_id: string;
1395
1403
  collection_id: string;
1396
1404
  inner_id: string;
package/dist/index.js CHANGED
@@ -1787,7 +1787,13 @@ export class OpenApiService {
1787
1787
  });
1788
1788
  return data;
1789
1789
  });
1790
- this.getNFTCollectionFees = (params) => __awaiter(this, void 0, void 0, function* () {
1790
+ this.getNFTListingOrders = (params) => __awaiter(this, void 0, void 0, function* () {
1791
+ const { data } = yield this.request.get('/v1/nft/order/listing', {
1792
+ params,
1793
+ });
1794
+ return data;
1795
+ });
1796
+ this.getNFTFees = (params) => __awaiter(this, void 0, void 0, function* () {
1791
1797
  const { data } = yield this.request.get('/v1/nft/fee', {
1792
1798
  params,
1793
1799
  });
package/dist/types.d.ts CHANGED
@@ -1843,189 +1843,6 @@ export declare type NFTTradingConfig = Record<string, {
1843
1843
  };
1844
1844
  }>;
1845
1845
  export interface NFTDetail extends NFTItem {
1846
- listing_order: {
1847
- created_date: string;
1848
- closing_date: string;
1849
- listing_time: number;
1850
- expiration_time: number;
1851
- order_hash: string;
1852
- protocol_data: {
1853
- parameters: {
1854
- offerer: string;
1855
- offer: Array<{
1856
- itemType: number;
1857
- token: string;
1858
- identifierOrCriteria: string;
1859
- startAmount: string;
1860
- endAmount: string;
1861
- }>;
1862
- consideration: Array<{
1863
- itemType: number;
1864
- token: string;
1865
- identifierOrCriteria: string;
1866
- startAmount: string;
1867
- endAmount: string;
1868
- recipient: string;
1869
- }>;
1870
- startTime: string;
1871
- endTime: string;
1872
- orderType: number;
1873
- zone: string;
1874
- zoneHash: string;
1875
- salt: string;
1876
- conduitKey: string;
1877
- totalOriginalConsiderationItems: number;
1878
- counter: number;
1879
- };
1880
- signature: null;
1881
- };
1882
- protocol_address: string;
1883
- current_price: string;
1884
- maker: {
1885
- address: string;
1886
- profile_img_url: null;
1887
- config: null;
1888
- };
1889
- taker: null;
1890
- maker_fees: any[];
1891
- taker_fees: any[];
1892
- side: 'ask' | 'bid';
1893
- order_type: 'basic' | string;
1894
- cancelled: boolean;
1895
- finalized: boolean;
1896
- marked_invalid: boolean;
1897
- remaining_quantity: number;
1898
- maker_asset_bundle: {
1899
- assets: Array<{
1900
- id: null;
1901
- token_id: string;
1902
- num_sales: null;
1903
- background_color: null;
1904
- image_url: string | null;
1905
- image_preview_url: null;
1906
- image_thumbnail_url: null;
1907
- image_original_url: null;
1908
- animation_url: null;
1909
- animation_original_url: null;
1910
- name: string;
1911
- description: string | null;
1912
- external_link: null;
1913
- asset_contract: {
1914
- address: string;
1915
- chain_identifier: string;
1916
- schema_name: 'ERC721' | 'ERC1155' | 'NATIVE' | string;
1917
- asset_contract_type: 'non-fungible' | 'semi-fungible' | 'unknown';
1918
- };
1919
- permalink: string | null;
1920
- collection: {
1921
- collection: string;
1922
- name: string;
1923
- description: string;
1924
- image_url: string;
1925
- banner_image_url: string;
1926
- owner: string;
1927
- safelist_status: 'not_requested' | 'verified' | string;
1928
- category: string;
1929
- is_disabled: boolean;
1930
- is_nsfw: boolean;
1931
- trait_offers_enabled: boolean;
1932
- collection_offers_enabled: boolean;
1933
- opensea_url: string;
1934
- project_url: string;
1935
- wiki_url: string;
1936
- discord_url: string;
1937
- telegram_url: string;
1938
- twitter_username: string;
1939
- instagram_username: string;
1940
- contracts: Array<{
1941
- address: string;
1942
- chain: string;
1943
- }>;
1944
- } | null;
1945
- decimals: number | null;
1946
- token_metadata: null;
1947
- is_nsfw: boolean | null;
1948
- owner: {
1949
- address: string;
1950
- profile_img_url: null;
1951
- config: null;
1952
- } | null;
1953
- }>;
1954
- maker: null;
1955
- asset_contract: null;
1956
- slug: null;
1957
- name: null;
1958
- description: null;
1959
- external_link: null;
1960
- permalink: null;
1961
- seaport_sell_orders: null;
1962
- };
1963
- taker_asset_bundle: {
1964
- assets: Array<{
1965
- id: null;
1966
- token_id: string;
1967
- num_sales: null;
1968
- background_color: null;
1969
- image_url: string | null;
1970
- image_preview_url: null;
1971
- image_thumbnail_url: null;
1972
- image_original_url: null;
1973
- animation_url: null;
1974
- animation_original_url: null;
1975
- name: string;
1976
- description: string | null;
1977
- external_link: null;
1978
- asset_contract: {
1979
- address: string;
1980
- chain_identifier: string;
1981
- schema_name: 'ERC721' | 'ERC1155' | 'NATIVE' | string;
1982
- asset_contract_type: 'non-fungible' | 'semi-fungible' | 'unknown';
1983
- };
1984
- permalink: string | null;
1985
- collection: {
1986
- collection: string;
1987
- name: string;
1988
- description: string;
1989
- image_url: string;
1990
- banner_image_url: string;
1991
- owner: string;
1992
- safelist_status: 'not_requested' | 'verified' | string;
1993
- category: string;
1994
- is_disabled: boolean;
1995
- is_nsfw: boolean;
1996
- trait_offers_enabled: boolean;
1997
- collection_offers_enabled: boolean;
1998
- opensea_url: string;
1999
- project_url: string;
2000
- wiki_url: string;
2001
- discord_url: string;
2002
- telegram_url: string;
2003
- twitter_username: string;
2004
- instagram_username: string;
2005
- contracts: Array<{
2006
- address: string;
2007
- chain: string;
2008
- }>;
2009
- } | null;
2010
- decimals: number | null;
2011
- token_metadata: null;
2012
- is_nsfw: boolean | null;
2013
- owner: {
2014
- address: string;
2015
- profile_img_url: null;
2016
- config: null;
2017
- } | null;
2018
- }>;
2019
- maker: null;
2020
- asset_contract: null;
2021
- slug: null;
2022
- name: null;
2023
- description: null;
2024
- external_link: null;
2025
- permalink: null;
2026
- seaport_sell_orders: null;
2027
- };
2028
- } | null;
2029
1846
  best_offer_order: {
2030
1847
  order_hash: string;
2031
1848
  chain: string;
@@ -2100,6 +1917,193 @@ export interface NFTDetail extends NFTItem {
2100
1917
  quantity: number;
2101
1918
  } | null;
2102
1919
  }
1920
+ export interface NFTListingOrder {
1921
+ created_date: string;
1922
+ closing_date: string;
1923
+ listing_time: number;
1924
+ expiration_time: number;
1925
+ order_hash: string;
1926
+ protocol_data: {
1927
+ parameters: {
1928
+ offerer: string;
1929
+ offer: Array<{
1930
+ itemType: number;
1931
+ token: string;
1932
+ identifierOrCriteria: string;
1933
+ startAmount: string;
1934
+ endAmount: string;
1935
+ }>;
1936
+ consideration: Array<{
1937
+ itemType: number;
1938
+ token: string;
1939
+ identifierOrCriteria: string;
1940
+ startAmount: string;
1941
+ endAmount: string;
1942
+ recipient: string;
1943
+ }>;
1944
+ startTime: string;
1945
+ endTime: string;
1946
+ orderType: number;
1947
+ zone: string;
1948
+ zoneHash: string;
1949
+ salt: string;
1950
+ conduitKey: string;
1951
+ totalOriginalConsiderationItems: number;
1952
+ counter: number;
1953
+ };
1954
+ signature: null;
1955
+ };
1956
+ protocol_address: string;
1957
+ current_price: string;
1958
+ maker: {
1959
+ address: string;
1960
+ profile_img_url: null;
1961
+ config: null;
1962
+ };
1963
+ taker: null;
1964
+ maker_fees: any[];
1965
+ taker_fees: any[];
1966
+ side: 'ask' | 'bid';
1967
+ order_type: 'basic' | string;
1968
+ cancelled: boolean;
1969
+ finalized: boolean;
1970
+ marked_invalid: boolean;
1971
+ remaining_quantity: number;
1972
+ maker_asset_bundle: {
1973
+ assets: Array<{
1974
+ id: null;
1975
+ token_id: string;
1976
+ num_sales: null;
1977
+ background_color: null;
1978
+ image_url: string | null;
1979
+ image_preview_url: null;
1980
+ image_thumbnail_url: null;
1981
+ image_original_url: null;
1982
+ animation_url: null;
1983
+ animation_original_url: null;
1984
+ name: string;
1985
+ description: string | null;
1986
+ external_link: null;
1987
+ asset_contract: {
1988
+ address: string;
1989
+ chain_identifier: string;
1990
+ schema_name: 'ERC721' | 'ERC1155' | 'NATIVE' | string;
1991
+ asset_contract_type: 'non-fungible' | 'semi-fungible' | 'unknown';
1992
+ };
1993
+ permalink: string | null;
1994
+ collection: {
1995
+ collection: string;
1996
+ name: string;
1997
+ description: string;
1998
+ image_url: string;
1999
+ banner_image_url: string;
2000
+ owner: string;
2001
+ safelist_status: 'not_requested' | 'verified' | string;
2002
+ category: string;
2003
+ is_disabled: boolean;
2004
+ is_nsfw: boolean;
2005
+ trait_offers_enabled: boolean;
2006
+ collection_offers_enabled: boolean;
2007
+ opensea_url: string;
2008
+ project_url: string;
2009
+ wiki_url: string;
2010
+ discord_url: string;
2011
+ telegram_url: string;
2012
+ twitter_username: string;
2013
+ instagram_username: string;
2014
+ contracts: Array<{
2015
+ address: string;
2016
+ chain: string;
2017
+ }>;
2018
+ } | null;
2019
+ decimals: number | null;
2020
+ token_metadata: null;
2021
+ is_nsfw: boolean | null;
2022
+ owner: {
2023
+ address: string;
2024
+ profile_img_url: null;
2025
+ config: null;
2026
+ } | null;
2027
+ }>;
2028
+ maker: null;
2029
+ asset_contract: null;
2030
+ slug: null;
2031
+ name: null;
2032
+ description: null;
2033
+ external_link: null;
2034
+ permalink: null;
2035
+ seaport_sell_orders: null;
2036
+ };
2037
+ taker_asset_bundle: {
2038
+ assets: Array<{
2039
+ id: null;
2040
+ token_id: string;
2041
+ num_sales: null;
2042
+ background_color: null;
2043
+ image_url: string | null;
2044
+ image_preview_url: null;
2045
+ image_thumbnail_url: null;
2046
+ image_original_url: null;
2047
+ animation_url: null;
2048
+ animation_original_url: null;
2049
+ name: string;
2050
+ description: string | null;
2051
+ external_link: null;
2052
+ asset_contract: {
2053
+ address: string;
2054
+ chain_identifier: string;
2055
+ schema_name: 'ERC721' | 'ERC1155' | 'NATIVE' | string;
2056
+ asset_contract_type: 'non-fungible' | 'semi-fungible' | 'unknown';
2057
+ };
2058
+ permalink: string | null;
2059
+ collection: {
2060
+ collection: string;
2061
+ name: string;
2062
+ description: string;
2063
+ image_url: string;
2064
+ banner_image_url: string;
2065
+ owner: string;
2066
+ safelist_status: 'not_requested' | 'verified' | string;
2067
+ category: string;
2068
+ is_disabled: boolean;
2069
+ is_nsfw: boolean;
2070
+ trait_offers_enabled: boolean;
2071
+ collection_offers_enabled: boolean;
2072
+ opensea_url: string;
2073
+ project_url: string;
2074
+ wiki_url: string;
2075
+ discord_url: string;
2076
+ telegram_url: string;
2077
+ twitter_username: string;
2078
+ instagram_username: string;
2079
+ contracts: Array<{
2080
+ address: string;
2081
+ chain: string;
2082
+ }>;
2083
+ } | null;
2084
+ decimals: number | null;
2085
+ token_metadata: null;
2086
+ is_nsfw: boolean | null;
2087
+ owner: {
2088
+ address: string;
2089
+ profile_img_url: null;
2090
+ config: null;
2091
+ } | null;
2092
+ }>;
2093
+ maker: null;
2094
+ asset_contract: null;
2095
+ slug: null;
2096
+ name: null;
2097
+ description: null;
2098
+ external_link: null;
2099
+ permalink: null;
2100
+ seaport_sell_orders: null;
2101
+ };
2102
+ }
2103
+ export interface NFTListingResponse {
2104
+ orders: NFTListingOrder[];
2105
+ next: string | null;
2106
+ }
2103
2107
  export interface PrepareListingNFTResponse {
2104
2108
  data: {
2105
2109
  sign: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rabby-wallet/rabby-api",
3
- "version": "0.9.48-2",
3
+ "version": "0.9.48-3",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [