i-doit icon

i-doit

i-doit JSON-RPC API

Recycle

AI-generated

Overview

This n8n node interacts with the i-doit CMDB (Configuration Management Database) system via its JSON-RPC API. Specifically, for the Resource: Default and Operation: Recycle, the node allows users to "recycle" (soft-delete or move to recycle bin) either a CMDB Object or a Category entry within i-doit. This operation is useful in scenarios where you want to remove items from active use but retain them for possible restoration or auditing, rather than permanently deleting them.

Practical examples:

  • Moving a server object to the recycle bin when it is decommissioned, but not yet ready for permanent deletion.
  • Recycling a specific category entry (e.g., a network interface configuration) that is no longer needed but should be retained for record-keeping.

Properties

Name Type Meaning
Namespace options Selects the i-doit API namespace. For recycling, typically "CMDB Object" or "CMDB Category".
Category options The category within the selected namespace. Required if recycling a category entry.
Object Type options The type of object (e.g., Server, Switch). Not used for recycle operation.
Id string The unique identifier of the resource (object or category) to recycle.
Category entry Id string Identifier of the specific category entry to recycle (used with "CMDB Category").
Search String string Not used for recycle operation.
Retrieve and Split Data Items boolean Not used for recycle operation.

Note: For the "Recycle" operation, only relevant properties are shown above.

Output

The output is a JSON object containing the response from the i-doit API after performing the recycle operation. The structure depends on the i-doit API's response, but typically includes status information and possibly details about the recycled item.

Example output:

{
  "result": {
    // ... details as returned by i-doit, e.g., success status, object/category info
  },
  "id": 1,
  "jsonrpc": "2.0"
}
  • If an error occurs and "Continue On Fail" is enabled, the output will include:
{
  "error": "Error message from i-doit or node"
}

Binary data: This node does not output binary data for this operation.

Dependencies

  • External Service: Requires access to an i-doit instance with the JSON-RPC API enabled.
  • API Key: You must provide valid i-doit credentials (API key) via n8n's credential system.
  • n8n Configuration: No special environment variables required beyond standard credential setup.

Troubleshooting

Common issues:

  • Invalid ID or Category Entry ID: If the provided IDs do not exist, the API will return an error.
  • Missing Required Fields: Omitting required fields like "Id" or "Category entry Id" (for categories) will result in errors.
  • Authentication Errors: Invalid or missing API key will cause authentication failures.
  • Insufficient Permissions: The i-doit user may lack permission to recycle objects or categories.

Common error messages:

  • "Object not found": Check that the "Id" matches an existing object or category entry.
  • "Permission denied": Ensure your API key/user has sufficient rights in i-doit.
  • "Missing parameter": Make sure all required fields are filled in the node.

Links and References

Discussion