CHACHAT Product Create Node

Node for creating a product

Overview

This node is designed to create a product by sending its details to an external API endpoint. It is useful in scenarios where you want to automate the creation of product entries in a remote system or service, such as an e-commerce platform or inventory management system. For example, you could use this node to add new products from a spreadsheet or another data source directly into your online store without manual entry.

Properties

Name Meaning
Product Name The name of the product to be created.
Currency The currency code for the product's price (e.g., PEN).
Description A textual description of the product.
Price The numeric price value of the product.
URL A URL linking to the product's webpage or more information.
Is Hidden Boolean flag indicating whether the product should be hidden from public view.
Retailer ID Identifier for the retailer associated with the product.
Origin Country Code The country code representing the product's origin (e.g., PE).
Image URL URL pointing to an image representing the product.

Output

The node outputs JSON data containing the response from the product creation API. This typically includes details about the newly created product as returned by the external service. The output does not include binary data.

Example structure of the output JSON:

{
  "data": {
    // API response fields related to the created product
  }
}

Dependencies

  • Requires an external API accessible via HTTP POST at a base URL configured in credentials.
  • Needs an API authentication token and session identifier provided through node credentials.
  • Uses the Axios library for HTTP requests.

Troubleshooting

  • Common issues:
    • Invalid or missing API credentials will cause authentication failures.
    • Network connectivity problems can prevent successful API calls.
    • Incorrect property values (e.g., invalid currency codes or URLs) may lead to API errors.
  • Error messages:
    • Errors thrown during execution include context about which input item caused the failure.
    • If continueOnFail is disabled, the node stops on the first error; enabling it allows processing remaining items.
  • Resolution tips:
    • Verify that the API token and session are correctly set in credentials.
    • Ensure all required properties have valid values before running the node.
    • Check network access to the API endpoint.

Links and References

Discussion