GET /api/v2/discovery_rules
Показать все правила обнаружения

Параметры

Имя параметра Описание
search
необязательно

отфильтровать результаты


Value:

Must be String

order
необязательно

отсортировать результаты


Value:

Must be String

page
необязательно

разместить результат на нескольких страницах


Value:

Must be String

per_page
необязательно

количество записей на запрос


Value:

Must be String


GET /api/v2/discovery_rules/:id
Показать правило

Параметры

Имя параметра Описание
id
обязательно

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, dot(.), space, underscore(_), hypen(-) with no leading or trailing space.


POST /api/v2/discovery_rules
Создать правило

Параметры

Имя параметра Описание
discovery_rule
необязательно , nil разрешен

Value:

Must be a Hash

discovery_rule[name]
обязательно

represents rule name shown to the users


Value:

Must be String

discovery_rule[search]
обязательно

query to match discovered hosts for the particular rule


Value:

Must be String

discovery_rule[hostgroup_id]
обязательно

the hostgroup that is used to auto provision a host


Value:

Must be Integer

discovery_rule[hostname]
необязательно , nil разрешен

defines a pattern to assign human-readable hostnames to the matching hosts


Value:

Must be String

discovery_rule[max_count]
необязательно , nil разрешен

enables to limit maximum amount of provisioned hosts per rule


Value:

Must be Integer

discovery_rule[priority]
необязательно , nil разрешен

puts the rules in order, low numbers go first. Must be greater then zero


Value:

Must be Integer

discovery_rule[enabled]
необязательно , nil разрешен

flag is used for temporary shutdown of rules


Value:

Must be ‘true’ or ‘false’


PUT /api/v2/discovery_rules/:id
Обновить правило

Параметры

Имя параметра Описание
id
обязательно

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.

discovery_rule
необязательно , nil разрешен

Value:

Must be a Hash

discovery_rule[name]
необязательно

represents rule name shown to the users


Value:

Must be String

discovery_rule[search]
необязательно

query to match discovered hosts for the particular rule


Value:

Must be String

discovery_rule[hostgroup_id]
необязательно

the hostgroup that is used to auto provision a host


Value:

Must be Integer

discovery_rule[hostname]
необязательно , nil разрешен

defines a pattern to assign human-readable hostnames to the matching hosts


Value:

Must be String

discovery_rule[max_count]
необязательно , nil разрешен

enables to limit maximum amount of provisioned hosts per rule


Value:

Must be Integer

discovery_rule[priority]
необязательно , nil разрешен

puts the rules in order, low numbers go first. Must be greater then zero


Value:

Must be Integer

discovery_rule[enabled]
необязательно , nil разрешен

flag is used for temporary shutdown of rules


Value:

Must be ‘true’ or ‘false’


DELETE /api/v2/discovery_rules/:id
Удалить правило

Параметры

Имя параметра Описание
id
обязательно

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.