WbAnalytics icon

WbAnalytics

n8n node to interact with WB API

Overview

This node allows users to post report download requests for seller analytics in CSV format. It is designed to interact with a specific API endpoint that accepts parameters describing the report to be generated and downloaded. Typical use cases include automating the retrieval of detailed sales or inventory reports from a marketplace or e-commerce platform, enabling sellers or analysts to programmatically request and process these reports without manual intervention.

For example, a seller might use this node to request a detailed history report filtered by certain product brands or tags, then use the resulting data for further analysis or integration into their business intelligence systems.

Properties

Name Meaning
Id The unique identifier (UUID format) of the report. This ID is generated by the seller.
Report Type The type of report to request. Currently supports DETAIL_HISTORY_REPORT.
User Report Name Optional custom name for the report. If not provided, the system will generate one automatically.
Params JSON object containing report parameters such as arrays of IDs (nmIDs, subjectIds, tagIds) and brand names to filter the report.

Output

The node outputs JSON data representing the response from the report download request. This typically includes metadata about the requested report and possibly a link or reference to the downloadable CSV file. The exact structure depends on the API response but generally contains information confirming the report generation status.

If binary data output is supported (e.g., direct CSV content), it would represent the actual report file; however, based on the code and properties, the node primarily handles JSON responses related to report requests rather than raw binary files.

Dependencies

  • Requires an API key credential for authentication with the external WB API service.
  • The node uses a base URL and OpenAPI specification bundled internally to construct requests.
  • No additional external dependencies are indicated beyond standard HTTP request capabilities.

Troubleshooting

  • Invalid UUID for Id: Ensure the Id property is a valid UUID string as required by the API.
  • Unsupported Report Type: Only DETAIL_HISTORY_REPORT is currently supported; using other values may cause errors.
  • Malformed Params JSON: The Params field must be valid JSON. Invalid JSON syntax will cause parsing errors.
  • Authentication Errors: Missing or incorrect API credentials will result in authorization failures.
  • Empty or Missing Required Fields: Omitting required fields like Id, Report Type, or Params will cause the request to fail.

To resolve these issues, verify all required inputs are correctly formatted and present, and ensure valid API credentials are configured in n8n.

Links and References

  • No direct external links are provided in the source code.
  • For more details on the report types and parameters, consult the WB API documentation or the seller analytics API guide associated with the platform.

Discussion