CHACHAT Product Delete Node

Node for deleting a product

Overview

This node is designed to delete products by their IDs via an API. It accepts a list of product IDs and sends a request to remove those products from the external system. This node is useful in workflows where you need to automate product management, such as cleaning up obsolete products or batch deleting multiple items based on certain criteria.

Practical examples:

  • Automatically deleting discontinued products from an inventory system.
  • Removing test or placeholder products after data migration.
  • Bulk deleting products flagged for removal in a data cleanup process.

Properties

Name Meaning
Product IDs Comma-separated list of product IDs to delete

Output

The node outputs JSON data containing the response from the product deletion API. The structure depends on the external API's response but typically includes confirmation of deleted products or status messages.

No binary data output is produced by this node.

Dependencies

  • Requires an API key credential with at least three properties: base URL, token, and session identifier.
  • Uses the Axios HTTP client library to send POST requests.
  • The node expects the external API endpoint /v1/productDelete to accept a POST request with a JSON body containing the session and an array of product IDs.

Troubleshooting

  • Common issues:

    • Invalid or expired API token may cause authentication failures.
    • Incorrectly formatted product IDs (e.g., empty strings or invalid IDs) might result in API errors.
    • Network connectivity problems can prevent successful API calls.
  • Error messages:

    • If the API returns an error, it will be thrown as a node operation error with context about which item caused the failure.
    • If "Continue On Fail" is disabled, the node execution stops on the first error; enabling it allows processing remaining items.
  • Resolutions:

    • Verify that the API credentials are correct and have necessary permissions.
    • Ensure product IDs are valid and properly formatted (trimmed, comma-separated).
    • Check network access and API availability.

Links and References

  • Axios HTTP Client
  • Refer to your external API documentation for details on the /v1/productDelete endpoint and required authentication.

Discussion