GET /api/hosts/980191213/subscriptions 200 { "total": 0, "subtotal": 0, "selectable": 0, "page": 1, "per_page": 0, "error": null, "search": null, "sort": { "by": null, "order": null }, "results": [] }
Param name | Description |
---|---|
host_id
required |
Id of the host Validations:
|
PUT /api/hosts/980191210/subscriptions/auto_attach { "host_subscription": {} } 204
Param name | Description |
---|---|
host_id
required |
Id of the host Validations:
|
DELETE /api/hosts/980191151/subscriptions { "host_subscription": {} } 200 {}
Param name | Description |
---|---|
host_id
required |
Id of the host Validations:
|
POST /api/hosts/subscriptions { "lifecycle_environment_id": 562075838, "content_view_id": 30237652, "facts": { "network.hostname": "host500" }, "installed_products": [ { "product_id": "1", "product_name": "name" } ], "purpose_role": "MyRole", "purpose_usage": "MyUsage", "purpose_addons": "Addon1,Addon2", "host_subscription": { "lifecycle_environment_id": 562075838, "content_view_id": 30237652, "facts": { "network.hostname": "host500" }, "installed_products": [ { "product_id": "1", "product_name": "name" } ], "purpose_role": "MyRole", "purpose_usage": "MyUsage", "purpose_addons": "Addon1,Addon2" } } 200 { "id": 980191207, "name": "host500", "operatingsystem_family": null, "operatingsystem_major": "55" }
Param name | Description |
---|---|
name
required |
Name of the host Validations:
|
uuid
optional |
UUID to use for registered host, random uuid is generated if not provided Validations:
|
facts
optional |
Key-value hash of subscription-manager facts, nesting uses a period delimiter (.) Validations:
|
hypervisor_guest_uuids
optional |
UUIDs of the virtual guests from the host's hypervisor Validations:
|
installed_products
optional |
List of products installed on the host Validations:
|
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:
|
installed_products[product_name]
optional |
Product name as listed from a host's installed products Validations:
|
installed_products[arch]
optional |
Product architecture Validations:
|
installed_products[version]
optional |
Product version Validations:
|
release_version
optional |
Release version of the content host Validations:
|
service_level
optional |
A service level for auto-healing process, e.g. SELF-SUPPORT Validations:
|
lifecycle_environment_id
required |
Lifecycle Environment ID Validations:
|
content_view_id
required |
Content View ID Validations:
|
POST /api/hosts/980191208/subscriptions/remove_subscriptions { "subscriptions": [ { "id": 128914721, "quantity": "3" } ], "host_subscription": { "subscriptions": [ { "id": 128914721, "quantity": "3" } ] } } 200 { "total": 0, "subtotal": 0, "selectable": 0, "page": 1, "per_page": 0, "error": null, "search": null, "sort": { "by": null, "order": null }, "results": [] }
Param name | Description |
---|---|
host_id
required |
Id of the host Validations:
|
subscriptions
optional |
Array of subscriptions to remove Validations:
|
subscriptions[id]
required |
Subscription Pool id Validations:
|
subscriptions[quantity]
optional |
If specified, remove the first instance of a subscription with matching id and quantity Validations:
|
POST /api/hosts/980191205/subscriptions/add_subscriptions { "subscriptions": [ { "id": 128914721, "quantity": "1" } ], "host_subscription": { "subscriptions": [ { "id": 128914721, "quantity": "1" } ] } } 200 { "total": 0, "subtotal": 0, "selectable": 0, "page": 1, "per_page": 0, "error": null, "search": null, "sort": { "by": null, "order": null }, "results": [] }
Param name | Description |
---|---|
host_id
required |
Id of the host Validations:
|
subscriptions
required |
Array of subscriptions to add Validations:
|
subscriptions[id]
required |
Subscription Pool id Validations:
|
subscriptions[quantity]
required |
Quantity of this subscriptions to add Validations:
|
Param name | Description |
---|---|
host_id
required |
Id of the host Validations:
|
content_access_mode_all
optional |
Get all content available, not just that provided by subscriptions Validations:
|
content_access_mode_env
optional |
Limit content to just that available in the host's content view version Validations:
|
search
optional |
Search string Validations:
|
page
optional |
Page number, starting at 1 Validations:
|
per_page
optional |
Number of results per page to return Validations:
|
order
optional |
Sort field and order, eg. 'id DESC' Validations:
|
full_result
optional |
Whether or not to show all results Validations:
|
sort_by
optional |
Field to sort the results on Validations:
|
sort_order
optional |
How to order the sorted results (e.g. ASC for ascending) Validations:
|
PUT /api/hosts/980191147/subscriptions/content_override { "content_overrides": [ { "content_label": "some-content", "value": 1 } ], "host_subscription": { "content_overrides": [ { "content_label": "some-content", "value": 1 } ] } } 200 { "total": 1, "subtotal": 1, "selectable": 1, "page": 1, "per_page": 1, "error": null, "search": null, "sort": { "by": null, "order": null }, "results": [ { "enabled": false, "product": { "id": null, "name": "Product 75" }, "content": { "id": null, "name": "content-name5", "label": "some-content", "vendor": null, "content_type": null, "content_url": null, "gpg_url": null }, "repositories": [], "name": "content-name5", "vendor": null, "label": "some-content", "id": null, "type": null, "gpgUrl": null, "contentUrl": null, "archRestricted": null, "osRestricted": null, "override": "default", "overrides": [], "enabled_content_override": null, "redhat": false } ] }
Param name | Description |
---|---|
host_id
required |
Id of the content host Validations:
|
value
optional |
Override to a boolean value or 'default' Validations:
|
content_overrides
optional |
Array of Content override parameters Validations:
|
content_overrides[content_label]
required |
Label of the content Validations:
|
content_overrides[value]
optional |
Override value. Provide a boolean value if name is 'enabled' Validations:
|
content_overrides[name]
optional |
Override key or name. Note if name is not provided the default name will be 'enabled' Validations:
|
content_overrides[remove]
optional |
Set true to remove an override and reset it to 'default' Validations:
|
content_overrides_search
optional |
Content override search parameters Validations:
|
content_overrides_search[search]
optional |
Search string Validations:
|
content_overrides_search[page]
optional |
Page number, starting at 1 Validations:
|
content_overrides_search[per_page]
optional |
Number of results per page to return Validations:
|
content_overrides_search[order]
optional |
Sort field and order, eg. 'id DESC' Validations:
|
content_overrides_search[full_result]
optional |
Whether or not to show all results Validations:
|
content_overrides_search[sort_by]
optional |
Field to sort the results on Validations:
|
content_overrides_search[sort_order]
optional |
How to order the sorted results (e.g. ASC for ascending) Validations:
|
content_overrides_search[enabled]
optional |
Set true to override to enabled; Set false to override to disabled.' Validations:
|
content_overrides_search[remove]
optional |
Set true to remove an override and reset it to 'default' Validations:
|
GET /api/hosts/980191148/subscriptions/available_release_versions 200 { "total": 0, "subtotal": 0, "selectable": 0, "page": 1, "per_page": 0, "error": null, "search": null, "sort": { "by": null, "order": null }, "results": [] }
Param name | Description |
---|---|
host_id
required |
id of host Validations:
|
GET /api/hosts/980191149/subscriptions/enabled_repositories 200 { "total": 1, "subtotal": 1, "selectable": 1, "page": 1, "per_page": 1, "error": null, "search": null, "sort": { "by": null, "order": null }, "results": [ { "backend_identifier": "fedora_17_acme_dev", "relative_path": "ACME_Corporation/dev/fedora_17_dev_label", "container_repository_name": null, "full_path": "https://centos8-katello-devel.redhat.example.com/pulp/content/ACME_Corporation/dev/fedora_17_dev_label/", "library_instance_id": null, "version_href": null, "remote_href": null, "publication_href": null, "content_counts": { "rpm": 0, "erratum": 0, "package_group": 0, "srpm": 0, "module_stream": 0 }, "mirroring_policy": "mirror_content_only", "id": 841170190, "name": "Fedora 17 x86_64", "label": "fedora_17_x86_64_label", "description": "My description", "content_view_versions": [], "filters": [], "last_sync": null, "content_view": { "id": 30237652, "name": "ACME Default ContentView" }, "content_view_version": { "id": 840492357, "name": "ACME Default ContentView 1.0", "content_view_id": 30237652 }, "kt_environment": { "id": 292811013, "name": "Dev" }, "content_type": "yum", "url": "http://myrepo.com", "arch": "noarch", "os_versions": null, "content_id": "1", "generic_remote_options": null, "major": null, "minor": null, "product": { "id": 785257261, "cp_id": "123123123001", "name": "Fedora", "orphaned": false, "redhat": false, "sync_plan": null }, "content_label": "fedora", "last_sync_words": null } ] }
Param name | Description |
---|---|
host_id
required |
id of host Validations:
|