GET /api/config_groups
Lista de grupos de configuração

Parâmentros

Nome parâmetro Descrição
location_id
opcional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
opcional

Set the current organization context for the request

Validations:

  • Must be a Integer

search
opcional

filtrar resultados

Validations:

  • Must be a String

order
opcional

Classificar campo e ordem, ex.: ‘id DESC’

Validations:

  • Must be a String

page
opcional

Número de página, iniciando em 1

Validations:

  • Must be a number.

per_page
opcional

Número de resultados por página para retornar

Validations:

  • Must be a number.

Pesquisar campos

Nome do campo Tipo Valores possíveis
class string
name string

GET /api/config_groups/:id
Mostrar um grupo de configuração

Parâmentros

Nome parâmetro Descrição
location_id
opcional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
opcional

Set the current organization context for the request

Validations:

  • Must be a Integer

id
requerido

Validations:

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


POST /api/config_groups
Criar um grupo de configuração

Exemplos

POST /api/config_groups
{
  "config_group": {
    "name": "config-group",
    "puppetclass_ids": [
      980190962,
      281110143
    ]
  }
}
201
{
  "created_at": "2019-11-07 09:07:21 UTC",
  "updated_at": "2019-11-07 09:07:21 UTC",
  "id": 980190969,
  "name": "config-group",
  "puppetclasses": [
    {
      "id": 980190962,
      "name": "base",
      "module_name": "base"
    },
    {
      "id": 281110143,
      "name": "vim",
      "module_name": "vim"
    }
  ]
}

Parâmentros

Nome parâmetro Descrição
location_id
opcional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
opcional

Set the current organization context for the request

Validations:

  • Must be a Integer

config_group
requerido

Validations:

  • Must be a Hash

config_group[name]
requerido

Validations:

  • Must be a String

config_group[puppetclass_ids]
opcional , nulo permitido

Validations:

  • Must be an array of any type


PUT /api/config_groups/:id
Atualizar um grupo de configuração

Exemplos

PUT /api/config_groups/980190962-Monitoring
{
  "config_group": {
    "name": "new name",
    "puppetclass_ids": [
      980190962,
      281110143
    ]
  }
}
200
{
  "created_at": "2019-11-07 09:06:52 UTC",
  "updated_at": "2019-11-07 09:07:21 UTC",
  "id": 980190962,
  "name": "new name",
  "puppetclasses": [
    {
      "id": 980190962,
      "name": "base",
      "module_name": "base"
    },
    {
      "id": 281110143,
      "name": "vim",
      "module_name": "vim"
    }
  ]
}

Parâmentros

Nome parâmetro Descrição
location_id
opcional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
opcional

Set the current organization context for the request

Validations:

  • Must be a Integer

id
requerido

Validations:

  • Must be a String

config_group
requerido

Validations:

  • Must be a Hash

config_group[name]
opcional

Validations:

  • Must be a String

config_group[puppetclass_ids]
opcional , nulo permitido

Validations:

  • Must be an array of any type


DELETE /api/config_groups/:id
Apagar um grupo de configuração

Parâmentros

Nome parâmetro Descrição
location_id
opcional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
opcional

Set the current organization context for the request

Validations:

  • Must be a Integer

id
requerido

Validations:

  • Must be a String