Sharpei icon

Sharpei

Consume Sharpei Api

Overview

This node integrates with the Sharpei API to update product information. It allows users to modify existing products by specifying the product identifier and providing updated product data in JSON format. This is useful in scenarios where product details such as title, description, or status need to be changed programmatically within an automation workflow.

Practical examples include:

  • Automatically updating product descriptions or statuses based on inventory changes.
  • Syncing product information from another system into Sharpei.
  • Bulk updating multiple products with new attributes or corrections.

Properties

Name Meaning
Product Pid The unique identifier (Pid) of the product to update.
Product Data (JSON) The product data to update, provided in JSON format. Typical fields include title, body, and status_pid.

Output

The node outputs a JSON object representing the updated product as returned by the Sharpei API. This typically includes the product's current state after the update operation, reflecting any changes made.

If the node supports binary data output, it would represent associated media or files related to the product, but this is not indicated in the provided code snippet.

Dependencies

  • Requires an active connection to the Sharpei API.
  • Needs an API authentication token or key configured in n8n credentials for authorization.
  • The base URL for API requests is https://api.prod.gosharpei.com/api.
  • The node expects JSON content-type headers for communication.

Troubleshooting

  • Invalid Product Pid: If the specified product identifier does not exist, the API may return an error indicating the product was not found. Verify the Pid is correct.
  • Malformed JSON: Providing invalid JSON in the "Product Data (JSON)" property can cause request failures. Ensure the JSON is well-formed and matches expected schema.
  • Authentication Errors: Missing or incorrect API credentials will result in authorization errors. Confirm that the API key/token is correctly set up in n8n.
  • API Rate Limits or Downtime: Temporary issues with the Sharpei API could cause request failures. Check API status and retry later if needed.

Links and References

Discussion