Lingua

CostControlProperties Class

Definition

The consumption budget and its traffic selection, notifications, and enforcement actions. A cost control applies within its owner's scope.

public class CostControlProperties : System.ClientModel.Primitives.IJsonModel<Azure.ResourceManager.CognitiveServices.Models.CostControlProperties>, System.ClientModel.Primitives.IPersistableModel<Azure.ResourceManager.CognitiveServices.Models.CostControlProperties>
type CostControlProperties = class
    interface IJsonModel<CostControlProperties>
    interface IPersistableModel<CostControlProperties>
Public Class CostControlProperties
Implements IJsonModel(Of CostControlProperties), IPersistableModel(Of CostControlProperties)
Inheritance
CostControlProperties
Implements

Constructors

Name Description
CostControlProperties(CostControlCategory, Double, CostControlTimeGrain, CostControlTimePeriod)

Initializes a new instance of CostControlProperties.

Properties

Name Description
Amount

The positive budget amount, measured in United States dollars for the Cost category or in tokens for the Tokens category. Token amounts must be whole numbers.

Category

Whether the budget measures estimated cost in United States dollars or token consumption. This category cannot be changed after creation.

Filter

Optional traffic selection. Omission selects all eligible traffic within the owner's scope.

Grouping

Optional additional partitioning of consumption. Omission or an empty array uses one counter for the owning account or Foundry project. Responses omit owner-default grouping. A project-owned control cannot explicitly group by project.

Notifications

Alert notifications keyed by nonempty, case-insensitively unique names. Each notification supplies its own Event Grid connection. PUT and the complete merged PATCH result may contain at most one notification, including disabled notifications. Omission on creation creates no notifications.

Provider

The resource provider for this budget. Omission selects Microsoft.CognitiveServices; responses return that value.

ProviderActions

Blocking actions keyed by nonempty, case-insensitively unique names. PUT and the complete merged PATCH result may contain at most one Block action, independently of the notification limit. Omission on creation creates no blocking actions.

TimeGrain

The calendar-aligned UTC interval at which consumption counters renew within the validity window.

TimePeriod

The finite UTC validity window during which the control applies.

Methods

Name Description
JsonModelCreateCore(Utf8JsonReader, ModelReaderWriterOptions)
JsonModelWriteCore(Utf8JsonWriter, ModelReaderWriterOptions)
PersistableModelCreateCore(BinaryData, ModelReaderWriterOptions)
PersistableModelWriteCore(ModelReaderWriterOptions)

Explicit Interface Implementations

Name Description
IJsonModel<CostControlProperties>.Create(Utf8JsonReader, ModelReaderWriterOptions)
IJsonModel<CostControlProperties>.Write(Utf8JsonWriter, ModelReaderWriterOptions)
IPersistableModel<CostControlProperties>.Create(BinaryData, ModelReaderWriterOptions)
IPersistableModel<CostControlProperties>.GetFormatFromOptions(ModelReaderWriterOptions)
IPersistableModel<CostControlProperties>.Write(ModelReaderWriterOptions)

Applies to