Asset Filters - Create Or Update
Create or update an Asset Filter
Creates or updates an Asset Filter associated with the specified Asset.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Media/mediaServices/{accountName}/assets/{assetName}/assetFilters/{filterName}?api-version=2022-08-01
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
account
|
path | True |
string |
The Media Services account name. |
asset
|
path | True |
string |
The Asset name. |
filter
|
path | True |
string |
The Asset Filter name |
resource
|
path | True |
string |
The name of the resource group within the Azure subscription. |
subscription
|
path | True |
string |
The unique identifier for a Microsoft Azure subscription. |
api-version
|
query | True |
string |
The version of the API to be used with the client request. |
Request Body
Name | Type | Description |
---|---|---|
properties.firstQuality |
The first quality. |
|
properties.presentationTimeRange |
The presentation time range. |
|
properties.tracks |
The tracks selection conditions. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
OK |
|
201 Created |
Created |
|
Other Status Codes |
Detailed error information. |
Examples
Create an Asset Filter
Sample request
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaServices/contosomedia/assets/ClimbingMountRainer/assetFilters/newAssetFilter?api-version=2022-08-01
{
"properties": {
"presentationTimeRange": {
"startTimestamp": 0,
"endTimestamp": 170000000,
"presentationWindowDuration": 9223372036854774806,
"liveBackoffDuration": 0,
"timescale": 10000000,
"forceEndTimestamp": false
},
"firstQuality": {
"bitrate": 128000
},
"tracks": [
{
"trackSelections": [
{
"property": "Type",
"operation": "Equal",
"value": "Audio"
},
{
"property": "Language",
"operation": "NotEqual",
"value": "en"
},
{
"property": "FourCC",
"operation": "NotEqual",
"value": "EC-3"
}
]
},
{
"trackSelections": [
{
"property": "Type",
"operation": "Equal",
"value": "Video"
},
{
"property": "Bitrate",
"operation": "Equal",
"value": "3000000-5000000"
}
]
}
]
}
}
Sample response
{
"name": "newAssetFilter",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountRainer/assetFilters/newAssetFilter",
"type": "Microsoft.Media/mediaservices/assets/assetFilters",
"properties": {
"presentationTimeRange": {
"startTimestamp": 0,
"endTimestamp": 170000000,
"presentationWindowDuration": 9223372036854774806,
"liveBackoffDuration": 0,
"timescale": 10000000,
"forceEndTimestamp": false
},
"firstQuality": {
"bitrate": 128000
},
"tracks": [
{
"trackSelections": [
{
"property": "Type",
"value": "Audio",
"operation": "Equal"
},
{
"property": "Language",
"value": "en",
"operation": "NotEqual"
},
{
"property": "FourCC",
"value": "EC-3",
"operation": "NotEqual"
}
]
},
{
"trackSelections": [
{
"property": "Type",
"value": "Video",
"operation": "Equal"
},
{
"property": "Bitrate",
"value": "3000000-5000000",
"operation": "Equal"
}
]
}
]
}
}
{
"name": "newAssetFilter",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contosorg/providers/Microsoft.Media/mediaservices/contosomedia/assets/ClimbingMountRainer/assetFilters/newAssetFilter",
"type": "Microsoft.Media/mediaservices/assets/assetFilters",
"properties": {
"presentationTimeRange": {
"startTimestamp": 0,
"endTimestamp": 170000000,
"presentationWindowDuration": 9223372036854774806,
"liveBackoffDuration": 0,
"timescale": 10000000,
"forceEndTimestamp": false
},
"firstQuality": {
"bitrate": 128000
},
"tracks": [
{
"trackSelections": [
{
"property": "Type",
"value": "Audio",
"operation": "Equal"
},
{
"property": "Language",
"value": "en",
"operation": "NotEqual"
},
{
"property": "FourCC",
"value": "EC-3",
"operation": "NotEqual"
}
]
},
{
"trackSelections": [
{
"property": "Type",
"value": "Video",
"operation": "Equal"
},
{
"property": "Bitrate",
"value": "3000000-5000000",
"operation": "Equal"
}
]
}
]
}
}
Definitions
Name | Description |
---|---|
Asset |
An Asset Filter. |
created |
The type of identity that created the resource. |
Error |
The resource management error additional info. |
Error |
The error detail. |
Error |
Error response |
Filter |
The track property condition operation. |
Filter |
The class to specify one track property condition. |
Filter |
The track property type. |
Filter |
Representing a list of FilterTrackPropertyConditions to select a track. The filters are combined using a logical AND operation. |
First |
Filter First Quality |
Presentation |
The presentation time range, this is asset related and not recommended for Account Filter. |
system |
Metadata pertaining to creation and last modification of the resource. |
AssetFilter
An Asset Filter.
Name | Type | Description |
---|---|---|
id |
string |
Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} |
name |
string |
The name of the resource |
properties.firstQuality |
The first quality. |
|
properties.presentationTimeRange |
The presentation time range. |
|
properties.tracks |
The tracks selection conditions. |
|
systemData |
The system metadata relating to this resource. |
|
type |
string |
The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" |
createdByType
The type of identity that created the resource.
Name | Type | Description |
---|---|---|
Application |
string |
|
Key |
string |
|
ManagedIdentity |
string |
|
User |
string |
ErrorAdditionalInfo
The resource management error additional info.
Name | Type | Description |
---|---|---|
info |
object |
The additional info. |
type |
string |
The additional info type. |
ErrorDetail
The error detail.
Name | Type | Description |
---|---|---|
additionalInfo |
The error additional info. |
|
code |
string |
The error code. |
details |
The error details. |
|
message |
string |
The error message. |
target |
string |
The error target. |
ErrorResponse
Error response
Name | Type | Description |
---|---|---|
error |
The error object. |
FilterTrackPropertyCompareOperation
The track property condition operation.
Name | Type | Description |
---|---|---|
Equal |
string |
The equal operation. |
NotEqual |
string |
The not equal operation. |
FilterTrackPropertyCondition
The class to specify one track property condition.
Name | Type | Description |
---|---|---|
operation |
The track property condition operation. |
|
property |
The track property type. |
|
value |
string |
The track property value. |
FilterTrackPropertyType
The track property type.
Name | Type | Description |
---|---|---|
Bitrate |
string |
The bitrate. |
FourCC |
string |
The fourCC. |
Language |
string |
The language. |
Name |
string |
The name. |
Type |
string |
The type. |
Unknown |
string |
The unknown track property type. |
FilterTrackSelection
Representing a list of FilterTrackPropertyConditions to select a track. The filters are combined using a logical AND operation.
Name | Type | Description |
---|---|---|
trackSelections |
The track selections. |
FirstQuality
Filter First Quality
Name | Type | Description |
---|---|---|
bitrate |
integer |
The first quality bitrate. |
PresentationTimeRange
The presentation time range, this is asset related and not recommended for Account Filter.
Name | Type | Description |
---|---|---|
endTimestamp |
integer |
The absolute end time boundary. |
forceEndTimestamp |
boolean |
The indicator of forcing existing of end time stamp. |
liveBackoffDuration |
integer |
The relative to end right edge. |
presentationWindowDuration |
integer |
The relative to end sliding window. |
startTimestamp |
integer |
The absolute start time boundary. |
timescale |
integer |
The time scale of time stamps. |
systemData
Metadata pertaining to creation and last modification of the resource.
Name | Type | Description |
---|---|---|
createdAt |
string |
The timestamp of resource creation (UTC). |
createdBy |
string |
The identity that created the resource. |
createdByType |
The type of identity that created the resource. |
|
lastModifiedAt |
string |
The timestamp of resource last modification (UTC) |
lastModifiedBy |
string |
The identity that last modified the resource. |
lastModifiedByType |
The type of identity that last modified the resource. |