Skip to content

CI modeling with YAML in the OTOBO ticket system

CI modeling with YAML in the OTOBO ticket system

Section titled “CI modeling with YAML in the OTOBO ticket system”

This chapter shows how you can define and extend your Configuration Items (CIs) in the OTOBO ticket system using YAML – from page and layout structure to dynamic fields and field types.


Every CI definition in OTOBO consists of several main components:

- Class:
Name: <CI-Class>
Categories:
- All
- <Additional Categories>
NumberModule: AutoIncrement
PermissionGroup: itsm-configitem
VersionStringModule: Incremental
Definition: |
Pages:
- Name: Summary
Layout:
Columns: 3
ColumnWidth: 1fr 1fr 1fr
Interfaces:
- Agent
- Customer
Content:
- Section: General Fields::General Information
RowStart: 1
ColumnStart: 1
- Section: ITSM Model::Model
RowStart: 1
ColumnStart: 2
- Section: CMDB Description::Description
RowStart: 2
ColumnStart: 1
ColumnSpan: 2
DynamicFields: { }
  • Name: Label of the tab in the Agent Zoom.
  • Interfaces: Control who sees the tab (Agent, Customer, …).
  • Content: List of sections, with position (RowStart, ColumnStart, optionally Span).
  • Columns: Number of columns in the tab.
  • ColumnWidth: Proportional width specifications (e.g., 1fr 2fr 1fr).

Roles define reusable sections and field lists:

- Definition: |
Sections:
General Information:
Content:
- Header: General Information
- DF: System-Name
- DF: System-Version
Relations:
Type: ConfigItemLinks
Header: Relations
RoleName: CMDB General Fields
  • RoleName: Unique name of the role.
  • Sections: Contains one or more sections with field references (DF:).

With DynamicFields, you can extend your CI classes with individual attributes. Each field receives a name, type, and configuration:

DynamicFields:
DynamicFieldName:
FieldType: Text
Label: My Label
Name: System-Name
ObjectType: ITSMConfigItem
Config:
DefaultValue: 'demo'
MultiValue: '0'
PossibleNone: '1'
Tooltip: ''
System-LifecycleStatus:
FieldType: Dropdown
Label: Lifecycle status of system
Name: System-LifecycleStatus
ObjectType: ITSMConfigItem
Config:
DefaultValue: ''
MultiValue: '0'
PossibleNone: '1'
PossibleValues:
demo: demo
productive: productive
Tooltip: ''
FieldTypeDescription
TextSimple single-line field
TextAreaMulti-line free text field
DateDate field (with restrictions via YearsInPast/...)
DropdownSelection field (Single/Multi via MultiValue)
AgentLDAP user/agent lookup
ConfigItemLink to another CI (relation type definable)
ScriptTemplateToolkitCalculated field via template (e.g., sums)
  • DefaultValue: Default value when creating a new item.
  • MultiValue: '0' (single selection) or '1' (multiple).
  • PossibleNone: '1' to allow an empty selection.
  • PossibleValues: Key-value pairs for dropdown fields.
  • EditFieldMode: e.g., Dropdown, AutoComplete.
  • ReferenceFilterList, ReferencedObjectType: For lookup fields.

- Class:
Name: CIName
Categories:
- All
- IT
NumberModule: AutoIncrement
PermissionGroup: itsm-configitem
VersionStringModule: Incremental
Definition: |
Pages:
- Name: Intro
Layout:
Columns: 2
ColumnWidth: 1fr 1fr
Interfaces:
- Agent
Content:
- Section: CMDB General Fields::Information
RowStart: 1
ColumnStart: 1
- Section: CMDB General Fields::Risks
RowStart: 2
ColumnStart: 1
- Name: Details
Layout:
Columns: 1
ColumnWidth: 1fr
Interfaces:
- Agent
Content:
- Section: CMDB General Fields::Software
RowStart: 1
ColumnStart: 1
DynamicFields:
System-Name: { }
System-Version: { }
System-LifecycleStatus: { }

  • Modularity: Use roles for recurring sections.
  • Clarity: Group related fields into their own pages.
  • Documentation: Comment your YAML files and maintain version triggers.
  • Testing: Validate new fields in a test instance first.

With this structure, you can flexibly adapt the OTOBO CMDB to your organizational requirements and keep it transparent at all times.