Printcart icon

Printcart

Consume Prinrcart API

Actions83

Overview

The node integrates with the Printcart API to manage "Side" resources of products, specifically allowing users to update details of a product side. This operation is useful in scenarios where you need to modify attributes of a product's side such as its name, background type and color, scale, image size, design arena dimensions, associated side image, and status.

Practical examples include:

  • Updating the visual appearance or metadata of a product side after design changes.
  • Adjusting layout parameters like scale or design area to fit new design requirements.
  • Changing the status of a side (e.g., from draft to publish) to control its visibility.

Properties

Name Meaning
Authentication Method of authentication; currently supports "API Token".
Side ID The unique identifier of the side to update (required).
Product ID The identifier of the product this side belongs to (required).
Name of the Side The new name for the side (required).
Background Type The background type of the side; options are: Color, Image, Transparent.
Background Color Value The color value used if the background type is color (required).
Scale The scale factor of the side (required).
Width Width dimension of the side image size (required).
Height Height dimension of the side image size (required).
Width Arena Width of the design arena area on the side.
Height Arena Height of the design arena area on the side.
Top Arena Top offset position of the design arena.
Left Arena Left offset position of the design arena.
Side Image ID Identifier of the side image associated with this side (required).
Status Status of the side; options are Publish, Draft, Trashed (required).

Output

The node outputs JSON data representing the updated side resource as returned by the Printcart API. This typically includes all properties of the side after the update, such as IDs, names, background settings, scale, image sizes, design arena dimensions, side image references, and status.

No binary data output is involved.

Dependencies

  • Requires an API token credential for authenticating requests to the Printcart API.
  • The node makes HTTP PUT requests to the Printcart API endpoint for sides, using the provided credentials.
  • No additional external dependencies beyond the Printcart API and n8n's HTTP request helper.

Troubleshooting

  • Authentication errors: Ensure that a valid API token is provided and has sufficient permissions to update side details.
  • Missing required fields: The operation requires several mandatory fields (Side ID, Product ID, Name, Background Color, Scale, Side Image ID, Status). Omitting these will likely cause API errors.
  • Invalid field values: For example, providing an unsupported background type or status value may result in API rejection.
  • Network or API errors: Check connectivity and API availability. Review error messages returned by the API for specific issues.
  • Incorrect URI or credentials: The node constructs the API URL using stored credentials; ensure these are correctly configured.

Links and References

Discussion