Distru icon

Distru

Interact with the Distru Public API v1

Actions35

File Attachments → Upload

AI-generated

Overview

This node uploads a file attachment to a specified entity within the Distru system. It is useful for automating the process of attaching files such as documents or images to various entities like products, orders, invoices, contacts, and more. For example, you can upload a product specification sheet to a product record or attach an invoice PDF to an invoice entity.

Use Case Examples

  1. Uploading a product image file to a product entity.
  2. Attaching a scanned invoice document to an invoice entity.

Properties

Name Meaning
Binary Property The binary property containing the file data to upload.
Attach To The type of entity to which the file will be attached (e.g., product, order, invoice).
Entity ID The unique identifier of the entity to which the file will be attached.
Additional Fields.Name Optional display name for the file attachment; defaults to the filename if not provided.

Output

JSON

  • data - The response data from the Distru API after uploading the file attachment, containing details about the uploaded file.

Dependencies

  • Requires an API token credential for the Distru API.

Troubleshooting

  • Error 'Distru API token is not set': Ensure the API token credential is configured correctly in the node credentials.
    Error 'Missing binary data in property ""': Verify that the specified binary property contains the file data to upload.
  • Error 'Resource ID is required': Make sure to provide the entity ID to which the file should be attached.

Discussion