Skip to content

Min Prices API

This documentation explains how to use the aggregatedMinPrices GraphQL query to fetch the minimum prices for items across multiple marketplaces.

Authentication

All API requests require authentication using a JWT token. Include the following header in your requests:

HeaderValueDescription
api-token<generated_jwt>Your JWT authentication token

For information on how to generate your JWT token, please refer to the Authentication Guide.

Query

graphql
query MinPrices($markets: [String!]) {
  aggregatedMinPrices(markets: $markets) {
    market_hash_name
    prices {
      market_name
      offers
      price
      price_locked
    }
  }
}

Variables

json
{
  "markets": [
    "buff163",
    "skinport",
    "csmoney",
    "steamcommunity"
  ]
}

Parameters

ParameterTypeDescriptionRequired
markets[String]Array of marketplace names to include in the comparisonYes

Supported Markets

The following marketplaces are supported:

Market NameDescription
avanpriceAvanPrice
bitskinsBitSkins
buff163Buff163
c5C5 Game
csdealsCS.Deals
csfloatCSFloat
csgoempireCSGOEmpire
csgorollCSGORoll
csgotmMarket CSGO
csmoneyCS.MONEY
dmarketDMarket
gamerpayGamerPay
haloskinsHaloSkins
itradeiTrade.gg
lis-skinsLiS-Skins
lootfarmLootFarm
rapidskinsRapidSkins
shadowpayShadowPay
skindeckSkinDeck
skinflowSkinFlow
skinoutSkinOut
skinportSkinPort
skins-monkeySkins Monkey
skinthunderSkin Thunder
steamcommunitySteam Community Market
tradeitTradeIt.gg
waxpeerWaxpeer
white-marketWhite Market

Response Fields

Root Object

FieldTypeDescription
market_hash_nameStringThe unique identifier of the item
prices[MarketPrice]Array of price information for each marketplace

MarketPrice Object

FieldTypeDescription
market_nameStringName of the marketplace
offersIntegerNumber of available offers/listings
priceIntegerMinimum price on the marketplace (divide by 1000 to get the real value)
price_lockedIntegerMinimum price for locked/trade-restricted items (divide by 1000 to get the real value)

Code Examples

js
const axios = require('axios');

async function getMinPrices(markets) {
  const query = `
    query MinPrices($markets: [String!]) {
      aggregatedMinPrices(markets: $markets) {
        market_hash_name
        prices {
          market_name
          offers
          price
          price_locked
        }
      }
    }
  `;

  try {
    const response = await axios({
      url: 'https://api.csmarketcap.com/api/v2/graphql',
      method: 'post',
      headers: {
        'Content-Type': 'application/json',
        'api-token': 'YOUR_JWT_TOKEN_HERE'
      },
      data: {
        query: query,
        variables: {
          markets: markets
        }
      }
    });

    console.log('Min prices:', response.data.data.aggregatedMinPrices);
    return response.data.data.aggregatedMinPrices;
  } catch (error) {
    console.error('Error fetching min prices:', error);
  }
}

// Compare prices across popular marketplaces
getMinPrices(['buff163', 'skinport', 'csmoney', 'steamcommunity']);
bash
curl -X POST https://api.csmarketcap.com/api/v2/graphql \
  -H "Content-Type: application/json" \
  -H "api-token: YOUR_JWT_TOKEN_HERE" \
  -d '{
    "query": "query MinPrices($markets: [String!]) { aggregatedMinPrices(markets: $markets) { market_hash_name prices { market_name offers price price_locked } } }",
    "variables": {
      "markets": ["buff163", "skinport", "csmoney", "steamcommunity"]
    }
  }'

Example Response

json
{
  "data": {
    "aggregatedMinPrices": [
      {
        "market_hash_name": "Sticker | Vitality | Paris 2023",
        "prices": [
          {
            "market_name": "csgotm",
            "offers": 2209,
            "price": 5,
            "price_locked": null
          },
          {
            "market_name": "csmoney",
            "offers": 408,
            "price": 20,
            "price_locked": null
          },
          {
            "market_name": "steamcommunity",
            "offers": 5399718,
            "price": 30,
            "price_locked": null
          }
        ]
      },
      {
        "market_hash_name": "Sticker | IEM | Rio 2022",
        "prices": [
          {
            "market_name": "csgotm",
            "offers": 1045,
            "price": 5,
            "price_locked": null
          },
          {
            "market_name": "csmoney",
            "offers": 44,
            "price": 20,
            "price_locked": null
          },
          {
            "market_name": "steamcommunity",
            "offers": 1239210,
            "price": 30,
            "price_locked": null
          }
        ]
      },
      {
        "market_hash_name": "Sticker | Techno4K | Copenhagen 2024",
        "prices": [
          {
            "market_name": "csgotm",
            "offers": 749,
            "price": 5,
            "price_locked": null
          },
          {
            "market_name": "csmoney",
            "offers": 23,
            "price": 20,
            "price_locked": null
          },
          {
            "market_name": "steamcommunity",
            "offers": 226648,
            "price": 30,
            "price_locked": null
          }
        ]
      },
      {
        "market_hash_name": "Sticker | ZywOo (Champion) | Paris 2023",
        "prices": [
          {
            "market_name": "csgotm",
            "offers": 747,
            "price": 5,
            "price_locked": null
          },
          {
            "market_name": "csmoney",
            "offers": 46,
            "price": 20,
            "price_locked": null
          },
          {
            "market_name": "steamcommunity",
            "offers": 857116,
            "price": 30,
            "price_locked": null
          }
        ]
      },
    ]
  }
}

Usage Notes

  • The price field represents the minimum price for items that can be traded immediately
  • The price_locked field represents the minimum price for items that have trade restrictions (e.g., Steam's 7-day trade hold)
  • For some marketplaces, price and price_locked might be the same if the marketplace doesn't distinguish between locked and unlocked items
  • Price values are provided in cents (divide by 1000 to get dollar value)
  • For efficiency, it's recommended to request only the marketplaces you need rather than all supported ones

Need help? Contact our support team