Skip to content

API Reference / Filter sets

Count filter sets in a workspace

Returns the number of filter sets in the workspace, so a list page can render a count without loading and counting every row.

POST/contracts.v1.Contracts/CountFilterSets

Request body

application/jsonRequired

Request for the number of filter sets in the caller's workspace matching a filter.

filter?FilterSetFilter

The same filter as ListFilterSets. Absent counts all live filter sets in the caller's workspace.

Show attributes
inUse?boolean

True keeps only filter sets referenced by the predicate of at least one live contract or other live filter set in the workspace. False keeps only unreferenced ones. Omitted includes both. The same reference walk GetFilterSetReferrers reports.

query?string

Literal case-insensitive substring to match against the name, the description or the filter set's own rule values: weapon, paint, collection, rarity, weapon type, category and item name values written in its predicate. Values a filter set only reaches through a referenced filter set are not searched. Omitted or empty matches all filter sets.

Response body

application/json

Success

count?integer

Number of live filter sets matching the query in the caller's workspace.

Format"int32"

curl -X POST "https://api.goldmine.to/contracts.v1.Contracts/CountFilterSets" \
  -H "Authorization: Bearer $CSTRADER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
{
  "count": 3
}