azure.iotcentral
Module azure.iotcentral
API
Definitions
ballerinax/azure.iotcentral Ballerina library
Overview
This is a generated connector from Azure IoT Central API v1.0 OpenAPI specification.
Azure IoT Central is a service that makes it easy to connect, monitor, and manage your IoT devices at scale.
Prerequisites
- Create an Azure account
- Create an Azure IoT Central application
- Obtain tokens
- Use this guide to obtain the credentials which are needed to create the <ACCESS_TOKEN>
Clients
azure.iotcentral: Client
This is a generated connector from Azure IoT Central API v1.0 OpenAPI specification. Azure IoT Central is a service that makes it easy to connect, monitor, and manage your IoT devices at scale.
Constructor
Gets invoked to initialize the connector
.
The connector initialization requires setting the API credentials.
Create an Azure IoT Central account and obtain OAuth tokens following this guide.
init (ClientConfig clientConfig, string serviceUrl)
- clientConfig ClientConfig - The configurations to be used when initializing the
connector
- serviceUrl string - URL of the target service
apitokensList
function apitokensList(string apiVersion) returns ApiTokenCollection|error
Get the list of API tokens in an application. The token value will never be returned for security reasons.
Parameters
- apiVersion string - The version of the API being called.
Return Type
- ApiTokenCollection|error - Success
apitokensGet
Get an API token by ID.
Parameters
- apiVersion string - The version of the API being called.
- tokenId string - Unique ID for the API token.
apitokensCreate
function apitokensCreate(string apiVersion, string tokenId, ApiToken payload) returns ApiToken|error
Create a new API token in the application to use in the IoT Central public API. The token value will be returned in the response, and won't be returned again in subsequent requests.
Parameters
- apiVersion string - The version of the API being called.
- tokenId string - Unique ID for the API token.
- payload ApiToken - API token body.
apitokensRemove
Delete an API token.
Parameters
- apiVersion string - The version of the API being called.
- tokenId string - Unique ID for the API token.
devicetemplatesList
function devicetemplatesList(string apiVersion) returns DeviceTemplateCollection|error
Get the list of device templates in an application
Parameters
- apiVersion string - The version of the API being called.
Return Type
- DeviceTemplateCollection|error - Success
devicetemplatesGet
function devicetemplatesGet(string apiVersion, string deviceTemplateId) returns DeviceTemplate|error
Get a device template by ID
Parameters
- apiVersion string - The version of the API being called.
- deviceTemplateId string - Digital Twin Model Identifier of the device template, More Details
Return Type
- DeviceTemplate|error - Success
devicetemplatesCreate
function devicetemplatesCreate(string apiVersion, string deviceTemplateId, DeviceTemplate payload) returns DeviceTemplate|error
Publish a new device template. Default views will be automatically generated for new device templates created this way.
Parameters
- apiVersion string - The version of the API being called.
- deviceTemplateId string - Digital Twin Model Identifier of the device template, More Details
- payload DeviceTemplate - Device template body.
Return Type
- DeviceTemplate|error - Success
devicetemplatesRemove
Delete a device template
Parameters
- apiVersion string - The version of the API being called.
- deviceTemplateId string - Digital Twin Model Identifier of the device template, More Details
devicetemplatesUpdate
function devicetemplatesUpdate(string apiVersion, string deviceTemplateId, Payload payload) returns DeviceTemplate|error
Update the cloud properties and overrides of an existing device template via patch.
Parameters
- apiVersion string - The version of the API being called.
- deviceTemplateId string - Digital Twin Model Identifier of the device template, More Details
- payload Payload - Device template patch body.
Return Type
- DeviceTemplate|error - Success
devicesList
function devicesList(string apiVersion) returns DeviceCollection|error
Get the list of devices in an application
Parameters
- apiVersion string - The version of the API being called.
Return Type
- DeviceCollection|error - Success
devicesGet
Get a device by ID
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
devicesCreate
Create or update a device
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- payload Device - Device body.
devicesRemove
Delete a device
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
devicesUpdate
Update a device via patch
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- payload Payload - Device patch body.
devicesGetattestation
function devicesGetattestation(string apiVersion, string deviceId) returns Attestation|error
Get device attestation
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
Return Type
- Attestation|error - Success
devicesCreateattestation
function devicesCreateattestation(string apiVersion, string deviceId, Attestation payload) returns Attestation|error
Create an individual device attestation
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- payload Attestation - Individual device attestation body.
Return Type
- Attestation|error - Success
devicesRemoveattestation
Remove an individual device attestation
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
devicesUpdateattestation
function devicesUpdateattestation(string apiVersion, string deviceId, Payload payload) returns Attestation|error
Update an individual device attestation via patch
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- payload Payload - Individual device attestation patch body.
Return Type
- Attestation|error - Success
devicesGetcommandhistory
function devicesGetcommandhistory(string apiVersion, string deviceId, string commandName) returns DeviceCommandCollection|error
Get device command history
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- commandName string - Name of this device command.
Return Type
- DeviceCommandCollection|error - Success
devicesRuncommand
function devicesRuncommand(string apiVersion, string deviceId, string commandName, DeviceCommand payload) returns DeviceCommand|error
Run a device command
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- commandName string - Name of this device command.
- payload DeviceCommand - Device command body.
Return Type
- DeviceCommand|error - Success
devicesListcomponents
function devicesListcomponents(string apiVersion, string deviceId) returns Collection|error
List the components present in a device
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
Return Type
- Collection|error - Success
devicesGetcomponentcommandhistory
function devicesGetcomponentcommandhistory(string apiVersion, string deviceId, string componentName, string commandName) returns DeviceCommandCollection|error
Get component command history
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- componentName string - Name of the device component.
- commandName string - Name of this device command.
Return Type
- DeviceCommandCollection|error - Success
devicesRuncomponentcommand
function devicesRuncomponentcommand(string apiVersion, string deviceId, string componentName, string commandName, DeviceCommand payload) returns DeviceCommand|error
Run a component command
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- componentName string - Name of the device component.
- commandName string - Name of this device command.
- payload DeviceCommand - Device command body.
Return Type
- DeviceCommand|error - Success
devicesGetcomponentproperties
function devicesGetcomponentproperties(string apiVersion, string deviceId, string componentName) returns DeviceProperties|error
Get device properties for a specific component
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- componentName string - Name of the device component.
Return Type
- DeviceProperties|error - Success
devicesReplacecomponentproperties
function devicesReplacecomponentproperties(string apiVersion, string deviceId, string componentName, DeviceProperties payload) returns DeviceProperties|error
Replace device properties for a specific component
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- componentName string - Name of the device component.
- payload DeviceProperties - Device properties.
Return Type
- DeviceProperties|error - Success
devicesUpdatecomponentproperties
function devicesUpdatecomponentproperties(string apiVersion, string deviceId, string componentName, Payload payload) returns DeviceProperties|error
Update device properties for a specific component via patch
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- componentName string - Name of the device component.
- payload Payload - Device properties patch.
Return Type
- DeviceProperties|error - Success
devicesGetcomponenttelemetryvalue
function devicesGetcomponenttelemetryvalue(string apiVersion, string deviceId, string componentName, string telemetryName) returns DeviceTelemetry|error
Get component telemetry value
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- componentName string - Name of the device component.
- telemetryName string - Name of this device telemetry.
Return Type
- DeviceTelemetry|error - Success
devicesGetcredentials
function devicesGetcredentials(string apiVersion, string deviceId) returns DeviceCredentials|error
Get device credentials
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
Return Type
- DeviceCredentials|error - Success
devicesListmodules
function devicesListmodules(string apiVersion, string deviceId) returns Collection|error
List the modules present in a device
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
Return Type
- Collection|error - Success
devicesGetmodulecommandhistory
function devicesGetmodulecommandhistory(string apiVersion, string deviceId, string moduleName, string commandName) returns DeviceCommandCollection|error
Get module command history
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- commandName string - Name of this device command.
Return Type
- DeviceCommandCollection|error - Success
devicesRunmodulecommand
function devicesRunmodulecommand(string apiVersion, string deviceId, string moduleName, string commandName, DeviceCommand payload) returns DeviceCommand|error
Run a module command
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- commandName string - Name of this device command.
- payload DeviceCommand - Device command body.
Return Type
- DeviceCommand|error - Success
devicesListmodulecomponents
function devicesListmodulecomponents(string apiVersion, string deviceId, string moduleName) returns Collection|error
List the components present in a module
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
Return Type
- Collection|error - Success
devicesGetmodulecomponentcommandhistory
function devicesGetmodulecomponentcommandhistory(string apiVersion, string deviceId, string moduleName, string componentName, string commandName) returns DeviceCommandCollection|error
Get module component command history
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- componentName string - Name of the device component.
- commandName string - Name of this device command.
Return Type
- DeviceCommandCollection|error - Success
devicesRunmodulecomponentcommand
function devicesRunmodulecomponentcommand(string apiVersion, string deviceId, string moduleName, string componentName, string commandName, DeviceCommand payload) returns DeviceCommand|error
Run a module component command
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- componentName string - Name of the device component.
- commandName string - Name of this device command.
- payload DeviceCommand - Device command body.
Return Type
- DeviceCommand|error - Success
devicesGetmodulecomponentproperties
function devicesGetmodulecomponentproperties(string apiVersion, string deviceId, string moduleName, string componentName) returns DeviceProperties|error
Get module properties for a specific component
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- componentName string - Name of the device component.
Return Type
- DeviceProperties|error - Success
devicesReplacemodulecomponentproperties
function devicesReplacemodulecomponentproperties(string apiVersion, string deviceId, string moduleName, string componentName, DeviceProperties payload) returns DeviceProperties|error
Replace module properties for a specific component
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- componentName string - Name of the device component.
- payload DeviceProperties - Module properties.
Return Type
- DeviceProperties|error - Success
devicesUpdatemodulecomponentproperties
function devicesUpdatemodulecomponentproperties(string apiVersion, string deviceId, string moduleName, string componentName, Payload payload) returns DeviceProperties|error
Update module properties for a specific component via patch
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- componentName string - Name of the device component.
- payload Payload - Module properties patch.
Return Type
- DeviceProperties|error - Success
devicesGetmodulecomponenttelemetryvalue
function devicesGetmodulecomponenttelemetryvalue(string apiVersion, string deviceId, string moduleName, string componentName, string telemetryName) returns DeviceTelemetry|error
Get module component telemetry value
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- componentName string - Name of the device component.
- telemetryName string - Name of this device telemetry.
Return Type
- DeviceTelemetry|error - Success
devicesGetmoduleproperties
function devicesGetmoduleproperties(string apiVersion, string deviceId, string moduleName) returns DeviceProperties|error
Get module properties
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
Return Type
- DeviceProperties|error - Success
devicesReplacemoduleproperties
function devicesReplacemoduleproperties(string apiVersion, string deviceId, string moduleName, DeviceProperties payload) returns DeviceProperties|error
Replace module properties
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- payload DeviceProperties - Module properties.
Return Type
- DeviceProperties|error - Success
devicesUpdatemoduleproperties
function devicesUpdatemoduleproperties(string apiVersion, string deviceId, string moduleName, Payload payload) returns DeviceProperties|error
Update module properties via patch
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- payload Payload - Module properties patch.
Return Type
- DeviceProperties|error - Success
devicesGetmoduletelemetryvalue
function devicesGetmoduletelemetryvalue(string apiVersion, string deviceId, string moduleName, string telemetryName) returns DeviceTelemetry|error
Get module telemetry value
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- moduleName string - Name of the device module.
- telemetryName string - Name of this device telemetry.
Return Type
- DeviceTelemetry|error - Success
devicesGetproperties
function devicesGetproperties(string apiVersion, string deviceId) returns DeviceProperties|error
Get device properties
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
Return Type
- DeviceProperties|error - Success
devicesReplaceproperties
function devicesReplaceproperties(string apiVersion, string deviceId, DeviceProperties payload) returns DeviceProperties|error
Replace device properties
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- payload DeviceProperties - Device properties.
Return Type
- DeviceProperties|error - Success
devicesUpdateproperties
function devicesUpdateproperties(string apiVersion, string deviceId, Payload payload) returns DeviceProperties|error
Update device properties via patch
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- payload Payload - Device properties patch.
Return Type
- DeviceProperties|error - Success
devicesGettelemetryvalue
function devicesGettelemetryvalue(string apiVersion, string deviceId, string telemetryName) returns DeviceTelemetry|error
Get device telemetry value
Parameters
- apiVersion string - The version of the API being called.
- deviceId string - Unique ID of the device.
- telemetryName string - Name of this device telemetry.
Return Type
- DeviceTelemetry|error - Success
rolesList
function rolesList(string apiVersion) returns RoleCollection|error
Get the list of roles in an application.
Parameters
- apiVersion string - The version of the API being called.
Return Type
- RoleCollection|error - Success
rolesGet
Get a role by ID.
Parameters
- apiVersion string - The version of the API being called.
- roleId string - Unique ID for the role.
usersList
function usersList(string apiVersion) returns UserCollection|error
Get the list of users in an application
Parameters
- apiVersion string - The version of the API being called.
Return Type
- UserCollection|error - Success
usersGet
Get a user by ID
Parameters
- apiVersion string - The version of the API being called.
- userId string - Unique ID of the user.
usersCreate
Create a user in the application
Parameters
- apiVersion string - The version of the API being called.
- userId string - Unique ID of the user.
- payload User - User body.
usersRemove
Delete a user
Parameters
- apiVersion string - The version of the API being called.
- userId string - Unique ID of the user.
usersUpdate
Update a user in the application via patch
Records
azure.iotcentral: ApiToken
Fields
- Fields Included from *Permission
- roles RoleAssignment[]
- anydata...
azure.iotcentral: ApiTokenCollection
Fields
- value ApiToken[] - The collection of API tokens.
- nextLink string? - URL to get the next page of API tokens.
azure.iotcentral: Attestation
Fields
- 'type string - Type of the attestation.
azure.iotcentral: ClientConfig
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 string(default "1.1") - The HTTP version understood by the client
- http1Settings ClientHttp1Settings(default {}) - Configurations related to HTTP/1.x protocol
- http2Settings ClientHttp2Settings(default {}) - 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
- followRedirects FollowRedirects?(default ()) - Configurations associated with Redirection
- poolConfig PoolConfiguration?(default ()) - Configurations associated with request pooling
- cache CacheConfig(default {}) - HTTP caching related configurations
- compression Compression(default http:COMPRESSION_AUTO) - Specifies the way of handling compression (
accept-encoding
) header
- circuitBreaker CircuitBreakerConfig?(default ()) - Configurations associated with the behaviour of the Circuit Breaker
- retryConfig RetryConfig?(default ()) - Configurations associated with retrying
- cookieConfig CookieConfig?(default ()) - Configurations associated with cookies
- responseLimits ResponseLimitConfigs(default {}) - Configurations associated with inbound response size limits
- secureSocket ClientSecureSocket?(default ()) - SSL/TLS-related options
azure.iotcentral: Collection
Fields
- value record {}[] - The collection of entities.
- nextLink string? - URL to get the next page of entities.
azure.iotcentral: Device
Fields
- id string? - Unique ID of the device.
- etag string? - ETag used to prevent conflict in device updates.
- displayName string? - Display name of the device.
- template string? - The device template definition for the device.
- enabled boolean? - Whether the device connection to IoT Central has been enabled.
- provisioned boolean? - Whether resources have been allocated for the device.
- simulated boolean? - Whether the device is simulated.
azure.iotcentral: DeviceCollection
Fields
- value Device[] - The collection of devices.
- nextLink string? - URL to get the next page of devices.
azure.iotcentral: DeviceCommand
Fields
- id string? - The request ID of the device command execution.
- connectionTimeout int? - Connection timeout in seconds to wait for a disconnected device to come online. Defaults to 0 seconds.
- responseTimeout int? - Response timeout in seconds to wait for a command completion on a device. Defaults to 30 seconds.
- request record {}? - The payload for the device command.
- response record {}? - The payload of the device command response.
- responseCode int? - The status code of the device command response.
azure.iotcentral: DeviceCommandCollection
Fields
- value DeviceCommand[] - The collection of device command executions.
- nextLink string? - URL to get the next page of device command executions.
azure.iotcentral: DeviceCredentials
Fields
- idScope string - ID scope for connecting to the IoT Central application.
- symmetricKey SymmetricKey? -
- x509 X509? -
- tpm Tpm? -
azure.iotcentral: DeviceProperties
Property values associated with the device.
azure.iotcentral: DeviceTelemetry
Fields
- value record {}? - The last known value of this device telemetry.
- timestamp string? - String-formatted date representing the time when the telemetry value was sent.
azure.iotcentral: DeviceTemplate
Fields
- '\@id string? - Unique ID of the device template.
- '\@type string[] - The JSON-LD types of this device template.
- etag string? - ETag used to prevent conflict in device template updates.
- displayName string? - Display name of the device template.
- description string? - Detailed description of the device template.
- capabilityModel record {} - The capability model utilized by this device template.
azure.iotcentral: DeviceTemplateCollection
Fields
- value DeviceTemplate[] - The collection of device templates.
- nextLink string? - URL to get the next page of device templates.
azure.iotcentral: EmailUser
Fields
- Fields Included from *User
- roles RoleAssignment[]
- anydata...
azure.iotcentral: Payload
azure.iotcentral: Permission
Fields
- roles RoleAssignment[] - List of role assignments that specify the permissions to access the application.
azure.iotcentral: Role
Fields
- id string? - Unique ID of the role.
- displayName string? - Display name of the role.
azure.iotcentral: RoleAssignment
Fields
- role string - ID of the role for this role assignment.
azure.iotcentral: RoleCollection
Fields
- value Role[] - The collection of roles.
- nextLink string? - URL to get the next page of roles.
azure.iotcentral: ServicePrincipalUser
Fields
- Fields Included from *User
- roles RoleAssignment[]
- anydata...
azure.iotcentral: SymmetricKey
Fields
- primaryKey string - The primary key for this credential.
- secondaryKey string - The secondary key for this credential.
azure.iotcentral: SymmetricKeyAttestation
Fields
- Fields Included from *Attestation
- type string
- anydata...
azure.iotcentral: Tpm
Fields
- endorsementKey string - The TPM endorsement key for this credential.
azure.iotcentral: TpmAttestation
Fields
- Fields Included from *Attestation
- type string
- anydata...
azure.iotcentral: User
Fields
- Fields Included from *Permission
- roles RoleAssignment[]
- anydata...
azure.iotcentral: UserCollection
Fields
- value User[] - The collection of users.
- nextLink string? - URL to get the next page of users.
azure.iotcentral: X509
Fields
- clientCertificates X509Certificates? -
azure.iotcentral: X509Attestation
Fields
- Fields Included from *Attestation
- type string
- anydata...
azure.iotcentral: X509Certificate
Fields
- certificate string? - The string representation of this certificate.
- info X509CertificateInfo? -
azure.iotcentral: X509CertificateInfo
Fields
- sha1Thumbprint string - The SHA-1 hash value of the certificate.
azure.iotcentral: X509Certificates
Fields
- primary X509Certificate -
- secondary X509Certificate? -
Import
import ballerinax/azure.iotcentral;
Metadata
Released date: almost 3 years ago
Version: 1.2.0
License: Apache-2.0
Compatibility
Platform: any
Ballerina version: 2201.0.0
GraalVM compatible: Yes
Pull count
Total: 1
Current verison: 0
Weekly downloads
Keywords
Internet of Things/Device Management
Cost/Paid
Vendor/Microsoft
Contributors
Dependencies