Class: AWS.IotData
- Inherits:
-
AWS.Service
- Object
- AWS.Service
- AWS.IotData
- Identifier:
- iotdata
- API Version:
- 2015-05-28
- Defined in:
- lib/services/iotdata.js
Overview
You must provide an endpoint
configuration parameter when
constructing this service. See constructor() for more information.
Constructs a service interface object. Each API operation is exposed as a function on service.
Sending a Request Using IotData
var iotdata = new AWS.IotData({endpoint: 'my.host.tld'});
iotdata.getThingShadow(params, function (err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Locking the API Version
In order to ensure that the IotData object uses this specific API,
you can construct the object by passing the apiVersion
option to the
constructor:
var iotdata = new AWS.IotData({
endpoint: 'my.host.tld',
apiVersion: '2015-05-28'
});
You can also set the API version globally in AWS.config.apiVersions
using
the iotdata service identifier:
AWS.config.apiVersions = {
iotdata: '2015-05-28',
// other service API versions
};
var iotdata = new AWS.IotData({endpoint: 'my.host.tld'});
Constructor Summary collapse
-
new AWS.IotData(options = {}) ⇒ Object
constructor
Constructs a service object.
Property Summary collapse
-
endpoint ⇒ AWS.Endpoint
readwrite
An Endpoint object representing the endpoint URL for service requests.
Properties inherited from AWS.Service
Method Summary collapse
-
deleteThingShadow(params = {}, callback) ⇒ AWS.Request
Deletes the shadow for the specified thing.
Requires permission to access the DeleteThingShadow action.
For more information, see DeleteThingShadow in the IoT Developer Guide.
. -
getRetainedMessage(params = {}, callback) ⇒ AWS.Request
Gets the details of a single retained message for the specified topic.
This action returns the message payload of the retained message, which can incur messaging costs.
-
getThingShadow(params = {}, callback) ⇒ AWS.Request
Gets the shadow for the specified thing.
Requires permission to access the GetThingShadow action.
For more information, see GetThingShadow in the IoT Developer Guide.
. -
listNamedShadowsForThing(params = {}, callback) ⇒ AWS.Request
Lists the shadows for the specified thing.
Requires permission to access the ListNamedShadowsForThing action.
. -
listRetainedMessages(params = {}, callback) ⇒ AWS.Request
Lists summary information about the retained messages stored for the account.
This action returns only the topic names of the retained messages.
-
publish(params = {}, callback) ⇒ AWS.Request
Publishes an MQTT message.
Requires permission to access the Publish action.
For more information about MQTT messages, see MQTT Protocol in the IoT Developer Guide.
For more information about messaging costs, see IoT Core pricing - Messaging.
. -
updateThingShadow(params = {}, callback) ⇒ AWS.Request
Updates the shadow for the specified thing.
Requires permission to access the UpdateThingShadow action.
For more information, see UpdateThingShadow in the IoT Developer Guide.
.
Methods inherited from AWS.Service
makeRequest, makeUnauthenticatedRequest, waitFor, defineService
Constructor Details
new AWS.IotData(options = {}) ⇒ Object
You must provide an endpoint
when constructing this service.
Constructs a service object. This object has one method for each API operation.
Property Details
Method Details
deleteThingShadow(params = {}, callback) ⇒ AWS.Request
Deletes the shadow for the specified thing.
Requires permission to access the DeleteThingShadow action.
For more information, see DeleteThingShadow in the IoT Developer Guide.
getRetainedMessage(params = {}, callback) ⇒ AWS.Request
Gets the details of a single retained message for the specified topic.
This action returns the message payload of the retained message, which can incur messaging costs. To list only the topic names of the retained messages, call ListRetainedMessages.
Requires permission to access the GetRetainedMessage action.
For more information about messaging costs, see IoT Core pricing - Messaging.
getThingShadow(params = {}, callback) ⇒ AWS.Request
Gets the shadow for the specified thing.
Requires permission to access the GetThingShadow action.
For more information, see GetThingShadow in the IoT Developer Guide.
listNamedShadowsForThing(params = {}, callback) ⇒ AWS.Request
Lists the shadows for the specified thing.
Requires permission to access the ListNamedShadowsForThing action.
listRetainedMessages(params = {}, callback) ⇒ AWS.Request
Lists summary information about the retained messages stored for the account.
This action returns only the topic names of the retained messages. It doesn't return any message payloads. Although this action doesn't return a message payload, it can still incur messaging costs.
To get the message payload of a retained message, call GetRetainedMessage with the topic name of the retained message.
Requires permission to access the ListRetainedMessages action.
For more information about messaging costs, see IoT Core pricing - Messaging.
publish(params = {}, callback) ⇒ AWS.Request
Publishes an MQTT message.
Requires permission to access the Publish action.
For more information about MQTT messages, see MQTT Protocol in the IoT Developer Guide.
For more information about messaging costs, see IoT Core pricing - Messaging.
updateThingShadow(params = {}, callback) ⇒ AWS.Request
Updates the shadow for the specified thing.
Requires permission to access the UpdateThingShadow action.
For more information, see UpdateThingShadow in the IoT Developer Guide.