Werk #16099: create_host: creating a host with a custom attribute now returns expected attributes

Komponente REST API
Titel create_host: creating a host with a custom attribute now returns expected attributes
Datum 14.09.2023
Level Kleine Änderung
Klasse Bugfix
Kompatibilität Kompatibel - benötigt kein manuelles Eingreifen
Checkmk versions & editions
2.3.0b1 Checkmk Raw (CRE), Checkmk Enterprise (CEE), Checkmk Cloud (CCE), Checkmk MSP (CME)
2.2.0p10 Checkmk Raw (CRE), Checkmk Enterprise (CEE), Checkmk Cloud (CCE), Checkmk MSP (CME)
2.1.0p34 Checkmk Raw (CRE), Checkmk Enterprise (CEE), Checkmk MSP (CME)

This werk addresses an issue when creating a host with custom attributes. For example, when you added a new tag to a tag group and then created a host with that tag group: tag value, the created host would have this new attribute but it wouldn't have any other attributes.

So sending this in your request, after creating the new tag 'tag1',

{
    "folder": "~",
    "host_name": "api_created_host2",
    "attributes": {
        "ipaddress": "127.0.0.1",
        "tag_agent": "no-agent",
        "tag_snmp_ds": "no-snmp",
        "tag_networking": "tag1"
        }
}

before this would create a host with the only the tag networking attribute and ignore all others, like so

{
    ...
    "attributes" {
    "tag_networking": "tag1"
    }

Now, we return all the expected attributes.

Zur Liste aller Werks