inventory_items
Creates, updates, deletes, gets or lists an inventory_items resource.
Overview
| Name | inventory_items |
| Type | Resource |
| Id | azure_isv.connectedvmware.inventory_items |
Fields
The following fields are returned by SELECT queries:
- get
- list_by_v_center
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}". |
name | string | The name of the resource. |
inventoryType | string | They inventory type. Required. Known values are: "ResourcePool", "VirtualMachine", "VirtualMachineTemplate", "VirtualNetwork", "Cluster", "Datastore", and "Host". |
kind | string | Metadata used by portal/tooling/etc to render different UX experiences for resources of the same type; e.g. ApiApps are a kind of Microsoft.Web/sites type. If supported, the resource provider must validate and persist this value. |
managedResourceId | string | Gets or sets the tracked resource id corresponding to the inventory resource. |
moName | string | Gets or sets the vCenter Managed Object name for the inventory item. |
moRefId | string | Gets or sets the MoRef (Managed Object Reference) ID for the inventory item. |
provisioningState | string | Gets the provisioning state. Known values are: "Succeeded", "Failed", "Canceled", "Provisioning", "Updating", "Deleting", "Accepted", and "Created". |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}". |
name | string | The name of the resource. |
inventoryType | string | They inventory type. Required. Known values are: "ResourcePool", "VirtualMachine", "VirtualMachineTemplate", "VirtualNetwork", "Cluster", "Datastore", and "Host". |
kind | string | Metadata used by portal/tooling/etc to render different UX experiences for resources of the same type; e.g. ApiApps are a kind of Microsoft.Web/sites type. If supported, the resource provider must validate and persist this value. |
managedResourceId | string | Gets or sets the tracked resource id corresponding to the inventory resource. |
moName | string | Gets or sets the vCenter Managed Object name for the inventory item. |
moRefId | string | Gets or sets the MoRef (Managed Object Reference) ID for the inventory item. |
provisioningState | string | Gets the provisioning state. Known values are: "Succeeded", "Failed", "Canceled", "Provisioning", "Updating", "Deleting", "Accepted", and "Created". |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | resource_group_name, vcenter_name, inventory_item_name, subscription_id | Gets InventoryItem. Implements InventoryItem GET method. | |
list_by_v_center | select | resource_group_name, vcenter_name, subscription_id | Implements GET inventoryItems in a vCenter. Returns the list of inventoryItems of the given vCenter. | |
create | insert | resource_group_name, vcenter_name, inventory_item_name, subscription_id, properties | Implements InventoryItem PUT method. Create Or Update InventoryItem. | |
delete | delete | resource_group_name, vcenter_name, inventory_item_name, subscription_id | Deletes an inventoryItem. Implements inventoryItem DELETE method. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
inventory_item_name | string | Name of the inventoryItem. Required. |
resource_group_name | string | The Resource Group Name. Required. |
subscription_id | string | |
vcenter_name | string | Name of the vCenter. Required. |
SELECT examples
- get
- list_by_v_center
Gets InventoryItem. Implements InventoryItem GET method.
SELECT
id,
name,
inventoryType,
kind,
managedResourceId,
moName,
moRefId,
provisioningState,
systemData,
type
FROM azure_isv.connectedvmware.inventory_items
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND vcenter_name = '{{ vcenter_name }}' -- required
AND inventory_item_name = '{{ inventory_item_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Implements GET inventoryItems in a vCenter. Returns the list of inventoryItems of the given vCenter.
SELECT
id,
name,
inventoryType,
kind,
managedResourceId,
moName,
moRefId,
provisioningState,
systemData,
type
FROM azure_isv.connectedvmware.inventory_items
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND vcenter_name = '{{ vcenter_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create
- Manifest
Implements InventoryItem PUT method. Create Or Update InventoryItem.
INSERT INTO azure_isv.connectedvmware.inventory_items (
kind,
properties,
resource_group_name,
vcenter_name,
inventory_item_name,
subscription_id
)
SELECT
'{{ kind }}',
'{{ properties }}' /* required */,
'{{ resource_group_name }}',
'{{ vcenter_name }}',
'{{ inventory_item_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
kind,
properties,
systemData,
type
;
# Description fields are for documentation purposes
- name: inventory_items
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the inventory_items resource.
- name: vcenter_name
value: "{{ vcenter_name }}"
description: Required parameter for the inventory_items resource.
- name: inventory_item_name
value: "{{ inventory_item_name }}"
description: Required parameter for the inventory_items resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the inventory_items resource.
- name: kind
value: "{{ kind }}"
description: |
Metadata used by portal/tooling/etc to render different UX experiences for resources of the same type; e.g. ApiApps are a kind of Microsoft.Web/sites type. If supported, the resource provider must validate and persist this value.
- name: properties
value:
inventoryType: "{{ inventoryType }}"
managedResourceId: "{{ managedResourceId }}"
moRefId: "{{ moRefId }}"
moName: "{{ moName }}"
DELETE examples
- delete
Deletes an inventoryItem. Implements inventoryItem DELETE method.
DELETE FROM azure_isv.connectedvmware.inventory_items
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND vcenter_name = '{{ vcenter_name }}' --required
AND inventory_item_name = '{{ inventory_item_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;