chore: Add allDevices query resolver, update Zabbix device query handling, and enhance schema with DeviceConfig and WidgetPreview types

This commit is contained in:
Andreas Hilbig 2026-01-20 17:10:08 +01:00
parent c1035cd614
commit e641f8e610
7 changed files with 200 additions and 33 deletions

View file

@ -34,6 +34,16 @@ type Query {
allHosts(name_pattern: String = "", filter_host: String = null, hostids: Int,
groupids:[Int!] = null, with_items: Boolean = false, tag_deviceType:[String]=[], tag_hostType:[String!]): [Host]
"""
Get all devices + corresponding items. Devices are modelled as hosts having a device type + a state.
If with_items==true only hosts with attached items are delivered
name_pattern: If provided this will perform a LIKE "%…%" search on the name attribute within the database.
Authentication: By zbx_session - cookie or zabbix-auth-token - header
"""
allDevices(name_pattern: String = "", filter_host: String = null, hostids: Int,
groupids:[Int!] = null, with_items: Boolean = false, tag_deviceType:[String]=[], tag_hostType:[String!]): [Device]
"""
Get all host groups.
If with_hosts==true only groups with attached hosts are delivered.