Examples

POST /katello/api/content_views/909058347/filters
{
  "name": "My Filter",
  "type": "rpm",
  "content_view_filter": {
    "name": "My Filter",
    "type": "rpm"
  }
}
201
{
  "inclusion": false,
  "original_packages": false,
  "id": 703096779,
  "name": "My Filter",
  "description": null,
  "created_at": "2022-11-08 19:12:34 UTC",
  "updated_at": "2022-11-08 19:12:34 UTC",
  "content_view": {
    "composite": false,
    "component_ids": [],
    "default": false,
    "version_count": 1,
    "latest_version": "1.0",
    "latest_version_id": 172022917,
    "auto_publish": false,
    "solve_dependencies": false,
    "import_only": false,
    "generated_for": "none",
    "related_cv_count": 0,
    "related_composite_cvs": [],
    "repository_ids": [],
    "id": 909058347,
    "name": "Published Library and dev view",
    "label": "published_dev_view",
    "description": "A content view",
    "organization_id": 114267492,
    "organization": {
      "name": "Empty Organization",
      "label": "Empty_Organization",
      "id": 114267492
    },
    "created_at": "2022-11-08 19:09:32 UTC",
    "updated_at": "2022-11-08 19:09:32 UTC",
    "last_task": null,
    "latest_version_environments": [
      {
        "id": 562075838,
        "name": "Library",
        "label": "library_label"
      },
      {
        "id": 292811013,
        "name": "Dev",
        "label": "dev_label"
      },
      {
        "id": 292811013,
        "name": "Dev",
        "label": "dev_label"
      }
    ],
    "repositories": [],
    "versions": [
      {
        "id": 172022917,
        "version": "1.0",
        "published": "2022-11-08 19:09:32 UTC",
        "environment_ids": [
          562075838,
          292811013,
          292811013
        ]
      }
    ],
    "components": [],
    "content_view_components": [],
    "activation_keys": [],
    "hosts": [
      {
        "id": 298486374,
        "name": "host2.example.com"
      }
    ],
    "next_version": "2.0",
    "last_published": "2022-11-08 19:09:32 UTC",
    "environments": [
      {
        "id": 562075838,
        "label": "library_label",
        "name": "library_label",
        "activation_keys": [],
        "hosts": [],
        "permissions": {
          "readable": true
        }
      },
      {
        "id": 292811013,
        "label": "dev_label",
        "name": "dev_label",
        "activation_keys": [],
        "hosts": [
          298486374
        ],
        "permissions": {
          "readable": true
        }
      }
    ]
  },
  "repositories": [],
  "type": "rpm",
  "rules": []
}

Params

Param name Description
content_view_id
required

content view identifier

Validations:

  • Must be a number.

name
required

name of the filter

Validations:

  • String

type
required

type of filter (e.g. deb, rpm, package_group, erratum, erratum_id, erratum_date, docker, modulemd)

Validations:

  • String

original_packages
optional

add all packages without errata to the included/excluded list. (package filter only)

Validations:

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

original_module_streams
optional

add all module streams without errata to the included/excluded list. (module stream filter only)

Validations:

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

inclusion
optional

specifies if content should be included or excluded, default: inclusion=false

Validations:

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

repository_ids
optional

list of repository ids

Validations:

  • Must be an array of any type

description
optional

description of the filter

Validations:

  • String