Actions37
- Contact Actions
- Invoice Actions
- Item Actions
- Payment Actions
- Estimate Actions
- Tax Actions
- Bank Account Actions
Overview
This node integrates with the Alegra API to update an existing item (product or service) in your Alegra account. It allows you to modify various attributes of an item such as its name, price, description, category, tax settings, stock levels, and status.
Common scenarios where this node is useful include:
- Automatically updating product details when inventory changes.
- Adjusting prices or descriptions based on external data sources.
- Managing stock thresholds and unit costs programmatically.
- Activating or deactivating items in bulk workflows.
For example, you could use this node in a workflow that syncs your e-commerce platform's product catalog with Alegra, ensuring all item information stays consistent.
Properties
| Name | Meaning |
|---|---|
| Item ID | The unique identifier of the item to update. |
| Update Fields | Collection of fields to update for the item. Options include: |
| - Name | The new name of the item. |
| - Price | The updated price of the item (number with 2 decimal precision). |
| - Description | A textual description of the item. |
| - Reference | Reference code or SKU for the item. |
| - Category Name or ID | Select a category from the list or specify an ID via expression. |
| - Tax Name or ID | Select one or more taxes from the list or specify IDs via expression. |
| - Unit | Unit of measurement for the item (e.g., kg, pcs). |
| - Unit Cost | Cost per unit of the item (number with 2 decimal precision). |
| - Minimum Stock | Minimum stock level threshold for the item. |
| - Maximum Stock | Maximum stock level threshold for the item. |
| - Active | Boolean flag indicating whether the item is active (true) or inactive (false). |
Output
The node outputs JSON data representing the updated item object returned by the Alegra API after the update operation. This typically includes all current properties of the item, reflecting the changes made.
No binary data output is produced by this node.
Dependencies
- Requires an API key credential configured in n8n to authenticate requests against the Alegra API.
- The node uses the Alegra API endpoint corresponding to the environment specified in the credentials.
- Network connectivity to Alegra's API is necessary.
Troubleshooting
Common issues:
- Invalid or missing Item ID will cause the update to fail.
- Providing invalid field values (e.g., negative price) may result in API errors.
- Network or authentication failures can prevent successful updates.
Error messages:
- Errors from the API are surfaced as node execution errors with descriptive messages.
- If "Continue On Fail" is enabled, errors for individual items will be included in the output JSON under an
errorproperty.
Resolution tips:
- Verify the Item ID exists in Alegra before attempting an update.
- Ensure all required fields have valid values.
- Check API credentials and network access.
- Use expressions carefully when specifying category or tax IDs.
Links and References
- Alegra API Documentation: https://developer.alegra.com/
- n8n Expressions Guide: https://docs.n8n.io/code-examples/expressions/