Alegra (Unofficial - BETA) icon

Alegra (Unofficial - BETA)

Consume Alegra API - UNOFFICIAL BETA community node. NOT officially supported by Alegra.

Overview

This node integrates with the Alegra API to manage items, which can be products or services. Specifically, the "Create" operation under the "Item" resource allows users to add new items into their Alegra account. This is useful for automating inventory management, product catalog updates, or service listings within workflows.

Practical examples include:

  • Automatically adding new products from an e-commerce platform into Alegra.
  • Creating service entries when a new service offering is launched.
  • Syncing item data from other systems into Alegra for unified accounting and invoicing.

Properties

Name Meaning
Name The name of the item to create.
Type The type of the item; options are "Product" or "Service".
Price The price of the item, with two decimal precision.
Additional Fields A collection of optional fields to provide more details about the item:
- Description Text description of the item.
- Reference Item reference or SKU code.
- Category Name or ID Select a category from a list or specify an ID via expression.
- Tax Name or ID Select one or multiple taxes from a list or specify IDs via expression.
- Unit Unit of measurement (default is "unit").
- Unit Cost Cost per unit, with two decimal precision.
- Initial Quantity Initial stock quantity (only shown if Type is "Product").
- Minimum Stock Minimum stock level threshold (only for products).
- Maximum Stock Maximum stock level threshold (only for products).
- Product Key Product key used for electronic invoicing.
- Active Boolean indicating whether the item is active (true by default).

Output

The output JSON contains the newly created item object as returned by the Alegra API. This includes all properties sent during creation plus any additional metadata or identifiers assigned by Alegra.

No binary data output is produced by this operation.

Dependencies

  • Requires an API key credential for authenticating with the Alegra API.
  • The node uses HTTP requests to the Alegra API endpoints.
  • Some input options (like categories and taxes) are dynamically loaded from Alegra via helper methods that fetch available options.

Troubleshooting

  • Common issues:

    • Missing required fields such as "Name", "Type", or "Price" will cause errors.
    • Invalid category or tax IDs may result in API errors.
    • Network or authentication failures if the API key is invalid or missing.
  • Error messages:

    • Errors from the API are wrapped and surfaced as node operation errors with descriptive messages.
    • If the node is set to continue on failure, errors will appear in the output JSON under an error field.
  • Resolutions:

    • Ensure all required fields are provided and valid.
    • Verify the API key credential is correctly configured.
    • Use expressions carefully when specifying IDs to avoid invalid references.

Links and References

Discussion