Skip to content

创建终端用户订阅

接口地址:/v2/quecrule/{version}/openapi/subscribe/enduser

请求方式:POST

请求数据类型:application/json

响应数据类型:*/*

接口描述:

创建终端用户订阅

请求示例:

javascript
{
  "endUserDomain": "C.DM.26106.1",
  "msgTypes": [
    201
  ],
  "queueName": "a.000000026106.testAbc",
  "subscribeName": "test"
}

请求参数:

参数名称参数说明请求类型是否必须数据类型schema
subscribeDTO订阅信息bodytrueOpenApiSubscribeEndUserDTOOpenApiSubscribeEndUserDTO
  endUserDomain用户域truestring
  msgTypes消息类型, 201-终端用户新增/删除/修改truearrayinteger
  queueName队列名称truestring
  subscribeName订阅名,最大长度128字符, 支持中文、大小写英文字符串(区分大小写)、数字、下划线(_)、中划线(-)、不支持斜杠(/)、空格等其他字符truestring
version当前版本,可用值:r1pathtruestring

响应状态:

状态码说明schema
200OKActionResultOfOpenApiSubscribeIdDTO
201Created
401Unauthorized
403Forbidden
404Not Found
16002The queue name does not exist
16018The number of subscription rules is out of limit
16024The message subscription is not enabled, please go to the SaaS development Guide to apply for enabling
50000service exception
50004param null or empty
50005param check error
70017The product does not exist
70060Permission Denied
70130The device does not exist
91004token incorrect
91005doesn't have permission

响应参数:

参数名称参数说明类型schema
code返回码integer(int32)integer(int32)
data对象OpenApiSubscribeIdDTOOpenApiSubscribeIdDTO
  subscribeId订阅IDinteger(int64)
msg提示信息string
pageNum当前页数integer(int32)integer(int32)
pageSize每页数量integer(int32)integer(int32)
pages总页数integer(int32)integer(int32)
total总数integer(int32)integer(int32)

响应示例:

javascript
{
	"code": 0,
	"data": {
		"subscribeId": 1
	},
	"msg": "",
	"pageNum": 0,
	"pageSize": 0,
	"pages": 0,
	"total": 0
}