Skip to content

Update Subscription

API Address:/v2/quecrule/{version}/openapi/subscribe/update

Request Method:POST

Request Data Type:application/json

Response Data Type:*/*

API Description:Update subscription

Request Example:

javascript
{
    "msgTypes": [
        1
    ],
        "queueName": "testQueue",
        "subscribeId": 6169,
        "subscribeName": "subscribeName01"
}

Request Parameters:

Parameter NameParameter DescriptionRequest TypeRequiredData TypeSchema
msgTypesMessage types
Product/Device level subscription:
Transparent transmission products support the following types:
1-Device online/offline events
2-Device and module status
3-Device uplink data
4-Device downlink data
5-Device command response
12-Device location original information
13-Device location information
14-Device binding change information
15-Device information change
Thing model products support the following types:
1-Device online/offline events
2-Device and module status
5-Device command response
6-Thing model property information
7-Thing model event report-information
8-Thing model event report-alert
9-Thing model event report-fault
10-Thing model service call log
12-Device location original information
13-Device location information
14-Device binding change information
15-Device information change
User level subscription:
101-Product information change
102-Device information change
103-Thing model publication information change
SaaS user level subscription:
101-Product information change
102-Device information change
103-Thing model publication information change
104-Product authorization information
End user domain level subscription:
201-End user add/delete/modify
falsearrayinteger
queueNameQueue namefalsestring
subscribeIdSubscription IDtrueinteger(int64)
subscribeNameSubscription name, maximum length 128 characters, supports Chinese, uppercase and lowercase English characters (case-sensitive), numbers, underscores (_), hyphens (-), does not support slashes (/), spaces, or other charactersfalsestring
versionCurrent version, valid value:r1pathtruestring

Response Status:

Status CodeDescriptionSchema
200OKActionResultOfobject
201Created
401Unauthorized
403Forbidden
404Not Found
16002The queue name does not exist
16022The running subscription rule does not allow modification
50000Service exception
50004Parameter null or empty
50005Parameter check error
70060Permission Denied
91004Token incorrect
91005Doesn't have permission

Response Parameters:

Parameter NameParameter DescriptionTypeSchema
codeReturn codeinteger(int32)integer(int32)
dataObjectobject
msgPrompt messagestring
pageNumCurrent page numberinteger(int32)integer(int32)
pageSizeItems per pageinteger(int32)integer(int32)
pagesTotal pagesinteger(int32)integer(int32)
totalTotal countinteger(int32)integer(int32)

Response Example:

javascript
{
	"code": 200,
	"msg": ""
}