content library subscriptions: get
Returns information about the specified subscription of the published library. This operation was added in vSphere API 6.7.2.
Request:
HTTP request
POST https://{server}/rest/com/vmware/content/library/subscriptions/id:{library}?~action=get
Path Parameters
Name | Type | Description |
---|---|---|
Required | ||
library | string | Identifier of the published library. |
Request Body Structure:
{
"subscription" : "obj-103"
}
"subscription" : "obj-103"
}
Request Body Parameters:
Name | Type | Description |
---|---|---|
bold = required | ||
subscription | string | Identifier of the subscription. |
Response:
HTTP Status Code: 200
Representation:
{
"value" : {
"subscribed_library" : "obj-103",
"subscribed_library_vcenter" : {
"hostname" : "string",
"https_port" : 1,
"server_guid" : "string"
},
"subscribed_library_name" : "string",
"subscribed_library_location" : "LOCAL",
"subscribed_library_placement" : {
"cluster" : "obj-103",
"folder" : "obj-103",
"host" : "obj-103",
"resource_pool" : "obj-103",
"network" : "obj-103"
}
}
}
"value" : {
"subscribed_library" : "obj-103",
"subscribed_library_vcenter" : {
"hostname" : "string",
"https_port" : 1,
"server_guid" : "string"
},
"subscribed_library_name" : "string",
"subscribed_library_location" : "LOCAL",
"subscribed_library_placement" : {
"cluster" : "obj-103",
"folder" : "obj-103",
"host" : "obj-103",
"resource_pool" : "obj-103",
"network" : "obj-103"
}
}
}
Response Type:
Name | Type | Description |
---|---|---|
bold = required | ||
value | info | Information about the subscription. |
value.subscribed_library | string | Identifier of the subscribed library associated with the subscription. This attribute was added in vSphere API 6.7.2. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.content.Library . When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.content.Library . |
value.subscribed_library_name | string | Name of the subscribed library associated with the subscription. This attribute was added in vSphere API 6.7.2. |
value.subscribed_library_location | string | Location of the subscribed library relative to the published library. This attribute was added in vSphere API 6.7.2. Defines the location of subscribed library relative to the published library. This enumeration was added in vSphere API 6.7.2. Value is one of: LOCAL: The subscribed library belongs to the same vCenter instance as the published library. This constant was added in vSphere API 6.7.2. REMOTE: The subscribed library belongs to a different vCenter instance than the published library. This constant was added in vSphere API 6.7.2. |
value.subscribed_library_vcenter | vcenter_info | Information about the vCenter Server instance where the subscribed library exists. This attribute was added in vSphere API 6.7.2. Optional. It is only relevant when subscribed_library_location has value REMOTE. This field is optional and it is only relevant when the value of subscribed_library_location is REMOTE. |
value.subscribed_library_vcenter.hostname | string | Hostname of the vCenter Server instance where the subscribed library exists. This attribute was added in vSphere API 6.7.2. |
value.subscribed_library_vcenter.https_port | long | The HTTPS port of the vCenter Server instance where the subscribed library exists. This attribute was added in vSphere API 6.7.2. Optional. If unset, port 443 will be used. |
value.subscribed_library_vcenter.server_guid | string | The unique identifier of the vCenter Server where the subscribed library exists. This attribute was added in vSphere API 6.7.2. |
value.subscribed_library_placement | placement_info | Placement information about the subscribed library's virtual machine template items. This attribute was added in vSphere API 6.7.2. |
value.subscribed_library_placement.folder | string | Virtual machine folder into which the virtual machine template should be placed. This attribute was added in vSphere API 6.7.2. Optional. The field will be unset if the subscribed library associated with the subscription does not have a virtual machine folder.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: Folder:VCenter . When operations return a value of this structure as a result, the field will be an identifier for the resource type: Folder:VCenter . |
value.subscribed_library_placement.cluster | string | Cluster onto which the virtual machine template should be placed. This attribute was added in vSphere API 6.7.2. Optional. The field will be unset if the subscribed library associated with the subscription does not have a cluster.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: ClusterComputeResource:VCenter . When operations return a value of this structure as a result, the field will be an identifier for the resource type: ClusterComputeResource:VCenter . |
value.subscribed_library_placement.resource_pool | string | Resource pool into which the virtual machine template should be placed. This attribute was added in vSphere API 6.7.2. Optional. The field will be unset if the subscribed library associated with the subscription does not have a resource pool.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: ResourcePool:VCenter . When operations return a value of this structure as a result, the field will be an identifier for the resource type: ResourcePool:VCenter . |
value.subscribed_library_placement.host | string | Host onto which the virtual machine template should be placed. If host and resource_pool are both specified, resource_pool must belong to host . If host and cluster are both specified, host must be a member of cluster . This attribute was added in vSphere API 6.7.2. Optional. The field will be unset if the subscribed library associated with the subscription does not have a host.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: HostSystem:VCenter . When operations return a value of this structure as a result, the field will be an identifier for the resource type: HostSystem:VCenter . |
value.subscribed_library_placement.network | string | Network that backs the virtual Ethernet adapters in the virtual machine template. This attribute was added in vSphere API 6.7.2. Optional. The field will be unset if the subscribed library associated with the subscription does not have a network.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: Network:VCenter . When operations return a value of this structure as a result, the field will be an identifier for the resource type: Network:VCenter . |
Errors:
HTTP Status Code | Type | Description |
---|---|---|
500 | error | If the system reports an error while responding to the request. |
404 | not_found | If the library specified by library does not exist. |
400 | invalid_argument | If the subscription is not valid. |
400 | invalid_element_type | If the library specified by library is a subscribed library. |
400 | not_allowed_in_current_state | If the library specified by library is not a published library. |
401 | unauthenticated | If the user that requested the operation cannot be authenticated. |
403 | unauthorized | If the user that requested the operation is not authorized to perform the operation. |