Assets - List
使用選擇性篩選和排序列出媒體服務帳戶中的資產
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Media/mediaServices/{accountName}/assets?api-version=2022-08-01
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Media/mediaServices/{accountName}/assets?api-version=2022-08-01&$filter={$filter}&$top={$top}&$orderby={$orderby}
URI 參數
名稱 | 位於 | 必要 | 類型 | Description |
---|---|---|---|---|
account
|
path | True |
string |
媒體服務帳戶名稱。 |
resource
|
path | True |
string |
Azure 訂用帳戶內的資源組名。 |
subscription
|
path | True |
string |
Microsoft Azure 訂用帳戶的唯一標識符。 |
api-version
|
query | True |
string |
要與用戶端要求搭配使用的 API 版本。 |
$filter
|
query |
string |
限制傳回的專案集。 |
|
$orderby
|
query |
string |
指定應該排序結果集合的索引鍵。 |
|
$top
|
query |
integer int32 |
指定非負整數 n,限制從集合傳回的項目數。 服務會傳回最多但大於指定值 n 的可用項目數目。 |
回應
名稱 | 類型 | Description |
---|---|---|
200 OK |
確定 |
|
Other Status Codes |
詳細的錯誤資訊。 |
範例
List all Assets |
List Asset created in a date range |
List Asset ordered by date |
List all Assets
範例要求
範例回覆
{
"value": [
{
"name": "ClimbingLittleTahoma",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingLittleTahoma",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "e6c7ee55-d1f5-48bc-9c36-2d2157aadbbe",
"created": "2012-04-01T00:00:00Z",
"lastModified": "2017-11-01T00:00:00Z",
"alternateId": "CLIMB00003",
"description": "A documentary showing the ascent of Little Tahoma",
"container": "asset-e6c7ee55-d1f5-48bc-9c36-2d2157aadbbe",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountAdams",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountAdams",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "1b648c1a-2268-461d-a1da-742bde23db40",
"created": "2013-02-01T00:00:00Z",
"lastModified": "2017-11-01T00:00:00Z",
"alternateId": "CLIMB00002",
"description": "A documentary showing the ascent of Mount Adams",
"container": "asset-1b648c1a-2268-461d-a1da-742bde23db40",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountBaker",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountBaker",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "89af1750-e681-4fbe-8c4c-9a5567867a6b",
"created": "2011-02-01T00:00:00Z",
"lastModified": "2017-11-01T00:00:00Z",
"alternateId": "CLIMB00004",
"description": "A documentary showing the ascent of Mount Baker",
"container": "asset-89af1750-e681-4fbe-8c4c-9a5567867a6b",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountRainer",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountRainer",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "258878ef-fe05-4518-988f-052e86dc19f6",
"created": "2018-08-08T18:29:24.3948982Z",
"lastModified": "2018-08-08T21:29:24.3948982Z",
"alternateId": "altClimbingMountRainer",
"description": "descClimbingMountRainer",
"container": "testasset0",
"storageAccountName": "storage0",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountRainier",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountRainier",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "f8eea45c-b814-44c2-9c42-a5174ebdee4c",
"created": "2012-11-01T00:00:00Z",
"lastModified": "2012-11-01T00:00:00Z",
"alternateId": "CLIMB00001",
"description": "A documentary showing the ascent of Mount Rainier",
"container": "asset-f8eea45c-b814-44c2-9c42-a5174ebdee4c",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountSaintHelens",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountSaintHelens",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "14d58c40-ec1f-446c-b041-f5cff949bd1d",
"created": "2013-03-01T00:00:00Z",
"lastModified": "2013-04-01T00:00:00Z",
"alternateId": "CLIMB00005",
"description": "A documentary showing the ascent of Saint Helens",
"container": "asset-14d58c40-ec1f-446c-b041-f5cff949bd1d",
"storageEncryptionFormat": "MediaStorageClientEncryption"
}
}
]
}
List Asset created in a date range
範例要求
GET https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaServices/contosomedia/assets?api-version=2022-08-01&$filter=properties/created gt 2012-06-01 and properties/created lt 2013-07-01&$orderby=properties/created
範例回覆
{
"value": [
{
"name": "ClimbingMountRainier",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountRainier",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "f8eea45c-b814-44c2-9c42-a5174ebdee4c",
"created": "2012-11-01T00:00:00Z",
"lastModified": "2012-11-01T00:00:00Z",
"alternateId": "CLIMB00001",
"description": "A documentary showing the ascent of Mount Rainier",
"container": "asset-f8eea45c-b814-44c2-9c42-a5174ebdee4c",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountAdams",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountAdams",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "1b648c1a-2268-461d-a1da-742bde23db40",
"created": "2013-02-01T00:00:00Z",
"lastModified": "2017-11-01T00:00:00Z",
"alternateId": "CLIMB00002",
"description": "A documentary showing the ascent of Mount Adams",
"container": "asset-1b648c1a-2268-461d-a1da-742bde23db40",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountSaintHelens",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountSaintHelens",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "14d58c40-ec1f-446c-b041-f5cff949bd1d",
"created": "2013-03-01T00:00:00Z",
"lastModified": "2013-04-01T00:00:00Z",
"alternateId": "CLIMB00005",
"description": "A documentary showing the ascent of Saint Helens",
"container": "asset-14d58c40-ec1f-446c-b041-f5cff949bd1d",
"storageEncryptionFormat": "MediaStorageClientEncryption"
}
}
]
}
List Asset ordered by date
範例要求
範例回覆
{
"value": [
{
"name": "ClimbingMountBaker",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountBaker",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "89af1750-e681-4fbe-8c4c-9a5567867a6b",
"created": "2011-02-01T00:00:00Z",
"lastModified": "2017-11-01T00:00:00Z",
"alternateId": "CLIMB00004",
"description": "A documentary showing the ascent of Mount Baker",
"container": "asset-89af1750-e681-4fbe-8c4c-9a5567867a6b",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingLittleTahoma",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingLittleTahoma",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "e6c7ee55-d1f5-48bc-9c36-2d2157aadbbe",
"created": "2012-04-01T00:00:00Z",
"lastModified": "2017-11-01T00:00:00Z",
"alternateId": "CLIMB00003",
"description": "A documentary showing the ascent of Little Tahoma",
"container": "asset-e6c7ee55-d1f5-48bc-9c36-2d2157aadbbe",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountRainier",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountRainier",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "f8eea45c-b814-44c2-9c42-a5174ebdee4c",
"created": "2012-11-01T00:00:00Z",
"lastModified": "2012-11-01T00:00:00Z",
"alternateId": "CLIMB00001",
"description": "A documentary showing the ascent of Mount Rainier",
"container": "asset-f8eea45c-b814-44c2-9c42-a5174ebdee4c",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountAdams",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountAdams",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "1b648c1a-2268-461d-a1da-742bde23db40",
"created": "2013-02-01T00:00:00Z",
"lastModified": "2017-11-01T00:00:00Z",
"alternateId": "CLIMB00002",
"description": "A documentary showing the ascent of Mount Adams",
"container": "asset-1b648c1a-2268-461d-a1da-742bde23db40",
"storageEncryptionFormat": "None"
}
},
{
"name": "ClimbingMountSaintHelens",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountSaintHelens",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "14d58c40-ec1f-446c-b041-f5cff949bd1d",
"created": "2013-03-01T00:00:00Z",
"lastModified": "2013-04-01T00:00:00Z",
"alternateId": "CLIMB00005",
"description": "A documentary showing the ascent of Saint Helens",
"container": "asset-14d58c40-ec1f-446c-b041-f5cff949bd1d",
"storageEncryptionFormat": "MediaStorageClientEncryption"
}
},
{
"name": "ClimbingMountRainer",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountRainer",
"type": "Microsoft.Media/mediaservices/assets",
"properties": {
"assetId": "8cdacfe5-8473-413a-9aec-dd2a478b37c8",
"created": "2018-08-08T18:29:25.0514734Z",
"lastModified": "2018-08-08T21:29:25.0514734Z",
"alternateId": "altClimbingMountRainer",
"description": "descClimbingMountRainer",
"container": "testasset0",
"storageAccountName": "storage0",
"storageEncryptionFormat": "None"
}
}
]
}
定義
名稱 | Description |
---|---|
Asset |
資產。 |
Asset |
資產專案的集合。 |
Asset |
資產加密格式。 None 或 MediaStorageEncryption 其中一個。 |
created |
建立資源的身分識別類型。 |
Error |
資源管理錯誤其他資訊。 |
Error |
錯誤詳細數據。 |
Error |
錯誤回應 |
system |
與建立和上次修改資源相關的元數據。 |
Asset
資產。
名稱 | 類型 | Description |
---|---|---|
id |
string |
資源的完整資源識別碼。 例如 - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} |
name |
string |
資源的名稱 |
properties.alternateId |
string |
資產的替代 ID。 |
properties.assetId |
string |
資產識別碼。 |
properties.container |
string |
資產 Blob 容器的名稱。 |
properties.created |
string |
資產的建立日期。 |
properties.description |
string |
資產描述。 |
properties.lastModified |
string |
資產的上次修改日期。 |
properties.storageAccountName |
string |
儲存體帳戶的名稱。 |
properties.storageEncryptionFormat |
資產加密格式。 None 或 MediaStorageEncryption 其中一個。 |
|
systemData |
與此資源相關的系統元數據。 |
|
type |
string |
資源類型。 例如“Microsoft.Compute/virtualMachines” 或 “Microsoft.Storage/storageAccounts” |
AssetCollection
資產專案的集合。
名稱 | 類型 | Description |
---|---|---|
@odata.nextLink |
string |
當集合包含太多結果以傳回回應) 時,集合 (下一頁的連結。 |
value |
Asset[] |
資產專案的集合。 |
AssetStorageEncryptionFormat
資產加密格式。 None 或 MediaStorageEncryption 其中一個。
名稱 | 類型 | Description |
---|---|---|
MediaStorageClientEncryption |
string |
資產會使用媒體服務用戶端加密進行加密。 |
None |
string |
資產不會使用用戶端記憶體加密 (這是新資產唯一允許的值) 。 |
createdByType
建立資源的身分識別類型。
名稱 | 類型 | Description |
---|---|---|
Application |
string |
|
Key |
string |
|
ManagedIdentity |
string |
|
User |
string |
ErrorAdditionalInfo
資源管理錯誤其他資訊。
名稱 | 類型 | Description |
---|---|---|
info |
object |
其他資訊。 |
type |
string |
其他信息類型。 |
ErrorDetail
錯誤詳細數據。
名稱 | 類型 | Description |
---|---|---|
additionalInfo |
錯誤其他資訊。 |
|
code |
string |
錯誤碼。 |
details |
錯誤詳細資料。 |
|
message |
string |
錯誤訊息。 |
target |
string |
錯誤目標。 |
ErrorResponse
錯誤回應
名稱 | 類型 | Description |
---|---|---|
error |
錯誤物件。 |
systemData
與建立和上次修改資源相關的元數據。
名稱 | 類型 | Description |
---|---|---|
createdAt |
string |
資源建立的時間戳 (UTC) 。 |
createdBy |
string |
建立資源的身分識別。 |
createdByType |
建立資源的身分識別類型。 |
|
lastModifiedAt |
string |
上次修改的資源時間戳 (UTC) |
lastModifiedBy |
string |
上次修改資源的身分識別。 |
lastModifiedByType |
上次修改資源的身分識別類型。 |