Actions28
Overview
This node interacts with the Dolibarr API to list contract lines associated with a specific contract. It is useful when you need to retrieve detailed line items or components of a contract stored in Dolibarr, such as for reporting, auditing, or further processing within an automation workflow.
A practical example would be automating the extraction of all line items from a given contract to generate invoices, update inventory, or synchronize contract details with other systems.
Properties
| Name | Meaning |
|---|---|
| Contract ID | The unique identifier (number) of the contract whose lines you want to list. Required. |
Output
The node outputs JSON data representing the list of lines belonging to the specified contract. Each item in the output corresponds to a line entry retrieved from the Dolibarr API endpoint /contracts/{contractID}/lines. This typically includes details such as product/service descriptions, quantities, prices, and other line-specific information.
If the API response contains binary data (not indicated here), it would represent attachments or files related to contract lines, but this node primarily deals with JSON data.
Dependencies
- Requires access to a Dolibarr instance with its REST API enabled.
- Needs an API authentication credential configured in n8n to authorize requests to Dolibarr.
- The base URL of the Dolibarr API must be set in the credentials configuration.
Troubleshooting
Common issues:
- Invalid or missing Contract ID will cause the API request to fail.
- Incorrect or expired API credentials will result in authentication errors.
- Network connectivity problems between n8n and the Dolibarr server can cause timeouts or connection errors.
- If the contract ID does not exist, the API may return a 404 error.
Error messages:
- Authentication failed: Check that the API key/token is correct and has sufficient permissions.
- 404 Not Found: Verify that the Contract ID exists in Dolibarr.
- Network Error: Ensure the Dolibarr server is reachable from the n8n environment.
Resolving these usually involves verifying input parameters, checking credentials, and ensuring network accessibility.
Links and References
- Dolibarr API Documentation
- n8n Documentation on HTTP Request Nodes (for understanding API calls)