I'm using templates for a few things in xi, and would like to be able to programmatically determine if a template is applied (using the template when creating the host is straightforward, now I want to be able to query for what templates a host has applied).
It doesnt appear that is possible. Am I missing something? An ability to use a template via the api without the ability to query for it later seems awkward.
Also, templates can be applied via the api with use=<template>... can templates be removed via api call?
thanks,
-Luke
api call to determine templates applied to host?
-
lukesullivan
- Posts: 34
- Joined: Tue Jan 24, 2017 11:12 am
Re: api call to determine templates applied to host?
I filed a feature request for the ability to view the current running configuration, including the template -
As for your second question -
Code: Select all
NEW TASK ID 11030 created - Nagios XI Feature Request: Allow querying of current configuration through API
When using the API, there isn't a delete function. If you add a service twice, then the expectation is the second call replaces all configurations that previously existed.Also, templates can be applied via the api with use=<template>... can templates be removed via api call?
Former Nagios Employee
Re: api call to determine templates applied to host?
Just checking in since we have not heard from you in a while. Did @rkennedy's post clear things up?
Former Nagios employee