// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
// Code generated by Microsoft (R) Go Code Generator. DO NOT EDIT.

package armdeviceregistry

import "time"

// Asset definition.
type Asset struct {
	// REQUIRED; The extended location.
	ExtendedLocation *ExtendedLocation

	// REQUIRED; The geo-location where the resource lives
	Location *string

	// The resource-specific properties for this resource.
	Properties *AssetProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

// AssetEndpointProfile - Asset Endpoint Profile definition.
type AssetEndpointProfile struct {
	// REQUIRED; The extended location.
	ExtendedLocation *ExtendedLocation

	// REQUIRED; The geo-location where the resource lives
	Location *string

	// The resource-specific properties for this resource.
	Properties *AssetEndpointProfileProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

// AssetEndpointProfileListResult - The response of a AssetEndpointProfile list operation.
type AssetEndpointProfileListResult struct {
	// REQUIRED; The AssetEndpointProfile items on this page
	Value []*AssetEndpointProfile

	// The link to the next page of items
	NextLink *string
}

// AssetEndpointProfileProperties - Defines the Asset Endpoint Profile properties.
type AssetEndpointProfileProperties struct {
	// REQUIRED; Defines the configuration for the connector type that is being used with the endpoint profile.
	EndpointProfileType *string

	// REQUIRED; The local valid URI specifying the network address/DNS name of a southbound device. The scheme part of the targetAddress
	// URI specifies the type of the device. The additionalConfiguration field holds further connector type specific configuration.
	TargetAddress *string

	// Stringified JSON that contains connectivity type specific further configuration (e.g. OPC UA, Modbus, ONVIF).
	AdditionalConfiguration *string

	// Defines the client authentication mechanism to the server.
	Authentication *Authentication

	// Reference to a discovered asset endpoint profile. Populated only if the asset endpoint profile has been created from discovery
	// flow. Discovered asset endpoint profile name must be provided.
	DiscoveredAssetEndpointProfileRef *string

	// READ-ONLY; Provisioning state of the resource.
	ProvisioningState *ProvisioningState

	// READ-ONLY; Read only object to reflect changes that have occurred on the Edge. Similar to Kubernetes status property for
	// custom resources.
	Status *AssetEndpointProfileStatus

	// READ-ONLY; Globally unique, immutable, non-reusable id.
	UUID *string
}

// AssetEndpointProfileStatus - Defines the asset endpoint profile status properties.
type AssetEndpointProfileStatus struct {
	// READ-ONLY; Array object to transfer and persist errors that originate from the Edge.
	Errors []*AssetEndpointProfileStatusError
}

// AssetEndpointProfileStatusError - Defines the asset endpoint profile status error properties.
type AssetEndpointProfileStatusError struct {
	// READ-ONLY; Error code for classification of errors (ex: 400, 404, 500, etc.).
	Code *int32

	// READ-ONLY; Human readable helpful error message to provide additional context for error (ex: “targetAddress 'foo' is not
	// a valid url”).
	Message *string
}

// AssetEndpointProfileUpdate - The type used for update operations of the AssetEndpointProfile.
type AssetEndpointProfileUpdate struct {
	// The resource-specific properties for this resource.
	Properties *AssetEndpointProfileUpdateProperties

	// Resource tags.
	Tags map[string]*string
}

// AssetEndpointProfileUpdateProperties - The updatable properties of the AssetEndpointProfile.
type AssetEndpointProfileUpdateProperties struct {
	// Stringified JSON that contains connectivity type specific further configuration (e.g. OPC UA, Modbus, ONVIF).
	AdditionalConfiguration *string

	// Defines the client authentication mechanism to the server.
	Authentication *Authentication

	// Defines the configuration for the connector type that is being used with the endpoint profile.
	EndpointProfileType *string

	// The local valid URI specifying the network address/DNS name of a southbound device. The scheme part of the targetAddress
	// URI specifies the type of the device. The additionalConfiguration field holds further connector type specific configuration.
	TargetAddress *string
}

// AssetListResult - The response of a Asset list operation.
type AssetListResult struct {
	// REQUIRED; The Asset items on this page
	Value []*Asset

	// The link to the next page of items
	NextLink *string
}

// AssetProperties - Defines the asset properties.
type AssetProperties struct {
	// REQUIRED; A reference to the asset endpoint profile (connection information) used by brokers to connect to an endpoint
	// that provides data points for this asset. Must provide asset endpoint profile name.
	AssetEndpointProfileRef *string

	// A set of key-value pairs that contain custom attributes set by the customer.
	Attributes map[string]any

	// Array of datasets that are part of the asset. Each dataset describes the data points that make up the set.
	Datasets []*Dataset

	// Stringified JSON that contains connector-specific default configuration for all datasets. Each dataset can have its own
	// configuration that overrides the default settings here.
	DefaultDatasetsConfiguration *string

	// Stringified JSON that contains connector-specific default configuration for all events. Each event can have its own configuration
	// that overrides the default settings here.
	DefaultEventsConfiguration *string

	// Object that describes the default topic information for the asset.
	DefaultTopic *Topic

	// Human-readable description of the asset.
	Description *string

	// Reference to a list of discovered assets. Populated only if the asset has been created from discovery flow. Discovered
	// asset names must be provided.
	DiscoveredAssetRefs []*string

	// Human-readable display name.
	DisplayName *string

	// Reference to the documentation.
	DocumentationURI *string

	// Enabled/Disabled status of the asset.
	Enabled *bool

	// Array of events that are part of the asset. Each event can have per-event configuration.
	Events []*Event

	// Asset id provided by the customer.
	ExternalAssetID *string

	// Revision number of the hardware.
	HardwareRevision *string

	// Asset manufacturer name.
	Manufacturer *string

	// Asset manufacturer URI.
	ManufacturerURI *string

	// Asset model name.
	Model *string

	// Asset product code.
	ProductCode *string

	// Asset serial number.
	SerialNumber *string

	// Revision number of the software.
	SoftwareRevision *string

	// READ-ONLY; Provisioning state of the resource.
	ProvisioningState *ProvisioningState

	// READ-ONLY; Read only object to reflect changes that have occurred on the Edge. Similar to Kubernetes status property for
	// custom resources.
	Status *AssetStatus

	// READ-ONLY; Globally unique, immutable, non-reusable id.
	UUID *string

	// READ-ONLY; An integer that is incremented each time the resource is modified.
	Version *int64
}

// AssetStatus - Defines the asset status properties.
type AssetStatus struct {
	// READ-ONLY; Array of dataset statuses that describe the status of each dataset.
	Datasets []*AssetStatusDataset

	// READ-ONLY; Array object to transfer and persist errors that originate from the Edge.
	Errors []*AssetStatusError

	// READ-ONLY; Array of event statuses that describe the status of each event.
	Events []*AssetStatusEvent

	// READ-ONLY; A read only incremental counter indicating the number of times the configuration has been modified from the
	// perspective of the current actual (Edge) state of the Asset. Edge would be the only writer of this value and would sync
	// back up to the cloud. In steady state, this should equal version.
	Version *int64
}

// AssetStatusDataset - Defines the asset status dataset properties.
type AssetStatusDataset struct {
	// READ-ONLY; The name of the dataset. Must be unique within the status.datasets array. This name is used to correlate between
	// the spec and status dataset information.
	Name *string

	// READ-ONLY; The message schema reference object.
	MessageSchemaReference *MessageSchemaReference
}

// AssetStatusError - Defines the asset status error properties.
type AssetStatusError struct {
	// READ-ONLY; Error code for classification of errors (ex: 400, 404, 500, etc.).
	Code *int32

	// READ-ONLY; Human readable helpful error message to provide additional context for error (ex: “capability Id 'foo' does
	// not exist”).
	Message *string
}

// AssetStatusEvent - Defines the asset status event properties.
type AssetStatusEvent struct {
	// READ-ONLY; The name of the event. Must be unique within the status.events array. This name is used to correlate between
	// the spec and status event information.
	Name *string

	// READ-ONLY; The message schema reference object.
	MessageSchemaReference *MessageSchemaReference
}

// AssetUpdate - The type used for update operations of the Asset.
type AssetUpdate struct {
	// The resource-specific properties for this resource.
	Properties *AssetUpdateProperties

	// Resource tags.
	Tags map[string]*string
}

// AssetUpdateProperties - The updatable properties of the Asset.
type AssetUpdateProperties struct {
	// A set of key-value pairs that contain custom attributes set by the customer.
	Attributes map[string]any

	// Array of datasets that are part of the asset. Each dataset describes the data points that make up the set.
	Datasets []*Dataset

	// Stringified JSON that contains connector-specific default configuration for all datasets. Each dataset can have its own
	// configuration that overrides the default settings here.
	DefaultDatasetsConfiguration *string

	// Stringified JSON that contains connector-specific default configuration for all events. Each event can have its own configuration
	// that overrides the default settings here.
	DefaultEventsConfiguration *string

	// Object that describes the default topic information for the asset.
	DefaultTopic *Topic

	// Human-readable description of the asset.
	Description *string

	// Human-readable display name.
	DisplayName *string

	// Reference to the documentation.
	DocumentationURI *string

	// Enabled/Disabled status of the asset.
	Enabled *bool

	// Array of events that are part of the asset. Each event can have per-event configuration.
	Events []*Event

	// Revision number of the hardware.
	HardwareRevision *string

	// Asset manufacturer name.
	Manufacturer *string

	// Asset manufacturer URI.
	ManufacturerURI *string

	// Asset model name.
	Model *string

	// Asset product code.
	ProductCode *string

	// Asset serial number.
	SerialNumber *string

	// Revision number of the software.
	SoftwareRevision *string
}

// Authentication - Definition of the client authentication mechanism to the server.
type Authentication struct {
	// REQUIRED; Defines the method to authenticate the user of the client at the server.
	Method *AuthenticationMethod

	// Defines the username and password references when UsernamePassword user authentication mode is selected.
	UsernamePasswordCredentials *UsernamePasswordCredentials

	// Defines the certificate reference when Certificate user authentication mode is selected.
	X509Credentials *X509Credentials
}

// BillingContainer - billingContainer Model as Azure resource whose sole purpose is to keep track of billables resources
// under a subscription.
type BillingContainer struct {
	// The resource-specific properties for this resource.
	Properties *BillingContainerProperties

	// READ-ONLY; Resource ETag
	Etag *string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
	SystemData *SystemData

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

// BillingContainerListResult - The response of a BillingContainer list operation.
type BillingContainerListResult struct {
	// REQUIRED; The BillingContainer items on this page
	Value []*BillingContainer

	// The link to the next page of items
	NextLink *string
}

// BillingContainerProperties - Defines the billingContainer properties.
type BillingContainerProperties struct {
	// READ-ONLY; Provisioning state of the resource.
	ProvisioningState *ProvisioningState
}

// DataPoint - Defines the data point properties.
type DataPoint struct {
	// REQUIRED; The address of the source of the data in the asset (e.g. URL) so that a client can access the data source on
	// the asset.
	DataSource *string

	// REQUIRED; The name of the data point.
	Name *string

	// Stringified JSON that contains connector-specific configuration for the data point. For OPC UA, this could include configuration
	// like, publishingInterval, samplingInterval, and queueSize.
	DataPointConfiguration *string

	// An indication of how the data point should be mapped to OpenTelemetry.
	ObservabilityMode *DataPointObservabilityMode
}

// Dataset - Defines the dataset properties.
type Dataset struct {
	// REQUIRED; Name of the dataset.
	Name *string

	// Array of data points that are part of the dataset. Each data point can have per-data point configuration.
	DataPoints []*DataPoint

	// Stringified JSON that contains connector-specific JSON string that describes configuration for the specific dataset.
	DatasetConfiguration *string

	// Object that describes the topic information for the specific dataset.
	Topic *Topic
}

// ErrorAdditionalInfo - The resource management error additional info.
type ErrorAdditionalInfo struct {
	// READ-ONLY; The additional info.
	Info any

	// READ-ONLY; The additional info type.
	Type *string
}

// ErrorDetail - The error detail.
type ErrorDetail struct {
	// READ-ONLY; The error additional info.
	AdditionalInfo []*ErrorAdditionalInfo

	// READ-ONLY; The error code.
	Code *string

	// READ-ONLY; The error details.
	Details []*ErrorDetail

	// READ-ONLY; The error message.
	Message *string

	// READ-ONLY; The error target.
	Target *string
}

// Event - Defines the event properties.
type Event struct {
	// REQUIRED; The address of the notifier of the event in the asset (e.g. URL) so that a client can access the event on the
	// asset.
	EventNotifier *string

	// REQUIRED; The name of the event.
	Name *string

	// Stringified JSON that contains connector-specific configuration for the event. For OPC UA, this could include configuration
	// like, publishingInterval, samplingInterval, and queueSize.
	EventConfiguration *string

	// An indication of how the event should be mapped to OpenTelemetry.
	ObservabilityMode *EventObservabilityMode

	// Object that describes the topic information for the specific event.
	Topic *Topic
}

// ExtendedLocation - The extended location.
type ExtendedLocation struct {
	// REQUIRED; The extended location name.
	Name *string

	// REQUIRED; The extended location type.
	Type *string
}

// MessageSchemaReference - Defines the message schema reference properties.
type MessageSchemaReference struct {
	// READ-ONLY; The message schema name.
	SchemaName *string

	// READ-ONLY; The message schema registry namespace.
	SchemaRegistryNamespace *string

	// READ-ONLY; The message schema version.
	SchemaVersion *string
}

// Operation - REST API Operation
//
// Details of a REST API operation, returned from the Resource Provider Operations API
type Operation struct {
	// Localized display information for this particular operation.
	Display *OperationDisplay

	// READ-ONLY; Extensible enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.
	ActionType *ActionType

	// READ-ONLY; Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for Azure
	// Resource Manager/control-plane operations.
	IsDataAction *bool

	// READ-ONLY; The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write",
	// "Microsoft.Compute/virtualMachines/capture/action"
	Name *string

	// READ-ONLY; The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default
	// value is "user,system"
	Origin *Origin
}

// OperationDisplay - Localized display information for and operation.
type OperationDisplay struct {
	// READ-ONLY; The short, localized friendly description of the operation; suitable for tool tips and detailed views.
	Description *string

	// READ-ONLY; The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual
	// Machine", "Restart Virtual Machine".
	Operation *string

	// READ-ONLY; The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft
	// Compute".
	Provider *string

	// READ-ONLY; The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job
	// Schedule Collections".
	Resource *string
}

// OperationListResult - A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to
// get the next set of results.
type OperationListResult struct {
	// REQUIRED; The Operation items on this page
	Value []*Operation

	// The link to the next page of items
	NextLink *string
}

// OperationStatusResult - The current status of an async operation.
type OperationStatusResult struct {
	// REQUIRED; Operation status.
	Status *string

	// The end time of the operation.
	EndTime *time.Time

	// If present, details of the operation error.
	Error *ErrorDetail

	// Fully qualified ID for the async operation.
	ID *string

	// Name of the async operation.
	Name *string

	// The operations list.
	Operations []*OperationStatusResult

	// Percent of the operation that is complete.
	PercentComplete *float64

	// The start time of the operation.
	StartTime *time.Time

	// READ-ONLY; Fully qualified ID of the resource against which the original async operation was started.
	ResourceID *string
}

// SystemData - Metadata pertaining to creation and last modification of the resource.
type SystemData struct {
	// The timestamp of resource creation (UTC).
	CreatedAt *time.Time

	// The identity that created the resource.
	CreatedBy *string

	// The type of identity that created the resource.
	CreatedByType *CreatedByType

	// The timestamp of resource last modification (UTC)
	LastModifiedAt *time.Time

	// The identity that last modified the resource.
	LastModifiedBy *string

	// The type of identity that last modified the resource.
	LastModifiedByType *CreatedByType
}

// Topic - Object that describes the topic information.
type Topic struct {
	// REQUIRED; The topic path for messages published to an MQTT broker.
	Path *string

	// When set to 'Keep', messages published to an MQTT broker will have the retain flag set. Default: 'Never'.
	Retain *TopicRetainType
}

// UsernamePasswordCredentials - The credentials for authentication mode UsernamePassword.
type UsernamePasswordCredentials struct {
	// REQUIRED; The name of the secret containing the password.
	PasswordSecretName *string

	// REQUIRED; The name of the secret containing the username.
	UsernameSecretName *string
}

// X509Credentials - The x509 certificate for authentication mode Certificate.
type X509Credentials struct {
	// REQUIRED; The name of the secret containing the certificate and private key (e.g. stored as .der/.pem or .der/.pfx).
	CertificateSecretName *string
}
