assets
Creates, updates, deletes, gets or lists a assets
resource.
Overview
Name | assets |
Type | Resource |
Id | google.migrationcenter.assets |
Fields
Name | Datatype | Description |
---|---|---|
name | string | Output only. The full name of the asset. |
assignedGroups | array | Output only. The list of groups that the asset is assigned to. |
attributes | object | Generic asset attributes. |
createTime | string | Output only. The timestamp when the asset was created. |
insightList | object | Message containing insights list. |
labels | object | Labels as key value pairs. |
machineDetails | object | Details of a machine. |
performanceData | object | Performance data for an asset. |
sources | array | Output only. The list of sources contributing to the asset. |
updateTime | string | Output only. The timestamp when the asset was last updated. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | assetsId, locationsId, projectsId | Gets the details of an asset. |
list | SELECT | locationsId, projectsId | Lists all the assets in a given project and location. |
batch_delete | DELETE | locationsId, projectsId | Deletes list of Assets. |
delete | DELETE | assetsId, locationsId, projectsId | Deletes an asset. |
batch_update | UPDATE | locationsId, projectsId | Updates the parameters of a list of assets. |
patch | UPDATE | assetsId, locationsId, projectsId | Updates the parameters of an asset. |
aggregate_values | EXEC | locationsId, projectsId | Aggregates the requested fields based on provided function. |
report_asset_frames | EXEC | locationsId, projectsId | Reports a set of frames. |
SELECT
examples
Lists all the assets in a given project and location.
SELECT
name,
assignedGroups,
attributes,
createTime,
insightList,
labels,
machineDetails,
performanceData,
sources,
updateTime
FROM google.migrationcenter.assets
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';
UPDATE
example
Updates a assets
resource.
/*+ update */
UPDATE google.migrationcenter.assets
SET
requests = '{{ requests }}'
WHERE
locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';
DELETE
example
Deletes the specified assets
resource.
/*+ delete */
DELETE FROM google.migrationcenter.assets
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';