Halaman ini belum tersedia dalam bahasa lokal Anda. Kami berusaha keras untuk menambahkan lebih banyak versi bahasa. Terima kasih atas dukungan Anda.
- What's New
- Product Bulletin
- Service Overview
- Billing
-
Getting Started
-
Quick Device Access - Property Reporting and Command Receiving
- Subscribing to IoTDA
- Connecting a Smart Smoke Detector to the Platform (Quick Usage)
- Registering a Simulated Smart Street Light Device
- Using MQTT.fx to Simulate Communication Between the Smart Street Light and the Platform
- Using a Virtual Smart Street Light to Communicate with the Platform (Java SDK)
- Using a Virtual Smart Street Light to Communicate with the Platform (C SDK)
- Quick Device Access - Message Sending and Receiving
- Quick Application Access
-
Quick Device Access - Property Reporting and Command Receiving
-
User Guide
- Overview
- IoTDA Instances
- Resource Spaces
- Device Access
- Message Communications
- Device Management
-
Rules
- Overview
- Data Forwarding Process
- SQL Statements
- Connectivity Tests
- Data Forwarding to Huawei Cloud Services
- Data Forwarding to Third-Party Applications
- Data Forwarding Channel Details
- Data Forwarding Stack Policies
- Data Forwarding Flow Control Policies
- Abnormal Data Target
- Device Linkage
- Monitoring and O&M
- Granting Permissions Using IAM
-
Best Practices
- Introduction
-
Device Access
- Developing an MQTT-based Simulated Smart Street Light Online
- Developing a Smart Street Light Using NB-IoT BearPi
- Developing a Smart Smoke Detector Using NB-IoT BearPi
- Connecting and Debugging an NB-IoT Smart Street Light Using a Simulator
- Developing a Protocol Conversion Gateway for Access of Generic-Protocol Devices
- Connecting a Device That Uses the X.509 Certificate Based on MQTT.fx
- Connecting to IoTDA Based on the BearPi-HM_Nano Development Board and OpenHarmony 3.0
- Testing MQTT Performance Using JMeter
- Device Management
- Data Forwarding
- Device Linkage
-
Developer Guide
- Before You Start
- Obtaining Resources
- Product Development
- Development on the Device Side
- Development on the Application Side
-
API Reference
-
API Reference on the Application Side
- Before You Start
- Calling APIs
- API Overview
-
API
- Product Management
- Device Management
- Device Message
- Device Command APIs
- Device Property
- AMQP Queue Management
- Access Credential Management
- Data Forwarding Rule Management
-
Transition Data
- Push a Device Status Change Notification
- Push a Device Property Reporting Notification
- Push a Device Message Status Change Notification
- Push a Batch Task Status Change Notification
- Push a Device Message Reporting Notification
- Push a Device Addition Notification
- Push a Device Update Notification
- Push a Device Deletion Notification
- Push a Product Addition Notification
- Push a Product Update Notification
- Push a Product Deletion Notification
- Push an Asynchronous Device Command Status Change Notification
- Rule Management
- Device Shadow
- Group Management
- Tag Management
- Instance Management
- Resource Space Management
- Batch Task
- Device CA Certificate Management
- OTA Upgrade Package Management
- Message Broadcasting
- Device Tunnel Management
- Stack policy management
- Flow control policy management
- Device Proxy
- Device Policy Management
- Bridge Management
- Pre-provisioning Template Management
- Custom Authentication
- Codec Function Management
- Permissions and Supported Actions
- Examples
- Appendix
-
MQTT or MQTTS API Reference on the Device Side
- Before You Start
- Communication Modes
- Topics
- Device Connection Authentication
- Device Commands
- Device Messages
- Device Properties
-
Gateway and Child Device Management
- Platform Notifying a Gateway of New Child Device Connection
- Platform Notifying a Gateway of Child Device Deletion
- Gateway Synchronizing Child Device Information
- Gateway Updating Child Device Status
- Responding to a Request for Updating Child Device Statuses
- Gateway Requesting for Adding Child Devices
- Platform Responding to a Request for Adding Child Devices
- Gateway Requesting for Deleting Child Devices
- Platform Responding to a Request for Deleting Child Devices
- Software and Firmware Upgrade
- File Upload and Download
- Device Time Synchronization
- Device Reporting Information
- Device Log Collection
- Remote Configuration
- Device Tunnel Management
- HTTPS API Reference on the Device Side
- LwM2M API Reference on the Device Side
- Security Tunnel WebSocket API Reference
- Module AT Command Reference
- Change History
-
API Reference on the Application Side
- SDK Reference
-
FAQs
- Top FAQs
-
Solution Consulting
- In What Scenarios Can the IoT Platform Be Applied?
- What Are the Changes Brought by the Integration of IoT Device Management and IoTDA?
- Can I Enable IoTDA for IAM Users or Sub-Projects?
- Which Regions of Huawei Cloud Are Supported by the IoT Platform?
- Does Huawei Provide Modules, Hardware Devices, and Application Software?
- What Should I Do If I Want to Call an API But Have No Permissions to Do So as an IAM User? (Is It Edition-specific?)
- Why Was I Prompted to Grant Security Administrator Permissions When I Create a Rule or Set Resource File Storage?
- Which Resource Space Will Be Set As Default on the IoT Platform?
- How Does IoTDA Obtain Device Data?
- Is There Any Limitation on the Number of Resource Spaces and Devices I Can Add on the IoT Platform?
- Does the IoTDA Support Device Registration in Batches?
- Are There Any Limitations on the Use of the IoT Platform?
- What DTLS Encryption Algorithms Are Supported by the IoT Platform?
- Does the IoT Platform Support Conversion Between Big-Endian and Little-Endian for Binary Data?
- What Is NB-IoT?
- What Are the Components of the IoT Platform and What Hardware Architectures Does It Support?
- How Do I Obtain the Platform Access Address?
- Device Integration
- IoT Device SDKs
- LwM2M/CoAP Device Access
- MQTT-based Device Access
- Products Models
- Message Communications
- Subscription and Push
- Codecs
- OTA Upgrades
- Application Integration
- General Reference
Copied.
Push a Device Message Status Change Notification
Function
After the application calls the API for creating a rule triggering condition (resource is set to device.message.status and event to update), the API for creating a rule action, and the API for modifying a rule triggering condition, and activates a rule, the platform pushes the result to the server specified by the rule when the device message status changes.
URI
POST /HTTP URL determined when the application creates a device message status change notification rule. The AMQP channel does not require the URL.
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
resource |
Yes |
String |
Parameter description: subscribed resource name. Set this parameter to device.message.status. |
event |
Yes |
String |
Parameter description: subscribed event. Set this parameter to update. |
event_time |
Yes |
String |
Parameter description: UTC time when the resource event was generated. The value is in the format of yyyyMMdd'T'HHmmss'Z', for example, 20151212T121212Z. If necessary, convert the time to display in the local time zone format. |
event_time_ms |
No |
String |
Parameter description: UTC time when a resource event was generated. The value in the format of yyyy-MM-dd'T'HH:mm:ss.SSS'Z', for example, 2015-12-12T12:12:12.000Z. If necessary, convert the time to display in the local time zone format. |
request_id |
No |
String |
Parameter description: message ID, which is specified by the device or generated by the platform, and is used to trace the service process. |
notify_data |
Yes |
Parameter description: message to push. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
header |
Yes |
NotifyDataHeader object |
Parameter description: message header. |
body |
Yes |
DeviceMessageStatusUpdate object |
Parameter description: message body. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
app_id |
No |
String |
Parameter description: application ID. Maximum: 256 |
device_id |
No |
String |
Parameter description: unique device ID, which is allocated by IoTDA during device registration. Maximum: 256 |
node_id |
No |
String |
Parameter description: device node ID. This parameter is set to the IMEI, MAC address, or serial number. Maximum: 256 |
product_id |
No |
String |
Parameter description: unique product ID, which is allocated by the platform during product registration. Maximum: 256 |
gateway_id |
No |
String |
Parameter description: gateway ID, which uniquely identifies a gateway. The gateway ID is the same as the device ID if the device is a directly connected device. If the device is an indirectly connected device, the gateway ID is the device ID of the directly connected device (that is, the gateway) with which it associates. Maximum: 256 |
tags |
No |
Array of TagV5DTO objects |
Parameter description: list of tags to be bound to a specific resource. Each tag key must be unique in the tag list. Up to 10 tags can be bound to a resource. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
tag_key |
Yes |
String |
Parameter description: tag key, which is unique for a resource. If the specified key already exists, the value of the existing tag is overwritten. If the specified key does not exist, a new tag is added. |
tag_value |
No |
String |
Parameter description: tag value. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
topic |
No |
String |
Parameter description: MQTT topic used for message reporting. |
message_id |
Yes |
String |
Parameter description: sequence number of a message, which uniquely identifies a message. |
name |
No |
String |
Parameter description: message name. |
status |
No |
String |
Parameter description: device message status. Options: PENDING, DELIVERED, TIMEOUT, and FAILED. |
error_info |
No |
ErrorInfoDTO object |
Parameter description: message delivery failure information. |
timestamp |
No |
String |
Parameter description: UTC when the message was updated. The value is in the format of yyyyMMdd'T'HHmmss'Z', for example, 20151212T121212Z. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
error_code |
No |
String |
Parameter description: error code. IOTDA.014016 indicates that the device is offline. IOTDA.014112 indicates that the device does not subscribe to any topic. |
error_msg |
No |
String |
Parameter description: error message. The device is offline or does not subscribe to any topic. |
Response Parameters
None
Example Requests
Example of a device message status change notification.
Device message status change notification. { "resource" : "device.message.status", "event" : "update", "event_time" : "20151212T121212Z", "event_time_ms" : "2015-12-12T12:12:12.000Z", "request_id" : "3fe58d5e-8697-4849-a165-7db128f7e776", "notify_data" : { "header" : { "device_id" : "d4922d8a-6c8e-4396-852c-164aefa6638f", "product_id" : "ABC123456789", "app_id" : "d4922d8a-6c8e-4396-852c-164aefa6638f", "gateway_id" : "d4922d8a-6c8e-4396-852c-164aefa6638f", "node_id" : "ABC123456789", "tags" : [ { "tag_value" : "testTagValue", "tag_key" : "testTagName" } ] }, "body" : { "error_info" : { "error_msg" : "Send to device failed, device not subscribe topic.", "error_code" : "IOTDA.014112" }, "name" : "name", "topic" : "topic", "message_id" : "1235", "status" : "DELIVERED", "timestamp" : "20151212T121212Z" } } }
Example Responses
None
Status Codes
Status Code |
Description |
---|---|
200 |
OK |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot