GET /api/hosts/:host_id/subscriptions
List a host's subscriptions

Params

Param name Description
host_id
required

Id of the host

Validations:

  • Integer


PUT /api/hosts/:host_id/subscriptions/auto_attach
Trigger an auto-attach of subscriptions

Params

Param name Description
host_id
required

Id of the host

Validations:

  • Integer


DELETE /api/hosts/:host_id/subscriptions
Unregister the host as a subscription consumer

Params

Param name Description
host_id
required

Id of the host

Validations:

  • Integer


POST /api/hosts/subscriptions
Register a host with subscription and information

Params

Param name Description
name
required

Name of the host

Validations:

  • String

uuid
optional

UUID to use for registered host, random uuid is generated if not provided

Validations:

  • String

facts
optional

Key-value hash of subscription-manager facts, nesting uses a period delimiter (.)

Validations:

  • Hash

hypervisor_guest_uuids
optional

UUIDs of the virtual guests from the host's hypervisor

Validations:

  • Must be an array of any type

installed_products
optional

List of products installed on the host

Validations:

  • Must be an Array of nested elements

installed_products[product_id]
optional

Product id as listed from a host's installed products, this is not the same product id as the products api returns

Validations:

  • String

installed_products[product_name]
optional

Product name as listed from a host's installed products

Validations:

  • String

installed_products[arch]
optional

Product architecture

Validations:

  • String

installed_products[version]
optional

Product version

Validations:

  • String

release_version
optional

Release version of the content host

Validations:

  • String

service_level
optional

A service level for auto-healing process, e.g. SELF-SUPPORT

Validations:

  • String

lifecycle_environment_id
required

Lifecycle Environment ID

Validations:

  • Integer

content_view_id
required

Content View ID

Validations:

  • Integer


PUT /api/hosts/:host_id/subscriptions/remove_subscriptions

Params

Param name Description
host_id
required

Id of the host

Validations:

  • Integer

subscriptions
optional

Array of subscriptions to remove

Validations:

  • Must be an Array of nested elements

subscriptions[id]
required

Subscription Pool id

Validations:

  • String

subscriptions[quantity]
optional

If specified, remove the first instance of a subscription with matching id and quantity

Validations:

  • Integer


PUT /api/hosts/:host_id/subscriptions/add_subscriptions
Add a subscription to a host

Params

Param name Description
host_id
required

Id of the host

Validations:

  • Integer

subscriptions
required

Array of subscriptions to add

Validations:

  • Must be an Array of nested elements

subscriptions[id]
required

Subscription Pool id

Validations:

  • String

subscriptions[quantity]
required

Quantity of this subscriptions to add

Validations:

  • Must be a number.


GET /api/hosts/:host_id/subscriptions/product_content
Get content and overrides for the host

Params

Param name Description
host_id
required

Id of the host

Validations:

  • String

content_access_mode_all
optional

Get all content available, not just that provided by subscriptions

Validations:

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

content_access_mode_env
optional

Limit content to just that available in the host's content view version

Validations:

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

search
optional

Search string

Validations:

  • String

page
optional

Page number, starting at 1

Validations:

  • Must be a number.

per_page
optional

Number of results per page to return

Validations:

  • Must be a number.

order
optional

Sort field and order, eg. 'id DESC'

Validations:

  • String

full_result
optional

Whether or not to show all results

Validations:

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

sort_by
optional

Field to sort the results on

Validations:

  • String

sort_order
optional

How to order the sorted results (e.g. ASC for ascending)

Validations:

  • String


PUT /api/hosts/:host_id/subscriptions/content_override
Set content overrides for the host

Params

Param name Description
host_id
required

Id of the content host

Validations:

  • String

value
optional

Override to a boolean value or 'default'

Validations:

  • String

content_overrides
optional

Array of Content override parameters

Validations:

  • Must be an Array of nested elements

content_overrides[content_label]
required

Label of the content

Validations:

  • String

content_overrides[value]
optional

Override value. Provide a boolean value if name is 'enabled'

Validations:

  • String

content_overrides[name]
optional

Override key or name. Note if name is not provided the default name will be 'enabled'

Validations:

  • String

content_overrides[remove]
optional

Set true to remove an override and reset it to 'default'

Validations:

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

content_overrides_search
optional

Content override search parameters

Validations:

  • Hash

content_overrides_search[search]
optional

Search string

Validations:

  • String

content_overrides_search[page]
optional

Page number, starting at 1

Validations:

  • Must be a number.

content_overrides_search[per_page]
optional

Number of results per page to return

Validations:

  • Must be a number.

content_overrides_search[order]
optional

Sort field and order, eg. 'id DESC'

Validations:

  • String

content_overrides_search[full_result]
optional

Whether or not to show all results

Validations:

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

content_overrides_search[sort_by]
optional

Field to sort the results on

Validations:

  • String

content_overrides_search[sort_order]
optional

How to order the sorted results (e.g. ASC for ascending)

Validations:

  • String

content_overrides_search[enabled]
optional

Set true to override to enabled; Set false to override to disabled.'

Validations:

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

content_overrides_search[remove]
optional

Set true to remove an override and reset it to 'default'

Validations:

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


GET /api/hosts/:host_id/subscriptions/available_release_versions
Show releases available for the content host

Params

Param name Description
host_id
required

id of host

Validations:

  • String


GET /api/hosts/:host_id/subscriptions/enabled_repositories
Show repositories enabled on the host that are known to Katello

Params

Param name Description
host_id
required

id of host

Validations:

  • String