assets
Creates, updates, deletes, gets or lists a assets
resource.
Overview
Name | assets |
Type | Resource |
Id | azure.media_services.assets |
Fields
- vw_assets
- assets
Name | Datatype | Description |
---|---|---|
description | text | field from the properties object |
accountName | text | field from the properties object |
alternate_id | text | field from the properties object |
assetName | text | field from the properties object |
asset_id | text | field from the properties object |
container | text | field from the properties object |
created | text | field from the properties object |
encryption_scope | text | field from the properties object |
last_modified | text | field from the properties object |
resourceGroupName | text | field from the properties object |
storage_account_name | text | field from the properties object |
storage_encryption_format | text | field from the properties object |
subscriptionId | text | field from the properties object |
system_data | text | field from the properties object |
Name | Datatype | Description |
---|---|---|
properties | object | The Asset properties. |
systemData | object | Metadata pertaining to creation and last modification of the resource. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | accountName, assetName, resourceGroupName, subscriptionId | Get the details of an Asset in the Media Services account |
list | SELECT | accountName, resourceGroupName, subscriptionId | List Assets in the Media Services account with optional filtering and ordering |
create_or_update | INSERT | accountName, assetName, resourceGroupName, subscriptionId | Creates or updates an Asset in the Media Services account |
delete | DELETE | accountName, assetName, resourceGroupName, subscriptionId | Deletes an Asset in the Media Services account |
update | UPDATE | accountName, assetName, resourceGroupName, subscriptionId | Updates an existing Asset in the Media Services account |
SELECT
examples
List Assets in the Media Services account with optional filtering and ordering
- vw_assets
- assets
SELECT
description,
accountName,
alternate_id,
assetName,
asset_id,
container,
created,
encryption_scope,
last_modified,
resourceGroupName,
storage_account_name,
storage_encryption_format,
subscriptionId,
system_data
FROM azure.media_services.vw_assets
WHERE accountName = '{{ accountName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
SELECT
properties,
systemData
FROM azure.media_services.assets
WHERE accountName = '{{ accountName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new assets
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.media_services.assets (
accountName,
assetName,
resourceGroupName,
subscriptionId,
properties
)
SELECT
'{{ accountName }}',
'{{ assetName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: properties
value:
- name: assetId
value: string
- name: created
value: string
- name: lastModified
value: string
- name: alternateId
value: string
- name: description
value: string
- name: container
value: string
- name: storageAccountName
value: string
- name: storageEncryptionFormat
value: string
- name: encryptionScope
value: string
- name: systemData
value:
- name: createdBy
value: string
- name: createdByType
value: string
- name: createdAt
value: string
- name: lastModifiedBy
value: string
- name: lastModifiedByType
value: string
- name: lastModifiedAt
value: string
UPDATE
example
Updates a assets
resource.
/*+ update */
UPDATE azure.media_services.assets
SET
properties = '{{ properties }}'
WHERE
accountName = '{{ accountName }}'
AND assetName = '{{ assetName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
DELETE
example
Deletes the specified assets
resource.
/*+ delete */
DELETE FROM azure.media_services.assets
WHERE accountName = '{{ accountName }}'
AND assetName = '{{ assetName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';