Actions58
- Applications Actions
- Components Actions
- Brands Actions
- Documents Actions
- Weblinks Actions
- Manufacturers Actions
- Catalogs Actions
- Download Actions
- Variations Actions
- Categories Actions
- Upload Actions
- Jobs Actions
Overview
This node integrates with the iTwin Component Center API to create new components within the system. It is designed for users who want to programmatically add components, specifying details such as display name, description, state, and associations with catalogs, applications, categories, and manufacturers.
Common scenarios include:
- Automating the creation of components during a CI/CD pipeline or integration workflow.
- Bulk importing component data from external sources.
- Managing component metadata dynamically based on other system events.
For example, a user could use this node to create a new component in draft state with specific hashtags and link it to an existing application and catalog, enabling streamlined asset management.
Properties
| Name | Meaning |
|---|---|
| Display Name | The display name of the component. Must be a string up to 150 characters without special characters >, <, ^, $, ?, ` |
| Description | A textual description of the component, up to 250 characters. Optional. |
| State | The current state of the component. Options are: Draft, Published, Checked, Approved, Archived. This is a required field. |
| Catalogs | JSON array of associated catalog IDs. Each must be a valid GUID string referencing existing catalogs. |
| Application | Associated application ID as a string GUID referencing an existing application. Optional. |
| Category | Associated category ID as a string GUID referencing an existing category. Optional. |
| Manufacturer | Associated manufacturer ID as a string GUID referencing an existing manufacturer. Optional. |
| Hashtags | JSON array of hashtags related to the component. Each hashtag can be up to 50 characters and must not contain special characters >, <, ^, $, ?, ` |
| Options | Collection allowing custom payload override. Contains: - Use Custom Payload (boolean): Whether to override the request body with a custom JSON payload. - JSON Payload: The actual custom JSON to send if enabled. |
Output
The node outputs an array of items where each item contains a json property representing the response from the iTwin Component Center API after creating the component.
- If the API returns multiple objects, each is output as a separate item.
- If a single object is returned, it is output as one item.
- If the result is a primitive or non-object, it is wrapped inside
{ "result": <value> }.
No binary data output is indicated by the source code.
Dependencies
- Requires an API authentication credential configured in n8n to access the iTwin Component Center API.
- Uses an internal interpreter module (
ComponentCenterOpenApiInterpreter) to map operations and execute API calls. - The node depends on the iTwin OAuth2 API credential for authentication.
Troubleshooting
- Unknown operation error: If the specified operation is not recognized, the node throws an error indicating "Unknown operation". Ensure the operation parameter is correctly set to "create-component".
- Invalid input data: Input properties like GUIDs for catalogs, application, category, or manufacturer must be valid strings representing existing entities. Invalid or malformed GUIDs may cause API errors.
- Special character restrictions: Display name and hashtags have restrictions on certain special characters. Violating these will likely cause validation errors.
- Custom payload issues: When using the custom payload option, ensure the JSON is well-formed. Malformed JSON will cause parsing errors.
- API authentication failures: Make sure the API key or OAuth2 credentials are properly configured and valid.
If the node is set to continue on fail, errors will be captured in the output JSON under an error property instead of stopping execution.
Links and References
- iTwin Developer Documentation
- Refer to the iTwin Component Center API docs for detailed information on component creation and allowed fields.