azure.iothub
Module azure.iothub
API
Definitions
ballerinax/azure.iothub Ballerina library
Overview
This is a generated connector from Azure IoT Hub API v1.0 OpenAPI specification.
Azure IoT Hub is a service that offers programmatic access to the device, messaging, and job services, as well as the resource provider, in IoT Hub. You can access messaging services from within an IoT service running in Azure, or directly over the Internet from any application that can send an HTTPS request and receive an HTTPS response.
Prerequisites
- Create an Azure account
- Create an Azure IoT Hub application
- Obtain tokens
- Use this guide to obtain the credentials which are needed to create the <ACCESS_TOKEN>
Clients
azure.iothub: Client
This is a generated connector from Azure IoT Hub API v1.0 OpenAPI specification. Azure IoT Hub is a service that offers programmatic access to the device, messaging, and job services, as well as the resource provider, in IoT Hub. You can access messaging services from within an IoT service running in Azure, or directly over the Internet from any application that can send an HTTPS request and receive an HTTPS response. Use this API to manage the IoT hubs in your Azure subscription.
Constructor
Gets invoked to initialize the connector
.
The connector initialization requires setting the API credentials.
Create an Azure IoT Hub account and obtain OAuth tokens following this guide.
init (ConnectionConfig config, string serviceUrl)
- config ConnectionConfig - The configurations to be used when initializing the
connector
- serviceUrl string "https://management.azure.com/" - URL of the target service
operationsList
function operationsList(string apiVersion) returns OperationListResult|error
Lists all of the available IoT Hub REST API operations.
Parameters
- apiVersion string - The version of the API.
Return Type
- OperationListResult|error - OK. The request has succeeded.
iothubresourceListbysubscription
function iothubresourceListbysubscription(string apiVersion, string subscriptionId) returns IotHubDescriptionListResult|error
Get all the IoT hubs in a subscription
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
Return Type
- IotHubDescriptionListResult|error - This is a synchronous operation. The body contains a JSON-serialized array of the metadata from all the IoT hubs in the subscription.
iothubresourceChecknameavailability
function iothubresourceChecknameavailability(string apiVersion, string subscriptionId, OperationInputs payload) returns IotHubNameAvailabilityInfo|error
Check if an IoT hub name is available
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- payload OperationInputs - Set the name parameter in the OperationInputs structure to the name of the IoT hub to check.
Return Type
- IotHubNameAvailabilityInfo|error - This is a synchronous operation. The body contains a JSON-serialized response that specifies whether the IoT hub name is available. If the name is not available, the body contains the reason.
resourceprovidercommonGetsubscriptionquota
function resourceprovidercommonGetsubscriptionquota(string subscriptionId, string apiVersion) returns UserSubscriptionQuotaListResult|error
Get the number of iot hubs in the subscription
Parameters
- subscriptionId string - The subscription identifier.
- apiVersion string - The version of the API.
Return Type
iothubresourceListbyresourcegroup
function iothubresourceListbyresourcegroup(string apiVersion, string subscriptionId, string resourceGroupName) returns IotHubDescriptionListResult|error
Get all the IoT hubs in a resource group
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
Return Type
- IotHubDescriptionListResult|error - This is a synchronous operation. The body contains a JSON-serialized array of the metadata from all the IoT hubs in the resource group.
iothubManualfailover
function iothubManualfailover(string iotHubName, string subscriptionId, string resourceGroupName, string apiVersion, FailoverInput payload) returns Response|error
Manually initiate a failover for the IoT Hub to its secondary region
Parameters
- iotHubName string - Name of the IoT hub to failover
- subscriptionId string - The subscription identifier.
- resourceGroupName string - Name of the resource group containing the IoT hub resource
- apiVersion string - The version of the API.
- payload FailoverInput - Region to failover to. Must be the Azure paired region. Get the value from the secondary location in the locations property. To learn more, see https://aka.ms/manualfailover/region
iothubresourceTestallroutes
function iothubresourceTestallroutes(string iotHubName, string subscriptionId, string resourceGroupName, string apiVersion, TestAllRoutesInput payload) returns TestAllRoutesResult|error
Test all routes
Parameters
- iotHubName string - IotHub to be tested
- subscriptionId string - The subscription identifier.
- resourceGroupName string - resource group which Iot Hub belongs to
- apiVersion string - The version of the API.
- payload TestAllRoutesInput - Input for testing all routes
Return Type
- TestAllRoutesResult|error - OK
iothubresourceTestroute
function iothubresourceTestroute(string iotHubName, string subscriptionId, string resourceGroupName, string apiVersion, TestRouteInput payload) returns TestRouteResult|error
Test the new route
Parameters
- iotHubName string - IotHub to be tested
- subscriptionId string - The subscription identifier.
- resourceGroupName string - resource group which Iot Hub belongs to
- apiVersion string - The version of the API.
- payload TestRouteInput - Route that needs to be tested
Return Type
- TestRouteResult|error - OK
iothubresourceGetendpointhealth
function iothubresourceGetendpointhealth(string subscriptionId, string resourceGroupName, string iotHubName, string apiVersion) returns EndpointHealthDataListResult|error
Get the health for routing endpoints
Parameters
- subscriptionId string - The subscription identifier.
- resourceGroupName string -
- iotHubName string -
- apiVersion string - The version of the API.
Return Type
iothubresourceGet
function iothubresourceGet(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns IotHubDescription|error
Get the non-security related metadata of an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- IotHubDescription|error - The body contains all the non-security properties of the IoT hub. Security-related properties are set to null.
iothubresourceCreateorupdate
function iothubresourceCreateorupdate(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, IotHubDescription payload, string? ifMatch) returns IotHubDescription|error
Create or update the metadata of an IoT hub.
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- payload IotHubDescription - The IoT hub metadata and security metadata.
- ifMatch string? (default ()) - ETag of the IoT Hub. Do not specify for creating a brand new IoT Hub. Required to update an existing IoT Hub.
Return Type
- IotHubDescription|error - This is returned as a response to the status polling request for the create or update operation. The body contains the resource representation that indicates a transitional provisioning state.
iothubresourceDelete
function iothubresourceDelete(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns IotHubDescription|error?
Delete an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- IotHubDescription|error? - This is returned as a response to the status polling request for the delete operation. The body contains the resource representation that indicates a transitional provisioning state.
iothubresourceUpdate
function iothubresourceUpdate(string subscriptionId, string resourceGroupName, string resourceName, string apiVersion, TagsResource payload) returns IotHubDescription|error
Update an existing IoT Hubs tags.
Parameters
- subscriptionId string - The subscription identifier.
- resourceGroupName string - Resource group identifier.
- resourceName string - Name of iot hub to update.
- apiVersion string - The version of the API.
- payload TagsResource - Updated tag information to set into the iot hub instance.
Return Type
- IotHubDescription|error - Iot Hub was successfully updated
iothubresourceGetkeysforkeyname
function iothubresourceGetkeysforkeyname(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string keyName) returns SharedAccessSignatureAuthorizationRule|error
Get a shared access policy by name from an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-security
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- keyName string - The name of the shared access policy.
Return Type
- SharedAccessSignatureAuthorizationRule|error - This is a synchronous operation. The body contains a JSON-serialized shared access policy, including keys, that you can use to access one or more IoT hub endpoints.
iothubresourceGetstats
function iothubresourceGetstats(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns RegistryStatistics|error
Get the statistics from an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- RegistryStatistics|error - This is a synchronous operation. The body contains JSON-serialized statistics from the identity registry in the IoT hub.
certificatesListbyiothub
function certificatesListbyiothub(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns CertificateListDescription|error
Get the certificate list.
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- CertificateListDescription|error - The body contains all the certificate list.
certificatesGet
function certificatesGet(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string certificateName) returns CertificateDescription|error
Get the certificate.
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- certificateName string - The name of the certificate
Return Type
- CertificateDescription|error - The body contains the certificate.
certificatesCreateorupdate
function certificatesCreateorupdate(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string certificateName, CertificateBodyDescription payload, string? ifMatch) returns CertificateDescription|error
Upload the certificate to the IoT hub.
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- certificateName string - The name of the certificate
- payload CertificateBodyDescription - The certificate body.
- ifMatch string? (default ()) - ETag of the Certificate. Do not specify for creating a brand new certificate. Required to update an existing certificate.
Return Type
- CertificateDescription|error - If certificate already exist and update was successful, the operation returns HTTP status code of 201 (OK).
certificatesDelete
function certificatesDelete(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string certificateName, string ifMatch) returns Response|error
Delete an X509 certificate.
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- certificateName string - The name of the certificate
- ifMatch string - ETag of the Certificate.
certificatesGenerateverificationcode
function certificatesGenerateverificationcode(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string certificateName, string ifMatch) returns CertificateWithNonceDescription|error
Generate verification code for proof of possession flow.
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- certificateName string - The name of the certificate
- ifMatch string - ETag of the Certificate.
Return Type
- CertificateWithNonceDescription|error - The body contains the certificate.
certificatesVerify
function certificatesVerify(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string certificateName, string ifMatch, CertificateVerificationDescription payload) returns CertificateDescription|error
Verify certificate's private key possession.
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- certificateName string - The name of the certificate
- ifMatch string - ETag of the Certificate.
- payload CertificateVerificationDescription - The name of the certificate
Return Type
- CertificateDescription|error - The body contains the certificate.
iothubresourceListeventhubconsumergroups
function iothubresourceListeventhubconsumergroups(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string eventHubEndpointName) returns EventHubConsumerGroupsListResult|error
Get a list of the consumer groups in the Event Hub-compatible device-to-cloud endpoint in an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- eventHubEndpointName string - The name of the Event Hub-compatible endpoint.
Return Type
- EventHubConsumerGroupsListResult|error - This is a synchronous operation. The body contains a JSON-serialized list of the consumer groups in the Event Hub-compatible endpoint in this IoT hub
iothubresourceGeteventhubconsumergroup
function iothubresourceGeteventhubconsumergroup(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string eventHubEndpointName, string name) returns EventHubConsumerGroupInfo|error
Get a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- eventHubEndpointName string - The name of the Event Hub-compatible endpoint in the IoT hub.
- name string - The name of the consumer group to retrieve.
Return Type
- EventHubConsumerGroupInfo|error - This is a synchronous operation. The body contains a JSON-serialized consumer group.
iothubresourceCreateeventhubconsumergroup
function iothubresourceCreateeventhubconsumergroup(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string eventHubEndpointName, string name) returns EventHubConsumerGroupInfo|error
Add a consumer group to an Event Hub-compatible endpoint in an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- eventHubEndpointName string - The name of the Event Hub-compatible endpoint in the IoT hub.
- name string - The name of the consumer group to add.
Return Type
- EventHubConsumerGroupInfo|error - This is a synchronous operation.
iothubresourceDeleteeventhubconsumergroup
function iothubresourceDeleteeventhubconsumergroup(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string eventHubEndpointName, string name) returns Response|error
Delete a consumer group from an Event Hub-compatible endpoint in an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- eventHubEndpointName string - The name of the Event Hub-compatible endpoint in the IoT hub.
- name string - The name of the consumer group to delete.
iothubresourceExportdevices
function iothubresourceExportdevices(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, ExportDevicesRequest payload) returns JobResponse|error
Exports all the device identities in the IoT hub identity registry to an Azure Storage blob container. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- payload ExportDevicesRequest - The parameters that specify the export devices operation.
Return Type
- JobResponse|error - OK
iothubresourceImportdevices
function iothubresourceImportdevices(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, ImportDevicesRequest payload) returns JobResponse|error
Import, update, or delete device identities in the IoT hub identity registry from a blob. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- payload ImportDevicesRequest - The parameters that specify the import devices operation.
Return Type
- JobResponse|error - OK
iothubresourceListjobs
function iothubresourceListjobs(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns JobResponseListResult|error
Get a list of all the jobs in an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- JobResponseListResult|error - This is a synchronous operation. The response contains a JSON-serialized array of all the jobs in the IoT hub.
iothubresourceGetjob
function iothubresourceGetjob(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName, string jobId) returns JobResponse|error
Get the details of a job from an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
- jobId string - The job identifier.
Return Type
- JobResponse|error - This is a synchronous operation. The response contains a JSON-serialized description of the job in the IoT hub.
iothubresourceListkeys
function iothubresourceListkeys(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns SharedAccessSignatureAuthorizationRuleListResult|error
Get the security metadata for an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-security
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- SharedAccessSignatureAuthorizationRuleListResult|error - This is a synchronous operation. The body contains a JSON-serialized array of shared access policies, including keys, that you can use to access the IoT hub endpoints.
iothubresourceGetquotametrics
function iothubresourceGetquotametrics(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns IotHubQuotaMetricInfoListResult|error
Get the quota metrics for an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- IotHubQuotaMetricInfoListResult|error - This is a synchronous operation. The response contains a JSON-serialized array of the quota metrics for the IoT hub.
iothubresourceGetvalidskus
function iothubresourceGetvalidskus(string apiVersion, string subscriptionId, string resourceGroupName, string resourceName) returns IotHubSkuDescriptionListResult|error
Get the list of valid SKUs for an IoT hub
Parameters
- apiVersion string - The version of the API.
- subscriptionId string - The subscription identifier.
- resourceGroupName string - The name of the resource group that contains the IoT hub.
- resourceName string - The name of the IoT hub.
Return Type
- IotHubSkuDescriptionListResult|error - This is a synchronous operation. The body contains a JSON-serialized array of the valid SKUs for this IoT hub.
Records
azure.iothub: CertificateBodyDescription
The JSON-serialized X509 Certificate.
Fields
- certificate string? - base-64 representation of the X509 leaf certificate .cer file or just .pem file content.
azure.iothub: CertificateDescription
The X509 Certificate.
Fields
- etag string? - The entity tag.
- id string? - The resource identifier.
- name string? - The name of the certificate.
- properties CertificateProperties? - The description of an X509 CA Certificate.
- 'type string? - The resource type.
azure.iothub: CertificateListDescription
The JSON-serialized array of Certificate objects.
Fields
- value CertificateDescription[]? - The array of Certificate objects.
azure.iothub: CertificateProperties
The description of an X509 CA Certificate.
Fields
- certificate string? - The certificate content
- created string? - The certificate's create date and time.
- expiry string? - The certificate's expiration date and time.
- isVerified boolean? - Determines whether certificate has been verified.
- subject string? - The certificate's subject name.
- thumbprint string? - The certificate's thumbprint.
- updated string? - The certificate's last update date and time.
azure.iothub: CertificatePropertiesWithNonce
The description of an X509 CA Certificate including the challenge nonce issued for the Proof-Of-Possession flow.
Fields
- certificate string? - The certificate content
- created string? - The certificate's create date and time.
- expiry string? - The certificate's expiration date and time.
- isVerified boolean? - Determines whether certificate has been verified.
- subject string? - The certificate's subject name.
- thumbprint string? - The certificate's thumbprint.
- updated string? - The certificate's last update date and time.
- verificationCode string? - The certificate's verification code that will be used for proof of possession.
azure.iothub: CertificateVerificationDescription
The JSON-serialized leaf certificate
Fields
- certificate string? - base-64 representation of X509 certificate .cer file or just .pem file content.
azure.iothub: CertificateWithNonceDescription
The X509 Certificate.
Fields
- etag string? - The entity tag.
- id string? - The resource identifier.
- name string? - The name of the certificate.
- properties CertificatePropertiesWithNonce? - The description of an X509 CA Certificate including the challenge nonce issued for the Proof-Of-Possession flow.
- 'type string? - The resource type.
azure.iothub: ClientHttp1Settings
Provides settings related to HTTP/1.x protocol.
Fields
- keepAlive KeepAlive(default http:KEEPALIVE_AUTO) - Specifies whether to reuse a connection for multiple requests
- chunking Chunking(default http:CHUNKING_AUTO) - The chunking behaviour of the request
- proxy ProxyConfig? - Proxy server related options
azure.iothub: CloudToDeviceProperties
The IoT hub cloud-to-device messaging properties.
Fields
- defaultTtlAsIso8601 string? - The default time to live for cloud-to-device messages in the device queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.
- feedback FeedbackProperties? - The properties of the feedback queue for cloud-to-device messages.
- maxDeliveryCount int? - The max delivery count for cloud-to-device messages in the device queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.
azure.iothub: ConnectionConfig
Provides a set of configurations for controlling the behaviours when communicating with a remote HTTP endpoint.
Fields
- auth BearerTokenConfig - Configurations related to client authentication
- httpVersion HttpVersion(default http:HTTP_2_0) - The HTTP version understood by the client
- http1Settings ClientHttp1Settings? - Configurations related to HTTP/1.x protocol
- http2Settings ClientHttp2Settings? - Configurations related to HTTP/2 protocol
- timeout decimal(default 60) - The maximum time to wait (in seconds) for a response before closing the connection
- forwarded string(default "disable") - The choice of setting
forwarded
/x-forwarded
header
- poolConfig PoolConfiguration? - Configurations associated with request pooling
- cache CacheConfig? - HTTP caching related configurations
- compression Compression(default http:COMPRESSION_AUTO) - Specifies the way of handling compression (
accept-encoding
) header
- circuitBreaker CircuitBreakerConfig? - Configurations associated with the behaviour of the Circuit Breaker
- retryConfig RetryConfig? - Configurations associated with retrying
- responseLimits ResponseLimitConfigs? - Configurations associated with inbound response size limits
- secureSocket ClientSecureSocket? - SSL/TLS-related options
- proxy ProxyConfig? - Proxy server related options
- validation boolean(default true) - Enables the inbound payload validation functionality which provided by the constraint package. Enabled by default
azure.iothub: EndpointHealthData
The health data for an endpoint
Fields
- endpointId string? - Id of the endpoint
- healthStatus string? - Health statuses have following meanings. The 'healthy' status shows that the endpoint is accepting messages as expected. The 'unhealthy' status shows that the endpoint is not accepting messages as expected and IoT Hub is retrying to send data to this endpoint. The status of an unhealthy endpoint will be updated to healthy when IoT Hub has established an eventually consistent state of health. The 'dead' status shows that the endpoint is not accepting messages, after IoT Hub retried sending messages for the retrial period. See IoT Hub metrics to identify errors and monitor issues with endpoints. The 'unknown' status shows that the IoT Hub has not established a connection with the endpoint. No messages have been delivered to or rejected from this endpoint
azure.iothub: EndpointHealthDataListResult
The JSON-serialized array of EndpointHealthData objects with a next link.
Fields
- nextLink string? - Link to more results
- value EndpointHealthData[]? - JSON-serialized array of Endpoint health data
azure.iothub: EnrichmentProperties
The properties of an enrichment that your IoT hub applies to messages delivered to endpoints.
Fields
- endpointNames string[] - The list of endpoints for which the enrichment is applied to the message.
- 'key string - The key or name for the enrichment property.
- value string - The value for the enrichment property.
azure.iothub: ErrorDetails
Error details.
Fields
- code string? - The error code.
- details string? - The error details.
- httpStatusCode string? - The HTTP status code.
- message string? - The error message.
azure.iothub: EventHubConsumerGroupInfo
The properties of the EventHubConsumerGroupInfo object.
Fields
- etag string? - The etag.
- id string? - The Event Hub-compatible consumer group identifier.
- name string? - The Event Hub-compatible consumer group name.
- properties record {}? - The tags.
- 'type string? - the resource type.
azure.iothub: EventHubConsumerGroupsListResult
The JSON-serialized array of Event Hub-compatible consumer group names with a next link.
Fields
- nextLink string? - The next link.
- value EventHubConsumerGroupInfo[]? - List of consumer groups objects
azure.iothub: EventHubProperties
The properties of the provisioned Event Hub-compatible endpoint used by the IoT hub.
Fields
- endpoint string? - The Event Hub-compatible endpoint.
- partitionCount int? - The number of partitions for receiving device-to-cloud messages in the Event Hub-compatible endpoint. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#device-to-cloud-messages.
- partitionIds string[]? - The partition ids in the Event Hub-compatible endpoint.
- path string? - The Event Hub-compatible name.
- retentionTimeInDays int? - The retention time for device-to-cloud messages in days. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#device-to-cloud-messages
azure.iothub: ExportDevicesRequest
Use to provide parameters when requesting an export of all devices in the IoT hub.
Fields
- excludeKeys boolean - The value indicating whether keys should be excluded during export.
- exportBlobContainerUri string - The export blob container URI.
azure.iothub: FailoverInput
Use to provide failover region when requesting manual Failover for a hub.
Fields
- failoverRegion string - Region the hub will be failed over to
azure.iothub: FallbackRouteProperties
The properties of the fallback route. IoT Hub uses these properties when it routes messages to the fallback endpoint.
Fields
- condition string? - The condition which is evaluated in order to apply the fallback route. If the condition is not provided it will evaluate to true by default. For grammar, See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-query-language
- endpointNames string[] - The list of endpoints to which the messages that satisfy the condition are routed to. Currently only 1 endpoint is allowed.
- isEnabled boolean - Used to specify whether the fallback route is enabled.
- name string? - The name of the route. The name can only include alphanumeric characters, periods, underscores, hyphens, has a maximum length of 64 characters, and must be unique.
- 'source string - The source to which the routing rule is to be applied to. For example, DeviceMessages
azure.iothub: FeedbackProperties
The properties of the feedback queue for cloud-to-device messages.
Fields
- lockDurationAsIso8601 string? - The lock duration for the feedback queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.
- maxDeliveryCount int? - The number of times the IoT hub attempts to deliver a message on the feedback queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.
- ttlAsIso8601 string? - The period of time for which a message is available to consume before it is expired by the IoT hub. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.
azure.iothub: ImportDevicesRequest
Use to provide parameters when requesting an import of all devices in the hub.
Fields
- inputBlobContainerUri string - The input blob container URI.
- outputBlobContainerUri string - The output blob container URI.
azure.iothub: IotHubCapacity
IoT Hub capacity information.
Fields
- default int? - The default number of units.
- maximum int? - The maximum number of units.
- minimum int? - The minimum number of units.
- scaleType string? - The type of the scaling enabled.
azure.iothub: IotHubDescriptionListResult
The JSON-serialized array of IotHubDescription objects with a next link.
Fields
- nextLink string? - The next link.
- value IotHubDescription[]? - The array of IotHubDescription objects.
azure.iothub: IotHubLocationDescription
Public representation of one of the locations where a resource is provisioned.
Fields
- location string? - The name of the Azure region
- role string? - The role of the region, can be either primary or secondary. The primary region is where the IoT hub is currently provisioned. The secondary region is the Azure disaster recovery (DR) paired region and also the region where the IoT hub can failover to.
azure.iothub: IotHubNameAvailabilityInfo
The properties indicating whether a given IoT hub name is available.
Fields
- message string? - The detailed reason message.
- nameAvailable boolean? - The value which indicates whether the provided name is available.
- reason string? - The reason for unavailability.
azure.iothub: IotHubProperties
The properties of an IoT hub.
Fields
- authorizationPolicies SharedAccessSignatureAuthorizationRule[]? - The shared access policies you can use to secure a connection to the IoT hub.
- cloudToDevice CloudToDeviceProperties? - The IoT hub cloud-to-device messaging properties.
- comments string? - IoT hub comments.
- enableFileUploadNotifications boolean? - If True, file upload notifications are enabled.
- eventHubEndpoints record {}? - The Event Hub-compatible endpoint properties. The only possible keys to this dictionary is events. This key has to be present in the dictionary while making create or update calls for the IoT hub.
- features string? - The capabilities and features enabled for the IoT hub.
- hostName string? - The name of the host.
- ipFilterRules IpFilterRule[]? - The IP filter rules.
- locations IotHubLocationDescription[]? - Primary and secondary location for iot hub
- messagingEndpoints record {}? - The messaging endpoint properties for the file upload notification queue.
- provisioningState string? - The provisioning state.
- routing RoutingProperties? - The routing related properties of the IoT hub. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging
- state string? - The hub state.
- storageEndpoints record {}? - The list of Azure Storage endpoints where you can upload files. Currently you can configure only one Azure Storage account and that MUST have its key as $default. Specifying more than one storage account causes an error to be thrown. Not specifying a value for this property when the enableFileUploadNotifications property is set to True, causes an error to be thrown.
azure.iothub: IotHubQuotaMetricInfo
Quota metrics properties.
Fields
- currentValue int? - The current value for the quota metric.
- maxValue int? - The maximum value of the quota metric.
- name string? - The name of the quota metric.
azure.iothub: IotHubQuotaMetricInfoListResult
The JSON-serialized array of IotHubQuotaMetricInfo objects with a next link.
Fields
- nextLink string? - The next link.
- value IotHubQuotaMetricInfo[]? - The array of quota metrics objects.
azure.iothub: IotHubSkuDescription
SKU properties.
Fields
- capacity IotHubCapacity - IoT Hub capacity information.
- resourceType string? - The type of the resource.
- sku IotHubSkuInfo - Information about the SKU of the IoT hub.
azure.iothub: IotHubSkuDescriptionListResult
The JSON-serialized array of IotHubSkuDescription objects with a next link.
Fields
- nextLink string? - The next link.
- value IotHubSkuDescription[]? - The array of IotHubSkuDescription.
azure.iothub: IotHubSkuInfo
Information about the SKU of the IoT hub.
Fields
- capacity int? - The number of provisioned IoT Hub units. See: https://docs.microsoft.com/azure/azure-subscription-service-limits#iot-hub-limits.
- name string - The name of the SKU.
- tier string? - The billing tier for the IoT hub.
azure.iothub: IpFilterRule
The IP filter rules for the IoT hub.
Fields
- action string - The desired action for requests captured by this rule.
- filterName string - The name of the IP filter rule.
- ipMask string - A string that contains the IP address range in CIDR notation for the rule.
azure.iothub: JobResponse
The properties of the Job Response object.
Fields
- endTimeUtc string? - The time the job stopped processing.
- failureReason string? - If status == failed, this string containing the reason for the failure.
- jobId string? - The job identifier.
- parentJobId string? - The job identifier of the parent job, if any.
- startTimeUtc string? - The start time of the job.
- status string? - The status of the job.
- statusMessage string? - The status message for the job.
- 'type string? - The type of the job.
azure.iothub: JobResponseListResult
The JSON-serialized array of JobResponse objects with a next link.
Fields
- nextLink string? - The next link.
- value JobResponse[]? - The array of JobResponse objects.
azure.iothub: MatchedRoute
Routes that matched
Fields
- properties RouteProperties? - The properties of a routing rule that your IoT hub uses to route messages to endpoints.
azure.iothub: MessagingEndpointProperties
The properties of the messaging endpoints used by this IoT hub.
Fields
- lockDurationAsIso8601 string? - The lock duration. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload.
- maxDeliveryCount int? - The number of times the IoT hub attempts to deliver a message. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload.
- ttlAsIso8601 string? - The period of time for which a message is available to consume before it is expired by the IoT hub. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload.
azure.iothub: Name
Name of Iot Hub type
Fields
- localizedValue string? - Localized value of name
- value string? - IotHub type
azure.iothub: Operation
IoT Hub REST API operation
Fields
- display OperationDisplay? - The object that represents the operation.
- name string? - Operation name: {provider}/{resource}/{read | write | action | delete}
azure.iothub: OperationDisplay
The object that represents the operation.
Fields
- description string? - Description of the operation
- operation string? - Name of the operation
- provider string? - Service provider: Microsoft Devices
- 'resource string? - Resource Type: IotHubs
azure.iothub: OperationInputs
Input values.
Fields
- name string - The name of the IoT hub to check.
azure.iothub: OperationListResult
Result of the request to list IoT Hub operations. It contains a list of operations and a URL link to get the next set of results.
Fields
- nextLink string? - URL to get the next set of operation list results if there are any.
- value Operation[]? - List of IoT Hub operations supported by the Microsoft.Devices resource provider.
azure.iothub: ProxyConfig
Proxy server configurations to be used with the HTTP client endpoint.
Fields
- host string(default "") - Host name of the proxy server
- port int(default 0) - Proxy server port
- userName string(default "") - Proxy server username
- password string(default "") - Proxy server password
azure.iothub: RegistryStatistics
Identity registry statistics.
Fields
- disabledDeviceCount int? - The count of disabled devices in the identity registry.
- enabledDeviceCount int? - The count of enabled devices in the identity registry.
- totalDeviceCount int? - The total count of devices in the identity registry.
azure.iothub: Resource
The common properties of an Azure resource.
Fields
- id string? - The resource identifier.
- location string - The resource location.
- name string? - The resource name.
- tags record {}? - The resource tags.
- 'type string? - The resource type.
azure.iothub: RouteCompilationError
Compilation error when evaluating route
Fields
- location RouteErrorRange? - Range of route errors
- message string? - Route error message
- severity string? - Severity of the route error
azure.iothub: RouteErrorPosition
Position where the route error happened
Fields
- column int? - Column where the route error happened
- line int? - Line where the route error happened
azure.iothub: RouteErrorRange
Range of route errors
Fields
- end RouteErrorPosition? - Position where the route error happened
- 'start RouteErrorPosition? - Position where the route error happened
azure.iothub: RouteProperties
The properties of a routing rule that your IoT hub uses to route messages to endpoints.
Fields
- condition string? - The condition that is evaluated to apply the routing rule. If no condition is provided, it evaluates to true by default. For grammar, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-query-language
- endpointNames string[] - The list of endpoints to which messages that satisfy the condition are routed. Currently only one endpoint is allowed.
- isEnabled boolean - Used to specify whether a route is enabled.
- name string - The name of the route. The name can only include alphanumeric characters, periods, underscores, hyphens, has a maximum length of 64 characters, and must be unique.
- 'source string - The source that the routing rule is to be applied to, such as DeviceMessages.
azure.iothub: RoutingEndpoints
The properties related to the custom endpoints to which your IoT hub routes messages based on the routing rules. A maximum of 10 custom endpoints are allowed across all endpoint types for paid hubs and only 1 custom endpoint is allowed across all endpoint types for free hubs.
Fields
- eventHubs RoutingEventHubProperties[]? - The list of Event Hubs endpoints that IoT hub routes messages to, based on the routing rules. This list does not include the built-in Event Hubs endpoint.
- serviceBusQueues RoutingServiceBusQueueEndpointProperties[]? - The list of Service Bus queue endpoints that IoT hub routes the messages to, based on the routing rules.
- serviceBusTopics RoutingServiceBusTopicEndpointProperties[]? - The list of Service Bus topic endpoints that the IoT hub routes the messages to, based on the routing rules.
- storageContainers RoutingStorageContainerProperties[]? - The list of storage container endpoints that IoT hub routes messages to, based on the routing rules.
azure.iothub: RoutingEventHubProperties
The properties related to an event hub endpoint.
Fields
- connectionString string - The connection string of the event hub endpoint.
- name string - The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types.
- resourceGroup string? - The name of the resource group of the event hub endpoint.
- subscriptionId string? - The subscription identifier of the event hub endpoint.
azure.iothub: RoutingMessage
Routing message
Fields
- appProperties record {}? - App properties
- body string? - Body of routing message
- systemProperties record {}? - System properties
azure.iothub: RoutingProperties
The routing related properties of the IoT hub. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging
Fields
- endpoints RoutingEndpoints? - The properties related to the custom endpoints to which your IoT hub routes messages based on the routing rules. A maximum of 10 custom endpoints are allowed across all endpoint types for paid hubs and only 1 custom endpoint is allowed across all endpoint types for free hubs.
- enrichments EnrichmentProperties[]? - The list of user-provided enrichments that the IoT hub applies to messages to be delivered to built-in and custom endpoints. See: https://aka.ms/telemetryoneventgrid
- fallbackRoute FallbackRouteProperties? - The properties of the fallback route. IoT Hub uses these properties when it routes messages to the fallback endpoint.
- routes RouteProperties[]? - The list of user-provided routing rules that the IoT hub uses to route messages to built-in and custom endpoints. A maximum of 100 routing rules are allowed for paid hubs and a maximum of 5 routing rules are allowed for free hubs.
azure.iothub: RoutingServiceBusQueueEndpointProperties
The properties related to service bus queue endpoint types.
Fields
- connectionString string - The connection string of the service bus queue endpoint.
- name string - The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types. The name need not be the same as the actual queue name.
- resourceGroup string? - The name of the resource group of the service bus queue endpoint.
- subscriptionId string? - The subscription identifier of the service bus queue endpoint.
azure.iothub: RoutingServiceBusTopicEndpointProperties
The properties related to service bus topic endpoint types.
Fields
- connectionString string - The connection string of the service bus topic endpoint.
- name string - The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types. The name need not be the same as the actual topic name.
- resourceGroup string? - The name of the resource group of the service bus topic endpoint.
- subscriptionId string? - The subscription identifier of the service bus topic endpoint.
azure.iothub: RoutingStorageContainerProperties
The properties related to a storage container endpoint.
Fields
- batchFrequencyInSeconds int? - Time interval at which blobs are written to storage. Value should be between 60 and 720 seconds. Default value is 300 seconds.
- connectionString string - The connection string of the storage account.
- containerName string - The name of storage container in the storage account.
- encoding string? - Encoding that is used to serialize messages to blobs. Supported values are 'avro', 'avrodeflate', and 'JSON'. Default value is 'avro'.
- fileNameFormat string? - File name format for the blob. Default format is {iothub}/{partition}/{YYYY}/{MM}/{DD}/{HH}/{mm}. All parameters are mandatory but can be reordered.
- maxChunkSizeInBytes int? - Maximum number of bytes for each blob written to storage. Value should be between 10485760(10MB) and 524288000(500MB). Default value is 314572800(300MB).
- name string - The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types.
- resourceGroup string? - The name of the resource group of the storage account.
- subscriptionId string? - The subscription identifier of the storage account.
azure.iothub: RoutingTwin
Twin reference input parameter. This is an optional parameter
Fields
- properties RoutingtwinProperties? -
- tags record {}? - Twin Tags
azure.iothub: RoutingtwinProperties
Fields
- desired record {}? - Twin desired properties
- reported record {}? - Twin desired properties
azure.iothub: SharedAccessSignatureAuthorizationRule
The properties of an IoT hub shared access policy.
Fields
- keyName string - The name of the shared access policy.
- primaryKey string? - The primary key.
- rights string - The permissions assigned to the shared access policy.
- secondaryKey string? - The secondary key.
azure.iothub: SharedAccessSignatureAuthorizationRuleListResult
The list of shared access policies with a next link.
Fields
- nextLink string? - The next link.
- value SharedAccessSignatureAuthorizationRule[]? - The list of shared access policies.
azure.iothub: StorageEndpointProperties
The properties of the Azure Storage endpoint for file upload.
Fields
- connectionString string - The connection string for the Azure Storage account to which files are uploaded.
- containerName string - The name of the root container where you upload files. The container need not exist but should be creatable using the connectionString specified.
- sasTtlAsIso8601 string? - The period of time for which the SAS URI generated by IoT Hub for file upload is valid. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload#file-upload-notification-configuration-options.
azure.iothub: TagsResource
A container holding only the Tags for a resource, allowing the user to update the tags on an IoT Hub instance.
Fields
- tags record {}? - Resource tags
azure.iothub: TestAllRoutesInput
Input for testing all routes
Fields
- message RoutingMessage? - Routing message
- routingSource string? - Routing source
- twin RoutingTwin? - Twin reference input parameter. This is an optional parameter
azure.iothub: TestAllRoutesResult
Result of testing all routes
Fields
- routes MatchedRoute[]? - JSON-serialized array of matched routes
azure.iothub: TestRouteInput
Input for testing route
Fields
- message RoutingMessage? - Routing message
- route RouteProperties - The properties of a routing rule that your IoT hub uses to route messages to endpoints.
- twin RoutingTwin? - Twin reference input parameter. This is an optional parameter
azure.iothub: TestRouteResult
Result of testing one route
Fields
- details TestRouteResultDetails? - Detailed result of testing a route
- result string? - Result of testing route
azure.iothub: TestRouteResultDetails
Detailed result of testing a route
Fields
- compilationErrors RouteCompilationError[]? - JSON-serialized list of route compilation errors
azure.iothub: UserSubscriptionQuota
User subscription quota response
Fields
- currentValue int? - Current number of IotHub type
- id string? - IotHub type id
- 'limit int? - Numerical limit on IotHub type
- name Name? - Name of Iot Hub type
- 'type string? - Response type
- unit string? - Unit of IotHub type
azure.iothub: UserSubscriptionQuotaListResult
Json-serialized array of User subscription quota response
Fields
- nextLink string? -
- value UserSubscriptionQuota[]? -
Import
import ballerinax/azure.iothub;
Metadata
Released date: over 1 year ago
Version: 1.5.1
License: Apache-2.0
Compatibility
Platform: any
Ballerina version: 2201.4.1
GraalVM compatible: Yes
Pull count
Total: 1
Current verison: 1
Weekly downloads
Keywords
Internet of Things/Device Management
Cost/Paid
Vendor/Microsoft
Contributors