zabbix-graphql-api/docs/queries/sample_all_hosts_query.graphql
Andreas Hilbig 4ec61ffba1 chore: add MCP integration and refactor documentation into modular how-to guides
- Moved GraphQL query samples into a new `docs/queries` directory for better organization.
- Added new queries and mutations, including `createHost.graphql` and `GetApiVersion.graphql`.
- Introduced `mcp-config.yaml` and updated `docker-compose.yml` for MCP integration.
- Updated IntelliJ `.idea/workspace.xml` settings to reflect project changes.
- Added new how-to guides (`docs/howtos`) for permissions, tags, MCP integration, and schema usage.
- Enhanced tests by updating file paths and improving sample data locations.
- Refined permissions and host group structures in `zabbix-hostgroups.ts` and `resolvers.ts`.
2026-01-30 00:47:02 +01:00

25 lines
452 B
GraphQL

### Query
Use this query to list all hosts, filtered by name pattern and/or device type.
```graphql
query AllHosts($name_pattern: String, $tag_deviceType: [String]) {
allHosts(name_pattern: $name_pattern, tag_deviceType: $tag_deviceType) {
hostid
host
name
deviceType
hostgroups {
groupid
name
}
}
}
```
### Variables
```json
{
"name_pattern": "BT_%",
"tag_deviceType": ["bt_device_tracker_generic"]
}
```