Curtain Group Status
Get the current status of Curtain in a group.
Description
The curtain status allows you to retrieve the current state of curtains in a group including:
- Current curtain level (0-100%)
Request Topic
LYT/41e0d6b2-37de-43d8-a348-4ba94853b6cd/GROUP/STATUS
Request Payload
{
"version": "v1.0",
"type": "curtain",
"address": 62014
}
Request Field Descriptions
| Field | Type | Required | Description |
|---|---|---|---|
| version | string | Yes | API version identifier (must be "v1.0") |
| type | string | Yes | Message type (must be "curtain") |
| address | number | Yes | Address of the group |
Response Topic
LYT/41e0d6b2-37de-43d8-a348-4ba94853b6cd/GROUP/E/STATUS
Response Payload
Success Response
{
"version": "v1.0",
"message": "success",
"type": "curtain",
"address": 62014,
"curtain": {
"curtain_level": 75
}
}
Error Handling
The API may return various error responses based on different scenarios:
1. Group Not Found Error (Code: 3006)
{
"message": "error",
"message_type": {
"code": 3006,
"message": "Group not found",
"errorCode": "GROUP_NOT_FOUND"
},
"type": "curtain",
"address": 50646
}
When it occurs:
- The specified group address doesn't exist
- Group has been deleted
- Group is not configured
How to resolve:
- Verify the group address is correct
- Check if the group exists in the system
- Ensure the group is properly configured
- Use group management API to list available groups
2. Project Not Found Error (Code: 2002)
{
"message": "error",
"message_type": {
"code": 2002,
"message": "Project not found",
"errorCode": "PROJECT_NOT_FOUND"
},
"type": "curtain",
"address": 50646
}
When it occurs:
- The project_uuid in your MQTT topic is invalid
- The project has been deleted
- The user doesn't have access to the project
How to resolve:
- Verify the project_uuid in your MQTT topic is correct
- Check if you have the necessary permissions to access the project
- Contact system administrator if you should have access but don't
3. Request Timeout Error (Code: 3002)
{
"message": "error",
"message_type": {
"code": 3002,
"message": "Request timeout",
"errorCode": "REQUEST_TIMEOUT"
},
"type": "curtain",
"address": 50646
}
When it occurs:
- Network connectivity issues
- Group devices are not responding
- MQTT broker connection issues
How to resolve:
- Check your network connection
- Verify MQTT broker is accessible
- Ensure group devices are powered and connected
4. Constraint Error (Code: 3005)
a. Address Constraint:
{
"message": "error",
"message_type": {
"code": 3005,
"message": "address must be a number conforming to the specified constraints",
"errorCode": "CONSTRAINT_ERROR"
},
"type": "curtain",
"address": 50646
}
b. Type Constraint:
{
"message": "error",
"message_type": {
"code": 3005,
"message": "type must be one of the following values: cct, dimmer, switch, fan, curtain, rgb",
"errorCode": "CONSTRAINT_ERROR"
},
"type": "curtain",
"address": 50646
}
c. Version Constraint:
{
"message": "error",
"message_type": {
"code": 3005,
"message": "version must be one of the following values: v1.0",
"errorCode": "CONSTRAINT_ERROR"
},
"type": "curtain",
"address": 50646
}
Constraint errors occur in the following cases:
-
Address Constraints:
- Address must be a valid number
- Address field is missing
- Address field has incorrect type
-
Type Constraints:
- Type must be one of: "cct", "dimmer", "switch", "fan", "curtain", "rgb"
- Type field is missing
- Type field has incorrect value
-
Version Constraints:
- Version must be exactly "v1.0"
- Version field is missing
- Version field has incorrect format
Resolution:
- Always use "v1.0" as the version value
- Use "curtain" as the type value
- Ensure address is a valid number
- Validate all parameters before sending
Error Code Summary
| Code | Error Code | Description | Solution |
|---|---|---|---|
| 3005 | CONSTRAINT_ERROR | Parameter validation failed | Check input values |
| 3006 | GROUP_NOT_FOUND | Group not available | Verify group status |
| 2002 | PROJECT_NOT_FOUND | Project doesn't exist | Check project_uuid |
| 3002 | REQUEST_TIMEOUT | Request took too long | Check connectivity |