Skip to content

feat: catch up to Tango API 5.11.0 (parity with tango-python 1.18.1) - #12

Merged
vdavez merged 2 commits into
mainfrom
feat/api-5.11.0-catchup
Oct 19, 2026
Merged

vdavez merged 2 commits into
mainfrom
feat/api-5.11.0-catchup

Conversation

@makegov-mark

@makegov-mark makegov-mark Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

What

Brings tango-go up to Tango API 5.11.0, matching tango-python 1.18.1, for everything not already covered by #9 (eBuy), #10 (budget categories, anomalies and data_through_period) and #11 (vehicle company counts).

  • Federal Register documents (API 5.3.0): ListFederalRegisterDocuments, IterateFederalRegisterDocuments, GetFederalRegisterDocument (by uuid), all seventeen filters on ListFederalRegisterDocumentsOptions, and ShapeFederalRegisterMinimal / ShapeFederalRegisterComprehensive (neither names full_text).
  • New filters: Agency on budget accounts, exclusions and IT Dashboard (API 5.3.0); CycleName on SBIR topics (5.3.1); Awarded / AwardeeUEI on opportunities (5.5.0); CommercialItemAcquisitionProcedures on contracts and IDVs, which also reaches ListIDVAwards / ListIDVChildIDVs (5.10.0); HasAwards on PSC.
  • List envelope: PaginatedResponse.Meta (previously dropped) with AgencyWarnings(), UnresolvedAgencyTokens() and ResolvedAgencies(), and CountType read from each response's own X-Results-CountType header.
  • ObligationsByFiscalYear(row) decodes the obligations_by_fiscal_year(fiscal_year, obligated) expand (5.11.0) into []FiscalYearObligation.
  • Error reasons (tango-python 1.18.1): a non-2xx response with no dedicated error type now returns an *APIError whose Message ends with the server's reason (API request failed with status 403: ...), read from error, message or detail, including one nested under detail. The parsed body stays on ResponseData; a non-JSON body keeps the bare message.
  • Docs for the fields this SDK passes through as Record: organization(...) expands, opportunity award leaves and awards(...), file and link counts, attachments(extraction_status), matched_by, pipe-joined UEIs, the current alert query types, and the corrected IT Dashboard filter tiers.

Breaking

  • ListPSC now takes *ListPSCOptions (embedding ListOptions) instead of *ListOptions, to carry HasAwards. This is pre-1.0, so it ships without a deprecation cycle and is marked Breaking in the CHANGELOG.

Not included

  • No attachment-search method: the API retired that route, and v0.2.0 removed it on purpose.
  • No IDV cursor fix: this SDK extracts the cursor generically for every list, so the bug fixed in tango-python 1.12.0 does not exist here.

Testing

  • go vet, go test -race and coverage (make ci minus lint) pass locally.
  • golangci-lint: the local binary is v2, which cannot read this repo's v1 config; against a migrated copy, the only new findings are two QF1008 style notes of the kind already present across the codebase, which v1 does not report. CI runs v1.
  • New tests cover every new filter (including false reaching the server on the *bool fields), the Federal Register methods and presets, the Meta accessors including matched_by, per-response CountType, and ObligationsByFiscalYear on full, narrowed, null, absent and malformed values.
  • Error reasons: a 403 with a detail string, a flat and a nested tier-gate body, a JSON body with no reason, and a non-JSON 502 page.

Merge order

This branch is cut from main and overlaps #9, #10 and #11 only in CHANGELOG.md, docs/API_REFERENCE.md, shapes.go, budget.go, budget_test.go and transport.go; it will be rebased once those land.

🤖 Generated with Claude Code

@makegov-mark makegov-mark Bot changed the title feat: catch up to Tango API 5.11.0 (parity with tango-python 1.18.0) feat: catch up to Tango API 5.11.0 (parity with tango-python 1.18.1) Oct 19, 2026
vdavez and others added 2 commits October 19, 2026 14:51
- Federal Register documents: ListFederalRegisterDocuments, IterateFederalRegisterDocuments and GetFederalRegisterDocument, with every API filter named and two shape presets.
- Agency filter on budget accounts, exclusions and IT Dashboard; CycleName on SBIR topics; Awarded and AwardeeUEI on opportunities; CommercialItemAcquisitionProcedures on contracts and IDVs; HasAwards on the new ListPSCOptions (breaking: ListPSC now takes *ListPSCOptions).
- PaginatedResponse gains Meta (with AgencyWarnings, UnresolvedAgencyTokens and ResolvedAgencies) and a per-response CountType from the X-Results-CountType header.
- ObligationsByFiscalYear decodes the obligations_by_fiscal_year expand.
- Docs for the pass-through shape fields: organization expands, award leaves, file and link counts, attachments(extraction_status), pipe-joined UEIs and matched_by; IT Dashboard tier fix.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A non-2xx response with no dedicated error type now returns an `*APIError` whose `Message` ends with the API's own explanation, read from the body's `error`, `message` or `detail` (also when nested under `detail`), matching tango-python 1.18.1.
The parsed body stays on `ResponseData`, and a non-JSON body such as a proxy's 502 page keeps the old message.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vdavez
vdavez force-pushed the feat/api-5.11.0-catchup branch from a58d4c7 to b76e1e7 Compare October 19, 2026 19:52
@vdavez
vdavez marked this pull request as ready for review October 19, 2026 19:52
@vdavez
vdavez merged commit ac514dc into main Oct 19, 2026
5 checks passed
@vdavez
vdavez deleted the feat/api-5.11.0-catchup branch October 19, 2026 19:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant