AppStore Sales icon

AppStore Sales

Download Apple App Store sales reports

Overview

This node downloads and optionally parses Apple App Store sales reports. It is useful for developers, analysts, or finance teams who need to automate the retrieval of sales data from the Apple App Store for further analysis or reporting.

Common scenarios include:

  • Automatically fetching daily or monthly sales summaries.
  • Integrating sales data into dashboards or databases.
  • Archiving raw sales reports for compliance or auditing purposes.

For example, a user can configure the node to download the monthly sales report for a specific vendor number and date, then parse it into structured JSON for easy consumption in subsequent workflow steps.

Properties

Name Meaning
Frequency The type of sales report to download: "Daily Sales Report" or "Monthly Sales Report".
Vendor Number The unique identifier for the vendor whose sales report is being requested (required).
Report Date (YYYY-MM-DD) The date of the report to download, formatted as year-month-day (required).
Options Additional options:
- Put Result in Field: The name of the output field where the parsed data will be stored (default: "report").

Output

The node outputs an array of items corresponding to each input item processed.

  • If the operation is Download & Parse, the output contains a JSON field with the parsed sales report data. The data is an array of objects, each representing a row from the report, with keys derived from the report's header columns.

    Example structure inside the chosen result field (e.g., report):

    [
      {
        "Provider": "Apple",
        "Vendor Number": "123456",
        "Product": "AppName",
        "Units": "100",
        ...
      },
      ...
    ]
    
  • If the operation is Download only, the node outputs binary data containing the raw TSV report file. The binary data is available under the key report and named like report_<reportDate>.tsv.

Dependencies

  • Requires an API key credential for authenticating with the Apple App Store Connect API.
  • Uses the Apple App Store Connect API endpoint to fetch sales reports.
  • Requires the jsonwebtoken library to generate JWT tokens for authentication.
  • Uses axios for HTTP requests.
  • Uses zlib to decompress the downloaded gzip-compressed report.

Troubleshooting

  • Authentication errors: Ensure the API key credentials are correctly configured with valid private key, issuer ID, and key ID. Invalid or expired tokens will cause authorization failures.
  • Invalid parameters: The vendor number and report date must be valid and correspond to existing reports. Incorrect dates or vendor numbers may result in empty responses or errors.
  • Network issues: Connectivity problems or API rate limits may cause request failures. Check network access and retry policies.
  • Parsing errors: If the report format changes or the file is corrupted, parsing the TSV content may fail or produce incorrect results.
  • Error messages: The node logs errors from the Apple API and throws them. Review the error message for details such as "Unauthorized", "Not Found", or "Bad Request" to diagnose issues.

Links and References

Discussion