Import, Export & Automation in the OTOBO CMDB
The OTOBO CMDB offers powerful interfaces and automation functions to keep your asset data up-to-date and simplify recurring tasks.
1. Data Integration via REST and SOAP APIs
REST API
- CRUD operations on CI classes and DynamicFields
- JSON Payloads: Simple and lightweight integration
- Authentication: Token-based or Basic Auth
SOAP API
- Legacy systems and deep functionality
- XML Payloads with WSDL descriptions
- State-ful sessions and extensive methods for CI relationships
Best Practices
- Batch Processing: Import data in batches to avoid timeouts.
- Error Handling: Check return codes and log entries ("SysLog").
- Rate Limiting: Pay attention to API limits to prevent blocks.
2. File-based Import/Export (CSV, XML)
CSV Import/Export
- Field Mapping: Column names → DynamicField names
- Separator, character set, and header row configurable
- Bulk update for existing CIs via key attribute (e.g., Name or ID)
XML Import/Export
- Complex structures and nested fields
- Mapping possible via XSLT stylesheets
- Usage with SOAP clients and third-party tools
Workflow
- Generate Template: First, export a sample CSV/XML.
- Enrich Data: Adjust values and validate locally.
- Start Import: Via Agent Interface or CLI script.
- Check Result: Review logs for error lines and warnings.
3. Auto-Discovery & Synchronization
- Network Scanning: Detect IP networks, devices, and services
- Agent-Based Discovery: Local agents report system details to the CMDB
- Integration of External Tools: Ansible, Puppet, SCCM, Nagios, and many more.
Features
- Scheduled Scans: Plan regular inventory runs.
- Overwrite vs. Enrich: Configure rules for update behavior.
- Conflict Resolution: Manual review or automatic prioritization of old vs. new data.
4. Triggers in CI Definitions
- Triggers
- Trigger actions on field changes (e.g., Notification, Auto-Assign)
- Configuration directly in YAML under
VersionTriggeror via script
yaml
VersionTrigger:
- DefinitionUpdate
- ValueUpdateUse Cases
- Automatically update inventory log after changing a serial number
- Send email reminder when a certificate expires
5. VersionTriggers
VersionTrigger: Controls on which events a new CI version is created
Common Values
NameUpdateConfigItemCreateValueUpdateDefinitionUpdate
yaml
VersionStringModule: Incremental
VersionTrigger:
- ConfigItemCreate
- ValueUpdateAdvantage
Version history of all changes for traceability and audit compliance.
6. Script Fields (ScriptTemplateToolkit)
- Calculated Fields: Sum, average, dynamic text snippets
- Syntax: TemplateToolkit (
[% … %])
yaml
DynamicFields:
TotalRAMGB:
FieldType: ScriptTemplateToolkit
Label: Total RAM (GB)
Config:
Expression: |
[% Count = DynamicField_RAMCount %]
[% Size = DynamicField_RAMSize %]
[% Total = Count * Size %]
[% Total %] GB
RequiredArgs:
- DynamicField_RAMCount
- DynamicField_RAMSize
Readonly: '1'Use Cases
- Cumulative Values (e.g., total memory)
- Status Calculations (e.g., "critical" at certain thresholds)
- Text Generation (e.g., asset descriptions with placeholders)
7. Merging Automation and Interfaces
- Automated Imports: Combine REST job with CSV import in cron jobs.
- Discovery + Trigger: Detect new devices and automatically start CI creation.
- Reporting: Use script fields and version history for automated reports via API.
With these mechanisms, processes can be seamlessly integrated in the OTOBO CMDB, data quality ensured, and manual routine tasks minimized.