Filter gauges by project and list archived or trashed templates (Go)
Go callers can now list gauges for chosen projects (GaugeListOptions.BucketIDs) and list archived or trashed templates (TemplateListOptions.Status). The spec and the generated client already take both query parameters (ListGaugesParams.BucketIds, ListTemplatesParams.Status). The hand-written Go wrappers never set them. The other six SDKs' services are generated, so this is a Go-only change.
Why
The MCP parity table (2026-11-04) found that list_gauges and list_templates in basecamp-mcp-server can't filter. The server reaches Basecamp only through these wrappers, so the fix has to start here:
- [MCP] Filter gauges by project
- [MCP] Templates: list archived or trashed ones, and give a new project a start date
The CLI has the same gaps ([CLI] Filter gauges by project; [CLI] List archived or trashed templates).
What changed
| Wrapper | New option | Wire |
|---|---|---|
GaugesService.List | BucketIDs []int64 | bucket_ids=30,10,20 (one comma-separated string, as bc3's GaugesController#bucket_ids splits it) |
TemplatesService.List | Status string | status=archived |
- Each parameter is sent only when it's set, and it composes with
Page. A nil or emptyBucketIDsand an emptyStatussend nothing, so existing calls go out unchanged. - With
BucketIDsset, Basecamp returns the gauges in the given order instead of by risk, and drops IDs whose gauge the caller can't see (Gauge::Collection::Enabled). The doc comment says both. Statustakesactive,archivedortrashed. Basecamp answers any other value with a 400 (TemplatesController#status_for_index), and the doc comment says so. It's a plain string like the generated param, so nothing new is added to the API surface beyond the field.
Breaking, narrowly
For callers this is additive. But BucketIDs is a slice, so GaugeListOptions stops being comparable, and the API Compatibility job flags that: code comparing two options values with ==, or using one as a map key, would no longer compile. An unkeyed literal of either options struct breaks as well. MIGRATING.md's # Unreleased section covers both. Release notes: Breaking Changes and Features. Labels: breaking, enhancement.
Tests
TestGaugesService_List_BucketIDs: the IDs go on the wire in order as one comma-separated string, together withpage, and an empty or absent list sends nothing.TestTemplatesService_List_Status:statusis sent when set, together withpage, and nothing goes out for an unset status or nil options.
make go-check passes (fmt, vet, golangci-lint 0 issues, race tests), and so do go-check-drift, go-check-wrapper-drift and check-grouped-client-coverage.
Downstream
basecamp/basecamp-mcp-server#354 (gauges) and #355 (templates) wait on a release carrying this. In the meantime they pin go-list-filters-on-v0.35.0, which is v0.35.0 with this one commit cherry-picked, so their CI runs the change without also taking #1080, whose marshalling change needs its own adaptation there. That branch exists only for that pin. Delete it once both PRs have moved to a release.