mirror of
https://github.com/rudrankriyam/App-Store-Connect-CLI.git
synced 2026-04-25 23:55:51 +03:00
[GH-ISSUE #68] Add Payments & Financial Reports (financeReports) support #15
Labels
No labels
bug
bug
documentation
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/App-Store-Connect-CLI#15
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @rudrankriyam on GitHub (Jan 24, 2026).
Original GitHub issue: https://github.com/rudrankriyam/App-Store-Connect-CLI/issues/68
Summary
Add Payments & Financial Reports support via the App Store Connect API. ASC currently covers App Analytics + Sales & Trends, but does not support financeReports (payments/proceeds). This blocks automation of monthly financial reports.
Current State (verified)
rg -n "payment|payments|financial|finance|payout|proceeds|tax|bank|transfer|statement" -S internal cmd README.md) returns no matches.Why this matters
Official References
API Details (from Apple OpenAPI spec)
Endpoint:
GET /v1/financeReportsRequired filters
filter[vendorNumber](array of string)filter[reportType](array of string)filter[regionCode](array of string)filter[reportDate](array of string)reportType enum
FINANCIALFINANCE_DETAILResponse
200returnsapplication/a-gzip(gzip payload)400,401,403,429Open Questions / Reconciliation
Apple’s Help docs list 4 UI report types:
But the API exposes only
FINANCIALandFINANCE_DETAIL. Need to confirm:FINANCIALvsFINANCE_DETAILreportTypeor filters apply)Proposed CLI Design
Add a new command group:
Flags (explicit, no short flags):
--vendor(required, fallbackASC_VENDOR_NUMBER)--report-type(required; FINANCIAL | FINANCE_DETAIL)--region(required; regionCode)--date(required; YYYY-MM)--output(optional; default:finance_report_{date}_{type}_{region}.tsv.gz)--decompress(optional; write .tsv)--output-format(json|table|markdown for metadata)--pretty(JSON only)JSON output example:
Implementation Plan
internal/asc/finance.goFinanceReportTypeenum.DownloadFinanceReportmethod.doStreamwithAccept: application/a-gzip.cmd/finance.gofinancecommand group withreportssubcommand.openNewFileNoFollow.Acceptance Criteria
asc finance reportsdownloads.gzcorrectly and prints metadata JSON.--decompresswrites.tsvand reports both paths.@rudrankriyam commented on GitHub (Jan 24, 2026):
@cursor please implement this issue. Follow the implementation plan and acceptance criteria in the issue description.
@cursor[bot] commented on GitHub (Jan 24, 2026):
Summary:
asc finance reportsCLI with validation, gzip download/decompress, and metadata output formatting.Tests:
PATH="$(go env GOPATH)/bin:$PATH" make formatPATH="$(go env GOPATH)/bin:$PATH" make lintPATH="$(go env GOPATH)/bin:$PATH" make testNotes:
gofumptviago install mvdan.cc/gofumpt@latestto satisfymake formatand ran the format/lint/test targets with GOPATH/bin on PATH.@rudrankriyam commented on GitHub (Jan 24, 2026):
This has been implemented. The
asc finance reportscommand supports all proposed functionality:--vendor(withASC_VENDOR_NUMBERfallback)--report-type(FINANCIAL | FINANCE_DETAIL)--region--date(YYYY-MM format)--output(custom file path)--decompress(writes .tsv)--output-format(json/table/markdown for metadata)--pretty(JSON formatting)Documentation added in PR #89 and API notes in PR #94.