You need to enable JavaScript to run this app.
文档中心
云原生消息引擎

云原生消息引擎

复制全文
下载 pdf
Topic 管理
SearchTopics - 查询 Topic
复制全文
下载 pdf
SearchTopics - 查询 Topic
调用 SearchTopics 接口,查询符合条件的 Topic 列表。​
请求说明​
  • 请求方式:GET​
  • 请求地址:https://open.volcengineapi.com?Action=SearchTopics&Version=2023-06-01​
调试​
API Explorer
您可以通过 API Explorer 在线发起调用,无需关注签名生成过程,快速获取调用结果。
​
请求参数​
下方仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。​
Action string 必选 示例值:SearchTopics​
要执行的操作,取值:SearchTopics。​
​
Version string 必选 示例值:2023-06-01​
API的版本,取值:2023-06-01。​
​
InstanceId string 可选 示例值:o-00c0****m46c​
根据实例 ID 进行查询。​
​
SearchKey string 可选 示例值:topic-test​
根据 Topic 名称关键词进行模糊查询。​
​
Status string[] 可选 示例值:RUNNING​
根据 Topic 状态进行查询。​
​
CreateTimeOrder string 可选 示例值:DESC​
按照 Topic 的创建时间进行排序,支持以下排序方式:​
  • DESC:降序排列。​
  • ASC:升序排列。​
​
PageNumber integer 可选 示例值:1​
页数。​
​
PageSize integer 可选 示例值:10​
每页展示的 Topic 数量。​
​
​
​
返回参数​
下方仅列出本接口特有的返回参数。更多信息请参见返回结构。​
Items object[] 示例值:\-​
返回的 Topic 列表。​
Status string 示例值:RUNNING​
Topic 状态。​
​
TopicId string 示例值:677bb****b1e406797e87e309785c4e6​
Topic ID。​
​
OwnerName string 示例值:wu****an@bytedance.com​
Topic 所属用户。​
​
Retention integer 示例值:72​
消息在 Topic 中的保留时长,单位为小时。​
​
TopicName string 示例值:topic-test​
Topic 名称。​
​
CreateTime string 示例值:2024-12-06T14:00:00​
Topic 创建时间。​
​
InstanceId string 示例值:o-00c0****m46c​
Topic 所属实例 ID。​
​
Partitions integer 示例值:12​
Topic 分区数。​
​
Description string 示例值:测试使用​
Topic 描述语句。​
​
​
PageSize integer 示例值:10​
每页展示的 Topic 数量​
​
PageCount integer 示例值:1​
总分页数。​
​
PageNumber integer 示例值:1​
当前页数。​
​
TotalCount long 示例值:1​
查询到的 Topic 总数。​
​
​
​
请求示例​
​
POST /?Action=SearchTopics&Version=2023-06-01&InstanceId=o-00c0****m46c&SearchKey=topic-test&CreateTimeOrder=DESC&PageNumber=1&PageSize=10 HTTP/1.1​
Host: bmq.volcengineapi.com​
Content-Type: application/json; charset=UTF-8​
X-Date: 20241112T082657Z​
X-Content-Sha256: 287e874e******d653b44d21e​
Authorization: HMAC-SHA256 Credential=AK********/20241112/cn-beijing/bmq/request, SignedHeaders=host;x-content-sha256;x-date, Signature=********​
​
{}​
​
返回示例​
​
{​
"ResponseMetadata": {​
"RequestId": "202412061433016B8D54884B521AD5****",​
"Action": "SearchTopics",​
"Version": "2023-06-01",​
"Service": "bmq",​
"Region": "cn-beijing"​
},​
"Result": {​
"Items": [​
{​
"TopicId": "677bb****b1e406797e87e309785c4e6",​
"InstanceId": "o-00c0****m46c",​
"TopicName": "topic-test",​
"Status": "RUNNING",​
"Partitions": 12,​
"Retention": 72,​
"Description": "测试使用",​
"OwnerId": "36****65",​
"OwnerName": "wu****an@bytedance.com",​
"CreateTime": "2024-12-06T14:00:00"​
}​
],​
"TotalCount": 1,​
"PageCount": 1,​
"PageNumber": 1,​
"PageSize": 10​
}​
}​
​
错误码​
下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。​
​
状态码​
错误码​
错误信息​
说明​
200​
InvalidParameter​
parameter is invalid, pls check parameters​
参数值无效。​
200​
Unauthorized​
authorized error​
授权错误,请授权或切换账号后重试。​
200​
InternalServiceError​
internal service error, please contact with admin​
内部服务错误,请联系技术支持或提交工单。​
200​
DatabaseError​
database error​
数据库错误。​
200​
ParameterEncodingError​
Failure encoding object into query map​
参数编码异常,请联系技术支持或提交工单。​
​
​
最近更新时间:2025.08.05 18:34:37
这个页面对您有帮助吗?
有用
有用
无用
无用