Library referenceClasses
PublicMarketApi
the market reads that answer without a token; listings, inventory and history need one (token wrapper)
Constructors
Constructor
new PublicMarketApi(gapi): PublicMarketApi;Parameters
| Parameter | Type |
|---|---|
gapi | KrunkerClient |
Returns
PublicMarketApi
Methods
itemSales()
itemSales(skinIndex): Promise<ItemSalesInfo>;GET /market/items/:id/sales, ask range, circulation and the full owner id list (the daily rows are itemSalesStatistics)
Parameters
| Parameter | Type |
|---|---|
skinIndex | number |
Returns
Promise<ItemSalesInfo>
itemSalesStatistics()
itemSalesStatistics(skinIndex, daysBack?): Promise<PlayerSale[]>;GET /market/items/:id/sales-statistics, one row per day with a sale
Parameters
| Parameter | Type | Default value |
|---|---|---|
skinIndex | number | undefined |
daysBack? | number | 30 |
Returns
Promise<PlayerSale[]>
stats()
stats(query?): Promise<MarketStats>;GET /market/stats, 100 skins per page with circulation, on sale count and ask range
Parameters
| Parameter | Type |
|---|---|
query? | MarketStatsQuery |
Returns
Promise<MarketStats>