iotdata

package
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 26, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package iotdata provides Cloud IoT type definitions for CloudEvent data payloads.

Supported CloudEvent Types

  • google.cloud.iot.v1.DeviceManager.CreateDevice
  • google.cloud.iot.v1.DeviceManager.UpdateDevice
  • google.cloud.iot.v1.DeviceManager.DeleteDevice
  • google.cloud.iot.v1.DeviceManager.CreateDeviceRegistry
  • google.cloud.iot.v1.DeviceManager.UpdateDeviceRegistry
  • google.cloud.iot.v1.DeviceManager.DeleteDeviceRegistry

Index

Constants

This section is empty.

Variables

View Source
var (
	MqttState_name = map[int32]string{
		0: "MQTT_STATE_UNSPECIFIED",
		1: "MQTT_ENABLED",
		2: "MQTT_DISABLED",
	}
	MqttState_value = map[string]int32{
		"MQTT_STATE_UNSPECIFIED": 0,
		"MQTT_ENABLED":           1,
		"MQTT_DISABLED":          2,
	}
)

Enum value maps for MqttState.

View Source
var (
	HttpState_name = map[int32]string{
		0: "HTTP_STATE_UNSPECIFIED",
		1: "HTTP_ENABLED",
		2: "HTTP_DISABLED",
	}
	HttpState_value = map[string]int32{
		"HTTP_STATE_UNSPECIFIED": 0,
		"HTTP_ENABLED":           1,
		"HTTP_DISABLED":          2,
	}
)

Enum value maps for HttpState.

View Source
var (
	LogLevel_name = map[int32]string{
		0:  "LOG_LEVEL_UNSPECIFIED",
		10: "NONE",
		20: "ERROR",
		30: "INFO",
		40: "DEBUG",
	}
	LogLevel_value = map[string]int32{
		"LOG_LEVEL_UNSPECIFIED": 0,
		"NONE":                  10,
		"ERROR":                 20,
		"INFO":                  30,
		"DEBUG":                 40,
	}
)

Enum value maps for LogLevel.

View Source
var (
	GatewayType_name = map[int32]string{
		0: "GATEWAY_TYPE_UNSPECIFIED",
		1: "GATEWAY",
		2: "NON_GATEWAY",
	}
	GatewayType_value = map[string]int32{
		"GATEWAY_TYPE_UNSPECIFIED": 0,
		"GATEWAY":                  1,
		"NON_GATEWAY":              2,
	}
)

Enum value maps for GatewayType.

View Source
var (
	GatewayAuthMethod_name = map[int32]string{
		0: "GATEWAY_AUTH_METHOD_UNSPECIFIED",
		1: "ASSOCIATION_ONLY",
		2: "DEVICE_AUTH_TOKEN_ONLY",
		3: "ASSOCIATION_AND_DEVICE_AUTH_TOKEN",
	}
	GatewayAuthMethod_value = map[string]int32{
		"GATEWAY_AUTH_METHOD_UNSPECIFIED":   0,
		"ASSOCIATION_ONLY":                  1,
		"DEVICE_AUTH_TOKEN_ONLY":            2,
		"ASSOCIATION_AND_DEVICE_AUTH_TOKEN": 3,
	}
)

Enum value maps for GatewayAuthMethod.

View Source
var (
	PublicKeyCertificateFormat_name = map[int32]string{
		0: "UNSPECIFIED_PUBLIC_KEY_CERTIFICATE_FORMAT",
		1: "X509_CERTIFICATE_PEM",
	}
	PublicKeyCertificateFormat_value = map[string]int32{
		"UNSPECIFIED_PUBLIC_KEY_CERTIFICATE_FORMAT": 0,
		"X509_CERTIFICATE_PEM":                      1,
	}
)

Enum value maps for PublicKeyCertificateFormat.

View Source
var (
	PublicKeyFormat_name = map[int32]string{
		0: "UNSPECIFIED_PUBLIC_KEY_FORMAT",
		3: "RSA_PEM",
		1: "RSA_X509_PEM",
		2: "ES256_PEM",
		4: "ES256_X509_PEM",
	}
	PublicKeyFormat_value = map[string]int32{
		"UNSPECIFIED_PUBLIC_KEY_FORMAT": 0,
		"RSA_PEM":                       3,
		"RSA_X509_PEM":                  1,
		"ES256_PEM":                     2,
		"ES256_X509_PEM":                4,
	}
)

Enum value maps for PublicKeyFormat.

View Source
var File_cloud_iot_v1_data_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Device

type Device struct {

	// The user-defined device identifier. The device ID must be unique
	// within a device registry.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// The resource path name. For example,
	// `projects/p1/locations/us-central1/registries/registry0/devices/dev0` or
	// `projects/p1/locations/us-central1/registries/registry0/devices/{num_id}`.
	// When `name` is populated as a response from the service, it always ends
	// in the device numeric ID.
	Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// [Output only] A server-defined unique numeric ID for the device. This is a
	// more compact way to identify devices, and it is globally unique.
	NumId uint64 `protobuf:"varint,3,opt,name=num_id,json=numId,proto3" json:"num_id,omitempty"`
	// The credentials used to authenticate this device. To allow credential
	// rotation without interruption, multiple device credentials can be bound to
	// this device. No more than 3 credentials can be bound to a single device at
	// a time. When new credentials are added to a device, they are verified
	// against the registry credentials. For details, see the description of the
	// `DeviceRegistry.credentials` field.
	Credentials []*DeviceCredential `protobuf:"bytes,12,rep,name=credentials,proto3" json:"credentials,omitempty"`
	// [Output only] The last time an MQTT `PINGREQ` was received. This field
	// applies only to devices connecting through MQTT. MQTT clients usually only
	// send `PINGREQ` messages if the connection is idle, and no other messages
	// have been sent. Timestamps are periodically collected and written to
	// storage; they may be stale by a few minutes.
	LastHeartbeatTime *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=last_heartbeat_time,json=lastHeartbeatTime,proto3" json:"last_heartbeat_time,omitempty"`
	// [Output only] The last time a telemetry event was received. Timestamps are
	// periodically collected and written to storage; they may be stale by a few
	// minutes.
	LastEventTime *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=last_event_time,json=lastEventTime,proto3" json:"last_event_time,omitempty"`
	// [Output only] The last time a state event was received. Timestamps are
	// periodically collected and written to storage; they may be stale by a few
	// minutes.
	LastStateTime *timestamppb.Timestamp `protobuf:"bytes,20,opt,name=last_state_time,json=lastStateTime,proto3" json:"last_state_time,omitempty"`
	// [Output only] The last time a cloud-to-device config version acknowledgment
	// was received from the device. This field is only for configurations
	// sent through MQTT.
	LastConfigAckTime *timestamppb.Timestamp `protobuf:"bytes,14,opt,name=last_config_ack_time,json=lastConfigAckTime,proto3" json:"last_config_ack_time,omitempty"`
	// [Output only] The last time a cloud-to-device config version was sent to
	// the device.
	LastConfigSendTime *timestamppb.Timestamp `protobuf:"bytes,18,opt,name=last_config_send_time,json=lastConfigSendTime,proto3" json:"last_config_send_time,omitempty"`
	// If a device is blocked, connections or requests from this device will fail.
	// Can be used to temporarily prevent the device from connecting if, for
	// example, the sensor is generating bad data and needs maintenance.
	Blocked bool `protobuf:"varint,19,opt,name=blocked,proto3" json:"blocked,omitempty"`
	// [Output only] The time the most recent error occurred, such as a failure to
	// publish to Cloud Pub/Sub. This field is the timestamp of
	// 'last_error_status'.
	LastErrorTime *timestamppb.Timestamp `protobuf:"bytes,10,opt,name=last_error_time,json=lastErrorTime,proto3" json:"last_error_time,omitempty"`
	// [Output only] The error message of the most recent error, such as a failure
	// to publish to Cloud Pub/Sub. 'last_error_time' is the timestamp of this
	// field. If no errors have occurred, this field has an empty message
	// and the status code 0 == OK. Otherwise, this field is expected to have a
	// status code other than OK.
	LastErrorStatus *status.Status `protobuf:"bytes,11,opt,name=last_error_status,json=lastErrorStatus,proto3" json:"last_error_status,omitempty"`
	// The most recent device configuration, which is eventually sent from
	// Cloud IoT Core to the device. If not present on creation, the
	// configuration will be initialized with an empty payload and version value
	// of `1`. To update this field after creation, use the
	// `DeviceManager.ModifyCloudToDeviceConfig` method.
	Config *DeviceConfig `protobuf:"bytes,13,opt,name=config,proto3" json:"config,omitempty"`
	// [Output only] The state most recently received from the device. If no state
	// has been reported, this field is not present.
	State *DeviceState `protobuf:"bytes,16,opt,name=state,proto3" json:"state,omitempty"`
	// **Beta Feature**
	//
	// The logging verbosity for device activity. If unspecified,
	// DeviceRegistry.log_level will be used.
	LogLevel LogLevel `` /* 128-byte string literal not displayed */
	// The metadata key-value pairs assigned to the device. This metadata is not
	// interpreted or indexed by Cloud IoT Core. It can be used to add contextual
	// information for the device.
	//
	// Keys must conform to the regular expression [a-zA-Z][a-zA-Z0-9-_.+~%]+ and
	// be less than 128 bytes in length.
	//
	// Values are free-form strings. Each value must be less than or equal to 32
	// KB in size.
	//
	// The total size of all keys and values must be less than 256 KB, and the
	// maximum number of key-value pairs is 500.
	Metadata map[string]string `` /* 158-byte string literal not displayed */
	// Gateway-related configuration and state.
	GatewayConfig *GatewayConfig `protobuf:"bytes,24,opt,name=gateway_config,json=gatewayConfig,proto3" json:"gateway_config,omitempty"`
	// contains filtered or unexported fields
}

The device resource.

func (*Device) Descriptor deprecated

func (*Device) Descriptor() ([]byte, []int)

Deprecated: Use Device.ProtoReflect.Descriptor instead.

func (*Device) GetBlocked

func (x *Device) GetBlocked() bool

func (*Device) GetConfig

func (x *Device) GetConfig() *DeviceConfig

func (*Device) GetCredentials

func (x *Device) GetCredentials() []*DeviceCredential

func (*Device) GetGatewayConfig

func (x *Device) GetGatewayConfig() *GatewayConfig

func (*Device) GetId

func (x *Device) GetId() string

func (*Device) GetLastConfigAckTime

func (x *Device) GetLastConfigAckTime() *timestamppb.Timestamp

func (*Device) GetLastConfigSendTime

func (x *Device) GetLastConfigSendTime() *timestamppb.Timestamp

func (*Device) GetLastErrorStatus

func (x *Device) GetLastErrorStatus() *status.Status

func (*Device) GetLastErrorTime

func (x *Device) GetLastErrorTime() *timestamppb.Timestamp

func (*Device) GetLastEventTime

func (x *Device) GetLastEventTime() *timestamppb.Timestamp

func (*Device) GetLastHeartbeatTime

func (x *Device) GetLastHeartbeatTime() *timestamppb.Timestamp

func (*Device) GetLastStateTime

func (x *Device) GetLastStateTime() *timestamppb.Timestamp

func (*Device) GetLogLevel

func (x *Device) GetLogLevel() LogLevel

func (*Device) GetMetadata

func (x *Device) GetMetadata() map[string]string

func (*Device) GetName

func (x *Device) GetName() string

func (*Device) GetNumId

func (x *Device) GetNumId() uint64

func (*Device) GetState

func (x *Device) GetState() *DeviceState

func (*Device) ProtoMessage

func (*Device) ProtoMessage()

func (*Device) ProtoReflect

func (x *Device) ProtoReflect() protoreflect.Message

func (*Device) Reset

func (x *Device) Reset()

func (*Device) String

func (x *Device) String() string

type DeviceConfig

type DeviceConfig struct {

	// [Output only] The version of this update. The version number is assigned by
	// the server, and is always greater than 0 after device creation. The
	// version must be 0 on the `CreateDevice` request if a `config` is
	// specified; the response of `CreateDevice` will always have a value of 1.
	Version int64 `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"`
	// [Output only] The time at which this configuration version was updated in
	// Cloud IoT Core. This timestamp is set by the server.
	CloudUpdateTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=cloud_update_time,json=cloudUpdateTime,proto3" json:"cloud_update_time,omitempty"`
	// [Output only] The time at which Cloud IoT Core received the
	// acknowledgment from the device, indicating that the device has received
	// this configuration version. If this field is not present, the device has
	// not yet acknowledged that it received this version. Note that when
	// the config was sent to the device, many config versions may have been
	// available in Cloud IoT Core while the device was disconnected, and on
	// connection, only the latest version is sent to the device. Some
	// versions may never be sent to the device, and therefore are never
	// acknowledged. This timestamp is set by Cloud IoT Core.
	DeviceAckTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=device_ack_time,json=deviceAckTime,proto3" json:"device_ack_time,omitempty"`
	// The device configuration data.
	BinaryData []byte `protobuf:"bytes,4,opt,name=binary_data,json=binaryData,proto3" json:"binary_data,omitempty"`
	// contains filtered or unexported fields
}

The device configuration. Eventually delivered to devices.

func (*DeviceConfig) Descriptor deprecated

func (*DeviceConfig) Descriptor() ([]byte, []int)

Deprecated: Use DeviceConfig.ProtoReflect.Descriptor instead.

func (*DeviceConfig) GetBinaryData

func (x *DeviceConfig) GetBinaryData() []byte

func (*DeviceConfig) GetCloudUpdateTime

func (x *DeviceConfig) GetCloudUpdateTime() *timestamppb.Timestamp

func (*DeviceConfig) GetDeviceAckTime

func (x *DeviceConfig) GetDeviceAckTime() *timestamppb.Timestamp

func (*DeviceConfig) GetVersion

func (x *DeviceConfig) GetVersion() int64

func (*DeviceConfig) ProtoMessage

func (*DeviceConfig) ProtoMessage()

func (*DeviceConfig) ProtoReflect

func (x *DeviceConfig) ProtoReflect() protoreflect.Message

func (*DeviceConfig) Reset

func (x *DeviceConfig) Reset()

func (*DeviceConfig) String

func (x *DeviceConfig) String() string

type DeviceCredential

type DeviceCredential struct {

	// The credential data. Reserved for expansion in the future.
	//
	// Types that are assignable to Credential:
	//
	//	*DeviceCredential_PublicKey
	Credential isDeviceCredential_Credential `protobuf_oneof:"credential"`
	// [Optional] The time at which this credential becomes invalid. This
	// credential will be ignored for new client authentication requests after
	// this timestamp; however, it will not be automatically deleted.
	ExpirationTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=expiration_time,json=expirationTime,proto3" json:"expiration_time,omitempty"`
	// contains filtered or unexported fields
}

A server-stored device credential used for authentication.

func (*DeviceCredential) Descriptor deprecated

func (*DeviceCredential) Descriptor() ([]byte, []int)

Deprecated: Use DeviceCredential.ProtoReflect.Descriptor instead.

func (*DeviceCredential) GetCredential

func (m *DeviceCredential) GetCredential() isDeviceCredential_Credential

func (*DeviceCredential) GetExpirationTime

func (x *DeviceCredential) GetExpirationTime() *timestamppb.Timestamp

func (*DeviceCredential) GetPublicKey

func (x *DeviceCredential) GetPublicKey() *PublicKeyCredential

func (*DeviceCredential) ProtoMessage

func (*DeviceCredential) ProtoMessage()

func (*DeviceCredential) ProtoReflect

func (x *DeviceCredential) ProtoReflect() protoreflect.Message

func (*DeviceCredential) Reset

func (x *DeviceCredential) Reset()

func (*DeviceCredential) String

func (x *DeviceCredential) String() string

type DeviceCredential_PublicKey

type DeviceCredential_PublicKey struct {
	// A public key used to verify the signature of JSON Web Tokens (JWTs).
	// When adding a new device credential, either via device creation or via
	// modifications, this public key credential may be required to be signed by
	// one of the registry level certificates. More specifically, if the
	// registry contains at least one certificate, any new device credential
	// must be signed by one of the registry certificates. As a result,
	// when the registry contains certificates, only X.509 certificates are
	// accepted as device credentials. However, if the registry does
	// not contain a certificate, self-signed certificates and public keys will
	// be accepted. New device credentials must be different from every
	// registry-level certificate.
	PublicKey *PublicKeyCredential `protobuf:"bytes,2,opt,name=public_key,json=publicKey,proto3,oneof"`
}

type DeviceEventData

type DeviceEventData struct {

	// Optional. The Device event payload. Unset for deletion events.
	Payload *Device `protobuf:"bytes,1,opt,name=payload,proto3,oneof" json:"payload,omitempty"`
	// contains filtered or unexported fields
}

The data within all Cloud IoT Device events.

func (*DeviceEventData) Descriptor deprecated

func (*DeviceEventData) Descriptor() ([]byte, []int)

Deprecated: Use DeviceEventData.ProtoReflect.Descriptor instead.

func (*DeviceEventData) GetPayload

func (x *DeviceEventData) GetPayload() *Device

func (*DeviceEventData) ProtoMessage

func (*DeviceEventData) ProtoMessage()

func (*DeviceEventData) ProtoReflect

func (x *DeviceEventData) ProtoReflect() protoreflect.Message

func (*DeviceEventData) Reset

func (x *DeviceEventData) Reset()

func (*DeviceEventData) String

func (x *DeviceEventData) String() string

type DeviceRegistry

type DeviceRegistry struct {

	// The identifier of this device registry. For example, `myRegistry`.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// The resource path name. For example,
	// `projects/example-project/locations/us-central1/registries/my-registry`.
	Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// The configuration for notification of telemetry events received from the
	// device. All telemetry events that were successfully published by the
	// device and acknowledged by Cloud IoT Core are guaranteed to be
	// delivered to Cloud Pub/Sub. If multiple configurations match a message,
	// only the first matching configuration is used. If you try to publish a
	// device telemetry event using MQTT without specifying a Cloud Pub/Sub topic
	// for the device's registry, the connection closes automatically. If you try
	// to do so using an HTTP connection, an error is returned. Up to 10
	// configurations may be provided.
	EventNotificationConfigs []*EventNotificationConfig `` /* 136-byte string literal not displayed */
	// The configuration for notification of new states received from the device.
	// State updates are guaranteed to be stored in the state history, but
	// notifications to Cloud Pub/Sub are not guaranteed. For example, if
	// permissions are misconfigured or the specified topic doesn't exist, no
	// notification will be published but the state will still be stored in Cloud
	// IoT Core.
	StateNotificationConfig *StateNotificationConfig `` /* 132-byte string literal not displayed */
	// The MQTT configuration for this device registry.
	MqttConfig *MqttConfig `protobuf:"bytes,4,opt,name=mqtt_config,json=mqttConfig,proto3" json:"mqtt_config,omitempty"`
	// The DeviceService (HTTP) configuration for this device registry.
	HttpConfig *HttpConfig `protobuf:"bytes,9,opt,name=http_config,json=httpConfig,proto3" json:"http_config,omitempty"`
	// **Beta Feature**
	//
	// The default logging verbosity for activity from devices in this registry.
	// The verbosity level can be overridden by Device.log_level.
	LogLevel LogLevel `` /* 128-byte string literal not displayed */
	// The credentials used to verify the device credentials. No more than 10
	// credentials can be bound to a single registry at a time. The verification
	// process occurs at the time of device creation or update. If this field is
	// empty, no verification is performed. Otherwise, the credentials of a newly
	// created device or added credentials of an updated device should be signed
	// with one of these registry credentials.
	//
	// Note, however, that existing devices will never be affected by
	// modifications to this list of credentials: after a device has been
	// successfully created in a registry, it should be able to connect even if
	// its registry credentials are revoked, deleted, or modified.
	Credentials []*RegistryCredential `protobuf:"bytes,8,rep,name=credentials,proto3" json:"credentials,omitempty"`
	// contains filtered or unexported fields
}

A container for a group of devices.

func (*DeviceRegistry) Descriptor deprecated

func (*DeviceRegistry) Descriptor() ([]byte, []int)

Deprecated: Use DeviceRegistry.ProtoReflect.Descriptor instead.

func (*DeviceRegistry) GetCredentials

func (x *DeviceRegistry) GetCredentials() []*RegistryCredential

func (*DeviceRegistry) GetEventNotificationConfigs

func (x *DeviceRegistry) GetEventNotificationConfigs() []*EventNotificationConfig

func (*DeviceRegistry) GetHttpConfig

func (x *DeviceRegistry) GetHttpConfig() *HttpConfig

func (*DeviceRegistry) GetId

func (x *DeviceRegistry) GetId() string

func (*DeviceRegistry) GetLogLevel

func (x *DeviceRegistry) GetLogLevel() LogLevel

func (*DeviceRegistry) GetMqttConfig

func (x *DeviceRegistry) GetMqttConfig() *MqttConfig

func (*DeviceRegistry) GetName

func (x *DeviceRegistry) GetName() string

func (*DeviceRegistry) GetStateNotificationConfig

func (x *DeviceRegistry) GetStateNotificationConfig() *StateNotificationConfig

func (*DeviceRegistry) ProtoMessage

func (*DeviceRegistry) ProtoMessage()

func (*DeviceRegistry) ProtoReflect

func (x *DeviceRegistry) ProtoReflect() protoreflect.Message

func (*DeviceRegistry) Reset

func (x *DeviceRegistry) Reset()

func (*DeviceRegistry) String

func (x *DeviceRegistry) String() string

type DeviceState

type DeviceState struct {

	// [Output only] The time at which this state version was updated in Cloud
	// IoT Core.
	UpdateTime *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`
	// The device state data.
	BinaryData []byte `protobuf:"bytes,2,opt,name=binary_data,json=binaryData,proto3" json:"binary_data,omitempty"`
	// contains filtered or unexported fields
}

The device state, as reported by the device.

func (*DeviceState) Descriptor deprecated

func (*DeviceState) Descriptor() ([]byte, []int)

Deprecated: Use DeviceState.ProtoReflect.Descriptor instead.

func (*DeviceState) GetBinaryData

func (x *DeviceState) GetBinaryData() []byte

func (*DeviceState) GetUpdateTime

func (x *DeviceState) GetUpdateTime() *timestamppb.Timestamp

func (*DeviceState) ProtoMessage

func (*DeviceState) ProtoMessage()

func (*DeviceState) ProtoReflect

func (x *DeviceState) ProtoReflect() protoreflect.Message

func (*DeviceState) Reset

func (x *DeviceState) Reset()

func (*DeviceState) String

func (x *DeviceState) String() string

type EventNotificationConfig

type EventNotificationConfig struct {

	// If the subfolder name matches this string exactly, this configuration will
	// be used. The string must not include the leading '/' character. If empty,
	// all strings are matched. This field is used only for telemetry events;
	// subfolders are not supported for state changes.
	SubfolderMatches string `protobuf:"bytes,2,opt,name=subfolder_matches,json=subfolderMatches,proto3" json:"subfolder_matches,omitempty"`
	// A Cloud Pub/Sub topic name. For example,
	// `projects/myProject/topics/deviceEvents`.
	PubsubTopicName string `protobuf:"bytes,1,opt,name=pubsub_topic_name,json=pubsubTopicName,proto3" json:"pubsub_topic_name,omitempty"`
	// contains filtered or unexported fields
}

The configuration for forwarding telemetry events.

func (*EventNotificationConfig) Descriptor deprecated

func (*EventNotificationConfig) Descriptor() ([]byte, []int)

Deprecated: Use EventNotificationConfig.ProtoReflect.Descriptor instead.

func (*EventNotificationConfig) GetPubsubTopicName

func (x *EventNotificationConfig) GetPubsubTopicName() string

func (*EventNotificationConfig) GetSubfolderMatches

func (x *EventNotificationConfig) GetSubfolderMatches() string

func (*EventNotificationConfig) ProtoMessage

func (*EventNotificationConfig) ProtoMessage()

func (*EventNotificationConfig) ProtoReflect

func (x *EventNotificationConfig) ProtoReflect() protoreflect.Message

func (*EventNotificationConfig) Reset

func (x *EventNotificationConfig) Reset()

func (*EventNotificationConfig) String

func (x *EventNotificationConfig) String() string

type GatewayAuthMethod

type GatewayAuthMethod int32

The gateway authorization/authentication method. This setting determines how Cloud IoT Core authorizes/authenticate devices to access the gateway.

const (
	// No authentication/authorization method specified. No devices are allowed to
	// access the gateway.
	GatewayAuthMethod_GATEWAY_AUTH_METHOD_UNSPECIFIED GatewayAuthMethod = 0
	// The device is authenticated through the gateway association only. Device
	// credentials are ignored even if provided.
	GatewayAuthMethod_ASSOCIATION_ONLY GatewayAuthMethod = 1
	// The device is authenticated through its own credentials. Gateway
	// association is not checked.
	GatewayAuthMethod_DEVICE_AUTH_TOKEN_ONLY GatewayAuthMethod = 2
	// The device is authenticated through both device credentials and gateway
	// association. The device must be bound to the gateway and must provide its
	// own credentials.
	GatewayAuthMethod_ASSOCIATION_AND_DEVICE_AUTH_TOKEN GatewayAuthMethod = 3
)

func (GatewayAuthMethod) Descriptor

func (GatewayAuthMethod) Enum

func (GatewayAuthMethod) EnumDescriptor deprecated

func (GatewayAuthMethod) EnumDescriptor() ([]byte, []int)

Deprecated: Use GatewayAuthMethod.Descriptor instead.

func (GatewayAuthMethod) Number

func (GatewayAuthMethod) String

func (x GatewayAuthMethod) String() string

func (GatewayAuthMethod) Type

type GatewayConfig

type GatewayConfig struct {

	// Indicates whether the device is a gateway.
	GatewayType GatewayType `` /* 139-byte string literal not displayed */
	// Indicates how to authorize and/or authenticate devices to access the
	// gateway.
	GatewayAuthMethod GatewayAuthMethod `` /* 165-byte string literal not displayed */
	// [Output only] The ID of the gateway the device accessed most recently.
	LastAccessedGatewayId string `` /* 128-byte string literal not displayed */
	// [Output only] The most recent time at which the device accessed the gateway
	// specified in `last_accessed_gateway`.
	LastAccessedGatewayTime *timestamppb.Timestamp `` /* 134-byte string literal not displayed */
	// contains filtered or unexported fields
}

Gateway-related configuration and state.

func (*GatewayConfig) Descriptor deprecated

func (*GatewayConfig) Descriptor() ([]byte, []int)

Deprecated: Use GatewayConfig.ProtoReflect.Descriptor instead.

func (*GatewayConfig) GetGatewayAuthMethod

func (x *GatewayConfig) GetGatewayAuthMethod() GatewayAuthMethod

func (*GatewayConfig) GetGatewayType

func (x *GatewayConfig) GetGatewayType() GatewayType

func (*GatewayConfig) GetLastAccessedGatewayId

func (x *GatewayConfig) GetLastAccessedGatewayId() string

func (*GatewayConfig) GetLastAccessedGatewayTime

func (x *GatewayConfig) GetLastAccessedGatewayTime() *timestamppb.Timestamp

func (*GatewayConfig) ProtoMessage

func (*GatewayConfig) ProtoMessage()

func (*GatewayConfig) ProtoReflect

func (x *GatewayConfig) ProtoReflect() protoreflect.Message

func (*GatewayConfig) Reset

func (x *GatewayConfig) Reset()

func (*GatewayConfig) String

func (x *GatewayConfig) String() string

type GatewayType

type GatewayType int32

Gateway type.

const (
	// If unspecified, the device is considered a non-gateway device.
	GatewayType_GATEWAY_TYPE_UNSPECIFIED GatewayType = 0
	// The device is a gateway.
	GatewayType_GATEWAY GatewayType = 1
	// The device is not a gateway.
	GatewayType_NON_GATEWAY GatewayType = 2
)

func (GatewayType) Descriptor

func (GatewayType) Enum

func (x GatewayType) Enum() *GatewayType

func (GatewayType) EnumDescriptor deprecated

func (GatewayType) EnumDescriptor() ([]byte, []int)

Deprecated: Use GatewayType.Descriptor instead.

func (GatewayType) Number

func (x GatewayType) Number() protoreflect.EnumNumber

func (GatewayType) String

func (x GatewayType) String() string

func (GatewayType) Type

type HttpConfig

type HttpConfig struct {

	// If enabled, allows devices to use DeviceService via the HTTP protocol.
	// Otherwise, any requests to DeviceService will fail for this registry.
	HttpEnabledState HttpState `` /* 154-byte string literal not displayed */
	// contains filtered or unexported fields
}

The configuration of the HTTP bridge for a device registry.

func (*HttpConfig) Descriptor deprecated

func (*HttpConfig) Descriptor() ([]byte, []int)

Deprecated: Use HttpConfig.ProtoReflect.Descriptor instead.

func (*HttpConfig) GetHttpEnabledState

func (x *HttpConfig) GetHttpEnabledState() HttpState

func (*HttpConfig) ProtoMessage

func (*HttpConfig) ProtoMessage()

func (*HttpConfig) ProtoReflect

func (x *HttpConfig) ProtoReflect() protoreflect.Message

func (*HttpConfig) Reset

func (x *HttpConfig) Reset()

func (*HttpConfig) String

func (x *HttpConfig) String() string

type HttpState

type HttpState int32

Indicates whether DeviceService (HTTP) is enabled or disabled for the registry. See the field description for details.

const (
	// No HTTP state specified. If not specified, DeviceService will be
	// enabled by default.
	HttpState_HTTP_STATE_UNSPECIFIED HttpState = 0
	// Enables DeviceService (HTTP) service for the registry.
	HttpState_HTTP_ENABLED HttpState = 1
	// Disables DeviceService (HTTP) service for the registry.
	HttpState_HTTP_DISABLED HttpState = 2
)

func (HttpState) Descriptor

func (HttpState) Descriptor() protoreflect.EnumDescriptor

func (HttpState) Enum

func (x HttpState) Enum() *HttpState

func (HttpState) EnumDescriptor deprecated

func (HttpState) EnumDescriptor() ([]byte, []int)

Deprecated: Use HttpState.Descriptor instead.

func (HttpState) Number

func (x HttpState) Number() protoreflect.EnumNumber

func (HttpState) String

func (x HttpState) String() string

func (HttpState) Type

type LogLevel

type LogLevel int32

**Beta Feature**

The logging verbosity for device activity. Specifies which events should be written to logs. For example, if the LogLevel is ERROR, only events that terminate in errors will be logged. LogLevel is inclusive; enabling INFO logging will also enable ERROR logging.

const (
	// No logging specified. If not specified, logging will be disabled.
	LogLevel_LOG_LEVEL_UNSPECIFIED LogLevel = 0
	// Disables logging.
	LogLevel_NONE LogLevel = 10
	// Error events will be logged.
	LogLevel_ERROR LogLevel = 20
	// Informational events will be logged, such as connections and
	// disconnections.
	LogLevel_INFO LogLevel = 30
	// All events will be logged.
	LogLevel_DEBUG LogLevel = 40
)

func (LogLevel) Descriptor

func (LogLevel) Descriptor() protoreflect.EnumDescriptor

func (LogLevel) Enum

func (x LogLevel) Enum() *LogLevel

func (LogLevel) EnumDescriptor deprecated

func (LogLevel) EnumDescriptor() ([]byte, []int)

Deprecated: Use LogLevel.Descriptor instead.

func (LogLevel) Number

func (x LogLevel) Number() protoreflect.EnumNumber

func (LogLevel) String

func (x LogLevel) String() string

func (LogLevel) Type

type MqttConfig

type MqttConfig struct {

	// If enabled, allows connections using the MQTT protocol. Otherwise, MQTT
	// connections to this registry will fail.
	MqttEnabledState MqttState `` /* 154-byte string literal not displayed */
	// contains filtered or unexported fields
}

The configuration of MQTT for a device registry.

func (*MqttConfig) Descriptor deprecated

func (*MqttConfig) Descriptor() ([]byte, []int)

Deprecated: Use MqttConfig.ProtoReflect.Descriptor instead.

func (*MqttConfig) GetMqttEnabledState

func (x *MqttConfig) GetMqttEnabledState() MqttState

func (*MqttConfig) ProtoMessage

func (*MqttConfig) ProtoMessage()

func (*MqttConfig) ProtoReflect

func (x *MqttConfig) ProtoReflect() protoreflect.Message

func (*MqttConfig) Reset

func (x *MqttConfig) Reset()

func (*MqttConfig) String

func (x *MqttConfig) String() string

type MqttState

type MqttState int32

Indicates whether an MQTT connection is enabled or disabled. See the field description for details.

const (
	// No MQTT state specified. If not specified, MQTT will be enabled by default.
	MqttState_MQTT_STATE_UNSPECIFIED MqttState = 0
	// Enables a MQTT connection.
	MqttState_MQTT_ENABLED MqttState = 1
	// Disables a MQTT connection.
	MqttState_MQTT_DISABLED MqttState = 2
)

func (MqttState) Descriptor

func (MqttState) Descriptor() protoreflect.EnumDescriptor

func (MqttState) Enum

func (x MqttState) Enum() *MqttState

func (MqttState) EnumDescriptor deprecated

func (MqttState) EnumDescriptor() ([]byte, []int)

Deprecated: Use MqttState.Descriptor instead.

func (MqttState) Number

func (x MqttState) Number() protoreflect.EnumNumber

func (MqttState) String

func (x MqttState) String() string

func (MqttState) Type

type PublicKeyCertificate

type PublicKeyCertificate struct {

	// The certificate format.
	Format PublicKeyCertificateFormat `protobuf:"varint,1,opt,name=format,proto3,enum=google.events.cloud.iot.v1.PublicKeyCertificateFormat" json:"format,omitempty"`
	// The certificate data.
	Certificate string `protobuf:"bytes,2,opt,name=certificate,proto3" json:"certificate,omitempty"`
	// [Output only] The certificate details. Used only for X.509 certificates.
	X509Details *X509CertificateDetails `protobuf:"bytes,3,opt,name=x509_details,json=x509Details,proto3" json:"x509_details,omitempty"`
	// contains filtered or unexported fields
}

A public key certificate format and data.

func (*PublicKeyCertificate) Descriptor deprecated

func (*PublicKeyCertificate) Descriptor() ([]byte, []int)

Deprecated: Use PublicKeyCertificate.ProtoReflect.Descriptor instead.

func (*PublicKeyCertificate) GetCertificate

func (x *PublicKeyCertificate) GetCertificate() string

func (*PublicKeyCertificate) GetFormat

func (*PublicKeyCertificate) GetX509Details

func (x *PublicKeyCertificate) GetX509Details() *X509CertificateDetails

func (*PublicKeyCertificate) ProtoMessage

func (*PublicKeyCertificate) ProtoMessage()

func (*PublicKeyCertificate) ProtoReflect

func (x *PublicKeyCertificate) ProtoReflect() protoreflect.Message

func (*PublicKeyCertificate) Reset

func (x *PublicKeyCertificate) Reset()

func (*PublicKeyCertificate) String

func (x *PublicKeyCertificate) String() string

type PublicKeyCertificateFormat

type PublicKeyCertificateFormat int32

The supported formats for the public key.

const (
	// The format has not been specified. This is an invalid default value and
	// must not be used.
	PublicKeyCertificateFormat_UNSPECIFIED_PUBLIC_KEY_CERTIFICATE_FORMAT PublicKeyCertificateFormat = 0
	// An X.509v3 certificate ([RFC5280](https://www.ietf.org/rfc/rfc5280.txt)),
	// encoded in base64, and wrapped by `-----BEGIN CERTIFICATE-----` and
	// `-----END CERTIFICATE-----`.
	PublicKeyCertificateFormat_X509_CERTIFICATE_PEM PublicKeyCertificateFormat = 1
)

func (PublicKeyCertificateFormat) Descriptor

func (PublicKeyCertificateFormat) Enum

func (PublicKeyCertificateFormat) EnumDescriptor deprecated

func (PublicKeyCertificateFormat) EnumDescriptor() ([]byte, []int)

Deprecated: Use PublicKeyCertificateFormat.Descriptor instead.

func (PublicKeyCertificateFormat) Number

func (PublicKeyCertificateFormat) String

func (PublicKeyCertificateFormat) Type

type PublicKeyCredential

type PublicKeyCredential struct {

	// The format of the key.
	Format PublicKeyFormat `protobuf:"varint,1,opt,name=format,proto3,enum=google.events.cloud.iot.v1.PublicKeyFormat" json:"format,omitempty"`
	// The key data.
	Key string `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

A public key format and data.

func (*PublicKeyCredential) Descriptor deprecated

func (*PublicKeyCredential) Descriptor() ([]byte, []int)

Deprecated: Use PublicKeyCredential.ProtoReflect.Descriptor instead.

func (*PublicKeyCredential) GetFormat

func (x *PublicKeyCredential) GetFormat() PublicKeyFormat

func (*PublicKeyCredential) GetKey

func (x *PublicKeyCredential) GetKey() string

func (*PublicKeyCredential) ProtoMessage

func (*PublicKeyCredential) ProtoMessage()

func (*PublicKeyCredential) ProtoReflect

func (x *PublicKeyCredential) ProtoReflect() protoreflect.Message

func (*PublicKeyCredential) Reset

func (x *PublicKeyCredential) Reset()

func (*PublicKeyCredential) String

func (x *PublicKeyCredential) String() string

type PublicKeyFormat

type PublicKeyFormat int32

The supported formats for the public key.

const (
	// The format has not been specified. This is an invalid default value and
	// must not be used.
	PublicKeyFormat_UNSPECIFIED_PUBLIC_KEY_FORMAT PublicKeyFormat = 0
	// An RSA public key encoded in base64, and wrapped by
	// `-----BEGIN PUBLIC KEY-----` and `-----END PUBLIC KEY-----`. This can be
	// used to verify `RS256` signatures in JWT tokens ([RFC7518](
	// https://www.ietf.org/rfc/rfc7518.txt)).
	PublicKeyFormat_RSA_PEM PublicKeyFormat = 3
	// As RSA_PEM, but wrapped in an X.509v3 certificate ([RFC5280](
	// https://www.ietf.org/rfc/rfc5280.txt)), encoded in base64, and wrapped by
	// `-----BEGIN CERTIFICATE-----` and `-----END CERTIFICATE-----`.
	PublicKeyFormat_RSA_X509_PEM PublicKeyFormat = 1
	// Public key for the ECDSA algorithm using P-256 and SHA-256, encoded in
	// base64, and wrapped by `-----BEGIN PUBLIC KEY-----` and `-----END
	// PUBLIC KEY-----`. This can be used to verify JWT tokens with the `ES256`
	// algorithm ([RFC7518](https://www.ietf.org/rfc/rfc7518.txt)). This curve is
	// defined in [OpenSSL](https://www.openssl.org/) as the `prime256v1` curve.
	PublicKeyFormat_ES256_PEM PublicKeyFormat = 2
	// As ES256_PEM, but wrapped in an X.509v3 certificate ([RFC5280](
	// https://www.ietf.org/rfc/rfc5280.txt)), encoded in base64, and wrapped by
	// `-----BEGIN CERTIFICATE-----` and `-----END CERTIFICATE-----`.
	PublicKeyFormat_ES256_X509_PEM PublicKeyFormat = 4
)

func (PublicKeyFormat) Descriptor

func (PublicKeyFormat) Enum

func (x PublicKeyFormat) Enum() *PublicKeyFormat

func (PublicKeyFormat) EnumDescriptor deprecated

func (PublicKeyFormat) EnumDescriptor() ([]byte, []int)

Deprecated: Use PublicKeyFormat.Descriptor instead.

func (PublicKeyFormat) Number

func (PublicKeyFormat) String

func (x PublicKeyFormat) String() string

func (PublicKeyFormat) Type

type RegistryCredential

type RegistryCredential struct {

	// The credential data. Reserved for expansion in the future.
	//
	// Types that are assignable to Credential:
	//
	//	*RegistryCredential_PublicKeyCertificate
	Credential isRegistryCredential_Credential `protobuf_oneof:"credential"`
	// contains filtered or unexported fields
}

A server-stored registry credential used to validate device credentials.

func (*RegistryCredential) Descriptor deprecated

func (*RegistryCredential) Descriptor() ([]byte, []int)

Deprecated: Use RegistryCredential.ProtoReflect.Descriptor instead.

func (*RegistryCredential) GetCredential

func (m *RegistryCredential) GetCredential() isRegistryCredential_Credential

func (*RegistryCredential) GetPublicKeyCertificate

func (x *RegistryCredential) GetPublicKeyCertificate() *PublicKeyCertificate

func (*RegistryCredential) ProtoMessage

func (*RegistryCredential) ProtoMessage()

func (*RegistryCredential) ProtoReflect

func (x *RegistryCredential) ProtoReflect() protoreflect.Message

func (*RegistryCredential) Reset

func (x *RegistryCredential) Reset()

func (*RegistryCredential) String

func (x *RegistryCredential) String() string

type RegistryCredential_PublicKeyCertificate

type RegistryCredential_PublicKeyCertificate struct {
	// A public key certificate used to verify the device credentials.
	PublicKeyCertificate *PublicKeyCertificate `protobuf:"bytes,1,opt,name=public_key_certificate,json=publicKeyCertificate,proto3,oneof"`
}

type RegistryEventData

type RegistryEventData struct {

	// Optional. The Registry event payload. Unset for deletion events.
	Payload *DeviceRegistry `protobuf:"bytes,1,opt,name=payload,proto3,oneof" json:"payload,omitempty"`
	// contains filtered or unexported fields
}

The data within all Cloud IoT Registry events.

func (*RegistryEventData) Descriptor deprecated

func (*RegistryEventData) Descriptor() ([]byte, []int)

Deprecated: Use RegistryEventData.ProtoReflect.Descriptor instead.

func (*RegistryEventData) GetPayload

func (x *RegistryEventData) GetPayload() *DeviceRegistry

func (*RegistryEventData) ProtoMessage

func (*RegistryEventData) ProtoMessage()

func (*RegistryEventData) ProtoReflect

func (x *RegistryEventData) ProtoReflect() protoreflect.Message

func (*RegistryEventData) Reset

func (x *RegistryEventData) Reset()

func (*RegistryEventData) String

func (x *RegistryEventData) String() string

type StateNotificationConfig

type StateNotificationConfig struct {

	// A Cloud Pub/Sub topic name. For example,
	// `projects/myProject/topics/deviceEvents`.
	PubsubTopicName string `protobuf:"bytes,1,opt,name=pubsub_topic_name,json=pubsubTopicName,proto3" json:"pubsub_topic_name,omitempty"`
	// contains filtered or unexported fields
}

The configuration for notification of new states received from the device.

func (*StateNotificationConfig) Descriptor deprecated

func (*StateNotificationConfig) Descriptor() ([]byte, []int)

Deprecated: Use StateNotificationConfig.ProtoReflect.Descriptor instead.

func (*StateNotificationConfig) GetPubsubTopicName

func (x *StateNotificationConfig) GetPubsubTopicName() string

func (*StateNotificationConfig) ProtoMessage

func (*StateNotificationConfig) ProtoMessage()

func (*StateNotificationConfig) ProtoReflect

func (x *StateNotificationConfig) ProtoReflect() protoreflect.Message

func (*StateNotificationConfig) Reset

func (x *StateNotificationConfig) Reset()

func (*StateNotificationConfig) String

func (x *StateNotificationConfig) String() string

type X509CertificateDetails

type X509CertificateDetails struct {

	// The entity that signed the certificate.
	Issuer string `protobuf:"bytes,1,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// The entity the certificate and public key belong to.
	Subject string `protobuf:"bytes,2,opt,name=subject,proto3" json:"subject,omitempty"`
	// The time the certificate becomes valid.
	StartTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=start_time,json=startTime,proto3" json:"start_time,omitempty"`
	// The time the certificate becomes invalid.
	ExpiryTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=expiry_time,json=expiryTime,proto3" json:"expiry_time,omitempty"`
	// The algorithm used to sign the certificate.
	SignatureAlgorithm string `protobuf:"bytes,5,opt,name=signature_algorithm,json=signatureAlgorithm,proto3" json:"signature_algorithm,omitempty"`
	// The type of public key in the certificate.
	PublicKeyType string `protobuf:"bytes,6,opt,name=public_key_type,json=publicKeyType,proto3" json:"public_key_type,omitempty"`
	// contains filtered or unexported fields
}

Details of an X.509 certificate. For informational purposes only.

func (*X509CertificateDetails) Descriptor deprecated

func (*X509CertificateDetails) Descriptor() ([]byte, []int)

Deprecated: Use X509CertificateDetails.ProtoReflect.Descriptor instead.

func (*X509CertificateDetails) GetExpiryTime

func (x *X509CertificateDetails) GetExpiryTime() *timestamppb.Timestamp

func (*X509CertificateDetails) GetIssuer

func (x *X509CertificateDetails) GetIssuer() string

func (*X509CertificateDetails) GetPublicKeyType

func (x *X509CertificateDetails) GetPublicKeyType() string

func (*X509CertificateDetails) GetSignatureAlgorithm

func (x *X509CertificateDetails) GetSignatureAlgorithm() string

func (*X509CertificateDetails) GetStartTime

func (x *X509CertificateDetails) GetStartTime() *timestamppb.Timestamp

func (*X509CertificateDetails) GetSubject

func (x *X509CertificateDetails) GetSubject() string

func (*X509CertificateDetails) ProtoMessage

func (*X509CertificateDetails) ProtoMessage()

func (*X509CertificateDetails) ProtoReflect

func (x *X509CertificateDetails) ProtoReflect() protoreflect.Message

func (*X509CertificateDetails) Reset

func (x *X509CertificateDetails) Reset()

func (*X509CertificateDetails) String

func (x *X509CertificateDetails) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL