New: live data for Youpin, CSFloat, and Steam

POST /v1/live/youpin/listing_detail

Returns one Youpin listing by its ID, with the fullest item data Youpin has for it.

Available on all plans, at 4 requests per minute on Developer and 20 on Scale. Each request is for one listing.

Prices are in CNY and aren't converted. Data is real-time.

Inputs#

FieldTypeMeaning
listingobjectRequired. The listing to read, with its ID in listing.listing_id as a string of digits.
market_hash_namestringOptional. The item you expect the listing to be.
item_idstringOptional. The same, by Youpin template ID.
raw_responsebooleanfalse returns a structured row. Without it, data is Youpin's own JSON.
{
  "listing": { "listing_id": "2108650166" }
}

The ID is the id of a structured listings row, whose detail_query is this request.

If you name an item and the listing is a different one, the request returns 400.

Listing detail takes no filters, no sorting, and no listing_type.

Request#

POSTapi.cs2.sh/v1/live/youpin/listing_detail
curl -X POST https://api.cs2.sh/v1/live/youpin/listing_detail \
  -H "Authorization: Bearer <<YOUR_API_KEY>>" \
  -H "Accept-Encoding: gzip" --compressed \
  -H "Content-Type: application/json" \
  -d '{
  "listing": {
    "listing_id": "2108650166"
  },
  "raw_response": false
}'

Response#

{
  "market": "string",
  "operation": "string",
  "data": null,
  "page": {
    "page_size": 0,
    "has_next": false,
    "next_cursor": "string",
    "cursor_expires_at": "string",
    "total_count": 0,
    "total_exact": false
  },
  "warnings": [
    {
      "code": "string",
      "field": "string",
      "message": "string"
    }
  ],
  "response_time": "string"
}

Response fields#

LiveResponse fields:

FieldTypeRequiredDescription
marketstringNoThe marketplace: youpin, csfloat, or steam.
operationstringNoThe operation that ran, such as listings.
dataobjectNoWith raw_response: true, the default, the marketplace's own JSON, unchanged. With raw_response: false, the operation's structured object, which is one of LiveListingsData, LiveListingDetailData, LiveBuyOrdersData, SteamBuyOrderBook, LiveFloatRankData, or LiveSearchData.
pageLivePage | nullNoPaging for the next request. null on operations that aren't paged.
warningsLiveRequestWarning[]NoNotes about the request itself. Absent when there are none.
response_timestring (date-time)NoWhen cs2.sh sent the response (UTC).

Response data#

With raw_response: false, data.listing is one LiveListing, the same shape listings returns, with its LiveItem and the seller's store_query.

Notes#

Youpin still responds for a listing that has sold, so a response doesn't mean the item can be bought.

Auctions have no listing detail. An auction row's detail_query is null, and its id is an auction ID that this operation doesn't take.

Errors#

Listing detail returns the shared live errors.

POST /v1/live/youpin/listing_detail/options#

Listing detail takes no filters and no sorting, so its options path has nothing useful to list. It exists because every live operation has one.

Request#

POSTapi.cs2.sh/v1/live/youpin/listing_detail/options
curl -X POST https://api.cs2.sh/v1/live/youpin/listing_detail/options \
  -H "Authorization: Bearer <<YOUR_API_KEY>>" \
  -H "Accept-Encoding: gzip" --compressed \
  -H "Content-Type: application/json" \
  -d '{
  "field": "string",
  "contains": "string",
  "cursor": "string"
}'

Parameters#

FieldTypeRequiredDescription
fieldstringYesThe request field to list choices for, such as filters.weapon or filters.stickers.entries[].name.
containsstringNoText that a choice's label must contain, matched without regard to case.
cursorstringNoThe page.next_cursor from the previous page of choices, sent as the only field.

Response#

{
  "market": "string",
  "operation": "string",
  "field": "string",
  "availability": "string",
  "completeness": "string",
  "options": [
    {
      "label": "string",
      "query": {
        "path": "string",
        "body": null
      }
    }
  ],
  "metadata": null,
  "page": {
    "page_size": 0,
    "has_next": false,
    "next_cursor": "string",
    "cursor_expires_at": "string",
    "total_count": 0,
    "total_exact": false
  },
  "response_time": "string"
}

Response fields#

LiveOptionsResponse fields:

FieldTypeRequiredDescription
marketstringNoThe marketplace.
operationstringNoThe data operation the choices apply to.
fieldstringNoThe request field the choices are for.
availabilitystringNoWhether choices could be loaded for this request.
completenessstringNocomplete when the list holds every accepted value. partial when it holds suggestions, and other values may also work.
optionsLiveOption[]NoThe choices.
metadataobjectNoInformation about the choice list, such as when it was fetched.
pageLivePageNoPaging for long choice lists.
response_timestring (date-time)NoWhen cs2.sh sent the response (UTC).