GET /api/smart_variables
Elenca tutte le variabili smart

GET /api/hosts/:host_id/smart_variables
Elenco di variabili smart per un host specifico

GET /api/hostgroups/:hostgroup_id/smart_variables
Elenco variabili smart per un gruppo di host specifico

GET /api/puppetclasses/:puppetclass_id/smart_variables
Elenco di variabili smart per una classe puppet specifica

Parametri

Nome parametro Descrizione
host_id
opzionale

Validations:

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

hostgroup_id
opzionale

Validations:

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

puppetclass_id
opzionale

Validations:

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

show_hidden
opzionale

Display hidden values

Validations:

  • Must be one of: true, false, 1, 0

search
opzionale

filtra i risultati

Validations:

  • Must be a String

order
opzionale

ordina risultati

Validations:

  • Must be a String

page
opzionale

paginazione risultati

Validations:

  • Must be a String

per_page
opzionale

numero di voci per richiesta

Validations:

  • Must be a String


GET /api/smart_variables/:id
Mostra una variabile smart

Parametri

Nome parametro Descrizione
id
richiesto

Validations:

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

show_hidden
opzionale

Display hidden values

Validations:

  • Must be one of: true, false, 1, 0


POST /api/smart_variables
Crea una variabile smart

Parametri

Nome parametro Descrizione
smart_variable
richiesto

Validations:

  • Must be a Hash

smart_variable[variable]
richiesto

Name of variable

Validations:

  • Must be a String

smart_variable[puppetclass_id]
opzionale , consentito nil

Puppet class ID

Validations:

  • Must be a number.

smart_variable[default_value]
opzionale , consentito nil

Default value of variable

Validations:

  • Must be one of: string, boolean, integer, real, array, hash, yaml, json.

smart_variable[hidden_value]
opzionale , consentito nil

When enabled the parameter is hidden in the UI

Validations:

  • Must be one of: true, false, 1, 0

smart_variable[override_value_order]
opzionale , consentito nil

L'ordine attraverso il quale vengono risolti i valori

Validations:

  • Must be a String

smart_variable[description]
opzionale , consentito nil

Description of variable

Validations:

  • Must be a String

smart_variable[validator_type]
opzionale , consentito nil

Types of validation values

Validations:

  • Must be one of: regexp, list.

smart_variable[validator_rule]
opzionale , consentito nil

Used to enforce certain values for the parameter values

Validations:

  • Must be a String

smart_variable[variable_type]
opzionale , consentito nil

Types of variable values

Validations:

  • Must be one of: string, boolean, integer, real, array, hash, yaml, json.

smart_variable[merge_overrides]
opzionale , consentito nil

Merge all matching values (only array/hash type)

Validations:

  • Must be one of: true, false, 1, 0

smart_variable[merge_default]
opzionale , consentito nil

Include default value when merging all matching values

Validations:

  • Must be one of: true, false, 1, 0

smart_variable[avoid_duplicates]
opzionale , consentito nil

Remove duplicate values (only array type)

Validations:

  • Must be one of: true, false, 1, 0


PUT /api/smart_variables/:id
Aggiorna una variabile smart

Parametri

Nome parametro Descrizione
id
richiesto

Validations:

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

smart_variable
richiesto

Validations:

  • Must be a Hash

smart_variable[variable]
opzionale

Name of variable

Validations:

  • Must be a String

smart_variable[puppetclass_id]
opzionale , consentito nil

Puppet class ID

Validations:

  • Must be a number.

smart_variable[default_value]
opzionale , consentito nil

Default value of variable

Validations:

  • Must be one of: string, boolean, integer, real, array, hash, yaml, json.

smart_variable[hidden_value]
opzionale , consentito nil

When enabled the parameter is hidden in the UI

Validations:

  • Must be one of: true, false, 1, 0

smart_variable[override_value_order]
opzionale , consentito nil

L'ordine attraverso il quale vengono risolti i valori

Validations:

  • Must be a String

smart_variable[description]
opzionale , consentito nil

Description of variable

Validations:

  • Must be a String

smart_variable[validator_type]
opzionale , consentito nil

Types of validation values

Validations:

  • Must be one of: regexp, list.

smart_variable[validator_rule]
opzionale , consentito nil

Used to enforce certain values for the parameter values

Validations:

  • Must be a String

smart_variable[variable_type]
opzionale , consentito nil

Types of variable values

Validations:

  • Must be one of: string, boolean, integer, real, array, hash, yaml, json.

smart_variable[merge_overrides]
opzionale , consentito nil

Merge all matching values (only array/hash type)

Validations:

  • Must be one of: true, false, 1, 0

smart_variable[merge_default]
opzionale , consentito nil

Include default value when merging all matching values

Validations:

  • Must be one of: true, false, 1, 0

smart_variable[avoid_duplicates]
opzionale , consentito nil

Remove duplicate values (only array type)

Validations:

  • Must be one of: true, false, 1, 0


DELETE /api/smart_variables/:id
Cancella una variabile smart

Parametri

Nome parametro Descrizione
id
richiesto

Validations:

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