Examples

POST /api/puppetclasses
{
  "puppetclass": {
    "name": "test_puppetclass",
    "lookup_keys_attributes": [
      {
        "key": "smart_variable1"
      }
    ]
  }
}
201
{
  "created_at": "2019-09-11 14:57:13 UTC",
  "updated_at": "2019-09-11 14:57:13 UTC",
  "id": 1018350800,
  "name": "test_puppetclass",
  "module_name": "test_puppetclass",
  "environments": [],
  "hostgroups": [],
  "smart_variables": [
    {
      "variable": "smart_variable1",
      "id": 1018350797
    }
  ],
  "smart_class_parameters": []
}

Params

Param Name Description
location_id
Optional

Scope by locations

Validations:

  • Must be a Integer

organization_id
Optional

Scope by organizations

Validations:

  • Must be a Integer

puppetclass
Required

Validations:

  • Must be a Hash

puppetclass[name]
Required

Validations:

  • Must be a String