Skip to content

API Reference / Contracts

Count the copies of items the workspace holds

For each named item, the copies the workspace holds now across every float window: items in its Steam inventories plus items bought and still arriving, each counted once, which is the count a contract's max owned per item limit is held to.

POST/contracts.v1.Contracts/GetOwnedItemCounts

Request body

application/jsonRequired

Request for the copies the caller's workspace holds of each named item.

marketHashNames?array<string>

The items to count, from 1 to 100 distinct market hash names.

Response body

application/json

Success

items?array<OwnedItemCount>

One entry per requested item, in request order.

Show attributes
marketHashName?string

The item's market hash name.

ownedCount?integer

Copies held across every float window: items in the workspace's Steam inventories plus items bought and still arriving, each counted once.

Format"int32"

curl -X POST "https://api.goldmine.to/contracts.v1.Contracts/GetOwnedItemCounts" \
  -H "Authorization: Bearer $CSTRADER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "marketHashNames": [
      "AK-47 | Redline (Field-Tested)",
      "AWP | Asiimov (Field-Tested)"
    ]
  }'
{
  "items": [
    {
      "marketHashName": "AK-47 | Redline (Field-Tested)",
      "ownedCount": 2
    },
    {
      "marketHashName": "AWP | Asiimov (Field-Tested)",
      "ownedCount": 0
    }
  ]
}