TDMQ for Apache Pulsar

TDMQ for Apache Pulsar
API Documentation
Product Documentation©2013-2022 Tencent Cloud. All rights reserved.

Page 1 of 450

TDMQ for Apache Pulsar

Copyright Notice©2013-2024 Tencent Cloud. All rights reserved.
Copyright in this document is exclusively owned by Tencent Cloud. You must not reproduce, modify, copy or distributein any way, in whole or in part, the contents of this document without Tencent Cloud's the prior written consent.
Trademark Notice

All trademarks associated with Tencent Cloud and its services are owned by Tencent Cloud Computing (Beijing)
Company Limited and its affiliated companies. Trademarks of third parties referred to in this document are owned bytheir respective proprietors.
Service Statement
This document is intended to provide users with general information about Tencent Cloud's products and services
only and does not form part of Tencent Cloud's terms and conditions. Tencent Cloud's products or services are
subject to change. Specific products and services and the standards applicable to them are exclusively provided for in
Tencent Cloud's applicable terms and conditions.

©2013-2022 Tencent Cloud. All rights reserved.

Page 2 of 450

TDMQ for Apache Pulsar

Contents
API Documentation
History
Introduction
API Category
Making API Requests
Request Structure
Common Params
Signature v3
Signature
Responses
Cluster APIs
DescribePulsarProInstanceDetail
DescribePulsarProInstances
DescribeRabbitMQVirtualHostList
DescribeRabbitMQNodeList
DescribeClusters
DescribeClusterDetail
DeleteCluster
ModifyCluster
DescribeBindClusters
CreateCluster
Namespace APIs
ModifyEnvironmentAttributes
DescribeEnvironments
DescribeEnvironmentAttributes
DeleteEnvironments
CreateEnvironment
DescribeEnvironmentRoles
DeleteRocketMQNamespace
Topic APIs
ModifyTopic
DescribeTopics
DeleteTopics
CreateTopic
Message APIs

©2013-2022 Tencent Cloud. All rights reserved.

Page 3 of 450

TDMQ for Apache Pulsar

SendMessages
SendBatchMessages
ReceiveMessage
AcknowledgeMessage
CMQ Message APIs
SendCmqMsg
PublishCmqMsg
ClearCmqSubscriptionFilterTags
ClearCmqQueue
CMQ Management APIs
UnbindCmqDeadLetter
RewindCmqQueue
ModifyCmqTopicAttribute
ModifyCmqSubscriptionAttribute
ModifyCmqQueueAttribute
DescribeCmqTopics
DescribeCmqTopicDetail
DescribeCmqSubscriptionDetail
DescribeCmqQueues
DescribeCmqQueueDetail
DescribeCmqDeadLetterSourceQueues
DeleteCmqTopic
DeleteCmqSubscribe
DeleteCmqQueue
CreateCmqTopic
CreateCmqSubscribe
CreateCmqQueue
Other APIs
SendRocketMQMessage
DescribeBindVpcs
SendMsg
Environment Role APIs
ModifyRole
ModifyEnvironmentRole
DescribeRoles
DeleteEnvironmentRoles
CreateRole
CreateEnvironmentRole©2013-2022 Tencent Cloud. All rights reserved.

Page 4 of 450

TDMQ for Apache Pulsar

DeleteRoles
TDMQ for RabbitMQ APIs
CreateRabbitMQUser
CreateRabbitMQVirtualHost
DeleteRabbitMQUser
DeleteRabbitMQVirtualHost
DescribeRabbitMQUser
DescribeRabbitMQVirtualHost
ModifyRabbitMQUser
ModifyRabbitMQVirtualHost
CreateRabbitMQVipInstanceDeleteRabbitMQVipInstanceDescribeRabbitMQVipInstances
RocketMQ APIs
DescribeRocketMQVipInstanceDetail
DescribeRocketMQMsg
ModifyRocketMQTopic
ModifyRocketMQNamespace
ModifyRocketMQGroup
ModifyRocketMQCluster
DescribeRocketMQTopics
DescribeRocketMQNamespaces
DescribeRocketMQGroups
DescribeRocketMQClusters
DescribeRocketMQCluster
DeleteRocketMQTopic
DeleteRocketMQGroup
DeleteRocketMQCluster
CreateRocketMQTopic
CreateRocketMQNamespace
CreateRocketMQGroup
CreateRocketMQCluster
TDMQ for RocketMQ APIs
ModifyRocketMQInstanceSpec
DescribeRocketMQVipInstances
Production and Consumption APIs
DescribeSubscriptions
DeleteSubscriptions©2013-2022 Tencent Cloud. All rights reserved.

Page 5 of 450

TDMQ for Apache Pulsar

CreateSubscription
ResetMsgSubOffsetByTimestamp
DescribePublishers
DescribePublisherSummary
ResetRocketMQConsumerOffSet
Data Types
Error Codes©2013-2022 Tencent Cloud. All rights reserved.

Page 6 of 450

TDMQ for Apache Pulsar

API Documentation
History：

Last updated 2023-08-09 14:43:17

Release 17
Release time: 2023-08-09 14:39:40
Release updates:
Improvement to existing documentation.
New APIs:
CreateRabbitMQUser
CreateRabbitMQVirtualHost
DeleteRabbitMQUser
DeleteRabbitMQVipInstanceDeleteRabbitMQVirtualHost
DescribeRabbitMQUser
DescribeRabbitMQVirtualHost
DescribeRabbitMQVirtualHostList
DescribeRocketMQMsg
ModifyRabbitMQUser
ModifyRabbitMQVirtualHost
ModifyRocketMQInstanceSpec
SendRocketMQMessage
Modified APIs:
CreateEnvironment
New input parameters:AutoSubscriptionCreation
CreateRocketMQNamespace
Modified input parameters: Ttl, RetentionTime
CreateRole
New output parameters:EnvironmentRoleSets
ModifyEnvironmentAttributes
New input parameters:AutoSubscriptionCreation©2013-2022 Tencent Cloud. All rights reserved.

Page 7 of 450

TDMQ for Apache Pulsar

ModifyRocketMQCluster
New input parameters:PublicAccessEnabled
ModifyRocketMQNamespace
New input parameters:PublicAccessEnabled
Modified input parameters: Ttl, RetentionTime
New data structures:
EnvironmentRoleSet
RabbitMQPrivateVirtualHost
RabbitMQUser
RabbitMQVirtualHostInfo
RabbitMQVirtualHostStatistics
RocketMQMessageTrack
Modified data structures:
Environment
New members:AutoSubscriptionCreation
PulsarProClusterInfo
New members:CanEditRoute
Modified members: ClusterId, ClusterName, Remark, CreateTime, Status, Version, NodeDistribution,
MaxStorage
RabbitMQVipInstanceNew members:ClusterStatus
RocketMQClusterInfo
New members:InternalEndpoint, HttpInternalEndpoint
RocketMQNamespace
New members:InternalEndpoint
RocketMQVipInstanceNew members:MaxRetention, MinRetention, Retention

Release 16
Release time: 2023-04-28 10:21:04
Release updates:
Improvement to existing documentation.

©2013-2022 Tencent Cloud. All rights reserved.

Page 8 of 450

TDMQ for Apache Pulsar

New APIs:
DescribePulsarProInstanceDetail
DescribePulsarProInstances
New data structures:
PulsarNetworkAccessPointInfo
PulsarProClusterInfo
PulsarProClusterSpecInfo
PulsarProInstanceRelease 15
Release time: 2023-04-18 14:50:58
Release updates:
Improvement to existing documentation.
New APIs:
CreateRabbitMQVipInstanceRelease 14
Release time: 2023-03-14 17:02:14
Release updates:
Improvement to existing documentation.
New APIs:
DescribeRocketMQVipInstanceDetail
New data structures:InstanceNodeDistribution
RocketMQInstanceConfig
RocketMQTopicDistribution©2013-2022 Tencent Cloud. All rights reserved.

Page 9 of 450

TDMQ for Apache Pulsar

Release 13
Release time: 2023-02-24 15:13:01
Release updates:
Improvement to existing documentation.
Modified APIs:
DescribeRabbitMQNodeList
New input parameters:NodeName, Filters, SortElement, SortOrder
Modified data structures:
RabbitMQPrivateNode
New members:NodeStatus, CPUUsage, Memory, DiskUsage, ProcessNumber
RabbitMQVipInstanceNew members:ExceptionInformation
RocketMQClusterConfig
New members:MaxQueuesPerTopic
Modified members: MaxTpsPerNamespace, MaxNamespaceNum, UsedNamespaceNum, MaxTopicNum,
UsedTopicNum, MaxGroupNum, UsedGroupNum, MaxRetentionTime, MaxLatencyTime

Release 12
Release time: 2023-01-31 17:54:03
Release updates:
Improvement to existing documentation.
Modified APIs:
CreateRocketMQGroupNew input parameters:GroupType, RetryMaxTimes
DescribeRocketMQGroups
New input parameters:Types
ModifyRocketMQGroupNew input parameters:RetryMaxTimes
Modified data structures:©2013-2022 Tencent Cloud. All rights reserved.

Page 10 of 450

TDMQ for Apache Pulsar

RocketMQGroupNew members:GroupType, RetryMaxTimes
Modified members: Name, ConsumerNum, TPS, TotalAccumulative, ConsumptionMode, ReadEnabled,
RetryPartitionNum, CreateTime, UpdateTime, ClientProtocol, Remark, ConsumerType, BroadcastEnabled
RocketMQTopic
New members:Type, GroupNum

Release 11
Release time: 2022-12-29 15:03:29
Release updates:
Improvement to existing documentation.
Modified data structures:
RocketMQClusterInfo
New members:RocketMQFlag, Status, IsolateTime, HttpPublicEndpoint, HttpVpcEndpoint
Modified members: ClusterId, ClusterName, Region, CreateTime, Remark, PublicEndPoint, VpcEndPoint,
SupportNamespaceEndpoint, Vpcs, IsVip

Release 10
Release time: 2022-11-23 16:11:56
Release updates:
Improvement to existing documentation.
New data structures:
VpcConfig
Modified data structures:
RocketMQClusterInfo
New members:Vpcs, IsVip

Release 9©2013-2022 Tencent Cloud. All rights reserved.

Page 11 of 450

TDMQ for Apache Pulsar

Release time: 2022-11-18 17:10:38
Release updates:
Improvement to existing documentation.
Modified data structures:
CmqTopic
New members:BrokerType

Release 8
Release time: 2022-11-14 15:30:28
Release updates:
Improvement to existing documentation.
New APIs:
DescribeRabbitMQNodeList
DescribeRabbitMQVipInstances
New data structures:
RabbitMQPrivateNode
RabbitMQVipInstanceRelease 7
Release time: 2022-10-09 15:18:32
Release updates:
Improvement to existing documentation.
New APIs:
DescribeRocketMQVipInstances
New data structures:
RocketMQVipInstance©2013-2022 Tencent Cloud. All rights reserved.

Page 12 of 450

TDMQ for Apache Pulsar

Release 6
Release time: 2022-07-18 10:12:31
Release updates:
Improvement to existing documentation.
Modified APIs:
DescribeTopics
New input parameters:TopicCreator
ReceiveMessage
New input parameters:MaxNumMessages, MaxNumBytes, Timeout
New output parameters:MessageIDList, MessagesPayload
Modified data structures:
RocketMQNamespace
New members:PublicEndpoint, VpcEndpoint

Release 5
Release time: 2022-06-30 16:20:19
Release updates:
Improvement to existing documentation.
New APIs:
DeleteSubscriptions
DeleteTopics
DescribeBindClusters
DescribeClusters
DescribeCmqQueues
DescribeCmqTopics
DescribeEnvironmentRoles
DescribeEnvironments
DescribeRocketMQClusters
DescribeRocketMQGroups
DescribeRocketMQNamespaces©2013-2022 Tencent Cloud. All rights reserved.

Page 13 of 450

TDMQ for Apache Pulsar

DescribeRocketMQTopics
DescribeSubscriptions
DescribeTopics
New data structures:
BindCluster
Consumer
ConsumersSchedule
Environment
EnvironmentRole
FilterSubscription
PartitionsTopic
RocketMQClusterDetailRocketMQGroup
RocketMQNamespace
RocketMQTopic
Subscription
SubscriptionTopic
Topic
TopicRecord

Release 4
Release time: 2022-05-06 10:28:04
Release updates:
Improvement to existing documentation.
New APIs:
ResetRocketMQConsumerOffSet
Deleted APIs:
DeleteSubscriptions
DeleteTopics
DescribeBindClusters
DescribeClusters
DescribeCmqQueues©2013-2022 Tencent Cloud. All rights reserved.

Page 14 of 450

TDMQ for Apache Pulsar

DescribeCmqTopics
DescribeEnvironmentRoles
DescribeEnvironments
DescribeRocketMQClusters
DescribeRocketMQGroups
DescribeRocketMQNamespaces
DescribeRocketMQTopics
DescribeSubscriptions
DescribeTopics
Modified APIs:
CreateCmqQueue
New input parameters:RetentionSizeInMB
ModifyCmqQueueAttribute
New input parameters:RetentionSizeInMB
Deleted data structures:
BindCluster
Consumer
ConsumersSchedule
Environment
EnvironmentRole
FilterSubscription
PartitionsTopic
RocketMQClusterDetailRocketMQGroup
RocketMQNamespace
RocketMQTopic
Subscription
SubscriptionTopic
Topic
TopicRecord
Modified data structures:
CmqQueue
New members:RetentionSizeInMB
CmqTopic©2013-2022 Tencent Cloud. All rights reserved.

Page 15 of 450

TDMQ for Apache Pulsar

New members:Status
RocketMQClusterInfo
New members:SupportNamespaceEndpoint

Release 3
Release time: 2022-02-24 16:17:02
Release updates:
Improvement to existing documentation.
Modified APIs:
CreateCmqQueue
New input parameters:Tags
CreateCmqTopic
New input parameters:Tags
CreateTopic
New input parameters:PulsarTopicType
Modified input parameters: TopicType
Modified data structures:
Cluster
New members:PayMode
Consumer
New members:Partition
Subscription
New members:SubType, BlockedSubscriptionOnUnackedMsgs, MaxUnackedMsgNum
Topic
New members:PulsarTopicType

Release 2
Release time: 2022-02-10 17:07:12
Release updates:
Improvement to existing documentation.

©2013-2022 Tencent Cloud. All rights reserved.

Page 16 of 450

TDMQ for Apache Pulsar

New APIs:
DescribePublisherSummary
DescribePublishers
Deleted APIs:
DescribeProducers
New data structures:
Publisher
Sort
Deleted data structures:
Connection
Producer
Modified data structures:
CmqQueue
New members:Status, MaxUnackedMsgNum, MaxMsgBacklogSize

Release 1
Release time: 2021-12-28 11:17:30
Release updates:
Improvement to existing documentation.
New APIs:
AcknowledgeMessage
ClearCmqQueue
ClearCmqSubscriptionFilterTags
CreateCluster
CreateCmqQueue
CreateCmqSubscribe
CreateCmqTopic
CreateEnvironment
CreateEnvironmentRole©2013-2022 Tencent Cloud. All rights reserved.

Page 17 of 450

TDMQ for Apache Pulsar

CreateRocketMQCluster
CreateRocketMQGroup
CreateRocketMQNamespace
CreateRocketMQTopic
CreateRole
CreateSubscription
CreateTopic
DeleteCluster
DeleteCmqQueue
DeleteCmqSubscribe
DeleteCmqTopic
DeleteEnvironmentRoles
DeleteEnvironments
DeleteRocketMQCluster
DeleteRocketMQGroup
DeleteRocketMQNamespace
DeleteRocketMQTopic
DeleteRoles
DeleteSubscriptions
DeleteTopics
DescribeBindClusters
DescribeBindVpcs
DescribeClusterDetail
DescribeClusters
DescribeCmqDeadLetterSourceQueues
DescribeCmqQueueDetail
DescribeCmqQueues
DescribeCmqSubscriptionDetail
DescribeCmqTopicDetail
DescribeCmqTopics
DescribeEnvironmentAttributes
DescribeEnvironmentRoles
DescribeEnvironments
DescribeProducers
DescribeRocketMQCluster
DescribeRocketMQClusters
DescribeRocketMQGroups
DescribeRocketMQNamespaces©2013-2022 Tencent Cloud. All rights reserved.

Page 18 of 450

TDMQ for Apache Pulsar

DescribeRocketMQTopics
DescribeRoles
DescribeSubscriptions
DescribeTopics
ModifyCluster
ModifyCmqQueueAttribute
ModifyCmqSubscriptionAttribute
ModifyCmqTopicAttribute
ModifyEnvironmentAttributes
ModifyEnvironmentRole
ModifyRocketMQCluster
ModifyRocketMQGroup
ModifyRocketMQNamespace
ModifyRocketMQTopic
ModifyRole
ModifyTopic
PublishCmqMsg
ReceiveMessage
ResetMsgSubOffsetByTimestamp
RewindCmqQueue
SendBatchMessages
SendCmqMsg
SendMessages
SendMsg
UnbindCmqDeadLetter
New data structures:
BindCluster
Cluster
CmqDeadLetterPolicy
CmqDeadLetterSource
CmqQueue
CmqSubscription
CmqTopic
CmqTransactionPolicy
Connection
Consumer©2013-2022 Tencent Cloud. All rights reserved.

Page 19 of 450

TDMQ for Apache Pulsar

ConsumersSchedule
Environment
EnvironmentRole
FilterFilterSubscription
PartitionsTopic
Producer
RetentionPolicy
RocketMQClusterConfig
RocketMQClusterDetailRocketMQClusterInfo
RocketMQClusterRecentStats
RocketMQGroup
RocketMQNamespace
RocketMQTopic
Role
Subscription
SubscriptionTopic
Tag
Topic
TopicRecord
VpcBindRecord©2013-2022 Tencent Cloud. All rights reserved.

Page 20 of 450

TDMQ for Apache Pulsar

Introduction：

Last updated 2022-10-09 15:20:40
Welcome to TDMQ
TDMQ runs in Tencent IDC and provides scalable message queue services in a serverless manner.

©2013-2022 Tencent Cloud. All rights reserved.

Page 21 of 450

TDMQ for Apache Pulsar

API Category：

Last updated 2023-08-09 14:43:17

Cluster APIs
API Name

FeatureFrequency Limit (maximum
requests per second)

CreateCluster

Creates cluster

20

DeleteCluster

Deletes cluster

20

DescribeBindClusters

Gets the list of dedicated clusters

20

DescribeClusterDetailGets cluster details

20

DescribeClusters

Gets the list of clusters

20

DescribePulsarProInstanceDetail

DescribePulsarProInstances

Obtains the information of a TDMQ for
Pulsar pro cluster instanceQueries the list of TDMQ for Pulsar pro
instances20

20

DescribeRabbitMQNodeList

Queries the list of TDMQ for RabbitMQ
exclusive cluster nodes

20

DescribeRabbitMQVirtualHostList

Queries the list of TDMQ for RabbitMQ
exclusive vhosts

20

ModifyCluster

Updates cluster

20

Namespace APIs
Frequency Limit (maximum requests

API Name

FeatureCreateEnvironment

Creates namespace

20

DeleteEnvironments

Deletes namespaces

20

DeleteRocketMQNamespace

Deletes RocketMQ namespace20©2013-2022 Tencent Cloud. All rights reserved.

per second)

Page 22 of 450

TDMQ for Apache Pulsar

DescribeEnvironmentAttributes

Gets namespace attributes

20

DescribeEnvironmentRoles

Gets the list of namespace roles

20

DescribeEnvironments

Gets the list of namespaces
under a tenant

20

ModifyEnvironmentAttributes

Modifies namespace attributes

20

Topic APIs
API Name

FeatureFrequency Limit (maximum requests per second)

CreateTopic

Adds topic

200

DeleteTopics

Deletes topics

20

DescribeTopics

Gets the topic list

20

ModifyTopic

Modifies topic

50

Message APIs
API Name

FeatureFrequency Limit (maximum requests per second)

AcknowledgeMessage

Acknowledges message

1000

ReceiveMessage

Receives messages

1000

SendBatchMessages

Batch sends messages

1000

SendMessages

Sends one message

1000

CMQ Message APIs
API Name

FeatureFrequency Limit (maximum
requests per second)

ClearCmqQueue

Clears the messages in the CMQ
message queue.

20©2013-2022 Tencent Cloud. All rights reserved.

Page 23 of 450

TDMQ for Apache Pulsar

ClearCmqSubscriptionFilterTags

Clears the message tags of CMQ
subscriber

20

PublishCmqMsg

Sends CMQ topic message

20

SendCmqMsg

Sends CMQ message

20

CMQ Management APIs
API Name

FeatureFrequency Limit (maximum
requests per second)

CreateCmqQueue

Creates CMQ queue

20

CreateCmqSubscribe

Creates CMQ subscription

20

CreateCmqTopic

Creates CMQ topic

20

DeleteCmqQueue

Deletes CMQ queue

20

DeleteCmqSubscribe

Deletes CMQ subscription

20

DeleteCmqTopic

Deletes CMQ topic

20

DescribeCmqDeadLetterSourceQueues

Enumerates the source queues of
CMQ dead letter queue

20

DescribeCmqQueues

Queries all CMQ queues-

DescribeCmqSubscriptionDetail

Queries CMQ subscription details

20

DescribeCmqTopicDetail

Queries the details of CMQ topic

20

DescribeCmqTopics

Enumerates all CMQ topics

20

ModifyCmqQueueAttribute

Modifies CMQ queue attributes

20

ModifyCmqSubscriptionAttribute

Modifies CMQ subscription
attributes

20

ModifyCmqTopicAttribute

Modifies CMQ topic attributes

20

RewindCmqQueue

Rewinds CMQ queue

20

UnbindCmqDeadLetter

Unbinds CMQ dead letter queue

20

DescribeCmqQueueDetail

Queries the details of CMQ queue100©2013-2022 Tencent Cloud. All rights reserved.

Page 24 of 450

TDMQ for Apache Pulsar

Other APIs
API Name

FeatureFrequency Limit (maximum requests per
second)DescribeBindVpcs

Gets the tenant-VPC binding
relationship

20

SendMsg

Sends message

20

SendRocketMQMessage

Sends a TDMQ for RocketMQ
message

20

TDMQ for RabbitMQ APIs
API Name

FeatureFrequency Limit (maximum
requests per second)

CreateRabbitMQUser

Creates a TDMQ for RabbitMQ user

20

CreateRabbitMQVirtualHost

Creates a TDMQ for RabbitMQ vhost

20

DeleteRabbitMQUser

Deletes a TDMQ for RabbitMQ user

20

DeleteRabbitMQVirtualHost

Deletes a TDMQ for RabbitMQ vhost

20

DescribeRabbitMQUser

Queries the list of TDMQ for RabbitMQ
users

20

DescribeRabbitMQVipInstances

Queries the list of the purchased TDMQ for
RabbitMQ exclusive instances

20

DescribeRabbitMQVirtualHost

Queries the list of TDMQ for RabbitMQ
vhosts20

ModifyRabbitMQUser

Modifies a TDMQ for RabbitMQ user

20

ModifyRabbitMQVirtualHost

Modifies a TDMQ for RabbitMQ vhost

20

CreateRabbitMQVipInstance

Creates a TDMQ for RabbitMQ exclusive
instance

1©2013-2022 Tencent Cloud. All rights reserved.

Page 25 of 450

TDMQ for Apache Pulsar

DeleteRabbitMQVipInstanceDeletes a TDMQ for RabbitMQ exclusive
instance

20

Environment Role APIs
API Name

FeatureFrequency Limit (maximum requests per second)

CreateEnvironmentRole

Creates environment role

20

CreateRole

Creates role

20

DeleteEnvironmentRoles

Deletes environment role

20

DeleteRoles

Delete role

20

DescribeRoles

Gets the list of roles

20

ModifyEnvironmentRole

Modifies environment role

20

ModifyRole

Modifies role

20

RocketMQ APIs
API Name

FeatureFrequency Limit(maximum requests per
second)CreateRocketMQCluster

Creates RocketMQ cluster

20

CreateRocketMQGroup

Creates RocketMQ consumer group

20

CreateRocketMQNamespace

Creates RocketMQ namespace

20

CreateRocketMQTopic

Creates RocketMQ topic

20

DeleteRocketMQCluster

Deletes RocketMQ cluster

20

DeleteRocketMQGroup

Deletes RocketMQ consumer group

20

DeleteRocketMQTopic

Deletes RocketMQ topic

20

DescribeRocketMQClusters

Gets the list of RocketMQ clusters

20

DescribeRocketMQGroups

Gets the list of RocketMQ consumer

20©2013-2022 Tencent Cloud. All rights reserved.

Page 26 of 450

TDMQ for Apache Pulsar

groupsQueries the TDMQ for RocketMQ

DescribeRocketMQMsg

message details

20

DescribeRocketMQNamespaces

Gets the list of RocketMQ namespaces

20

DescribeRocketMQTopics

Gets the list of RocketMQ topics

20

DescribeRocketMQVipInstanceDetailGets the information of a specific
TDMQ for RocketMQ exclusive cluster

20

ModifyRocketMQCluster

Updates RocketMQ cluster

20

ModifyRocketMQGroup

Updates RocketMQ consumer group20

ModifyRocketMQNamespace

Updates RocketMQ namespace

20

ModifyRocketMQTopic

Updates RocketMQ topic

20

DescribeRocketMQCluster

Gets the information of specificRocketMQ cluster

20

TDMQ for RocketMQ APIs
API Name

FeatureFrequency Limit (maximum
requests per second)

DescribeRocketMQVipInstances

Queries the list of TDMQ for RocketMQ
exclusive instances

20

ModifyRocketMQInstanceSpec

Modifies the configurations of a TDMQ for
RocketMQ exclusive instance20

Production and Consumption APIs
API Name

FeatureFrequency Limit (maximum requests
per second)

CreateSubscription

Creates subscription

200

DeleteSubscriptions

Deletes a subscription

20©2013-2022 Tencent Cloud. All rights reserved.

Page 27 of 450

TDMQ for Apache Pulsar

DescribePublisherSummary

Obtains message production
overview

20

DescribePublishers

Obtains the list of producer
information

20

DescribeSubscriptions

Gets the consumer
subscription list

20

ResetMsgSubOffsetByTimestamp

Rewinds message

20

ResetRocketMQConsumerOffSet

Resets RocketMQ
consumption offset

20©2013-2022 Tencent Cloud. All rights reserved.

Page 28 of 450

TDMQ for Apache Pulsar

Making API Requests
Request Structure：

Last updated 2023-02-24 15:14:51

1. Service Address
The API supports access from either a nearby region (at tdmq.tencentcloudapi.com) or a specified region (at tdmq.apguangzhou.tencentcloudapi.com for Guangzhou, for example).
We recommend using the domain name to access the nearest server. When you call an API, the request is
automatically resolved to a server in the region nearest to the location where the API is initiated. For example, when
you initiate an API request in Guangzhou, this domain name is automatically resolved to a Guangzhou server, theresult is the same as that of specifying the region in the domain like "tdmq.ap-guangzhou.tencentcloudapi.com".
Note: For latency-sensitive businesses, we recommend that you specify the region in the domain name.
Tencent Cloud currently supports the following regions:
Hosted region

Domain nameLocal access region (recommended, only for non-financial availability
zones)

tdmq.tencentcloudapi.com

South China (Guangzhou)

tdmq.apguangzhou.tencentcloudapi.com

East China (Shanghai)tdmq.apshanghai.tencentcloudapi.com

North China (Beijing)tdmq.ap-beijing.tencentcloudapi.com

Southwest China (Chengdu)

tdmq.apchengdu.tencentcloudapi.com

Southwest China (Chongqing)tdmq.apchongqing.tencentcloudapi.com

Hong Kong, Macao, Taiwan (Hong Kong, China)

tdmq.aphongkong.tencentcloudapi.com

Southeast Asia (Singapore)

tdmq.apsingapore.tencentcloudapi.com©2013-2022 Tencent Cloud. All rights reserved.

Page 29 of 450

TDMQ for Apache Pulsar

Southeast Asia (Bangkok)

tdmq.apbangkok.tencentcloudapi.com

South Asia (Mumbai)

tdmq.ap-mumbai.tencentcloudapi.com

Northeast Asia (Seoul)tdmq.ap-seoul.tencentcloudapi.com

Northeast Asia (Tokyo)

tdmq.ap-tokyo.tencentcloudapi.com

U.S. East Coast (Virginia)

tdmq.na-ashburn.tencentcloudapi.com

U.S. West Coast (Silicon Valley)

tdmq.nasiliconvalley.tencentcloudapi.com

North America (Toronto)

tdmq.na-toronto.tencentcloudapi.com

Europe (Frankfurt)

tdmq.eu-frankfurt.tencentcloudapi.com

2. Communications Protocol
All the Tencent Cloud APIs communicate via HTTPS, providing highly secure communication tunnels.

3. Request Methods
Supported HTTP request methods:
POST (recommended)GETThe Content-Type types supported by POST requests:
application/json (recommended). The TC3-HMAC-SHA256 signature algorithm must be used.
application/x-www-form-urlencoded. The HmacSHA1 or HmacSHA256 signature algorithm must be used.
multipart/form-data (only supported by certain APIs). You must use TC3-HMAC-SHA256 to calculate the signature.
The size of a GET request packet is up to 32 KB. The size of a POST request is up to 1 MB when the HmacSHA1 or
HmacSHA256 signature algorithm is used, and up to 10 MB when TC3-HMAC-SHA256 is used.

4. Character Encoding©2013-2022 Tencent Cloud. All rights reserved.

Page 30 of 450

TDMQ for Apache Pulsar

Only UTF-8 encoding is used.

©2013-2022 Tencent Cloud. All rights reserved.

Page 31 of 450

TDMQ for Apache Pulsar

Common Params：

Last updated 2023-02-24 15:14:51
Common parameters are used for all APIs authenticating requestors. Common parameters must be included in all API
requests, and they will not be described in individual API documents.
The exact contents of the common parameters will vary depending on the version of the signature method you use.

Common parameters for Signature Algorithm v3
When the TC3-HMAC-SHA256 algorithm is used, the common parameters should be uniformly placed in the HTTP
request header, as shown below:
Parameter
Name

Type

Required

Description
The name of the API for the desired operation. For the specific value, see

X-TC-Action

X-TCRegion

X-TCTimestamp

StringStringYes

Yes

description of common parameter Action in the input parameters in r
documentation. For example, the API for querying the CVM instance list is
DescribeInstances .
Region parameter, which is used to identify the region to which the data ywork with belongs. For values supported for an API, see the description oparameter Region in the input parameters in related API documentati
parameter is not required for some APIs (which will be indicated in related
documentation), and will not take effect even it is passed.

Integer

X-TCVersion

StringAuthorization

StringYes

Yes

The current UNIX timestamp that records the time when the API request w
for example, 1529223702. Note: If the difference between the UNIX times
server time is greater than 5 minutes, a signature expiration error may occ
API version of the action. For the valid values, see the description of the cparameter Version in the API documentation. For example, the versi
2017-03-12.

Yes

The HTTP authentication request header, for example:
TC3-HMAC-SHA256 Credential=AKIDEXAMPLE/Date/service/tc3_requ
SignedHeaders=content-type;host,Signature=fe5f80f77d5fa3beca038a248ff027d0445342fe2855ddc96317
Here:- TC3-HMAC-SHA256: Signature method, currently fixed as this value;- Credential: Signature credential; AKIDEXAMPLE is the SecretId; Date is
UTC time, and this value must match the value of X-TC-Timestamp (a co©2013-2022 Tencent Cloud. All rights reserved.

Page 32 of 450

TDMQ for Apache Pulsar

parameter) in UTC time format; service is the name of the product/service
generally a domain name prefix. For example, a domain name cvm.tencen
refers to the CVM product and the value would be cvm;
- SignedHeaders: The headers that contains the authentication informatio
type and host are the required headers;- Signature: Signature digest.

X-TC-Token

String

No

The token used for a temporary certificate. It must be used with a tempora
can obtain the temporary key and token by calling a CAM API. No token ia long-term key.

Assuming you want to query the list of Cloud Virtual Machine instances in the Guangzhou region, the request structurein the form of request URL, request header and request body may be as follows:
Example of an HTTP GET request structure:https://cvm.tencentcloudapi.com/?Limit=10&Offset=0
Authorization: TC3-HMAC-SHA256 Credential=AKIDz8krbsJ5yKBZQpn74WFkmLPx3EXAMPLE/20
18-10-09/cvm/tc3_request, SignedHeaders=content-type;host, Signature=5da7a33f6993
f0614b047e5df4582db9e9bf4672ba50567dba16c6ccf174c474
Content-Type: application/x-www-form-urlencoded
Host: cvm.tencentcloudapi.com
X-TC-Action: DescribeInstances
X-TC-Version: 2017-03-12
X-TC-Timestamp: 1539084154
X-TC-Region: ap-guangzhou
The following example shows you how to structure an HTTP POST (application/json) request:
https://cvm.tencentcloudapi.com/
Authorization: TC3-HMAC-SHA256 Credential=AKIDEXAMPLE/2018-05-30/cvm/tc3_request,
SignedHeaders=content-type;host, Signature=582c400e06b5924a6f2b5d7d672d79c15b1316
2d9279b0855cfba6789a8edb4c
Content-Type: application/json
Host: cvm.tencentcloudapi.com
X-TC-Action: DescribeInstances
X-TC-Version: 2017-03-12
X-TC-Timestamp: 1527672334
X-TC-Region: ap-guangzhou{"Offset":0,"Limit":10}
Example of an HTTP POST (multipart/form-data) request structure (only supported by specific APIs):©2013-2022 Tencent Cloud. All rights reserved.

Page 33 of 450

TDMQ for Apache Pulsar

https://cvm.tencentcloudapi.com/
Authorization: TC3-HMAC-SHA256 Credential=AKIDEXAMPLE/2018-05-30/cvm/tc3_request,
SignedHeaders=content-type;host, Signature=582c400e06b5924a6f2b5d7d672d79c15b1316
2d9279b0855cfba6789a8edb4c
Content-Type: multipart/form-data; boundary=58731222010402
Host: cvm.tencentcloudapi.com
X-TC-Action: DescribeInstances
X-TC-Version: 2017-03-12
X-TC-Timestamp: 1527672334
X-TC-Region: ap-guangzhou--58731222010402
Content-Disposition: form-data; name="Offset"
0--58731222010402
Content-Disposition: form-data; name="Limit"
10--58731222010402--

Common parameters for Signature Algorithm v1
To adopt the HmacSHA1 and HmacSHA256 signature methods, common parameters must be put into the request
string, as shown below:
Parameter NameType

Required

Description
The name of the API for the desired operation. For the specificvalue, see the description of common parameter Action in the

ActionStringYes

input parameters in related API documentation. For example, theAPI for querying the CVM instance list is
DescribeInstances .
Region parameter, which is used to identify the region to which
the data you want to work with belongs. For values supported for
an API, see the description of common parameter Region in

RegionStringYes

the input parameters in related API documentation. Note: Thisparameter is not required for some APIs (which will be indicated inrelated API documentation), and will not take effect even if it ispassed.

©2013-2022 Tencent Cloud. All rights reserved.

Page 34 of 450

TDMQ for Apache Pulsar

Timestamp

IntegerYes

The current UNIX timestamp that records the time when the API
request was initiated, for example, 1529223702. If the difference
between the value and the current system time is too large, asignature expiration error may occur.
A random positive integer used along with Timestamp to

Nonce

Integer

Yes

SecretId

StringYes

The identifying SecretId obtained on the Cloud API Key page. A
SecretId corresponds to a unique SecretKey which is used togenerate the request signature (Signature).

Yes

Request signature used to verify the validity of this request. This iscalculated based on the actual input parameters. For more
information about how this is calculated, see the API
authentication documentation.

Signature

VersionStringStringYes

prevent replay attacks.

API version of the action. For the valid values, see the descriptionof the common input parameter Version in the API
documentation. For example, the version of CVM is 2017-03-12.

SignatureMethod

StringNo

Signature method. Currently, only HmacSHA256 and HmacSHA1
are supported. The HmacSHA256 algorithm is used to verify thesignature only when this parameter is specified as HmacSHA256.
In other cases, the signature is verified with HmacSHA1.

Token

String

No

The token used for a temporary certificate. It must be used with atemporary key. You can obtain the temporary key and token bycalling a CAM API. No token is required for a long-term key.

Assuming you want to query the list of Cloud Virtual Machine instances in the Guangzhou region, the request structurein the form of request URL, request header and request body may be as follows:
Example of an HTTP GET request structure:https://cvm.tencentcloudapi.com/?Action=DescribeInstances&Version=2017-03-12&Sign
atureMethod=HmacSHA256&Timestamp=1527672334&Signature=37ac2f4fde00b0ac9bd9eadeb45
9b1bbee224158d66e7ae5fcadb70b2d181d02&Region=ap-guangzhou&Nonce=23823223&SecretId=AKIDEXAMPLE
Host: cvm.tencentcloudapi.com
Content-Type: application/x-www-form-urlencoded
Example of an HTTP POST request structure:©2013-2022 Tencent Cloud. All rights reserved.

Page 35 of 450

TDMQ for Apache Pulsar

https://cvm.tencentcloudapi.com/
Host: cvm.tencentcloudapi.com
Content-Type: application/x-www-form-urlencoded
Action=DescribeInstances&Version=2017-03-12&SignatureMethod=HmacSHA256&Timestamp=
1527672334&Signature=37ac2f4fde00b0ac9bd9eadeb459b1bbee224158d66e7ae5fcadb70b2d18
1d02&Region=ap-guangzhou&Nonce=23823223&SecretId=AKIDEXAMPLE©2013-2022 Tencent Cloud. All rights reserved.

Page 36 of 450

TDMQ for Apache Pulsar

Signature v3：

Last updated 2022-02-11 10:10:18
TencentCloud API authenticates every single request, i.e., the request must be signed using the security credentials inthe designated steps. Each request has to contain the signature information (Signature) in the common request
parameters and be sent in the specified way and format.

Applying for Security Credentials
The security credential used in this document is a key, which includes a SecretId and a SecretKey. Each user canhave up to two pairs of keys.
SecretId: Used to identify the API caller, which is just like a username.
SecretKey: Used to authenticate the API caller, which is just like a password.
You must keep your security credentials private and avoid disclosure; otherwise, your assets may becompromised. If they are disclosed, please disable them as soon as possible.
You can apply for the security credentials through the following steps:
1. Log in to the Tencent Cloud Console.
2. Go to the TencentCloud API Key console page.
3. On the TencentCloud API Key page, click Create to create a SecretId/SecretKey pair.

Using the Resources for Developers
TencentCloud API comes with SDKs for seven commonly used programming languages, including Python, Java,
PHP, Go, NodeJS and .NET. In addition, it provides API Explorer which enables online call, signature verification, andSDK code generation. If you have any troubles calculating a signature, consult these resources.

TC3-HMAC-SHA256 Signature Algorithm
Compatible with the previous HmacSHA1 and HmacSHA256 signature algorithms, the TC3-HMAC-SHA256
signature algorithm is more secure and supports larger requests and JSON format with better performance. We
recommend using TC3-HMAC-SHA256 to calculate the signature.
TencentCloud API supports both GET and POST requests. For the GET method, only the Content-Type:application/x-www-form-urlencoded protocol format is supported. For the POST method, two protocol formats,©2013-2022 Tencent Cloud. All rights reserved.

Page 37 of 450

TDMQ for Apache Pulsar

Content-Type: application/json and Content-Type: multipart/form-data, are supported. The JSON format is supported
by default for all business APIs, and the multipart format is supported only for specific business APIs. In this case, theAPI cannot be called in JSON format. See the specific business API documentation for more information. The POST
method is recommended, as there is no difference in the results of both the methods, but the GET method only
supports request packets up to 32 KB.
The following uses querying the list of CVM instances in the Guangzhou region as an example to describe the steps ofsignature splicing. We chose this API because:
1. CVM is activated by default, and this API is often used;
2. It is read-only and does not change the status of existing resources;
3. It covers many types of parameters, which allows it to be used to demonstrate how to use arrays containing data
structures.
In the example, we try to choose common parameters and API parameters that are prone to mistakes. When you
actually call an API, please use parameters based on the actual conditions. The parameters vary by API. Do not copy
the parameters and values in this example.
Assuming that your SecretId and SecretKey are AKIDz8krbsJ5yKBZQpn74WFkmLPx3******* andGu5t9xGARNpq86cd98joQYCN3******* , respectively, if you want to view the status of the instance in the
Guangzhou region whose CVM instance name is "unnamed" and have only one data entry returned, then the request
may be:curl -X POST https://cvm.tencentcloudapi.com \-H "Authorization: TC3-HMAC-SHA256 Credential=AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******/2019-02-25/cvm/tc3_request, SignedHeaders=content-type;host, Signature=c492e8e4
1437e97a620b728c301bb8d17e7dc0c17eeabce80c20cd70fc3a78ff" \-H "Content-Type: application/json; charset=utf-8" \-H "Host: cvm.tencentcloudapi.com" \-H "X-TC-Action: DescribeInstances" \-H "X-TC-Timestamp: 1551113065" \-H "X-TC-Version: 2017-03-12" \-H "X-TC-Region: ap-guangzhou" \-d '{"Limit": 1, "Filters": [{"Values": ["unnamed"], "Name": "instance-name"}]}'The signature calculation process is explained in detail below.

1. Concatenating the CanonicalRequest String
Concatenate the canonical request string (CanonicalRequest) in the following pseudocode format:
CanonicalRequest =HTTPRequestMethod + '\n' +CanonicalURI + '\n' +©2013-2022 Tencent Cloud. All rights reserved.

Page 38 of 450

TDMQ for Apache Pulsar

CanonicalQueryString + '\n' +CanonicalHeaders + '\n' +SignedHeaders + '\n' +HashedRequestPayload
Field Name

Explanation

HTTPRequestMethod

HTTP request method (GET or POST). This example uses POST .

CanonicalURI

URI parameter. Slash ("/") is used for API 3.0.
The query string in the URL of the originating HTTP request. This is always an empty st“” for POST requests, and is the string after the question mark (?) for GET requests. Fo

CanonicalQueryString。

example: Limit=10&Offset=0
Note: CanonicalQueryString must be URL-encoded, referencing RFC3986, theUTF8 character set. We recommend using the programming language library. All specia
characters must be encoded and capitalized.
Header information for signature calculation, including at least two headers of host
content-type . Custom headers can be added to participate in the signature proce
improve the uniqueness and security of the request.
Concatenation rules:
1. Both the key and value of the header should be converted to lowercase with the lead

CanonicalHeaders

and trailing spaces removed, so they are concatenated in the format of key:value\nformat;2. If there are multiple headers, they should be sorted in ASCII ascending order by theheader keys (lowercase).
The calculation result in this example is content-type:application/json;
charset=utf-8\nhost:cvm.tencentcloudapi.com\n .
Note: content-type must match the actually sent content. In some programming
languages, a charset value would be added even if it is not specified. In this case, therequest sent is different from the one signed, and the sever will return an error indicating
signature verification failed.
Header information for signature calculation, indicating which headers of the request
participate in the signature process (they must each individually correspond to the headin CanonicalHeaders). Content-type and host are required headers.

SignedHeaders

Concatenation rules:
1. Both the key and value of the header should be converted to lowercase;
2. If there are multiple headers, they should be sorted in ASCII ascending order by theheader keys (lowercase) and separated by semicolons (;).
The value in this example is content-type;hostHashedRequestPayload

Hash value of the request payload (i.e., the body, such as {"Limit": 1, "Filter©2013-2022 Tencent Cloud. All rights reserved.

Page 39 of 450

TDMQ for Apache Pulsar[{"Values": ["unnamed"], "Name": "instance-name"}]} in this example
The pseudocode for calculation is
Lowercase(HexEncode(Hash.SHA256(RequestPayload))) by SHA256 hashing the payof the HTTP request, performing hexadecimal encoding, and finally converting the enco
string to lowercase letters. For GET requests, RequestPayload is always an empt
string. The calculation result in this example is
99d58dfbc6745f6747f36bfca17dee5e6881dc0428a0a36f96199342bc5b49

According to the rules above, the CanonicalRequest string obtained in the example is as follows:

POST/
content-type:application/json; charset=utf-8
host:cvm.tencentcloudapi.com
content-type;host
99d58dfbc6745f6747f36bfca17dee5e6881dc0428a0a36f96199342bc5b4907

2. Concatenating the String to Be Signed
The string to sign is concatenated as follows:
StringToSign =Algorithm + \n +RequestTimestamp + \n +CredentialScope + \n +HashedCanonicalRequest
Field Name

Explanation

Algorithm

Signature algorithm, which is currently always TC3-HMAC-SHA256 .
Request timestamp, i.e., the value of the common parameter X-TC-Timestamp in

RequestTimestamp

request header, which is the UNIX timestamp of the current time in seconds, such as1551113065 in this example.
Scope of the credential in the format of Date/service/tc3_request , including
date, requested service and termination string (tc3_request). Date is a date in UT

CredentialScopetime, whose value should match the UTC date converted by the common
parameter X-TC-Timestamp ; service is the product name, which should mthe domain name of the product called. The calculation result in this example is 201
25/cvm/tc3_request .

©2013-2022 Tencent Cloud. All rights reserved.

Page 40 of 450

TDMQ for Apache Pulsar

HashedCanonicalRequest

Hash value of the CanonicalRequest string concatenated in the steps above. The
pseudocode for calculation is Lowercase(HexEncode(Hash.SHA256(CanonicalRequ
The calculation result in this example is2815843035062fffda5fd6f2a44ea8a34818b0dc46f024b8b3786976a3ad

Note:

1. Date has to be calculated from the timestamp "X-TC-Timestamp" and the time zone is UTC+0. If you add
the system's local time zone information (such as UTC+8), calls can succeed both day and night but willdefinitely fail at 00:00. For example, if the timestamp is 1551113065 and the time in UTC+8 is 2019-02-26
00:44:25, the UTC+0 date in the calculated Date value should be 2019-02-25 instead of 2019-02-26.
2. Timestamp must be the same as your current system time, and your system time and standard time must be
synced; if the difference between Timestamp and your current system time is larger than five minutes, therequest will fail. If your system time is out of sync with the standard time for a while, the request will fail andreturn a signature expiration error.

According to the preceding rules, the string to be signed obtained in the example is as follows:
TC3-HMAC-SHA256
1551113065
2019-02-25/cvm/tc3_request
2815843035062fffda5fd6f2a44ea8a34818b0dc46f024b8b3786976a3adda7a

3. Calculating the Signature
1. Calculate the derived signature key with the following pseudocode:

SecretKey = "Gu5t9xGARNpq86cd98joQYCN3*******"
SecretDate = HMAC_SHA256("TC3" + SecretKey, Date)
SecretService = HMAC_SHA256(SecretDate, Service)
SecretSigning = HMAC_SHA256(SecretService, "tc3_request")
Field Name

Explanation

SecretKey

The original SecretKey, i.e., Gu5t9xGARNpq86cd98joQYCN3******* .

Date

The Date field information in Credential , such as 2019-02-25 in this example.

©2013-2022 Tencent Cloud. All rights reserved.

Page 41 of 450

TDMQ for Apache Pulsar

Service

Value in the Service field in Credential , such as cvm in this example.

2. Calculate the signature with the following pseudocode:

Signature = HexEncode(HMAC_SHA256(SecretSigning, StringToSign))

4. Concatenating the Authorization
The Authorization is concatenated as follows:

Authorization =Algorithm + ' ' +'Credential=' + SecretId + '/' + CredentialScope + ', ' +'SignedHeaders=' + SignedHeaders + ', ' +'Signature=' + Signature
Field Name

Explanation

Algorithm

Signature algorithm, which is always TC3-HMAC-SHA256 .

SecretId

The SecretId in the key pair, i.e., AKIDz8krbsJ5yKBZQpn74WFkmLPx3******* .

CredentialScope

SignedHeadersSignature

Credential scope (see above). The calculation result in this example is 2019-0225/cvm/tc3_request .
Header information for signature calculation (see above), such as content-type;hostin this example.
Signature value. The calculation result in this example isc492e8e41437e97a620b728c301bb8d17e7dc0c17eeabce80c20cd70fc3a78ff .

According to the rules above, the value obtained in the example is:TC3-HMAC-SHA256 Credential=AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******/2019-02-25/cvm/tc
3_request, SignedHeaders=content-type;host, Signature=c492e8e41437e97a620b728c301
bb8d17e7dc0c17eeabce80c20cd70fc3a78ff
The following example shows a finished authorization header:
POST https://cvm.tencentcloudapi.com/
Authorization: TC3-HMAC-SHA256 Credential=AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******/20
19-02-25/cvm/tc3_request, SignedHeaders=content-type;host, Signature=c492e8e41437
e97a620b728c301bb8d17e7dc0c17eeabce80c20cd70fc3a78ff©2013-2022 Tencent Cloud. All rights reserved.

Page 42 of 450

TDMQ for Apache Pulsar

Content-Type: application/json; charset=utf-8
Host: cvm.tencentcloudapi.com
X-TC-Action: DescribeInstances
X-TC-Version: 2017-03-12
X-TC-Timestamp: 1551113065
X-TC-Region: ap-guangzhou{"Limit": 1, "Filters": [{"Values": ["unnamed"], "Name": "instance-name"}]}5. Signature Demo
When calling API 3.0, you are recommended to use the corresponding Tencent Cloud SDK 3.0 which encapsulates
the signature process, enabling you to focus on only the specific APIs provided by the product when developing. See
SDK Center for more information. Currently, the following programming languages are supported:
PythonJava
PHP
Go
NodeJS.NET
To further explain the signing process, we will use a programming language to implement the process describedabove. The request domain name, API and parameter values in the sample are used here. This goal of this example isonly to provide additional clarification for the signature process, please see the SDK for actual usage.
The final output URL might be: https://cvm.tencentcloudapi.com/?Action=DescribeInstances&InstanceIds.0=ins09dx96dg&Limit=20&Nonce=11886&Offset=0&Region=apguangzhou&SecretId=AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******&Signature=EliP9YW3pW28FpsEdkXt%2F%2B
WcGeI%3D&Timestamp=1465185768&Version=2017-03-12.
Note: The key in the example is fictitious, and the timestamp is not the current time of the system, so if this URL is
opened in the browser or called using commands such as curl, an authentication error will be returned: Signature
expired. In order to get a URL that can work properly, you need to replace the SecretId and SecretKey in the example
with your real credentials and use the current time of the system as the Timestamp.
Note: In the example below, even if you use the same programming language, the order of the parameters in the URL
may be different for each execution. However, the order does not matter, as long as all the parameters are included in
the URL and the signature is calculated correctly.
Note: The following code is only applicable to API 3.0. It cannot be directly used in other signature processes. Even
with an older API, signature calculation errors may occur due to the differences in details. Please refer to thecorresponding documentation.

©2013-2022 Tencent Cloud. All rights reserved.

Page 43 of 450

TDMQ for Apache Pulsar

Java
import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.security.MessageDigest;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.TimeZone;
import java.util.TreeMap;
import javax.crypto.Mac;
import javax.crypto.spec.SecretKeySpec;
import javax.xml.bind.DatatypeConverter;
public class TencentCloudAPITC3Demo {private final static Charset UTF8 = StandardCharsets.UTF_8;
private final static String SECRET_ID = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******";
private final static String SECRET_KEY = "Gu5t9xGARNpq86cd98joQYCN3*******";
private final static String CT_JSON = "application/json; charset=utf-8";
public static byte[] hmac256(byte[] key, String msg) throws Exception {Mac mac = Mac.getInstance("HmacSHA256");
SecretKeySpec secretKeySpec = new SecretKeySpec(key, mac.getAlgorithm());
mac.init(secretKeySpec);
return mac.doFinal(msg.getBytes(UTF8));}
public static String sha256Hex(String s) throws Exception {MessageDigest md = MessageDigest.getInstance("SHA-256");
byte[] d = md.digest(s.getBytes(UTF8));
return DatatypeConverter.printHexBinary(d).toLowerCase();}public static void main(String[] args) throws Exception {String service = "cvm";
String host = "cvm.tencentcloudapi.com";
String region = "ap-guangzhou";String action = "DescribeInstances";
String version = "2017-03-12";
String algorithm = "TC3-HMAC-SHA256";
String timestamp = "1551113065";//String timestamp = String.valueOf(System.currentTimeMillis() / 1000);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");// Pay attention to the time zone; otherwise, errors may occur
sdf.setTimeZone(TimeZone.getTimeZone("UTC"));
String date = sdf.format(new Date(Long.valueOf(timestamp + "000")));// ************* Step 1: Concatenate the CanonicalRequest string *************©2013-2022 Tencent Cloud. All rights reserved.

Page 44 of 450

TDMQ for Apache Pulsar

String httpRequestMethod = "POST";
String canonicalUri = "/";
String canonicalQueryString = "";String canonicalHeaders = "content-type:application/json; charset=utf-8\n" + "host:" + host + "\n";String signedHeaders = "content-type;host";
String payload = "{\"Limit\": 1, \"Filters\": [{\"Values\": [\"unnamed\"], \"Name\": \"instance-name\"}]}";
String hashedRequestPayload = sha256Hex(payload);
String canonicalRequest = httpRequestMethod + "\n" + canonicalUri + "\n" + canoni
calQueryString + "\n"+ canonicalHeaders + "\n" + signedHeaders + "\n" + hashedRequestPayload;
System.out.println(canonicalRequest);// ************* Step 2: Concatenate the string to sign *************
String credentialScope = date + "/" + service + "/" + "tc3_request";
String hashedCanonicalRequest = sha256Hex(canonicalRequest);
String stringToSign = algorithm + "\n" + timestamp + "\n" + credentialScope +"\n" + hashedCanonicalRequest;
System.out.println(stringToSign);// ************* Step 3: Calculate the signature *************
byte[] secretDate = hmac256(("TC3" + SECRET_KEY).getBytes(UTF8), date);byte[] secretService = hmac256(secretDate, service);byte[] secretSigning = hmac256(secretService, "tc3_request");String signature = DatatypeConverter.printHexBinary(hmac256(secretSigning, string
ToSign)).toLowerCase();
System.out.println(signature);// ************* Step 4: Concatenate the Authorization *************
String authorization = algorithm + " " + "Credential=" + SECRET_ID + "/" + creden
tialScope + ", "+ "SignedHeaders=" + signedHeaders + ", " + "Signature=" + signature;
System.out.println(authorization);
TreeMap<String, String> headers = new TreeMap<String, String>();headers.put("Authorization", authorization);headers.put("Content-Type", CT_JSON);headers.put("Host", host);
headers.put("X-TC-Action", action);headers.put("X-TC-Timestamp", timestamp);
headers.put("X-TC-Version", version);headers.put("X-TC-Region", region);
StringBuilder sb = new StringBuilder();sb.append("curl -X POST https://").append(host)©2013-2022 Tencent Cloud. All rights reserved.

Page 45 of 450

TDMQ for Apache Pulsar.append(" -H \"Authorization: ").append(authorization).append("\"").append(" -H \"Content-Type: application/json; charset=utf-8\"").append(" -H \"Host: ").append(host).append("\"").append(" -H \"X-TC-Action: ").append(action).append("\"").append(" -H \"X-TC-Timestamp: ").append(timestamp).append("\"").append(" -H \"X-TC-Version: ").append(version).append("\"").append(" -H \"X-TC-Region: ").append(region).append("\"").append(" -d '").append(payload).append("'");
System.out.println(sb.toString());}}

Python# -*- coding: utf-8 -*import hashlib, hmac, json, os, sys, timefrom datetime import datetime# Key Parameters
secret_id = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"
secret_key = "Gu5t9xGARNpq86cd98joQYCN3*******"
service = "cvm"host = "cvm.tencentcloudapi.com"
endpoint = "https://" + hostregion = "ap-guangzhou"
action = "DescribeInstances"version = "2017-03-12"
algorithm = "TC3-HMAC-SHA256"#timestamp = int(time.time())
timestamp = 1551113065
date = datetime.utcfromtimestamp(timestamp).strftime("%Y-%m-%d")params = {"Limit": 1, "Filters": [{"Name": "instance-name", "Values": ["unnamed"]}]}# ************* Step 1: Concatenate the CanonicalRequest string *************
http_request_method = "POST"
canonical_uri = "/"canonical_querystring = ""ct = "application/json; charset=utf-8"
payload = json.dumps(params)
canonical_headers = "content-type:%s\nhost:%s\n" % (ct, host)signed_headers = "content-type;host"hashed_request_payload = hashlib.sha256(payload.encode("utf-8")).hexdigest()
canonical_request = (http_request_method + "\n" +canonical_uri + "\n" +©2013-2022 Tencent Cloud. All rights reserved.

Page 46 of 450

TDMQ for Apache Pulsar

canonical_querystring + "\n" +canonical_headers + "\n" +signed_headers + "\n" +hashed_request_payload)
print(canonical_request)# ************* Step 2: Concatenate the string to sign *************
credential_scope = date + "/" + service + "/" + "tc3_request"
hashed_canonical_request = hashlib.sha256(canonical_request.encode("utf-8")).hexd
igest()
string_to_sign = (algorithm + "\n" +str(timestamp) + "\n" +credential_scope + "\n" +hashed_canonical_request)
print(string_to_sign)# ************* Step 3: Calculate the Signature *************# Function for computing signature digest
def sign(key, msg):
return hmac.new(key, msg.encode("utf-8"), hashlib.sha256).digest()
secret_date = sign(("TC3" + secret_key).encode("utf-8"), date)secret_service = sign(secret_date, service)secret_signing = sign(secret_service, "tc3_request")
signature = hmac.new(secret_signing, string_to_sign.encode("utf-8"), hashlib.sha256).hexdigest()
print(signature)# ************* Step 4: Concatenate the Authorization *************
authorization = (algorithm + " " +"Credential=" + secret_id + "/" + credential_scope + ", " +"SignedHeaders=" + signed_headers + ", " +"Signature=" + signature)
print(authorization)
print('curl -X POST ' + endpoint+ ' -H "Authorization: ' + authorization + '"'+ ' -H "Content-Type: application/json; charset=utf-8"'+ ' -H "Host: ' + host + '"'+ ' -H "X-TC-Action: ' + action + '"'+ ' -H "X-TC-Timestamp: ' + str(timestamp) + '"'+ ' -H "X-TC-Version: ' + version + '"'+ ' -H "X-TC-Region: ' + region + '"'+ " -d '" + payload + "'")

Golang©2013-2022 Tencent Cloud. All rights reserved.

Page 47 of 450

TDMQ for Apache Pulsar

package main
import ("crypto/hmac""crypto/sha256""encoding/hex""fmt""time")
func sha256hex(s string) string {b := sha256.Sum256([]byte(s))
return hex.EncodeToString(b[:])}func hmacsha256(s, key string) string {hashed := hmac.New(sha256.New, []byte(key))hashed.Write([]byte(s))
return string(hashed.Sum(nil))}func main() {secretId := "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"
secretKey := "Gu5t9xGARNpq86cd98joQYCN3*******"
host := "cvm.tencentcloudapi.com"
algorithm := "TC3-HMAC-SHA256"
service := "cvm"version := "2017-03-12"
action := "DescribeInstances"
region := "ap-guangzhou"//var timestamp int64 = time.Now().Unix()
var timestamp int64 = 1551113065// step 1: build canonical request string
httpRequestMethod := "POST"
canonicalURI := "/"canonicalQueryString := ""canonicalHeaders := "content-type:application/json; charset=utf-8\n" + "host:" +host + "\n"signedHeaders := "content-type;host"
payload := `{"Limit": 1, "Filters": [{"Values": ["unnamed"], "Name": "instance-name"}]}`
hashedRequestPayload := sha256hex(payload)
canonicalRequest := fmt.Sprintf("%s\n%s\n%s\n%s\n%s\n%s",
httpRequestMethod,
canonicalURI,©2013-2022 Tencent Cloud. All rights reserved.

Page 48 of 450

TDMQ for Apache Pulsar

canonicalQueryString,canonicalHeaders,signedHeaders,hashedRequestPayload)
fmt.Println(canonicalRequest)// step 2: build string to sign
date := time.Unix(timestamp, 0).UTC().Format("2006-01-02")
credentialScope := fmt.Sprintf("%s/%s/tc3_request", date, service)hashedCanonicalRequest := sha256hex(canonicalRequest)
string2sign := fmt.Sprintf("%s\n%d\n%s\n%s",
algorithm,
timestamp,
credentialScope,
hashedCanonicalRequest)
fmt.Println(string2sign)// step 3: sign string
secretDate := hmacsha256(date, "TC3"+secretKey)
secretService := hmacsha256(service, secretDate)secretSigning := hmacsha256("tc3_request", secretService)signature := hex.EncodeToString([]byte(hmacsha256(string2sign, secretSigning)))
fmt.Println(signature)// step 4: build authorization
authorization := fmt.Sprintf("%s Credential=%s/%s, SignedHeaders=%s, Signature=%s",algorithm,
secretId,
credentialScope,
signedHeaders,signature)
fmt.Println(authorization)
curl := fmt.Sprintf(`curl -X POST https://%s\-H "Authorization: %s"\
-H "Content-Type: application/json; charset=utf-8"\-H "Host: %s" -H "X-TC-Action: %s"\
-H "X-TC-Timestamp: %d"\
-H "X-TC-Version: %s"\
-H "X-TC-Region: %s"\-d '%s'`, host, authorization, host, action, timestamp, version, region, payload)
fmt.Println(curl)}

PHP©2013-2022 Tencent Cloud. All rights reserved.

Page 49 of 450

TDMQ for Apache Pulsar<?php$secretId = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******";$secretKey = "Gu5t9xGARNpq86cd98joQYCN3*******";$host = "cvm.tencentcloudapi.com";$service = "cvm";$version = "2017-03-12";$action = "DescribeInstances";$region = "ap-guangzhou";// $timestamp = time();$timestamp = 1551113065;$algorithm = "TC3-HMAC-SHA256";// step 1: build canonical request string$httpRequestMethod = "POST";$canonicalUri = "/";
$canonicalQueryString = "";$canonicalHeaders = "content-type:application/json; charset=utf-8\n"."host:".$host."\n";$signedHeaders = "content-type;host";$payload = '{"Limit": 1, "Filters": [{"Values": ["unnamed"], "Name": "instance-name"}]}';$hashedRequestPayload = hash("SHA256", $payload);$canonicalRequest = $httpRequestMethod."\n".$canonicalUri."\n".$canonicalQueryString."\n".$canonicalHeaders."\n".$signedHeaders."\n".$hashedRequestPayload;
echo $canonicalRequest.PHP_EOL;// step 2: build string to sign
$date = gmdate("Y-m-d", $timestamp);$credentialScope = $date."/".$service."/tc3_request";$hashedCanonicalRequest = hash("SHA256", $canonicalRequest);$stringToSign = $algorithm."\n".$timestamp."\n".$credentialScope."\n".$hashedCanonicalRequest;
echo $stringToSign.PHP_EOL;// step 3: sign string$secretDate = hash_hmac("SHA256", $date, "TC3".$secretKey, true);$secretService = hash_hmac("SHA256", $service, $secretDate, true);$secretSigning = hash_hmac("SHA256", "tc3_request", $secretService, true);$signature = hash_hmac("SHA256", $stringToSign, $secretSigning);
echo $signature.PHP_EOL;©2013-2022 Tencent Cloud. All rights reserved.

Page 50 of 450

TDMQ for Apache Pulsar// step 4: build authorization$authorization = $algorithm." Credential=".$secretId."/".$credentialScope.", SignedHeaders=content-type;host, Signature=".$signature;echo $authorization.PHP_EOL;$curl = "curl -X POST https://".$host.' -H "Authorization: '.$authorization.'"'.' -H "Content-Type: application/json; charset=utf-8"'.' -H "Host: '.$host.'"'.' -H "X-TC-Action: '.$action.'"'.' -H "X-TC-Timestamp: '.$timestamp.'"'.' -H "X-TC-Version: '.$version.'"'.' -H "X-TC-Region: '.$region.'"'." -d '".$payload."'";
echo $curl.PHP_EOL;

Ruby# -*- coding: UTF-8 -*# require ruby>=2.3.0
require 'digest'
require 'json'
require 'time'require 'openssl'# Key Parameters
secret_id = 'AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******'
secret_key = 'Gu5t9xGARNpq86cd98joQYCN3*******'
service = 'cvm'
host = 'cvm.tencentcloudapi.com'
endpoint = 'https://' + hostregion = 'ap-guangzhou'
action = 'DescribeInstances'version = '2017-03-12'
algorithm = 'TC3-HMAC-SHA256'# timestamp = Time.now.to_i
timestamp = 1551113065
date = Time.at(timestamp).utc.strftime('%Y-%m-%d')# ************* Step 1: Concatenate the CanonicalRequest string *************
http_request_method = 'POST'
canonical_uri = '/'canonical_querystring = ''©2013-2022 Tencent Cloud. All rights reserved.

Page 51 of 450

TDMQ for Apache Pulsar

canonical_headers = "content-type:application/json; charset=utf-8\nhost:#{host}\n"signed_headers = 'content-type;host'# params = { 'Limit' => 1, 'Filters' => [{ 'Name' => 'instance-name', 'Values' =>['unnamed'] }] }# payload = JSON.generate(params, { 'ascii_only' => true, 'space' => ' ' })# json will generate in random order, to get specified result in example, we hard-code it here.
payload = '{"Limit": 1, "Filters": [{"Values": ["unnamed"], "Name": "instance-name"}]}'
hashed_request_payload = Digest::SHA256.hexdigest(payload)
canonical_request = [http_request_method,
canonical_uri,canonical_querystring,canonical_headers,signed_headers,hashed_request_payload,].join("\n")puts canonical_request# ************* Step 2: Concatenate the string to sign *************
credential_scope = date + '/' + service + '/' + 'tc3_request'
hashed_request_payload = Digest::SHA256.hexdigest(canonical_request)
string_to_sign = [algorithm,
timestamp.to_s,
credential_scope,
hashed_request_payload,].join("\n")puts string_to_sign# ************* Step 3: Calculate the Signature *************
digest = OpenSSL::Digest.new('sha256')secret_date = OpenSSL::HMAC.digest(digest, 'TC3' + secret_key, date)secret_service = OpenSSL::HMAC.digest(digest, secret_date, service)secret_signing = OpenSSL::HMAC.digest(digest, secret_service, 'tc3_request')
signature = OpenSSL::HMAC.hexdigest(digest, secret_signing, string_to_sign)
puts signature# ************* Step 4: Concatenate the Authorization *************
authorization = "#{algorithm} Credential=#{secret_id}/#{credential_scope}, Signed
Headers=#{signed_headers}, Signature=#{signature}"puts authorization
puts 'curl -X POST ' + endpoint \©2013-2022 Tencent Cloud. All rights reserved.

Page 52 of 450

TDMQ for Apache Pulsar+ ' -H "Authorization: ' + authorization + '"' \+ ' -H "Content-Type: application/json; charset=utf-8"' \+ ' -H "Host: ' + host + '"' \+ ' -H "X-TC-Action: ' + action + '"' \+ ' -H "X-TC-Timestamp: ' + timestamp.to_s + '"' \+ ' -H "X-TC-Version: ' + version + '"' \+ ' -H "X-TC-Region: ' + region + '"' \+ " -d '" + payload + "'"DotNetusing System;
using System.Collections.Generic;using System.Security.Cryptography;
using System.Text;
public class Application{
public static string SHA256Hex(string s){
using (SHA256 algo = SHA256.Create()){
byte[] hashbytes = algo.ComputeHash(Encoding.UTF8.GetBytes(s));
StringBuilder builder = new StringBuilder();for (int i = 0; i < hashbytes.Length; ++i){
builder.Append(hashbytes[i].ToString("x2"));}
return builder.ToString();}}
public static byte[] HmacSHA256(byte[] key, byte[] msg){
using (HMACSHA256 mac = new HMACSHA256(key)){
return mac.ComputeHash(msg);}}
public static Dictionary<String, String> BuildHeaders(string secretid,
string secretkey, string service, string endpoint, string region,
string action, string version, DateTime date, string requestPayload){
string datestr = date.ToString("yyyy-MM-dd");
DateTime startTime = new DateTime(1970, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc);
long requestTimestamp = (long)Math.Round((date - startTime).TotalMilliseconds, Mi©2013-2022 Tencent Cloud. All rights reserved.

Page 53 of 450

TDMQ for Apache Pulsar

dpointRounding.AwayFromZero) / 1000;// ************* Step 1: Concatenate the CanonicalRequest string *************
string algorithm = "TC3-HMAC-SHA256";
string httpRequestMethod = "POST";
string canonicalUri = "/";
string canonicalQueryString = "";string contentType = "application/json";string canonicalHeaders = "content-type:" + contentType + "; charset=utf-8\n" +"host:" + endpoint + "\n";string signedHeaders = "content-type;host";
string hashedRequestPayload = SHA256Hex(requestPayload);string canonicalRequest = httpRequestMethod + "\n"+ canonicalUri + "\n"+ canonicalQueryString + "\n"+ canonicalHeaders + "\n"+ signedHeaders + "\n"+ hashedRequestPayload;
Console.WriteLine(canonicalRequest);
Console.WriteLine("----------------------------------");// ************ Step 2: Concatenate the string to sign *************
string credentialScope = datestr + "/" + service + "/" + "tc3_request";
string hashedCanonicalRequest = SHA256Hex(canonicalRequest);
string stringToSign = algorithm + "\n" + requestTimestamp.ToString() + "\n" + cre
dentialScope + "\n" + hashedCanonicalRequest;
Console.WriteLine(stringToSign);
Console.WriteLine("----------------------------------");// ************* Step 3: Calculate the signature *************
byte[] tc3SecretKey = Encoding.UTF8.GetBytes("TC3" + secretkey);byte[] secretDate = HmacSHA256(tc3SecretKey, Encoding.UTF8.GetBytes(datestr));byte[] secretService = HmacSHA256(secretDate, Encoding.UTF8.GetBytes(service));byte[] secretSigning = HmacSHA256(secretService, Encoding.UTF8.GetBytes("tc3_request"));
byte[] signatureBytes = HmacSHA256(secretSigning, Encoding.UTF8.GetBytes(stringTo
Sign));
string signature = BitConverter.ToString(signatureBytes).Replace("-", "").ToLower();
Console.WriteLine(signature);
Console.WriteLine("----------------------------------");// ************* Step 4: Concatenate the Authorization *************
string authorization = algorithm + " "+ "Credential=" + secretid + "/" + credentialScope + ", "+ "SignedHeaders=" + signedHeaders + ", "+ "Signature=" + signature;
Console.WriteLine(authorization);©2013-2022 Tencent Cloud. All rights reserved.

Page 54 of 450

TDMQ for Apache Pulsar

Console.WriteLine("----------------------------------");
Dictionary<string, string> headers = new Dictionary<string, string>();headers.Add("Authorization", authorization);headers.Add("Host", endpoint);
headers.Add("Content-Type", contentType + "; charset=utf-8");
headers.Add("X-TC-Timestamp", requestTimestamp.ToString());
headers.Add("X-TC-Version", version);headers.Add("X-TC-Action", action);headers.Add("X-TC-Region", region);
return headers;}public static void Main(string[] args){// SecretID and SecretKey
string SECRET_ID = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******";
string SECRET_KEY = "Gu5t9xGARNpq86cd98joQYCN3*******";
string service = "cvm";
string endpoint = "cvm.tencentcloudapi.com";string region = "ap-guangzhou";string action = "DescribeInstances";
string version = "2017-03-12";// The timestamp `2019-02-26 00:44:25` used here is only for reference. In a proj
ect, use the following parameter:// DateTime date = DateTime.UtcNow;// Enter the correct time zone. We recommend using UTC timestamp to avoid errors.
DateTime date = new DateTime(1970, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc).AddSeconds(1551113065);
string requestPayload = "{\"Limit\": 1, \"Filters\": [{\"Values\": [\"\\u672a\\u5
47d\\u540d\"], \"Name\": \"instance-name\"}]}";
Dictionary<string, string> headers = BuildHeaders(SECRET_ID, SECRET_KEY, service, endpoint, region, action, version, date, requestPayload);
Console.WriteLine("POST https://cvm.tencentcloudapi.com");foreach (KeyValuePair<string, string> kv in headers){Console.WriteLine(kv.Key + ": " + kv.Value);}
Console.WriteLine();Console.WriteLine(requestPayload);}}©2013-2022 Tencent Cloud. All rights reserved.

Page 55 of 450

TDMQ for Apache Pulsar

NodeJS
const crypto = require('crypto');function sha256(message, secret = '', encoding) {const hmac = crypto.createHmac('sha256', secret)return hmac.update(message).digest(encoding)}
function getHash(message, encoding = 'hex') {const hash = crypto.createHash('sha256')
return hash.update(message).digest(encoding)}
function getDate(timestamp) {const date = new Date(timestamp * 1000)
const year = date.getUTCFullYear()const month = ('0' + (date.getUTCMonth() + 1)).slice(-2)
const day = ('0' + date.getUTCDate()).slice(-2)
return `${year}-${month}-${day}`}function main(){const SECRET_ID = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"
const SECRET_KEY = "Gu5t9xGARNpq86cd98joQYCN3*******"
const endpoint = "cvm.tencentcloudapi.com"
const service = "cvm"
const region = "ap-guangzhou"
const action = "DescribeInstances"
const version = "2017-03-12"//const timestamp = getTime()
const timestamp = 1551113065
const date = getDate(timestamp)// ************* Step 1: Concatenate the CanonicalRequest string *************
const signedHeaders = "content-type;host"const payload = "{\"Limit\": 1, \"Filters\": [{\"Values\": [\"unnamed\"], \"Name\": \"instance-name\"}]}"
const hashedRequestPayload = getHash(payload);
const httpRequestMethod = "POST"
const canonicalUri = "/"const canonicalQueryString = ""const canonicalHeaders = "content-type:application/json; charset=utf-8\n" + "host:" + endpoint + "\n"const canonicalRequest = httpRequestMethod + "\n"©2013-2022 Tencent Cloud. All rights reserved.

Page 56 of 450

TDMQ for Apache Pulsar+ canonicalUri + "\n"+ canonicalQueryString + "\n"+ canonicalHeaders + "\n"+ signedHeaders + "\n"+ hashedRequestPayload
console.log(canonicalRequest)
console.log("----------------------------")// ************* Step 2: Concatenate the string to sign *************
const algorithm = "TC3-HMAC-SHA256"
const hashedCanonicalRequest = getHash(canonicalRequest);
const credentialScope = date + "/" + service + "/" + "tc3_request"
const stringToSign = algorithm + "\n" +timestamp + "\n" +credentialScope + "\n" +hashedCanonicalRequest
console.log(stringToSign)
console.log("----------------------------")// ************* Step 3: Calculate the signature *************
const kDate = sha256(date, 'TC3' + SECRET_KEY)
const kService = sha256(service, kDate)
const kSigning = sha256('tc3_request', kService)
const signature = sha256(stringToSign, kSigning, 'hex')
console.log(signature)
console.log("----------------------------")// ************* Step 4: Concatenate the Authorization *************
const authorization = algorithm + " " +"Credential=" + SECRET_ID + "/" + credentialScope + ", " +"SignedHeaders=" + signedHeaders + ", " +"Signature=" + signature
console.log(authorization)
console.log("----------------------------")
const Call_Information = 'curl -X POST ' + "https://" + endpoint+ ' -H "Authorization: ' + authorization + '"'+ ' -H "Content-Type: application/json; charset=utf-8"'+ ' -H "Host: ' + endpoint + '"'+ ' -H "X-TC-Action: ' + action + '"'+ ' -H "X-TC-Timestamp: ' + timestamp.toString() + '"'+ ' -H "X-TC-Version: ' + version + '"'+ ' -H "X-TC-Region: ' + region + '"'+ " -d '" + payload + "'"console.log(Call_Information)}main()©2013-2022 Tencent Cloud. All rights reserved.

Page 57 of 450

TDMQ for Apache Pulsar

C++#include <iostream>#include <iomanip>#include <sstream>#include <string>#include <stdio.h>#include <time.h>#include <openssl/sha.h>#include <openssl/hmac.h>using namespace std;
string get_data(int64_t &timestamp){
string utcDate;char buff[20] = {0};// time_t timenow;
struct tm sttime;
sttime = *gmtime(&timestamp);
strftime(buff, sizeof(buff), "%Y-%m-%d", &sttime);
utcDate = string(buff);
return utcDate;}string int2str(int64_t n){
std::stringstream ss;
ss << n;return ss.str();}string sha256Hex(const string &str){
char buf[3];unsigned char hash[SHA256_DIGEST_LENGTH];
SHA256_CTX sha256;
SHA256_Init(&sha256);
SHA256_Update(&sha256, str.c_str(), str.size());
SHA256_Final(hash, &sha256);
std::string NewString = "";for(int i = 0; i < SHA256_DIGEST_LENGTH; i++){snprintf(buf, sizeof(buf), "%02x", hash[i]);NewString = NewString + buf;}
return NewString;©2013-2022 Tencent Cloud. All rights reserved.

Page 58 of 450

TDMQ for Apache Pulsar}
string HmacSha256(const string &key, const string &input){
unsigned char hash[32];
HMAC_CTX *h;#if OPENSSL_VERSION_NUMBER < 0x10100000L
HMAC_CTX hmac;
HMAC_CTX_init(&hmac);h = &hmac;#else
h = HMAC_CTX_new();#endif
HMAC_Init_ex(h, &key[0], key.length(), EVP_sha256(), NULL);
HMAC_Update(h, ( unsigned char* )&input[0], input.length());
unsigned int len = 32;
HMAC_Final(h, hash, &len);#if OPENSSL_VERSION_NUMBER < 0x10100000L
HMAC_CTX_cleanup(h);#else
HMAC_CTX_free(h);#endif
std::stringstream ss;
ss << std::setfill('0');for (int i = 0; i < len; i++){ss << hash[i];}return (ss.str());}
string HexEncode(const string &input){
static const char* const lut = "0123456789abcdef";
size_t len = input.length();string output;
output.reserve(2 * len);for (size_t i = 0; i < len; ++i){
const unsigned char c = input[i];output.push_back(lut[c >> 4]);
output.push_back(lut[c & 15]);}©2013-2022 Tencent Cloud. All rights reserved.

Page 59 of 450

TDMQ for Apache Pulsar

return output;}
int main(){string SECRET_ID = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******";
string SECRET_KEY = "Gu5t9xGARNpq86cd98joQYCN3*******";
string service = "cvm";
string host = "cvm.tencentcloudapi.com";string region = "ap-guangzhou";string action = "DescribeInstances";
string version = "2017-03-12";
int64_t timestamp = 1551113065;
string date = get_data(timestamp);// ************* Step 1: Concatenate the CanonicalRequest string *************
string httpRequestMethod = "POST";
string canonicalUri = "/";
string canonicalQueryString = "";string canonicalHeaders = "content-type:application/json; charset=utf-8\nhost:" +host + "\n";string signedHeaders = "content-type;host";
string payload = "{\"Limit\": 1, \"Filters\": [{\"Values\": [\"unnamed\"], \"Name\": \"instance-name\"}]}";
string hashedRequestPayload = sha256Hex(payload);string canonicalRequest = httpRequestMethod + "\n" + canonicalUri + "\n" + canoni
calQueryString + "\n"+ canonicalHeaders + "\n" + signedHeaders + "\n" + hashedRequestPayload;cout << canonicalRequest << endl;
cout << "-----------------------" << endl;// ************* Step 2: Concatenate the string to sign *************
string algorithm = "TC3-HMAC-SHA256";
string RequestTimestamp = int2str(timestamp);
string credentialScope = date + "/" + service + "/" + "tc3_request";
string hashedCanonicalRequest = sha256Hex(canonicalRequest);
string stringToSign = algorithm + "\n" + RequestTimestamp + "\n" + credentialScop
e + "\n" + hashedCanonicalRequest;
cout << stringToSign << endl;
cout << "-----------------------" << endl;// ************* Step 3: Calculate the signature ***************
string kKey = "TC3" + SECRET_KEY;
string kDate = HmacSha256(kKey, date);
string kService = HmacSha256(kDate, service);
string kSigning = HmacSha256(kService, "tc3_request");©2013-2022 Tencent Cloud. All rights reserved.

Page 60 of 450

TDMQ for Apache Pulsar

string signature = HexEncode(HmacSha256(kSigning, stringToSign));cout << signature << endl;
cout << "-----------------------" << endl;// ************* Step 4: Concatenate the Authorization *************
string authorization = algorithm + " " + "Credential=" + SECRET_ID + "/" + creden
tialScope + ", "+ "SignedHeaders=" + signedHeaders + ", " + "Signature=" + signature;cout << authorization << endl;
cout << "------------------------" << endl;
string headers = "curl -X POST https://" + host + "\n"+ " -H \"Authorization: " + authorization + "\n"+ " -H \"Content-Type: application/json; charset=utf-8\"" + "\n"+ " -H \"Host: " + host + "\n"+ " -H \"X-TC-Action: " + action + "\n"+ " -H \"X-TC-Timestamp: " + RequestTimestamp + "\n"+ " -H \"X-TC-Version: " + version + "\n"+ " -H \"X-TC-Region: " + region + "\n"+ " -d '" + payload;cout << headers << endl;
return 0;};

Signature Failure
The following situational error codes for signature failure may occur. Please resolve the errors accordingly.
Error CodeDescription

AuthFailure.SignatureExpire

Signature expired. Timestamp and server time cannot differ by more than fiveminutes.

AuthFailure.SecretIdNotFoundThe key does not exist. Please go to the console to check whether it isdisabled or you copied fewer or more characters.

AuthFailure.SignatureFailure

Signature error. It is possible that the signature was calculated incorrectly, thesignature does not match the content actually sent, or the SecretKey isincorrect.

AuthFailure.TokenFailure

Temporary certificate token error.

AuthFailure.InvalidSecretId

Invalid key (not a TencentCloud API key type).

©2013-2022 Tencent Cloud. All rights reserved.

Page 61 of 450

TDMQ for Apache Pulsar

Signature：

Last updated 2022-03-18 18:41:26
Tencent Cloud API authenticates each access request, i.e. each request needs to include authentication information(Signature) in the common parameters to verify the identity of the requester.
The Signature is generated by the security credentials which include SecretId and SecretKey. If you don't have thesecurity credentials yet, go to the TencentCloud API Key page to apply for them; otherwise, you cannot invoke theTencentCloud API.

1. Applying for Security Credentials
Before using the TencentCloud API for the first time, go to the TencentCloud API Key page to apply for security
credentials.
Security credentials consist of SecretId and SecretKey:
SecretId is used to identify the API requester.
SecretKey is used to encrypt the signature string and verify it on the server.
You must keep your security credentials private and avoid disclosure.
You can apply for the security credentials through the following steps:
1. Log in to the Tencent Cloud Console.
2. Go to the TencentCloud API Key page.
3. On the API Key Management page, click Create Key to create a SecretId/SecretKey pair.
Note: Each account can have up to two pairs of SecretId/SecretKey.

2. Generating a SignatureWith the SecretId and SecretKey, a signature can be generated. The following describes how to generate a signature:
Assume that the SecretId and SecretKey are:SecretId: AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******
SecretKey: Gu5t9xGARNpq86cd98joQYCN3*******
Note: This is just an example. For actual operations, please use your own SecretId and SecretKey.

©2013-2022 Tencent Cloud. All rights reserved.

Page 62 of 450

TDMQ for Apache Pulsar

Take the Cloud Virtual Machine's request to view the instance list (DescribeInstances) as an example. When you
invoke this API, the request parameters may be as follows:
Parameter
nameDescription

Parameter value

Action

Method name

DescribeInstances

SecretId

Key ID

AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******

Timestamp

Current timestamp

1465185768

Nonce

Random positive integer

11886

RegionRegion where the instance islocatedap-guangzhou

InstanceIds.0

ID of the instance to query

ins-09dx96dg

OffsetOffset0

Limit

Allowed maximum output

20

VersionAPI version number

2017-03-12

2.1. Sorting Parameters
First, sort all the request parameters in an ascending lexicographical order (ASCII code) by their names. Notes: (1)Parameters are sorted by their names instead of their values; (2) The parameters are sorted based on ASCII code, notin an alphabetical order or by values. For example, InstanceIds.2 should be arranged after InstanceIds.12. You cancomplete the sorting process using a sorting function in a programming language, such as the ksort function in PHP.
The parameters in the example are sorted as follows:{'Action' : 'DescribeInstances','InstanceIds.0' : 'ins-09dx96dg','Limit' : 20,'Nonce' : 11886,'Offset' : 0,
'Region' : 'ap-guangzhou','SecretId' : 'AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******','Timestamp' : 1465185768,'Version': '2017-03-12',}©2013-2022 Tencent Cloud. All rights reserved.

Page 63 of 450

TDMQ for Apache Pulsar

When developing in another programming language, you can sort these sample parameters and it will work as long as
you obtain the same results.

2.2. Concatenating a Request String
This step generates a request string.
Format the request parameters sorted in the previous step into the form of "parameter name"="parameter value". For
example, for the Action parameter, its parameter name is "Action" and its parameter value is "DescribeInstances", so it
will become Action=DescribeInstances after formatted.
Note: The "parameter value" is the original value but not the value after URL encoding.
Then, concatenate the formatted parameters with "&". The resulting request string is as follows:

Action=DescribeInstances&InstanceIds.0=ins-09dx96dg&Limit=20&Nonce=11886&Offset=0&Region=ap-guangzhou&SecretId=AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******&Timestamp=1465
185768&Version=2017-03-12

2.3. Concatenating the Signature Original String
This step generates a signature original string.
The signature original string consists of the following parameters:
1. HTTP method: POST and GET modes are supported, and GET is used here for the request. Please note that themethod name should be in all capital letters.
2. Request server: the domain name of the request to view the list of instances (DescribeInstances) is
cvm.tencentcloudapi.com. The actual request domain name varies by the module to which the API belongs. For
more information, see the instructions of the specific API.
3. Request path: The request path in the current version of TencentCloud API is fixed to /.
4. Request string: the request string generated in the previous step.
The concatenation rule of the signature original string is: Request method + request host + request path + ? + request
string
The concatenation result of the example is:

GETcvm.tencentcloudapi.com/?Action=DescribeInstances&InstanceIds.0=ins-09dx96dg&L
imit=20&Nonce=11886&Offset=0&Region=ap-guangzhou&SecretId=AKIDz8krbsJ5yKBZQpn74WF
kmLPx3*******&Timestamp=1465185768&Version=2017-03-12

2.4. Generating a Signature String
This step generates a signature string.
First, use the HMAC-SHA1 algorithm to sign the signature original string obtained in the previous step, and then©2013-2022 Tencent Cloud. All rights reserved.

Page 64 of 450

TDMQ for Apache Pulsar

encode the generated signature using Base64 to obtain the final signature.
The specific code is as follows with the PHP language being used as an example:$secretKey = 'Gu5t9xGARNpq86cd98joQYCN3*******';$srcStr = 'GETcvm.tencentcloudapi.com/?Action=DescribeInstances&InstanceIds.0=ins-09dx96dg&Limit=20&Nonce=11886&Offset=0&Region=ap-guangzhou&SecretId=AKIDz8krbsJ5
yKBZQpn74WFkmLPx3*******&Timestamp=1465185768&Version=2017-03-12';$signStr = base64_encode(hash_hmac('sha1', $srcStr, $secretKey, true));echo $signStr;
The final signature is:zmmjn35mikh6pM3V7sUEuX4wyYM=
When developing in another programming language, you can sign and verify the original in the example above and it
works as long as you get the same results.

3. Encoding a Signature String
The generated signature string cannot be directly used as a request parameter and must be URL encoded.
For example, if the signature string generated in the previous step is zmmjn35mikh6pM3V7sUEuX4wyYM=, the final
signature string request parameter (Signature) is zmmjn35mikh6pM3V7sUEuX4wyYM%3D, which will be used togenerate the final request URL.
Note: If your request method is GET, or the request method is POST and the Content-Type isapplication/x-www-form-urlencoded, then all the request parameter values need to be URL encoded(except the parameter key and the symbol of =) when sending the request. Non-ASCII characters need to
be encoded with UTF-8 before URL encoding.
Note: The network libraries of some programming languages automatically URL encode all parameters, inwhich case there is no need to URL encode the signature string; otherwise, two rounds of URL encoding
will cause the signature to fail.
Note: Other parameter values also need to be encoded using RFC 3986. Use %XY in percent-encoding forspecial characters such as Chinese characters, where "X" and "Y" are hexadecimal characters (0-9 anduppercase A-F), and using lowercase will cause an error.

4. Signature Failure©2013-2022 Tencent Cloud. All rights reserved.

Page 65 of 450

TDMQ for Apache Pulsar

The following situational error codes for signature failure may occur. Please resolve the errors accordingly.
Error code

Error description

AuthFailure.SignatureExpire

The signature is expired

AuthFailure.SecretIdNotFoundThe key does not exist

AuthFailure.SignatureFailure

Signature error

AuthFailure.TokenFailure

Token error

AuthFailure.InvalidSecretId

Invalid key (not a TencentCloud API key type)

5. Signature Demo
When calling API 3.0, you are recommended to use the corresponding Tencent Cloud SDK 3.0 which encapsulates
the signature process, enabling you to focus on only the specific APIs provided by the product when developing. See
SDK Center for more information. Currently, the following programming languages are supported:
PythonJava
PHP
Go
NodeJS.NET
To further explain the signing process, we will use a programming language to implement the process describedabove. The request domain name, API and parameter values in the sample are used here. This goal of this example isonly to provide additional clarification for the signature process, please see the SDK for actual usage.
The final output URL might be: https://cvm.tencentcloudapi.com/?
Action=DescribeInstances&InstanceIds.0=ins09dx96dg&Limit=20&Nonce=11886&Offset=0&Region=apguangzhou&SecretId=AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******&Signature=zmmjn35mikh6pM3V7s
UEuX4wyYM%3D&Timestamp=1465185768&Version=2017-03-12 .
Note: The key in the example is fictitious, and the timestamp is not the current time of the system, so if this URL is
opened in the browser or called using commands such as curl, an authentication error will be returned: Signature
expired. In order to get a URL that can work properly, you need to replace the SecretId and SecretKey in the example
with your real credentials and use the current time of the system as the Timestamp.

©2013-2022 Tencent Cloud. All rights reserved.

Page 66 of 450

TDMQ for Apache Pulsar

Note: In the example below, even if you use the same programming language, the order of the parameters in the URL
may be different for each execution. However, the order does not matter, as long as all the parameters are included in
the URL and the signature is calculated correctly.
Note: The following code is only applicable to API 3.0. It cannot be directly used in other signature processes. Even
with an older API, signature calculation errors may occur due to the differences in details. Please refer to thecorresponding documentation.

Java
import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;import java.util.Random;
import java.util.TreeMap;
import javax.crypto.Mac;
import javax.crypto.spec.SecretKeySpec;
import javax.xml.bind.DatatypeConverter;
public class TencentCloudAPIDemo {private final static String CHARSET = "UTF-8";
public static String sign(String s, String key, String method) throws Exception {Mac mac = Mac.getInstance(method);
SecretKeySpec secretKeySpec = new SecretKeySpec(key.getBytes(CHARSET), mac.getAlg
orithm());
mac.init(secretKeySpec);
byte[] hash = mac.doFinal(s.getBytes(CHARSET));
return DatatypeConverter.printBase64Binary(hash);}public static String getStringToSign(TreeMap<String, Object> params) {StringBuilder s2s = new StringBuilder("GETcvm.tencentcloudapi.com/?");// When signing, the parameters need to be sorted in lexicographical order. TreeM
ap is used here to guarantee the correct order.
for (String k : params.keySet()) {s2s.append(k).append("=").append(params.get(k).toString()).append("&");}
return s2s.toString().substring(0, s2s.length() - 1);}
public static String getUrl(TreeMap<String, Object> params) throws UnsupportedEnc
odingException {StringBuilder url = new StringBuilder("https://cvm.tencentcloudapi.com/?");// There is no requirement for the order of the parameters in the actual request
URL.
for (String k : params.keySet()) {// The request string needs to be URL encoded. As the Key is all in English letters, only the value is URL encoded here.
url.append(k).append("=").append(URLEncoder.encode(params.get(k).toString(), CHAR
SET)).append("&");©2013-2022 Tencent Cloud. All rights reserved.

Page 67 of 450

TDMQ for Apache Pulsar}
return url.toString().substring(0, url.length() - 1);}
public static void main(String[] args) throws Exception {TreeMap<String, Object> params = new TreeMap<String, Object>(); // TreeMap enable
s automatic sorting// A random number should be used when actually calling, for example: params.put("Nonce", new Random().nextInt(java.lang.Integer.MAX_VALUE));params.put("Nonce", 11886); // Common parameter// The current time of the system should be used when actually calling, for examp
le: params.put("Timestamp", System.currentTimeMillis() / 1000);params.put("Timestamp", 1465185768); // Common parameterparams.put("SecretId", "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"); // Common parameterparams.put("Action", "DescribeInstances"); // Common parameterparams.put("Version", "2017-03-12"); // Common parameterparams.put("Region", "ap-guangzhou"); // Common parameterparams.put("Limit", 20); // Business parameterparams.put("Offset", 0); // Business parameterparams.put("InstanceIds.0", "ins-09dx96dg"); // Business parameterparams.put("Signature", sign(getStringToSign(params), "Gu5t9xGARNpq86cd98joQYCN3*******", "HmacSHA1")); // Common parameter
System.out.println(getUrl(params));}}

PythonNote: If running in a Python 2 environment, the following requests dependency package must be installed first: pip
install requests .

# -*- coding: utf8 -*import base64
import hashlib
import hmac
import time
import requests
secret_id = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"
secret_key = "Gu5t9xGARNpq86cd98joQYCN3*******"
def get_string_to_sign(method, endpoint, params):
s = method + endpoint + "/?"
query_str = "&".join("%s=%s" % (k, params[k]) for k in sorted(params))
return s + query_str
def sign_str(key, s, method):
hmac_str = hmac.new(key.encode("utf8"), s.encode("utf8"), method).digest()
return base64.b64encode(hmac_str)©2013-2022 Tencent Cloud. All rights reserved.

Page 68 of 450

TDMQ for Apache Pulsar

if __name__ == '__main__':endpoint = "cvm.tencentcloudapi.com"
data = {'Action' : 'DescribeInstances','InstanceIds.0' : 'ins-09dx96dg','Limit' : 20,'Nonce' : 11886,'Offset' : 0,
'Region' : 'ap-guangzhou','SecretId' : secret_id,'Timestamp' : 1465185768, # int(time.time())'Version': '2017-03-12'}
s = get_string_to_sign("GET", endpoint, data)
data["Signature"] = sign_str(secret_key, s, hashlib.sha1)
print(data["Signature"])# An actual invocation would occur here, which may incur fees after success# resp = requests.get("https://" + endpoint, params=data)# print(resp.url)

Golangpackage main
import ("bytes""crypto/hmac""crypto/sha1""encoding/base64""fmt""sort")
func main() {secretId := "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"
secretKey := "Gu5t9xGARNpq86cd98joQYCN3*******"
params := map[string]string{"Nonce": "11886","Timestamp": "1465185768","Region": "ap-guangzhou","SecretId": secretId,"Version": "2017-03-12","Action": "DescribeInstances","InstanceIds.0": "ins-09dx96dg","Limit": "20","Offset": "0",}var buf bytes.Buffer©2013-2022 Tencent Cloud. All rights reserved.

Page 69 of 450

TDMQ for Apache Pulsar

buf.WriteString("GET")
buf.WriteString("cvm.tencentcloudapi.com")buf.WriteString("/")
buf.WriteString("?")// sort keys by ascii asc orderkeys := make([]string, 0, len(params))
for k, _ := range params {keys = append(keys, k)}sort.Strings(keys)
for i := range keys {k := keys[i]buf.WriteString(k)buf.WriteString("=")
buf.WriteString(params[k])buf.WriteString("&")}
buf.Truncate(buf.Len() - 1)hashed := hmac.New(sha1.New, []byte(secretKey))hashed.Write(buf.Bytes())
fmt.Println(base64.StdEncoding.EncodeToString(hashed.Sum(nil)))
}

PHP
<?php
$secretId = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******";$secretKey = "Gu5t9xGARNpq86cd98joQYCN3*******";$param["Nonce"] = 11886;//rand();$param["Timestamp"] = 1465185768;//time();$param["Region"] = "ap-guangzhou";$param["SecretId"] = $secretId;$param["Version"] = "2017-03-12";$param["Action"] = "DescribeInstances";$param["InstanceIds.0"] = "ins-09dx96dg";$param["Limit"] = 20;$param["Offset"] = 0;
ksort($param);$signStr = "GETcvm.tencentcloudapi.com/?";foreach ( $param as $key => $value ) {$signStr = $signStr . $key . "=" . $value . "&";}
$signStr = substr($signStr, 0, -1);
$signature = base64_encode(hash_hmac("sha1", $signStr, $secretKey, true));echo $signature.PHP_EOL;// need to install and enable curl extension in php.ini©2013-2022 Tencent Cloud. All rights reserved.

Page 70 of 450

TDMQ for Apache Pulsar// $param["Signature"] = $signature;// $url = "https://cvm.tencentcloudapi.com/?".http_build_query($param);// echo $url.PHP_EOL;// $ch = curl_init();// curl_setopt($ch, CURLOPT_URL, $url);// $output = curl_exec($ch);// curl_close($ch);// echo json_decode($output);Ruby# -*- coding: UTF-8 -*# require ruby>=2.3.0
require 'time'require 'openssl'
require 'base64'
secret_id = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"
secret_key = "Gu5t9xGARNpq86cd98joQYCN3*******"
method = 'GET'
endpoint = 'cvm.tencentcloudapi.com'
data = {'Action' => 'DescribeInstances','InstanceIds.0' => 'ins-09dx96dg','Limit' => 20,'Nonce' => 11886,'Offset' => 0,'Region' => 'ap-guangzhou','SecretId' => secret_id,'Timestamp' => 1465185768, # Time.now.to_i'Version' => '2017-03-12',}
sign = method + endpoint + '/?'
params = []data.sort.each do |item|
params << "#{item[0]}=#{item[1]}"endsign += params.join('&')
digest = OpenSSL::Digest.new('sha1')
data['Signature'] = Base64.encode64(OpenSSL::HMAC.digest(digest, secret_key, sign))puts data['Signature']# require 'net/http'# uri = URI('https://' + endpoint)# uri.query = URI.encode_www_form(data)# p uri©2013-2022 Tencent Cloud. All rights reserved.

Page 71 of 450

TDMQ for Apache Pulsar# res = Net::HTTP.get_response(uri)# puts res.body

DotNetusing System;
using System.Collections.Generic;using System.Net;
using System.Security.Cryptography;
using System.Text;
public class Application {public static string Sign(string signKey, string secret){string signRet = string.Empty;
using (HMACSHA1 mac = new HMACSHA1(Encoding.UTF8.GetBytes(signKey))){byte[] hash = mac.ComputeHash(Encoding.UTF8.GetBytes(secret));signRet = Convert.ToBase64String(hash);}return signRet;}
public static string MakeSignPlainText(SortedDictionary<string, string> requestParams, string requestMethod, string requestHost, string requestPath){string retStr = "";retStr += requestMethod;
retStr += requestHost;
retStr += requestPath;
retStr += "?";
string v = "";foreach (string key in requestParams.Keys){v += string.Format("{0}={1}&", key, requestParams[key]);}
retStr += v.TrimEnd('&');
return retStr;}
public static void Main(string[] args){
string SECRET_ID = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******";
string SECRET_KEY = "Gu5t9xGARNpq86cd98joQYCN3*******";
string endpoint = "cvm.tencentcloudapi.com";string region = "ap-guangzhou";string action = "DescribeInstances";
string version = "2017-03-12";
double RequestTimestamp = 1465185768;©2013-2022 Tencent Cloud. All rights reserved.

Page 72 of 450

TDMQ for Apache Pulsar// long timestamp = ToTimestamp() / 1000;// string requestTimestamp = timestamp.ToString();
Dictionary<string, string> param = new Dictionary<string, string>();param.Add("Limit", "20");param.Add("Offset", "0");param.Add("InstanceIds.0", "ins-09dx96dg");
param.Add("Action", action);param.Add("Nonce", "11886");// param.Add("Nonce", Math.Abs(new Random().Next()).ToString());
param.Add("Timestamp", RequestTimestamp.ToString());
param.Add("Version", version);param.Add("SecretId", SECRET_ID);
param.Add("Region", region);
SortedDictionary<string, string> headers = new SortedDictionary<string, string>(param, StringComparer.Ordinal);
string sigInParam = MakeSignPlainText(headers, "GET", endpoint, "/");
Console.WriteLine(sigInParam);
string sigOutParam = Sign(SECRET_KEY, sigInParam);
Console.WriteLine("GET https://cvm.tencentcloudapi.com");foreach (KeyValuePair<string, string> kv in headers){Console.WriteLine(kv.Key + ": " + kv.Value);}
Console.WriteLine("Signature" + ": " + WebUtility.UrlEncode(sigOutParam));
Console.WriteLine();string result = "https://cvm.tencentcloudapi.com/?";foreach (KeyValuePair<string, string> kv in headers){
result += WebUtility.UrlEncode(kv.Key) + "=" + WebUtility.UrlEncode(kv.Value) +"&";}result += WebUtility.UrlEncode("Signature") + "=" + WebUtility.UrlEncode(sigOutPa
ram);
Console.WriteLine("GET " + result);}}

NodeJS
const crypto = require('crypto');function get_req_url(params, endpoint){
params['Signature'] = escape(params['Signature']);const url_strParam = sort_params(params)
return "https://" + endpoint + "/?" + url_strParam.slice(1);}function formatSignString(reqMethod, endpoint, path, strParam){©2013-2022 Tencent Cloud. All rights reserved.

Page 73 of 450

TDMQ for Apache Pulsar

let strSign = reqMethod + endpoint + path + "?" + strParam.slice(1);return strSign;}function sha1(secretKey, strsign){
let signMethodMap = {'HmacSHA1': "sha1"};
let hmac = crypto.createHmac(signMethodMap['HmacSHA1'], secretKey || "");
return hmac.update(Buffer.from(strsign, 'utf8')).digest('base64')}function sort_params(params){
let strParam = "";let keys = Object.keys(params);
keys.sort();for (let k in keys) {//k = k.replace(/_/g, '.');
strParam += ("&" + keys[k] + "=" + params[keys[k]]);}return strParam}function main(){const SECRET_ID = "AKIDz8krbsJ5yKBZQpn74WFkmLPx3*******"
const SECRET_KEY = "Gu5t9xGARNpq86cd98joQYCN3*******"
const endpoint = "cvm.tencentcloudapi.com"
const Region = "ap-guangzhou"
const Version = "2017-03-12"
const Action = "DescribeInstances"
const Timestamp = 1465185768// const Timestamp = Math.round(Date.now() / 1000)
const Nonce = 11886//const nonce = Math.round(Math.random() * 65535)
let params = {};params['Action'] = Action;
params['InstanceIds.0'] = 'ins-09dx96dg';
params['Limit'] = 20;
params['Offset'] = 0;params['Nonce'] = Nonce;params['Region'] = Region;
params['SecretId'] = SECRET_ID;
params['Timestamp'] = Timestamp;
params['Version'] = Version;
strParam = sort_params(params)
const reqMethod = "GET";
const path = "/";
strSign = formatSignString(reqMethod, endpoint, path, strParam)
console.log(strSign)
console.log("-----------------------")
params['Signature'] = sha1(SECRET_KEY, strSign)
console.log(params['Signature'])©2013-2022 Tencent Cloud. All rights reserved.

Page 74 of 450

TDMQ for Apache Pulsar

console.log("-----------------------")
const req_url = get_req_url(params, endpoint)
console.log(params['Signature'])console.log("-----------------------")
console.log(req_url)}
main()©2013-2022 Tencent Cloud. All rights reserved.

Page 75 of 450

TDMQ for Apache Pulsar

Responses：

Last updated 2022-02-11 10:11:44

Response for Successful Requests
For example, when calling CAM API (version: 2017-03-12) to view the status of instances (DescribeInstancesStatus),
if the request has succeeded, you may see the response as shown below:{"Response": {"TotalCount": 0,"InstanceStatusSet": [],"RequestId": "b5b41468-520d-4192-b42f-595cc34b6c1c"}}
The API will return Response , which contains RequestId , as long as it processes the request. It does notmatter if the request is successful or not.
RequestId is the unique ID of an API request. Contact us with this ID when an exception occurs.
Except for the fixed fields, all fields are action-specified. For the definitions of action-specified fields, see thecorresponding API documentation. In this example, TotalCount and InstanceStatusSet are the fields
specified by the API DescribeInstancesStatus . 0 TotalCount means that the requester owns 0 CVM
instance so the InstanceStatusSet is empty.

Response for Failed Requests
If the request has failed, you may see the response as shown below:{"Response": {"Error": {"Code": "AuthFailure.SignatureFailure","Message": "The provided credentials could not be validated. Please ensure your signature is correct."},"RequestId": "ed93f3cb-f35e-473f-b9f3-0d451b8b79c6"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 76 of 450

TDMQ for Apache Pulsar

The presence of the Error field indicates that the request has failed. A response for a failed request will include
Error , Code and Message fields.
Code is the code of the error that helps you identify the cause and solution. There are two types of error codes
so you may find the code in either common error codes or API-specified error codes.
Message explains the cause of the error. Note that the returned messages are subject to service updates. The
information the messages provide may not be up-to-date and should not be the only source of reference.
RequestId is the unique ID of an API request. Contact us with this ID when an exception occurs.

Common Error Codes
If there is an Error field in the response, it means that the API call failed. The Code field in Error indicates the error
code. The following table lists the common error codes that all actions can return.
Error CodeDescription

AuthFailure.InvalidSecretId

Invalid key (not a TencentCloud API key type).

AuthFailure.MFAFailure

MFA failed.

AuthFailure.SecretIdNotFoundThe key does not exist.

AuthFailure.SignatureExpire

Signature expired.

AuthFailure.SignatureFailure

Signature error.

AuthFailure.TokenFailure

Token error.

AuthFailure.UnauthorizedOperation

The request does not have CAM authorization.

DryRunOperation

DryRun Operation. It means that the request would have succeeded, but
the DryRun parameter was used.

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidAction

The API does not exist.

InvalidParameter

Incorrect parameter.

InvalidParameterValue

Invalid parameter value.

LimitExceeded

Quota limit exceeded.

MissingParameter

A parameter is missing.

©2013-2022 Tencent Cloud. All rights reserved.

Page 77 of 450

TDMQ for Apache Pulsar

NoSuchVersion

The API version does not exist.

RequestLimitExceeded

The number of requests exceeds the frequency limit.

ResourceInUse

Resource is in use.

ResourceInsufficientInsufficient resource.

ResourceNotFoundThe resource does not exist.

ResourceUnavailable

Resource is unavailable.

UnauthorizedOperation

Unauthorized operation.

UnknownParameter

Unknown parameter.

UnsupportedOperation

Unsupported operation.

UnsupportedProtocol

HTTPS request method error. Only GET and POST requests aresupported.

UnsupportedRegion

API does not support the requested region.

©2013-2022 Tencent Cloud. All rights reserved.

Page 78 of 450

TDMQ for Apache Pulsar

Cluster APIs
DescribePulsarProInstanceDetail：

Last updated 2023-08-09 14:43:31

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to obtain the information of a TDMQ for Pulsar pro cluster instance.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribePulsarProInstanceDetail.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

3. Output Parameters
Parameter Name

Type©2013-2022 Tencent Cloud. All rights reserved.

Description

Page 79 of 450

TDMQ for Apache Pulsar

ClusterInfo

NetworkAccessPointInfos

ClusterSpecInfo

PulsarProClusterInfo
Array of
PulsarNetworkAccessPointInfo

PulsarProClusterSpecInfo

Cluster information
Cluster network access point information
Note: This field may return null, indicating thatno valid values can be obtained.
Cluster specification information
Note: This field may return null, indicating thatno valid values can be obtained.

RequestId

String

The unique request ID, which is returned foreach request. RequestId is required forlocating a problem.

4. Example
Example1 Obtaining the details of TDMQ for Pulsar pro cluster instances
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribePulsarProInstanceDetail<Common request parameters>{"ClusterId": "pulsar-test"}

Output Example{"Response": {"ClusterSpecInfo": {"MaxTopics": 1,"MaxNamespaces": 1,"SpecName": "xx","MaxBandWidth": 1,"ScalableTps": 1,"MaxTps": 1},"NetworkAccessPointInfos": [{©2013-2022 Tencent Cloud. All rights reserved.

Page 80 of 450

TDMQ for Apache Pulsar"SubnetId": "xx","InstanceId": "xx","Endpoint": "xx","VpcId": "xx","RouteType": 1}],"ClusterInfo": {"Status": 0,"Remark": "xx","NodeDistribution": [{"NodeCount": 1,"ZoneId": "xx","ZoneName": "xx"}],"ClusterName": "xx","ClusterId": "xx","MaxStorage": 1,"Version": "xx","CreateTime": "xx"},"RequestId": "xx"}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface©2013-2022 Tencent Cloud. All rights reserved.

Page 81 of 450

TDMQ for Apache Pulsar

Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 82 of 450

TDMQ for Apache Pulsar

DescribePulsarProInstances：

Last updated 2023-08-09 14:43:31

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of the purchased TDMQ for Pulsar pro instances.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribePulsarProInstances.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Filters.N

No

Array ofFilter

Query condition filter

Limit

No

Integer

The maximum number of queried items, which defaults to 20 .

OffsetNo

IntegerStart offset for query

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 83 of 450

TDMQ for Apache Pulsar

Parameter
Name

Type

Description

TotalCount

Integer

The total number of unpaginated items

Instances

Array of
PulsarProInstance

Instance information list

RequestId

String

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Obtaining the instance list
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribePulsarProInstances<Common request parameters>{"Limit": 1,"Filters": [{"Values": ["xx"],"Name": "xx"}],"Offset": 1}

Output Example{"Response": {"TotalCount": 1,"RequestId": "xx","Instances": [{©2013-2022 Tencent Cloud. All rights reserved.

Page 84 of 450

TDMQ for Apache Pulsar"Status": 1,"PayMode": 1,"Remark": "xx","VpcId": "xx","AutoRenewFlag": 1,"InstanceId": "xx","ScalableTps": 1,"ExpireTime": 1,"InstanceVersion": "xx","MaxStorage": 1,"SpecName": "xx","ConfigDisplay": "xx","SubnetId": "xx","InstanceName": "xx","MaxTps": 1}]}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code©2013-2022 Tencent Cloud. All rights reserved.

Page 85 of 450

TDMQ for Apache Pulsar

There is no error code related to the API business logic. For other error codes, please see Common Error Codes.

©2013-2022 Tencent Cloud. All rights reserved.

Page 86 of 450

TDMQ for Apache Pulsar

DescribeRabbitMQVirtualHostList：

Last updated 2023-08-09 14:43:31

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of TDMQ for RabbitMQ exclusive vhosts.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeRabbitMQVirtualHostList.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringA default parameter that won’t be used

OffsetNo

Integer

OffsetLimit

No

Integer

The maximum number of entries per page

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 87 of 450

TDMQ for Apache Pulsar

Parameter
Name

Type

Description

TotalCount

Integer

The number of clusters

VirtualHostList

Array ofRabbitMQPrivateVirtualHost

Cluster list
Note: u200dThis field may return null, indicating that no valid
values can be obtained.

RequestId

String

The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 Obtaining the vhost list
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRabbitMQVirtualHostList<Common request parameters>{"InstanceId": "amqp-testtesttest","Limit": 1,"Offset": 1}

Output Example{"Response": {"TotalCount": 1,"RequestId": "xx","VirtualHostList": [{"VirtualHostName": "xx","Description": "xx"}]}}©2013-2022 Tencent Cloud. All rights reserved.

Page 88 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 89 of 450

TDMQ for Apache Pulsar

DescribeRabbitMQNodeList：

Last updated 2023-04-18 14:53:13

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of TDMQ for RabbitMQ exclusive cluster nodes.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeRabbitMQNodeList.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

String

TDMQ for RabbitMQ cluster ID

OffsetNo

Integer

OffsetLimit

No

Integer

The maximum entries per page

NodeName

No

StringNode name for fuzzy search

Filters.N

No

Array ofFilterName and value of a filter.
Currently, only the nodeStatus filter is supported.

©2013-2022 Tencent Cloud. All rights reserved.

Page 90 of 450

TDMQ for Apache Pulsar

Valid values: running , down .
It is an array type and can contain multiple filters.
SortElement

No

StringSortOrder

No

String

Sorting by a specified element.
Valid values: cpuUsage , diskUsage .
Sorting order.
Valid values: ascend , descend .

3. Output Parameters
Parameter
Name

Type

Description

TotalCount

Integer

The number of clusters

NodeList

Array ofRabbitMQPrivateNode

Cluster list
Note: This field may return null, indicating that no valid value can beobtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId
is required for locating a problem.

4. Example
Example1 Querying the list of TDMQ for RabbitMQ exclusive cluster nodesThis example shows you how to query the list of TDMQ for RabbitMQ exclusive cluster nodes.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRabbitMQNodeList<Common request parameters>{"InstanceId": "amqp-testtesttest","Limit": 1,"Offset": 1}©2013-2022 Tencent Cloud. All rights reserved.

Page 91 of 450

TDMQ for Apache Pulsar

Output Example{"Response": {"TotalCount": 1,"RequestId": "xx","NodeList": [{"NodeName": "xx"}]}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

©2013-2022 Tencent Cloud. All rights reserved.

Page 92 of 450

TDMQ for Apache Pulsar

ResourceNotFound.Cluster©2013-2022 Tencent Cloud. All rights reserved.

The cluster does not exist.

Page 93 of 450

TDMQ for Apache Pulsar

DescribeClusters：

Last updated 2023-08-09 14:43:32

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of clusters.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DescribeClusters.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

OffsetNo

IntegerStart offset, which defaults to 0 if left empty.

Limit

No

Integer

ClusterIdList.N

No

IsTagFilter

No

Filters.N

No

Name

Array of
StringBooleanArray ofFilter©2013-2022 Tencent Cloud. All rights reserved.

The number of results to be returned, which defaults to 10 if left
empty. The maximum value is 20.
Filter by cluster ID.
Whether to filter by tag.
Filter. Currently, you can filter by tag.

Page 94 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name

Type

Description

TotalCount

Integer

The number of clusters.

ClusterSet

Array ofCluster

Cluster information list

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Getting the cluster list
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeClusters&<Common request parameters>

Output Example{"Response": {"TotalCount": 1,"ClusterSet": [{"MaxQps": 10000,"HealthyInfo": "xx","MaxTopicNum": 1000,"MaxStorageCapacity": 100,
"MaxMessageDelayInSeconds": 0,"Version": "xx","Status": 1,"Tags": [{"TagKey": "xx","TagValue": "xx"}],"ClusterId": "xx",©2013-2022 Tencent Cloud. All rights reserved.

Page 95 of 450

TDMQ for Apache Pulsar"PayMode": 0,"EndPointNum": 0,"Healthy": 1,"TopicNum": 0,"Remark": "xx","NamespaceNum": 0,"PublicEndPoint": "xx","MaxPublishRateInBytes": 0,"VpcEndPoint": "xx","MaxDispatchRateInBytes": 0,"PublicAccessEnabled": true,"ClusterName": "xx","MaxPublishRateInMessages": 0,"UsedStorageBudget": 0,"MessageRetentionTime": 86400,"MaxNamespaceNum": 10,"CreateTime": "xx","MaxDispatchRateInMessages": 0}],"RequestId": "xx"}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 96 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 97 of 450

TDMQ for Apache Pulsar

DescribeClusterDetail：

Last updated 2023-08-09 14:43:32

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the details of a cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeClusterDetail.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

Name

3. Output Parameters
Parameter
Name
ClusterSet

Type

Description

Cluster

Cluster details©2013-2022 Tencent Cloud. All rights reserved.

Page 98 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Getting cluster details
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeClusterDetail&ClusterId=pulsar-xxxxxxxx&<Common request parameters>

Output Example{"Response": {"ClusterSet": {"ClusterId": "pulsar-xxxxxxxx","ClusterName": "sdfsdfsdf","Remark": "","EndPointNum": 0,"CreateTime": "2021-01-13 15:43:29","Healthy": 1,"HealthyInfo": "","Status": 1,"MaxNamespaceNum": 50,"MaxTopicNum": 1000,"MaxQps": 10000,"MessageRetentionTime": 86400,"VpcEndPoint": "xx","NamespaceNum": 0,"Version": "xx","PublicEndPoint": "xx","MaxStorageCapacity": 100},"RequestId": "020eb354-144e-4cf8-9607-c6771cd24421"}}

5. Developer Resources©2013-2022 Tencent Cloud. All rights reserved.

Page 99 of 450

TDMQ for Apache Pulsar

SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 100 of 450

TDMQ for Apache Pulsar

DeleteCluster：

Last updated 2023-08-09 14:43:32

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DeleteCluster.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringID of the cluster to be deleted.

3. Output Parameters
Parameter

Type

Description

ClusterId

StringCluster ID

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forName©2013-2022 Tencent Cloud. All rights reserved.

Page 101 of 450

TDMQ for Apache Pulsar

locating a problem.

4. Example
Example1 Deleting cluster
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteCluster&ClusterId=pulsar-xxxxxxxx&<Common request parameters>

Output Example{"Response": {"ClusterId": "pulsar-5r59xd4vnx","RequestId": "0f368d07-3648-4546-9c51-65dad19a3234"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 102 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.DeleteCluster

Failed to delete the cluster.

FailedOperation.NamespaceInUse

You must clear the associated namespace before proceeding.

FailedOperation.RoleInUse

You must clear the associated role data before proceeding.

FailedOperation.VpcInUse

You must clear the associated VPC routing data before proceeding.

OperationDenied.DefaultEnvironment

Operations on the default environment are not allowed.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 103 of 450

TDMQ for Apache Pulsar

ModifyCluster：

Last updated 2023-08-09 14:43:31

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to update a cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringRegionNo

StringClusterId

YesStringID of the Pulsar cluster to be updated.

ClusterName

No

StringUpdated cluster name.

RemarkNo

StringRemarks.

PublicAccessEnabled

No

BooleanEnables public network access, which can only be true .

Common Params. The value used for this API:
ModifyCluster.
Common Params. The value used for this API: 2020-02-17.
Common Params. This parameter is not required for thisAPI.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 104 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

ClusterId

StringPulsar cluster ID

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Updating cluster
Input Example
https://tdmq.tencentcloudapi.com/?Action=ModifyCluster&ClusterId=pulsar-xxxxxxxx&Remark=test&<Common request parameters>

Output Example{"Response": {"ClusterId": "pulsar-5r59xd4vnx","RequestId": "b84bf1d8-2794-4c20-a50f-02b7a4698814"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS©2013-2022 Tencent Cloud. All rights reserved.

Page 105 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InvalidParameterValue.ClusterNameDuplication

The cluster name already exists.

MissingParameter

Missing parameter.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 106 of 450

TDMQ for Apache Pulsar

DescribeBindClusters：

Last updated 2023-08-09 14:43:32

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of dedicated clusters bound to a user.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeBindClusters.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

3. Output Parameters
Parameter
Name

Type

Description

TotalCount

Integer

The number of dedicated clusters

ClusterSet

Array of

List of dedicated clusters©2013-2022 Tencent Cloud. All rights reserved.

Page 107 of 450

TDMQ for Apache Pulsar

BindCluster
RequestId

String

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Getting the list of dedicated clusters
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeBindClusters&<Common request parameters>

Output Example{"Response": {"TotalCount": 1,"ClusterSet": [{"ClusterName": "xxx"}],"RequestId": "32a34a4c-58a8-445f-80ff-7152399b18f7"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS©2013-2022 Tencent Cloud. All rights reserved.

Page 108 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceUnavailable

The resource is unavailable.

ResourceUnavailable.SystemUpgrade

The system is being upgraded.

ResourcesSoldOut

The resources have been sold out.

UnauthorizedOperation

Unauthorized operation.

UnknownParameter

Unknown parameter error.

UnsupportedOperation

Unsupported operation.

©2013-2022 Tencent Cloud. All rights reserved.

Page 109 of 450

TDMQ for Apache Pulsar

CreateCluster：

Last updated 2023-08-09 14:43:32

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringRegionNo

StringClusterName

Yes

String

BindClusterId

No

Integer

Description
Common Params. The value used for this API:
CreateCluster.
Common Params. The value used for this API: 2020-02-17.
Common Params. This parameter is not required for thisAPI.
Cluster name, which can contain up to 16 letters, digits,
hyphens, and underscores.
ID of your dedicated physical cluster. If it is not passed in,cluster resources will be created in a public cluster by
default.

RemarkNo

Tags.NNo

StringArray ofTag

©2013-2022 Tencent Cloud. All rights reserved.

Remarks (up to 128 characters).
Cluster tag list (deprecated).

Page 110 of 450

TDMQ for Apache Pulsar

PublicAccessEnabled

No

BooleanWhether to enable public network access. If this parameteris left empty, the feature will be enabled by default

3. Output Parameters
Parameter

Type

Description

ClusterId

StringCluster ID

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating cluster
Input Example
https://tdmq.tencentcloudapi.com/?Action=CreateCluster&ClusterName=test&<Common request parameters>

Output Example{"Response": {"ClusterId": "pulsar-5r59xd4vnx","RequestId": "c1e66353-c87b-4a30-804d-94c6c2c8bac5"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to callAPIs.

©2013-2022 Tencent Cloud. All rights reserved.

Page 111 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.CreateCluster

Failed to create the cluster.

InternalError.SystemError

System error.

LimitExceeded.Clusters

The number of clusters under the instance exceeds the limit.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceInUse.Cluster

The cluster already exists.

ResourceUnavailable

The resource is unavailable.

ResourceUnavailable.CreateFailed

Assignment exception.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 112 of 450

TDMQ for Apache Pulsar

Namespace APIs
ModifyEnvironmentAttributes：

Last updated 2023-08-09 14:43:27

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify the attributes of the specified namespace.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringRegionNo

StringCommon Params. This parameter is not required
for this API.

EnvironmentId

Yes

StringNamespace name.

MsgTTLYes

Integer

Retention period for unconsumed messages inseconds. Value range: 60s to 1,296,000s (or 15

Common Params. The value used for this API:
ModifyEnvironmentAttributes.
Common Params. The value used for this API:
2020-02-17.

days).
RemarkNo©2013-2022 Tencent Cloud. All rights reserved.

StringRemarks (up to 128 characters).

Page 113 of 450

TDMQ for Apache Pulsar

ClusterId

No

StringCluster ID

RetentionPolicy

No

RetentionPolicy

Message retention policy

AutoSubscriptionCreation

No

BooleanWhether to enable "Auto-Create Subscription"

3. Output Parameters
Parameter
Name

Type

Description

EnvironmentId

StringNamespace name.

MsgTTL

Integer

TTL for unconsumed messages in seconds.

RemarkStringNamespaceId

StringNamespace ID
Note: this field may return null, indicating that no valid values can be obtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

Remarks (up to 128 characters).
Note: this field may return null, indicating that no valid values can be obtained.

4. Example
Example1 Modifying the attributes of a specified namespace
This example shows you how to modify the attributes of a specified namespace.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyEnvironmentAttributes<Common request parameters>{"EnvironmentId": "test","MsgTTL": "100","ClusterId": "pulsar-xxxxxxxx"}©2013-2022 Tencent Cloud. All rights reserved.

Page 114 of 450

TDMQ for Apache Pulsar

Output Example{"Response": {"EnvironmentId": "test","NamespaceId": "namespace-5r59xen74x","MsgTTL": 100,
"Remark": "","RequestId": "7db00a30-933c-4f6f-bba9-79cdf6be7d8c"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

©2013-2022 Tencent Cloud. All rights reserved.

Page 115 of 450

TDMQ for Apache Pulsar

FailedOperation

Operation failed.

FailedOperation.SetRetentionPolicy

Failed to set the message retention policy.

FailedOperation.SetTTL

Failed to configure the message TTL.

FailedOperation.UpdateEnvironment

Failed to update the environment.

InternalError.BrokerService

The broker service is exceptional.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

InvalidParameterValue.TTL

The message TTL value is invalid.

LimitExceeded.RetentionTime

The message retention period limit has been exceeded. Please enter avalid value.

MissingParameter.NeedMoreParams

A required parameter is missing.

OperationDenied.DefaultEnvironment

Operations on the default environment are not allowed.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

ResourceNotFound.Namespace

The namespace does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 116 of 450

TDMQ for Apache Pulsar

DescribeEnvironments：

Last updated 2023-08-09 14:43:27

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of namespaces under a tenant.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

No

StringFuzzy search by namespace name.

OffsetNo

Integer

Offset, which defaults to 0 if left empty.

Limit

No

Integer

The number of results to be returned, which defaults to 10 if left
empty. The maximum value is 20.

ClusterId

No

StringPulsar cluster ID

Filters.N

No

Array ofFilter* EnvironmentId
Filter by namespace for exact query.

Name©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
DescribeEnvironments.

Page 117 of 450

TDMQ for Apache Pulsar

Type: String
Required: No

3. Output Parameters
Parameter
Name
TotalCount
EnvironmentSet

RequestId

Type

Description

Integer

The number of namespaces.

Array ofEnvironment
StringArray of namespace sets.
The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Getting the namespace list
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeEnvironments&EnvironmentId=default&Offset=0&Limit=10&<Common request parameters>

Output Example{"Response": {"TotalCount": 1,"EnvironmentSet": [{"EnvironmentId": "xx","Remark": "xx","NamespaceName": "xx","UpdateTime": "2020-09-22 00:00:00","NamespaceId": "xx","RetentionPolicy": {©2013-2022 Tencent Cloud. All rights reserved.

Page 118 of 450

TDMQ for Apache Pulsar"TimeInMinutes": 0,"SizeInMB": 0},"TopicNum": 0,"MsgTTL": 0,"CreateTime": "2020-09-22 00:00:00"}],"RequestId": "xx"}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

InternalError.SystemError

System error.

©2013-2022 Tencent Cloud. All rights reserved.

Page 119 of 450

TDMQ for Apache Pulsar

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 120 of 450

TDMQ for Apache Pulsar

DescribeEnvironmentAttributes：

Last updated 2023-08-09 14:43:27

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the attributes of the specified namespace.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeEnvironmentAttributes.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

ClusterId

No

StringPulsar cluster ID

Name

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 121 of 450

TDMQ for Apache Pulsar

MsgTTL

Integer

TTL for unconsumed messages in seconds. Maximum value: 1296000 seconds(i.e., 15 days).

RateInByte

Integer

Consumption rate limit in bytes/second. 0: unlimited.

RateInSize

Integer

Consumption rate limit in messages/second. 0: unlimited.

RetentionHours

Integer

RetentionSize

Integer

Retention policy for consumed messages in GB. 0: deleted immediately after
consumption.

EnvironmentId

StringEnvironment (namespace) name.

Replicas

IntegerNumber of replicas.

RemarkStringRemarks.

RequestId

StringRetention policy for consumed messages in hours. 0: deleted immediately after
consumption.

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Listing specified namespace attributes
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeEnvironmentAttributes&EnvironmentId=test1&<Common request parameters>

Output Example{"Response": {"MsgTTL": 2000,"RateInByte": 0,"RateInSize": 0,"Replicas": 2,"RetentionHours": 0,"RetentionSize": 0,"EnvironmentId": "test1","Remark": "Remarks","RequestId": "dec113a8-599a-4e70-b143-14425d48ffc4"©2013-2022 Tencent Cloud. All rights reserved.

Page 122 of 450

TDMQ for Apache Pulsar}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation.GetEnvironmentAttributesFailed

Failed to get the environment attributes.

InternalError.BrokerService

The broker service is exceptional.

InternalError.GetAttributesFailed

Failed to get attributes.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

©2013-2022 Tencent Cloud. All rights reserved.

Page 123 of 450

TDMQ for Apache Pulsar

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 124 of 450

TDMQ for Apache Pulsar

DeleteEnvironments：

Last updated 2023-08-09 14:43:28

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to batch delete namespaces under a tenant.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DeleteEnvironments.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentIds.N

Yes

Array ofArray of environments (namespaces). Up to 20 environments

Stringcan be deleted at a time.

ClusterId

No

StringPulsar cluster ID

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 125 of 450

TDMQ for Apache Pulsar

EnvironmentIds

Array of
StringRequestId

StringArray of environments (namespaces) successfully deleted.

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Deleting a namespace
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteEnvironments&EnvironmentIds.0=test1&<Common request parameters>

Output Example{"Response": {"EnvironmentIds": ["test1"],"RequestId": "db8bd520-496e-4e7c-a4a1-e7414d3c315c"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET

©2013-2022 Tencent Cloud. All rights reserved.

Page 126 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation.DeleteEnvironments

Failed to delete the environment.

FailedOperation.DeleteNamespace

Failed to delete the namespace.

FailedOperation.RoleInUse

You must clear the associated role data before proceeding.

FailedOperation.TopicInUse

You must clear the associated topic data before proceeding.

InternalError.SystemError

System error.

InvalidParameter

Incorrect parameter.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

OperationDenied.DefaultEnvironment

Operations on the default environment are not allowed.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 127 of 450

TDMQ for Apache Pulsar

CreateEnvironment：

Last updated 2023-08-09 14:43:28

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a TDMQ namespace.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
CreateEnvironment.

VersionYes

StringCommon Params. The value used for this API:
2020-02-17.

RegionNo

StringCommon Params. This parameter is not required
for this API.
Environment (namespace) name, which canEnvironmentId

Yes

Stringcontain up to 16 letters, digits, hyphens, andunderscores.
Retention period for unconsumed messages in

MsgTTLYes

Integer

seconds. Value range: 60s to 1,296,000s (or 15days).

RemarkNo

StringRemarks (up to 128 characters).

©2013-2022 Tencent Cloud. All rights reserved.

Page 128 of 450

TDMQ for Apache Pulsar

ClusterId

No

StringPulsar cluster ID

RetentionPolicy

No

RetentionPolicy

Message retention policy

AutoSubscriptionCreation

No

BooleanWhether to enable "Auto-Create Subscription"

3. Output Parameters
Parameter
Name

Type

Description

EnvironmentId

StringEnvironment (namespace) name.

MsgTTL

Integer

TTL for unconsumed messages in seconds.

RemarkStringRemarks (up to 128 characters).
Note: this field may return null, indicating that no valid values can be obtained.

NamespaceId

StringNamespace ID

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Creating a namespace
This example shows you how to create a namespace. You can enable "Auto-Create Subscription" as needed whencreating the namespace.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateEnvironment<Common request parameters>{"EnvironmentId": "test1","MsgTTL": "100","AutoSubscriptionCreation": true,©2013-2022 Tencent Cloud. All rights reserved.

Page 129 of 450

TDMQ for Apache Pulsar"ClusterId": "pulsar-xxxxxxxx"}

Output Example{"Response": {"EnvironmentId": "test1","NamespaceId": "namespace-8893gp3428","MsgTTL": 100,
"Remark": "","RequestId": "0843ea4f-d6ba-463b-952c-75708a7e8901"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription©2013-2022 Tencent Cloud. All rights reserved.

Page 130 of 450

TDMQ for Apache Pulsar

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.CreateEnvironment

Failed to create the environment.

FailedOperation.CreateNamespace

Failed to create the namespace.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

InvalidParameterValue.TTL

The message TTL value is invalid.

LimitExceeded.Environments

The number of environments under the instance exceeds the limit.

LimitExceeded.Namespaces

The number of namespaces under the instance exceeds the limit.

LimitExceeded.RetentionSize

The remaining quota has been exceeded. Please enter a valid value.

LimitExceeded.RetentionTime

The message retention period limit has been exceeded. Please enter avalid value.

MissingParameter.NeedMoreParams

A required parameter is missing.

OperationDenied.DefaultEnvironment

Operations on the default environment are not allowed.

ResourceInUse

The resource is in use.

ResourceInUse.Namespace

A namespace with the same name already exists.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 131 of 450

TDMQ for Apache Pulsar

DescribeEnvironmentRoles：

Last updated 2023-08-09 14:43:27

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of namespace roles.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeEnvironmentRoles.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

No

StringEnvironment/namespace name (required).

OffsetNo

Integer

Offset, which defaults to 0 if left empty.

Limit

No

Integer

The number of results to be returned, which defaults to 10 if left
empty. The maximum value is 20.

ClusterId

No

StringPulsar cluster ID (required).

RoleName

No

StringRole name.

Name©2013-2022 Tencent Cloud. All rights reserved.

Page 132 of 450

TDMQ for Apache Pulsar

Filters.N

No

Array ofFilter* RoleName
Filter by role name for exact query.
Type: String
Required: No

3. Output Parameters
Parameter NameType

Description

TotalCount

Integer

The number of records.

EnvironmentRoleSets

Array ofEnvironmentRole

Namespace role set.

RequestId

String

The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 Getting the list of namespace roles
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeEnvironmentRoles&EnvironmentId=default&<Common request parameters>

Output Example{"Response": {"TotalCount": 1,"EnvironmentRoleSets": [{"EnvironmentId": "default","RoleName": "test_role","Permissions": ["produce","consume"],"RoleDescribe": "Remark1",©2013-2022 Tencent Cloud. All rights reserved.

Page 133 of 450

TDMQ for Apache Pulsar"CreateTime": "2020-08-03 19:46:37","UpdateTime": "2020-08-04 15:59:29"}],"RequestId": "gggxxxx"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 134 of 450

TDMQ for Apache Pulsar

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

ResourceNotFound.Role

The role does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 135 of 450

TDMQ for Apache Pulsar

DeleteRocketMQNamespace：

Last updated 2023-08-09 14:43:28

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a RocketMQ namespace.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

NamespaceId

YesStringNamespace name

Description
Common Params. The value used for this API:
DeleteRocketMQNamespace.

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 136 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting namespace
Input Example
https://tdmq.tencentcloudapi.com/?
Action=DeleteRocketMQNamespace&ClusterId=rocketmq-rd3545bkkj49&NamespaceId=test&<Common request parameters>

Output Example{"Response": {"RequestId": "ab274271-a599-4e1d-b044-f3d03699e32a"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface©2013-2022 Tencent Cloud. All rights reserved.

Page 137 of 450

TDMQ for Apache Pulsar

Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.RoleInUse

You must clear the associated role data before proceeding.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 138 of 450

TDMQ for Apache Pulsar

Topic APIs
ModifyTopic：

Last updated 2023-08-09 14:43:18

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify the topic remarks and number of partitions.
A maximum of 50 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: ModifyTopic.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

TopicName

Yes

StringTopic name.

Name

Number of partitions, which must be equal to or greater than thePartitions

Yes

Integer

original number of partitions. To maintain the original number ofpartitions, enter the original number. Modifying the number ofpartitions will take effect only for non-globally sequential messages.
There can be up to 128 partitions.

©2013-2022 Tencent Cloud. All rights reserved.

Page 139 of 450

TDMQ for Apache Pulsar

RemarkNo

StringRemarks (up to 128 characters).

ClusterId

No

StringPulsar cluster ID

3. Output Parameters
Parameter
Name

Type

Description

Partitions

IntegerNumber of partitions

RemarkStringRemarks (up to 128 characters).

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying topic attributes
Input Example
https://tdmq.tencentcloudapi.com/?Action=ModifyTopic&EnvironmentId=default&TopicName=test_topic&Partitions=3&Remark=Change partition to 3&<Common request parameters>

Output Example{"Response": {"Partitions": 3,"Remark": "Change partition to 3","RequestId": "c276a96f-1612-47ad-9562-da06d4fdf1ed"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 140 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.GetTopicPartitionsFailed

Failed to get the number of topic partitions.

FailedOperation.UpdateTopic

Failed to update the topic.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 141 of 450

TDMQ for Apache Pulsar

DescribeTopics：

Last updated 2023-08-09 14:43:18

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of topics under an environment.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DescribeTopics.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

TopicNameNo

StringFuzzy match by topic name.

OffsetNo

Integer

Offset, which defaults to 0 if left empty.

Limit

No

Integer

TopicTypeNo

Integer

The number of results to be returned, which defaults to 10 if left
empty. The maximum value is 20.
Topic type description:
0: Non-persistent and non-partitioned topic;
1: Non-persistent and partitioned topic;©2013-2022 Tencent Cloud. All rights reserved.

Page 142 of 450

TDMQ for Apache Pulsar

2: Persistent and non-partitioned topic;
3: Persistent and partitioned topic.
ClusterId

No

StringNo

Array ofFilterPulsar cluster ID.
* TopicName

Filters.N

Query by topic name for exact search.
Type: String
Required: No

TopicCreator

No

Integer

Topic creator:
1: User
2: System

3. Output Parameters
Parameter
Name

Type

Description

TopicSets

Array of
Topic

Array of topic sets.

TotalCount

Integer

The number of topics.

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Obtaining the list of topics under the environment
This example shows you how to obtain the list of topics under the environment.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeTopics<Common request parameters>{"EnvironmentId": "abc",©2013-2022 Tencent Cloud. All rights reserved.

Page 143 of 450

TDMQ for Apache Pulsar"TopicName": "abc","Offset": 1,"Limit": 1,"TopicType": 1,"ClusterId": "abc","Filters": [{"Name": "abc","Values": [
"abc"
]
}
],
"TopicCreator": 1}

Output Example{"Response": {"TotalCount": 1,"RequestId": "abc","TopicSets": [{"PulsarTopicType": 0,"TopicType": 1,"ProducerCount": "abc","ConsumerLimit": "abc","ConsumerCount": "abc","LastLedgerCreatedTimestamp": "14578964532","MsgThroughputIn": "abc","UpdateTime": "2020-09-22 00:00:00","AverageMsgSize": "abc","Partitions": 1,"Remark": "abc","LastConfirmedEntry": "abc","TotalSize": "1",
"NumberOfEntries": "abc","MsgRateOut": "abc","ProducerLimit": "abc","EnvironmentId": "abc","TopicName": "abc","MsgRateIn": "abc","MsgThroughputOut": "abc","SubTopicSets": [{©2013-2022 Tencent Cloud. All rights reserved.

Page 144 of 450

TDMQ for Apache Pulsar"TopicType": 1,"ProducerCount": "1",
"LastConfirmedEntry": "abc","TotalSize": "1",
"NumberOfEntries": "abc","ConsumerCount": "1","MsgRateOut": "abc","AverageMsgSize": "1",
"MsgThroughputIn": "abc","MsgRateIn": "abc","Partitions": 0,"LastLedgerCreatedTimestamp": "124567885324","MsgThroughputOut": "abc"}],"CreateTime": "2020-09-22 00:00:00"}]}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code©2013-2022 Tencent Cloud. All rights reserved.

Page 145 of 450

TDMQ for Apache Pulsar

The following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

InternalError.SystemError

System error.

InvalidParameter.InvalidAdminUrl

Invalid management API address

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 146 of 450

TDMQ for Apache Pulsar

DeleteTopics：

Last updated 2023-08-09 14:43:18

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to batch delete topics.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DeleteTopics.

VersionYes

StringRegionNo

StringTopicSets.N

Yes

Array of
TopicRecord

Topic set. Up to 20 topics can be deleted at a time.

ClusterId

No

StringPulsar cluster ID.

EnvironmentId

No

StringEnvironment (namespace) name.

Force

No

Boolean©2013-2022 Tencent Cloud. All rights reserved.

Common Params. The value used for this API: 202002-17.
Common Params. This parameter is not required forthis API.

Whether to forcibly delete a topic. Default value:
false .

Page 147 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name
TopicSets

RequestId

Type
Array of
TopicRecord
StringDescription

Array of deleted topics.
The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Deleting a topic list
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteTopics&TopicSets.0.EnvironmentId=default&TopicSets.0.TopicName=cloud_test_1&<Common request parameters>

Output Example{"Response": {"TopicSets": [{"EnvironmentId": "default","TopicName": "cloud_test_1"}],"RequestId": "5f4eabe4-94f2-4f91-8285-86f24ef8bcfa"}}

5. Developer Resources©2013-2022 Tencent Cloud. All rights reserved.

Page 148 of 450

TDMQ for Apache Pulsar

SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.DeleteTopics

Failed to delete the topic.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

OperationDenied.DefaultEnvironment

Operations on the default environment are not allowed.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 149 of 450

TDMQ for Apache Pulsar

CreateTopic：

Last updated 2023-08-09 14:43:18

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to add a message topic in the specified partition and type.
A maximum of 200 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: CreateTopic.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

TopicName

Yes

StringPartitions

Yes

Integer

Topic name, which can contain up to 64 letters, digits, hyphens,
and underscores.
The value “1” indicates a non-partitioned topic (a topic with nopartitions) will be created. A value between 1 (exclusive) and 128(inclusive) indicates the partition count of a partitioned topic.

RemarkNo

StringRemarks (up to 128 characters).

TopicTypeNo

IntegerThis input parameter will be disused soon. You can use
PulsarTopicType instead.

©2013-2022 Tencent Cloud. All rights reserved.

Page 150 of 450

TDMQ for Apache Pulsar

0: General message;
1: Globally sequential message;
2: Partitionally sequential message;
3: Retry letter topic;
4: Dead letter topic.
ClusterId

No

StringPulsar cluster ID
Pulsar topic type.
0 : Non-persistent and non-partitioned

PulsarTopicType

No

Integer

1 : Non-persistent and partitioned
2 : Persistent and non-partitioned
3 : Persistent and partitioned

3. Output Parameters
Parameter

Type

Description

EnvironmentId

StringEnvironment (namespace) name.

TopicName

StringTopic name.

Integer

Valid value: 0 or 1. Non-partitioned topic: No partitions. A value greater than 1: The
partition count of a partitioned topic. 0 is returned for existing non-partitioned

Name

Partitions

topics, and 1 is returned for incremental non-partitioned topics.
RemarkStringRemarks (up to 128 characters).
Note: this field may return null, indicating that no valid values can be obtained.
0: General message;
1: Globally sequential message;

TopicType

Integer

2: Partitionally sequential message;
3: Retry letter topic;
4: Dead letter topic.
Note: This field may return null, indicating that no valid values can be obtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example©2013-2022 Tencent Cloud. All rights reserved.

Page 151 of 450

TDMQ for Apache Pulsar

Example1 Creating a topic
This example shows you how to create a topic.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateTopic<Common request parameters>{"EnvironmentId": "default","Remark": "2-partition general message queue","TopicType": "0","TopicName": "test_topic","Partitions": "2"}

Output Example{"Response": {"EnvironmentId": "default","TopicName": "test_topic","Partitions": 2,"TopicType": 0,"Remark": "2-partition general message queue","RequestId": "d9686bf9-8d7d-4e78-bb44-5140d70a1ffa"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP©2013-2022 Tencent Cloud. All rights reserved.

Page 152 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.CreateTopic

Failed to create the topic.

InternalError.SystemError

System error.

InvalidParameterValue

The parameter value is incorrect.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

LimitExceeded.Topics

The number of topics under the instance exceeds the limit.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceInUse

The resource is in use.

ResourceInUse.Topic

A topic with the same name already exists.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 153 of 450

TDMQ for Apache Pulsar

Message APIs
SendMessages：

Last updated 2023-08-09 14:43:28

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to send a single message.
The message cannot be sent to a persistent topic.
A maximum of 1000 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringRegionNo

StringDescription
Common Params. The value used for this API:
SendMessages.
Common Params. The value used for this API: 2020-02-17.
Common Params. This parameter is not required for thisAPI.
Name of the topic to which to send the message. It is better

Topic

Yes

Stringto be the full path of the topic, such as
tenant/namespace/topic . If it is not specified,public/default will be used by default.

PayloadYes

String©2013-2022 Tencent Cloud. All rights reserved.

Content of the message to be sent

Page 154 of 450

TDMQ for Apache Pulsar

StringToken

No

StringToken used for authentication, which is optional and will be
automatically obtained by the system.
Producer name, which is randomly generated and must be
globally unique. If you set the producer name manually, theProducerName

No

Stringproducer may fail to be created, causing message sending
failure.
This parameter is used only when a specific producer isallowed to produce messages. It won’t be used in mostcases.

SendTimeout

No

Integer

MaxPendingMessages

No

Integer

Message sending timeout period, which is 30s by default.
Maximum number of produced messages which can becached in the memory. Default value: 1000

3. Output Parameters
Parameter
Name

Type

Description
messageID, which must be globally unique and is the metadata information used to

MessageId

StringErrorMsg

StringRequestId

Stringidentify the message.
Note: this field may return null, indicating that no valid values can be obtained.
Returned error message. If an empty string is returned, no error occurred.
Note: this field may return null, indicating that no valid values can be obtained.
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Sending a single message
This example shows you how to send a single message.
The message cannot be sent to a non-persistent topic.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com©2013-2022 Tencent Cloud. All rights reserved.

Page 155 of 450

TDMQ for Apache Pulsar

Content-Type: application/json
X-TC-Action: SendMessages<Common request parameters>{"Topic": "tenant/namespace/topic","Payload": "\"hello TDMQ\""}

Output Example{"Response": {"RequestId": "36713f94-d07d-4b96-babf-42d139276f23","MessageId": "71:11:0:0","ErrorMsg": ""}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code©2013-2022 Tencent Cloud. All rights reserved.

Page 156 of 450

TDMQ for Apache Pulsar

The following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation.CreateProducerError

An error occurred while creating the producer.

FailedOperation.CreatePulsarClientError

An error occurred while creating the TDMQ client.

FailedOperation.MaxMessageSizeError

The message size exceeds the upper limit of 1 MB.

FailedOperation.MessageIDError

The uploaded msgID is incorrect.

FailedOperation.ReceiveError

An error occurred while receiving the message.

FailedOperation.ReceiveTimeout

Message receiving timed out. Please try again.

FailedOperation.SendMessageTimeoutError

Message sending timed out.

FailedOperation.TopicTypeError

Please use a partition topic.

InvalidParameter.TenantNotFoundThe uploaded tenant name is incorrect.

InvalidParameter.TokenNotFoundThe correct token was not obtained.

InvalidParameterValue.TopicNotFoundThe uploaded topic name is incorrect.

©2013-2022 Tencent Cloud. All rights reserved.

Page 157 of 450

TDMQ for Apache Pulsar

SendBatchMessages：

Last updated 2023-08-09 14:43:29

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to batch send messages.
Note: the batch message sending API in TDMQ is to package messages into a batch on the service side of TDMQHTTP and then send the batch as a TCP request inside the service. Therefore, when using this API, you should still
follow the logic of sending a single message: each message is an independent HTTP request, and multiple HTTP
requests are aggregated into one batch inside the TDMQ-HTTP service and then sent to the server; that is, batch
sending messages is the same as sending a single message in terms of usage, and batch aggregation is completed
inside the TDMQ-HTTP service.
A maximum of 1000 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
SendBatchMessages.

VersionYes

StringCommon Params. The value used for this API: 2020-0217.

RegionNo

StringTopic

Yes

StringCommon Params. This parameter is not required for thisAPI.
Name of the topic to which to send the message. It isbetter to be the full path of the topic, such as©2013-2022 Tencent Cloud. All rights reserved.

Page 158 of 450

TDMQ for Apache Pulsar

tenant/namespace/topic . If it is not specified,public/default will be used by default.
PayloadYes

StringStringToken

No

StringProducerName

No

StringSendTimeout

No

Integer

MaxPendingMessages

No

Integer

BatchingMaxMessages

No

Integer

BatchingMaxPublishDelay

No

Integer

BatchingMaxBytes

No

IntegerContent of the message to be sent
String-Type token, which is optional and will be
automatically obtained by the system.
Producer name, which must be globally unique. If it is notconfigured, the system will automatically generate one.
Message sending timeout period in seconds. Default
value: 30s
Maximum number of produced messages which can becached in the memory. Default value: 1000
Maximum number of messages in each batch. Default
value: 1000 messages/batch
Maximum wait time for each batch, after which the batch
will be sent no matter whether the specified number orsize of messages in the batch is reached. Default value:
10 ms
Maximum allowed size of messages in each batch.
Default value: 128 KB

3. Output Parameters
Parameter
Name

Type

MessageId

StringErrorMsg

StringRequestId

StringDescription
Unique message ID
Note: this field may return null, indicating that no valid values can be obtained.
Error message. If an empty string is returned, no error occurred.
Note: this field may return null, indicating that no valid values can be obtained.
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example©2013-2022 Tencent Cloud. All rights reserved.

Page 159 of 450

TDMQ for Apache Pulsar

Example1 Sending multiple messages successfully
Input Example
https://tdmq.tencentcloudapi.com/?Action=SendBatchMessages&Topic=tenant/namespace/topic&Payload="hello TDMQ"&<Common request parameters>

Output Example{"Response": {"RequestId": "36713f94-d07d-4b96-babf-42d139276f23","MessageId": "71:12:0:0","ErrorMsg": ""}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code©2013-2022 Tencent Cloud. All rights reserved.

Page 160 of 450

TDMQ for Apache Pulsar

The following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation.CreateProducerError

An error occurred while creating the producer.

FailedOperation.CreatePulsarClientError

An error occurred while creating the TDMQ client.

FailedOperation.MaxMessageSizeError

The message size exceeds the upper limit of 1 MB.

FailedOperation.MessageIDError

The uploaded msgID is incorrect.

FailedOperation.ReceiveError

An error occurred while receiving the message.

FailedOperation.ReceiveTimeout

Message receiving timed out. Please try again.

FailedOperation.SendMessageTimeoutError

Message sending timed out.

FailedOperation.TopicTypeError

Please use a partition topic.

InvalidParameter.TenantNotFoundThe uploaded tenant name is incorrect.

InvalidParameter.TokenNotFoundThe correct token was not obtained.

InvalidParameterValue.TopicNotFoundThe uploaded topic name is incorrect.

©2013-2022 Tencent Cloud. All rights reserved.

Page 161 of 450

TDMQ for Apache Pulsar

ReceiveMessage：

Last updated 2023-08-09 14:43:29

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
Currently, the ReceiveMessage API only supports partitioned topics. It is used to receive messages sent to a
specified partitioned topic. If it is called when there are no messages in the partitioned topic, theReceiveTimeout exception will be reported.
Instructions on how to use BatchReceivePolicy :BatchReceive has three parameters:● MaxNumMessages : The maximum number of messages returned by Receive when BatchReceive isused.
● MaxNumBytes : The maximum size (in bytes) of the message returned by Receive when BatchReceiveis used.
● Timeout : The maximum timeout period (in milliseconds) of calling Receive when BatchReceive isused.
By default, if you don’t specify any of the three parameters, the BatchReceive feature is disabled; if one of thethree parameter values is above zero, BatchReceive is enabled. BatchReceive will be disabled when anyof the three parameter values reaches the threshold you specify.
Note: The values of both MaxNumMessages and MaxNumBytes are subject to the value of
ReceiveQueueSize . If the values of ReceiveQueueSize and MaxNumMessages are 5 and 10,
respectively, you can receive up to five rather than 10 messages when BatchReceive is used.
The API configured with BatchReceivePolicy returns multiple messages at a time.
1. These messages are separated by “###”. After receiving them, you can separate them with split tools in different
languages.
2. MessageIDs are separated by “###”. After receiving the messages, you can separate the MessageIDs with split
tools in different languages, so that you can obtain the MessageID field information required for calling the
AcknowledgeMessage API.

A maximum of 1000 requests can be initiated per second for this API.
We recommend you to use API Explorer©2013-2022 Tencent Cloud. All rights reserved.

Page 162 of 450

TDMQ for Apache Pulsar

Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
ReceiveMessage.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.
Name of the topic which receives the message. It is better to be

Topic

Yes

Stringthe full path of the topic, such as
tenant/namespace/topic . If it is not specified,public/default will be used by default.

SubscriptionName

Yes

StringSubscriber nameDefault value: 1000. Messages received by the consumer will

ReceiverQueueSize

No

Integerfirst be stored in the receiverQueueSize queue to tune
the message receiving rate.

SubInitialPosition

No

StringA parameter used to determine the position where theconsumer initially receives messages. Valid values:
Earliest (default), Latest .
This parameter is used to specify the maximum number of

MaxNumMessages

No

Integer

received messages in a batch for BatchReceivePolicy .
The default value is 0, indicating that
BatchReceivePolicy is disabled.
This parameter is used to specify the maximum body size (inMaxNumBytes

No

Integerbytes) of received messages in a batch for
BatchReceivePolicy . The default value is 0, indicatingthat BatchReceivePolicy is disabled.

Timeout

No

Integer©2013-2022 Tencent Cloud. All rights reserved.

This parameter is used to specify the maximum wait timeout (inPage 163 of 450

TDMQ for Apache Pulsar

milliseconds) for receiving a batch of messages for
BatchReceivePolicy . The default value is 0, indicatingthat BatchReceivePolicy is disabled.

3. Output Parameters
Parameter NameType

Description

MessageID

StringUnique primary key used to identify the message

MessagePayload

StringContent of the received message

AckTopic

StringProvided to the Ack API and used to acknowledge messages in the topic

ErrorMsg

StringReturned error message. If it is an empty string, no error occurred.
Note: this field may return null, indicating that no valid values can be obtained.
Returned subscriber name, which will be used when an acknowledgment

SubNameStringconsumer is created.
Note: this field may return null, indicating that no valid values can be obtained.
MessageIDs returned by BatchReceivePolicy at a time, which are

MessageIDList

Stringseparated by “###”.
Note: This field may return null, indicating that no valid values can be obtained.
Message contents returned by BatchReceivePolicy at a time, which are

MessagesPayload

Stringseparated by “###”.
Note: This field may return null, indicating that no valid values can be obtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Receiving messages
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ReceiveMessage©2013-2022 Tencent Cloud. All rights reserved.

Page 164 of 450

TDMQ for Apache Pulsar<Common request parameters>{"Topic": "tenant/namespace/topic","SubscriptionName": "\"test-sub\""}

Output Example{"Response": {"RequestId": "36713f94-d07d-4b96-babf-42d139276f23","MessageID": "71:12:0:0","MessageIDList": "","MessagesPayload": "","MessagePayload": "hello TDMQ","SubName": "xx","AckTopic": "persistent://tenant/namespace/topic","ErrorMsg": "xx"}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 165 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation.CreateProducerError

An error occurred while creating the producer.

FailedOperation.CreatePulsarClientError

An error occurred while creating the TDMQ client.

FailedOperation.MaxMessageSizeError

The message size exceeds the upper limit of 1 MB.

FailedOperation.MessageIDError

The uploaded msgID is incorrect.

FailedOperation.ReceiveError

An error occurred while receiving the message.

FailedOperation.ReceiveTimeout

Message receiving timed out. Please try again.

FailedOperation.SendMessageTimeoutError

Message sending timed out.

FailedOperation.TopicTypeError

Please use a partition topic.

InvalidParameter.TenantNotFoundThe uploaded tenant name is incorrect.

InvalidParameter.TokenNotFoundThe correct token was not obtained.

InvalidParameterValue.TopicNotFoundThe uploaded topic name is incorrect.

©2013-2022 Tencent Cloud. All rights reserved.

Page 166 of 450

TDMQ for Apache Pulsar

AcknowledgeMessage：

Last updated 2023-08-09 14:43:29

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to acknowledge the message in the specified topic by the provided MessageID .
A maximum of 1000 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: AcknowledgeMessage.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

MessageId

YesStringUnique ID used to identify the message, which can be obtained from thereturned value of receiveMessage .

Name

AckTopic

Yes

StringTopic name, which can be obtained from the returned value of
receiveMessage and is better to be the full path of the topic, suchas tenant/namespace/topic . If it is not specified,public/default will be used by default.

SubNameYes

StringSubscriber name, which can be obtained from the returned value of
receiveMessage . Make sure that it is the same as the subscriber©2013-2022 Tencent Cloud. All rights reserved.

Page 167 of 450

TDMQ for Apache Pulsar

name identified in receiveMessage ; otherwise, the received
message cannot be correctly acknowledged.

3. Output Parameters
Parameter

Type

Description

ErrorMsg

StringIf it is an empty string, no error occurred.
Note: this field may return null, indicating that no valid values can be obtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

Name

4. Example
Example1 Acknowledging message
Input Example
https://tdmq.tencentcloudapi.com/?Action=AcknowledgeMessage&AckTopic=tenant/namespace/topic&MessageId="71:12:0"&SubName="test-sub"&<Common request parameters>

Output Example{"Response": {"RequestId": "36713f94-d07d-4b96-babf-42d139276f23","ErrorMsg": "xxx"}}

5. Developer Resources
SDK©2013-2022 Tencent Cloud. All rights reserved.

Page 168 of 450

TDMQ for Apache Pulsar

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation.CreateProducerError

An error occurred while creating the producer.

FailedOperation.CreatePulsarClientError

An error occurred while creating the TDMQ client.

FailedOperation.MaxMessageSizeError

The message size exceeds the upper limit of 1 MB.

FailedOperation.MessageIDError

The uploaded msgID is incorrect.

FailedOperation.ReceiveError

An error occurred while receiving the message.

FailedOperation.ReceiveTimeout

Message receiving timed out. Please try again.

FailedOperation.TopicTypeError

Please use a partition topic.

InvalidParameter.TenantNotFoundThe uploaded tenant name is incorrect.

InvalidParameter.TokenNotFoundThe correct token was not obtained.

InvalidParameterValue.TopicNotFoundThe uploaded topic name is incorrect.

©2013-2022 Tencent Cloud. All rights reserved.

Page 169 of 450

TDMQ for Apache Pulsar

CMQ Message APIs
SendCmqMsg：

Last updated 2023-08-09 14:43:33

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to send a CMQ message.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: SendCmqMsg.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

QueueName

Yes

StringQueue name

MsgContent

Yes

StringMessage content

DelaySeconds

Yes

Integer

Delay time

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 170 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

ResultBooleantrue indicates that the sending is successful

MsgId

StringMessage ID

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

Name

4. Example
Example1 Sending message
Input Example
https://tdmq.tencentcloudapi.com/?Action=SendCmqMsg&QueueName=test-queue&MsgContent=test&DelaySeconds=0&<Common request parameters>

Output Example{"Response": {"Result": true,"MsgId": "50169152:0:0:-1","RequestId": "3593f784-fcfb-4f23-b3dd-4751cba3aec7"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java©2013-2022 Tencent Cloud. All rights reserved.

Page 171 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 172 of 450

TDMQ for Apache Pulsar

PublishCmqMsg：

Last updated 2023-08-09 14:43:33

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to send a CMQ topic message.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: PublishCmqMsg.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

TopicName

Yes

StringTopic name

MsgContent

Yes

StringMessage content. The total message size is up to 1,024 KB.

No

Array
of

MsgTag.N

StringMessage tag. You can pass in multiple tags or a single route. Each tag
or route can contain up to 64 characters.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 173 of 450

TDMQ for Apache Pulsar

Parameter
Name

Type

Description

ResultBooleantrue indicates that the sending is successful

MsgId

StringMessage ID

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Sending a CMQ topic message
Input Example
https://tdmq.tencentcloudapi.com/?Action=PublishCmqMsg&TopicName=test-queue&MsgContent=test&<Common request parameters>

Output Example{"Response": {"Result": true,"MsgId": "50169152:0:0:-1","RequestId": "3593f784-fcfb-4f23-b3dd-4751cba3aec7"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP©2013-2022 Tencent Cloud. All rights reserved.

Page 174 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 175 of 450

TDMQ for Apache Pulsar

ClearCmqSubscriptionFilterTags：

Last updated 2023-08-09 14:43:33

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to clear the message tags of a subscriber.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Common Params. The value used for this API:
ClearCmqSubscriptionFilterTags.

Topic name, which must be unique in the same topic under the
TopicName

Yes

Stringsame account in the same region. It can contain up to 64 letters,
digits, and hyphens and must begin with a letter.
Subscription name, which must be unique in the same topic under

SubscriptionName

Yes

Stringthe same account in the same region. It can contain up to 64
letters, digits, and hyphens and must begin with a letter.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 176 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

Name
RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Clearing the message tags of subscriber
Input Example
https://tdmq.tencentcloudapi.com/?Action=ClearCmqSubscriptionFilterTags&TopicName=ConnTopic&SubscriptionName=Queue&<Common request parameters>

Output Example{"Response": {"RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++©2013-2022 Tencent Cloud. All rights reserved.

Page 177 of 450

TDMQ for Apache Pulsar

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

©2013-2022 Tencent Cloud. All rights reserved.

Page 178 of 450

TDMQ for Apache Pulsar

ClearCmqQueue：

Last updated 2023-08-09 14:43:33

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to clear the messages in the CMQ message queue.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: ClearCmqQueue.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.
Queue name, which must be unique under the same account in theQueueName

Yes

Stringsame region. It can contain up to 64 letters, digits, and hyphens andmust begin with a letter.

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 179 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Clearing messages retained in queue
Input Example
https://tdmq.tencentcloudapi.com/?Action=ClearCmqQueue&QueueName=test&<Common request parameters>

Output Example{"Response": {"RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 180 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceNotFoundThe resource does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 181 of 450

TDMQ for Apache Pulsar

CMQ Management APIs
UnbindCmqDeadLetter：

Last updated 2023-08-09 14:43:33

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to unbind a CMQ dead letter queue.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
UnbindCmqDeadLetter.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

SourceQueueName

Yes

StringSource queue name of dead letter policy. Calling this API willclear the dead letter queue policy of this queue.

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 182 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Unbinding dead letter queue
Input Example
https://tdmq.tencentcloudapi.com/?Action=UnbindCmqDeadLetter&SourceQueueName=test&<Common request parameters>

Output Example{"Response": {"RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 183 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

©2013-2022 Tencent Cloud. All rights reserved.

Page 184 of 450

TDMQ for Apache Pulsar

RewindCmqQueue：

Last updated 2023-08-09 14:43:34

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to rewind a CMQ queue.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Common Params. The value used for this API:
RewindCmqQueue.

Queue name, which must be unique under the same account inQueueName

Yes

Stringthe same region. It can contain up to 64 letters, digits, andhyphens and must begin with a letter.

StartConsumeTime

Yes

Integer

After this time is configured, the(Batch)receiveMessage API will consume themessages received after this timestamp in the order in which
they are produced.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 185 of 450

TDMQ for Apache Pulsar

Parameter
Name
RequestId

Type

Description

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Rewinding consumption position in queue
Input Example
https://tdmq.tencentcloudapi.com/?Action=RewindCmqQueue&QueueName=test&StartConsumeTime=1582108595000&<Common request parameters>

Output Example{"Response": {"RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++©2013-2022 Tencent Cloud. All rights reserved.

Page 186 of 450

TDMQ for Apache Pulsar

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 187 of 450

TDMQ for Apache Pulsar

ModifyCmqTopicAttribute：

Last updated 2023-08-09 14:43:34

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify the attributes of a CMQ topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringRegionNo

StringDescription
Common Params. The value used for this API:
ModifyCmqTopicAttribute.
Common Params. The value used for this API: 2020-02-17.
Common Params. This parameter is not required for thisAPI.
Topic name, which must be unique under the same

TopicName

Yes

StringMaxMsgSize

No

Integer

MsgRetentionSeconds

No

Integer

Trace

No

Boolean©2013-2022 Tencent Cloud. All rights reserved.

account in the same region. It can contain up to 64 letters,
digits, and hyphens and must begin with a letter.
Maximum message length. Value range: 1024–65536
bytes (i.e., 1–64 KB). Default value: 65536.
Message retention period. Value range: 60–86400 seconds(i.e., 1 minute–1 day). Default value: 86400.
Whether to enable message trace. true: yes; false: no. If

Page 188 of 450

TDMQ for Apache Pulsar

this field is left empty, the feature will not be enabled.

3. Output Parameters
Parameter
Name

Type

RequestId

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying topic attributes
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyCmqTopicAttribute<Common request parameters>{"MaxMsgSize": 1,"TopicName": "xx","Trace": true,"MsgRetentionSeconds": 1}

Output Example{"Response": {"RequestId": "8a04c6b1-dec5-4979-b3b2-34ab3b3402b2"}}

5. Developer Resources©2013-2022 Tencent Cloud. All rights reserved.

Page 189 of 450

TDMQ for Apache Pulsar

SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 190 of 450

TDMQ for Apache Pulsar

ModifyCmqSubscriptionAttribute：

Last updated 2023-08-09 14:43:34

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify the attributes of a CMQ subscription.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Common Params. The value used for this API:
ModifyCmqSubscriptionAttribute.

Topic name, which must be unique in the same topic under the
TopicName

Yes

Stringsame account in the same region. It can contain up to 64
letters, digits, and hyphens and must begin with a letter.

SubscriptionName

Yes

StringSubscription name, which must be unique in the same topic
under the same account in the same region. It can contain up to
64 letters, digits, and hyphens and must begin with a letter.

NotifyStrategy

No

String

CMQ push server retry policy in case an error occurs while
pushing a message to the endpoint. Valid values:(1) BACKOFF_RETRY: backoff retry, which is to retry at a fixedinterval, discard the message after a certain number of retries,©2013-2022 Tencent Cloud. All rights reserved.

Page 191 of 450

TDMQ for Apache Pulsar

and continue to push the next message.
(2) EXPONENTIAL_DECAY_RETRY: exponential decay retry,
which is to retry at an exponentially increasing interval, such as
1s, 2s, 4s, 8s, and so on. As a message can be retained in a
topic for one day, failed messages will be discarded at mostafter one day of retry. Default value:
EXPONENTIAL_DECAY_RETRY.

NotifyContentFormat

No

StringPush content format. Valid values: 1. JSON; 2. SIMPLIFIED,
i.e., the raw format. If Protocol is queue , this value
must be SIMPLIFIED . If Protocol is HTTP , both
values are acceptable, and the default value is JSON .
Message body tag (used for message filtering). The number oftags cannot exceed 5, and each tag can contain up to 16
characters. It is used in conjunction with the MsgTagparameter of (Batch)PublishMessage . Rules: 1. If
FilterTag is not configured, no matter whether MsgTagis configured, the subscription will receive all messages
published to the topic; 2. If the array of FilterTag values

FilterTags.N

No

Array

has a value, only when at least one of the values in the arrayofalso exists in the array of MsgTag values (i.e.,

StringFilterTag and MsgTag have an intersection) can thesubscription receive messages published to the topic; 3. If thearray of FilterTag values has a value, but MsgTag is
not configured, then no message published to the topic will bereceived, which can be considered as a special case of rule 2
as FilterTag and MsgTag do not intersect in this case.
The overall design idea of rules is based on the intention of thesubscriber.
The number of BindingKey cannot exceed 5, and theBindingKey.N

No

Array

length of each BindingKey cannot exceed 64 bytes. Thisof
Stringfield indicates the filtering policy for subscribing to andreceiving messages. Each BindingKey includes up to 15
dots (namely up to 16 segments).

3. Output Parameters
Parameter
Name
RequestId

Type

Description

String

The unique request ID, which is returned for each request. RequestId is required for©2013-2022 Tencent Cloud. All rights reserved.

Page 192 of 450

TDMQ for Apache Pulsar

locating a problem.

4. Example
Example1 Modifying subscription attributes
Input Example
https://tdmq.tencentcloudapi.com/?Action=ModifyCmqSubscriptionAttribute&TopicName=test&SubscriptionName=test&<Common request parameters>

Output Example{"Response": {"RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 193 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

©2013-2022 Tencent Cloud. All rights reserved.

Page 194 of 450

TDMQ for Apache Pulsar

ModifyCmqQueueAttribute：

Last updated 2023-08-09 14:43:34

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify the attributes of a CMQ queue.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
ModifyCmqQueueAttribute.

VersionYes

StringRegionNo

StringCommon Params. The value used for this API: 2020-0217.
Common Params. This parameter is not required for thisAPI.
Queue name, which must be unique under the same

QueueName

Yes

Stringaccount in the same region. It can contain up to 64 letters,
digits, and hyphens and must begin with a letter.

MaxMsgHeapNum

No

IntegerMaximum number of heaped messages. The value range
is 1,000,000–10,000,000 during the beta test and can be
1,000,000–1,000,000,000 after the product is officiallyreleased. The default value is 10,000,000 during the beta
test and will be 100,000,000 after the product is officiallyreleased.

©2013-2022 Tencent Cloud. All rights reserved.

Page 195 of 450

TDMQ for Apache Pulsar

PollingWaitSeconds

No

Integer

VisibilityTimeout

No

IntegerMaxMsgSize

No

IntegerLong polling wait time for message reception. Value
range: 0–30 seconds. Default value: 0.
Message visibility timeout period. Value range: 1–43200
seconds (i.e., 12 hours). Default value: 30.
Max message size, which defaults to 1,024 KB for thequeue of TDMQ for CMQ and cannot be modified.
The max period during which a message is retained

MsgRetentionSeconds

No

Integer

before it is automatically acknowledged. Value range: 3043,200 seconds (30 seconds to 12 hours). Default value:
3600 seconds (1 hour).

RewindSeconds

No

Integer

Rewindable time of messages in the queue. Value range:
0-1,296,000s (if message rewind is enabled). The value“0” indicates that message rewind is not enabled.

FirstQueryInterval

No

IntegerFirst query time

MaxQueryCountNo

IntegerMaximum number of queries

DeadLetterQueueName

No

StringDead letter queue nameMaximum period in seconds before an unconsumed
message expires, which is required if

MaxTimeToLive

No

IntegerMaxTimeToLivepolicy is 1. Value range: 300–
43200. This value should be smaller than
MsgRetentionSeconds (maximum message
retention period)

MaxReceiveCountNo

IntegerMaximum number of receipts

PolicyNo

Integer

Dead letter queue policy

Trace

No

BooleanTransaction

No

Integer

Whether to enable message trace. true: yes; false: no. If
this field is left empty, the feature will not be enabled.
Whether to enable transaction. 1: yes; 0: no
Queue storage space configured for message rewind.

RetentionSizeInMB

No

Integer

Value range: 10,240-512,000 MB (if message rewind isenabled). The value “0” indicates that message rewind is
not enabled.

©2013-2022 Tencent Cloud. All rights reserved.

Page 196 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name

Type

RequestId

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying queue attributes
Input Example
https://tdmq.tencentcloudapi.com/?Action=ModifyCmqQueueAttribute&QueueName=test&MaxMsgSize=1024&<Common request parameters>

Output Example{"Response": {"RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS©2013-2022 Tencent Cloud. All rights reserved.

Page 197 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.SetRetentionPolicy

Failed to set the message retention policy.

FailedOperation.SetTTL

Failed to configure the message TTL.

InternalError.BrokerService

The broker service is exceptional.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Environment

The environment does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 198 of 450

TDMQ for Apache Pulsar

DescribeCmqTopics：

Last updated 2023-08-09 14:43:34

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to enumerate all CMQ topics.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

OffsetNo

Integer

Description
Common Params. The value used for this API:
DescribeCmqTopics.

Starting position of a queue list to be returned on the current
page in case of paginated return. If a value is entered, limit
must be specified. If this parameter is left empty, 0 will be usedby default.
The number of queues to be returned per page in case of

Limit

No

Integerpaginated return. If this parameter is not passed in, 20 will be
used by default. Maximum value: 50.

TopicNameNo

StringFuzzy search by TopicName

TopicNameList.N

No

Array ofFilter by CMQ topic name.

©2013-2022 Tencent Cloud. All rights reserved.

Page 199 of 450

TDMQ for Apache Pulsar

StringIsTagFilter

No

Filters.N

No

Boolean

For filtering by tag, this parameter must be set to true .

Array ofFilter. Currently, you can filter by tag. The tag name must be
prefixed with “tag:”, such as “tag: owner”, “tag: environment”, orFilter“tag: business”.

3. Output Parameters
Parameter

Type

Description

Array of

Topic list.

CmqTopic

Note: This field may return null, indicating that no valid values can be obtained.

TotalCount

Integer

The total number of topics.

RequestId

StringName
TopicList

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Enumerating topics (without distinguishing between users)
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeCmqTopics<Common request parameters>{"Limit": 1,"Offset": "0"}

Output Example{"Response": {©2013-2022 Tencent Cloud. All rights reserved.

Page 200 of 450

TDMQ for Apache Pulsar"TotalCount": 360,
"TopicList": [{"Tags": [],"TopicId": "topic-catv1v6h","TopicName": "QTA-6d1dfa44-5c70-11ea-8575-460d8830b47a","CreateUin": 100002742997,"MsgRetentionSeconds": 86400,"MaxMsgSize": 65536,"Qps": 5000,"FilterType": 1,"CreateTime": 1583144853,"LastModifyTime": 1583144874,"MsgCount": 0},{"Tags": [],"TopicId": "topic-caysfz7j","TopicName": "QTA-8f9162e2-5c6f-11ea-8dea-460d8830b47a","CreateUin": 100002742997,"MsgRetentionSeconds": 86400,"MaxMsgSize": 1025,"Qps": 5000,"FilterType": 1,"CreateTime": 1583144481,"LastModifyTime": 1583144484,"MsgCount": 0}],"RequestId": "104f0831-f81a-4d65-81e4-ff0c6217ae23"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go©2013-2022 Tencent Cloud. All rights reserved.

Page 201 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.CmqBackendError

CMQ backend error.

©2013-2022 Tencent Cloud. All rights reserved.

Page 202 of 450

TDMQ for Apache Pulsar

DescribeCmqTopicDetail：

Last updated 2023-08-09 14:43:35

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the details of a CMQ topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeCmqTopicDetail.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

TopicNameNo

StringExact match by TopicName .

Name

3. Output Parameters
Parameter
Name
TopicDescribeType

Description

CmqTopic

Topic details©2013-2022 Tencent Cloud. All rights reserved.

Page 203 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Querying CMQ topic details
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeCmqTopicDetail&<Common request parameters>

Output Example{"Response": {"TopicDescribe": {"MsgCount": 1,"TopicId": "xx","MaxMsgSize": 1,"Trace": true,"Tags": [{"TagKey": "xx","TagValue": "xx"}],"CreateUin": 1,"FilterType": 1,"TenantId": "xx","LastModifyTime": 1,"MsgRetentionSeconds": 1,"NamespaceName": "xx","Qps": 1,"CreateTime": 1,"TopicName": "xx"},"RequestId": "xx"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 204 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.CmqBackendError

CMQ backend error.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Topic

The topic does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 205 of 450

TDMQ for Apache Pulsar

DescribeCmqSubscriptionDetail：

Last updated 2023-08-09 14:43:35

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the CMQ subscription details.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Common Params. The value used for this API:
DescribeCmqSubscriptionDetail.

Topic name, which must be unique in the same topic under the
TopicName

Yes

Stringsame account in the same region. It can contain up to 64 letters,
digits, and hyphens and must begin with a letter.
Starting position of the list of topics to be returned on the current

OffsetNo

Integer

Limit

No

Integerpage in case of paginated return. If a value is entered, limit
is required. If this parameter is left empty, 0 will be used bydefault
Number of topics to be returned per page in case of paginatedreturn. If this parameter is not passed in, 20 will be used bydefault. Maximum value: 50.

©2013-2022 Tencent Cloud. All rights reserved.

Page 206 of 450

TDMQ for Apache Pulsar

SubscriptionName

No

StringFuzzy search by SubscriptionName

3. Output Parameters
Parameter
Name

Type

Description

TotalCount

Integer

Total number

SubscriptionSet

RequestId

Array of
CmqSubscription

StringSet of subscription attributes
Note: this field may return null, indicating that no valid values can beobtained.
The unique request ID, which is returned for each request. RequestId
is required for locating a problem.

4. Example
Example1 Querying subscription details
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeCmqSubscriptionDetail&TopicName=Conn&<Common request parameters>

Output Example{"Response": {"TotalCount": 1,"SubscriptionSet": [{"SubscriptionName": "ConnSub","SubscriptionId": "subsc-8y7fn4t2","TopicOwner": 0,"MsgCount": 0,"LastModifyTime": 1590632987,"CreateTime": 1590632987,"BindingKey": null,"Endpoint": "test1",©2013-2022 Tencent Cloud. All rights reserved.

Page 207 of 450

TDMQ for Apache Pulsar"FilterTags": [],"Protocol": "queue","NotifyStrategy": "EXPONENTIAL_DECAY_RETRY","NotifyContentFormat": "SIMPLIFIED"}],"RequestId": "72cd2d9d-d666-45ad-963a-cf5065a1984c"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation.CmqBackendError

CMQ backend error.

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 208 of 450

TDMQ for Apache Pulsar

DescribeCmqQueues：

Last updated 2023-08-09 14:43:35

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query all CMQ queues.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Common Params. The value used for this API:
DescribeCmqQueues.

Starting position of a queue list to be returned on the current
OffsetNo

Integerpage in case of paginated return. If a value is entered,limit must be specified. If this parameter is left empty, 0
will be used by default.
The number of queues to be returned per page in case of

Limit

No

Integerpaginated return. If this parameter is not passed in, 20 will be
used by default. Maximum value: 50.

QueueName

No

QueueNameList.N

No

StringArray of
String©2013-2022 Tencent Cloud. All rights reserved.

Filter by QueueName
Filter by CMQ queue name.

Page 209 of 450

TDMQ for Apache Pulsar

IsTagFilter

No

Filters.N

No

BooleanArray ofFilterFor filtering by tag, this parameter must be set to true .
Filter. Currently, you can filter by tag. The tag name must be
prefixed with “tag:”, such as “tag: owner”, “tag: environment”,
or “tag: business”.

3. Output Parameters
Parameter
Name
TotalCount

QueueList

RequestId

Type

Description

Integer

The number of queues.

Array ofQueue list.
Note: This field may return null, indicating that no valid values can be

CmqQueue

Stringobtained.
The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Enumerating queues (without distinguishing between users)
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeCmqQueues<Common request parameters>{"Limit": 1,"Offset": "0"}

Output Example{"Response": {©2013-2022 Tencent Cloud. All rights reserved.

Page 210 of 450

TDMQ for Apache Pulsar"TotalCount": 2005,"QueueList": [{"Tags": [],"QueueId": "queue-6zs45b15","QueueName": "QTA-5cd25c1e-5c7c-11ea-b510-460d8830b47a","CreateUin": 100002742997,"Qps": 5000,"Bps": 52428800,"MaxDelaySeconds": 3600,"MaxMsgHeapNum": 10000000,"PollingWaitSeconds": 0,"MsgRetentionSeconds": 345600,"VisibilityTimeout": 30,"MaxMsgSize": 65536,"RewindSeconds": 43200,"CreateTime": 1583149980,"LastModifyTime": 1583149980,"Transaction": false,"DeadLetterSource": [],"DeadLetterPolicy": [],"TransactionPolicy": [],"ActiveMsgNum": 0,"InactiveMsgNum": 0,"DelayMsgNum": 0,"RewindMsgNum": 0,"MinMsgTime": 0}],"RequestId": "6bab9048-bc14-4142-80c6-3ec119729bed"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go©2013-2022 Tencent Cloud. All rights reserved.

Page 211 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 212 of 450

TDMQ for Apache Pulsar

DescribeCmqQueueDetail：

Last updated 2023-04-18 14:53:18

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the details of a CMQ queue.
A maximum of 100 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

QueueName

Yes

StringExact match by QueueName

Name

Description
Common Params. The value used for this API:
DescribeCmqQueueDetail.

3. Output Parameters
Parameter
Name
QueueDescribeType

Description

CmqQueue

List of queue details.

©2013-2022 Tencent Cloud. All rights reserved.

Page 213 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Obtaining CMQ queue details
This example shows you how to obtain the queue details.
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeCmqQueueDetail&QueueName=cmq-xxx&<Common request parameters>

Output Example{"Response": {"QueueDescribe": {"QueueId": "abc","QueueName": "abc","Qps": 1,"Bps": 1,"MaxDelaySeconds": 1,"MaxMsgHeapNum": 1,"PollingWaitSeconds": 1,"MsgRetentionSeconds": 1,"VisibilityTimeout": 1,"MaxMsgSize": 1,"RewindSeconds": 1,"CreateTime": 1,"LastModifyTime": 1,"ActiveMsgNum": 1,"InactiveMsgNum": 1,"DelayMsgNum": 1,"RewindMsgNum": 1,"MinMsgTime": 1,"Transaction": true,"DeadLetterSource": [{"QueueId": "abc","QueueName": "abc"}©2013-2022 Tencent Cloud. All rights reserved.

Page 214 of 450

TDMQ for Apache Pulsar],"DeadLetterPolicy": {"DeadLetterQueue": "abc","Policy": 1,"MaxTimeToLive": 1,"MaxReceiveCount": 1},"TransactionPolicy": {"FirstQueryInterval": 1,"MaxQueryCount": 1},"CreateUin": 1,"Tags": null,"Trace": true,"TenantId": "abc","NamespaceName": "abc","Status": 0,"MaxUnackedMsgNum": 0,"MaxMsgBacklogSize": 0,"RetentionSizeInMB": 1},"RequestId": "abc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 215 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 216 of 450

TDMQ for Apache Pulsar

DescribeCmqDeadLetterSourceQueues：

Last updated 2023-08-09 14:43:35

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to enumerate the source queues of a CMQ dead letter queue.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringRegionNo

StringDeadLetterQueueName

Yes

StringDescription
Common Params. The value used for this API:
DescribeCmqDeadLetterSourceQueues.
Common Params. The value used for this API: 2020-02-17.
Common Params. This parameter is not required for thisAPI.
Dead letter queue nameStarting position of the list of topics to be returned on the

Limit

No

Integercurrent page in case of paginated return. If a value isentered, limit is required. If this parameter is left
empty, 0 will be used by default.
Number of topics to be returned per page in case of

OffsetNo

Integerpaginated return. If this parameter is not passed in, 20 will
be used by default. Maximum value: 50.

©2013-2022 Tencent Cloud. All rights reserved.

Page 217 of 450

TDMQ for Apache Pulsar

SourceQueueName

No

StringFilter by SourceQueueName

3. Output Parameters
Parameter
Name

Type

Description

TotalCount

IntegerNumber of eligible queues

QueueSet

RequestId

Array of
CmqDeadLetterSource
StringSource queues of dead letter queue
The unique request ID, which is returned for each request. RequestId
is required for locating a problem.

4. Example
Example1 Enumerating the source queues of dead letter queue
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeCmqDeadLetterSourceQueues&DeadLetterQueueName=test123&<Common request parameters>

Output Example{"Response": {"QueueSet": [{"QueueName": "test","QueueId": "queue-kc7m75to"}],"TotalCount": 1,"RequestId": "83fce81a-7305-49b4-a154-983dd76204da"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 218 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code
There is no error code related to the API business logic. For other error codes, please see Common Error Codes.

©2013-2022 Tencent Cloud. All rights reserved.

Page 219 of 450

TDMQ for Apache Pulsar

DeleteCmqTopic：

Last updated 2023-08-09 14:43:36

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a CMQ topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DeleteCmqTopic.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.
Topic name, which must be unique under the same account in the same

TopicName

Yes

Stringregion. It can contain up to 64 letters, digits, and hyphens and must
begin with a letter.

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 220 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting a topic
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteCmqTopic&TopicName=ConnTopic&<Common request parameters>

Output Example{"Response": {"RequestId": "96b28b30-393a-48aa-9f00-07dbe6d86229"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 221 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.DeleteCluster

Failed to delete the cluster.

ResourceNotFound.Topic

The topic does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 222 of 450

TDMQ for Apache Pulsar

DeleteCmqSubscribe：

Last updated 2023-08-09 14:43:36

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a CMQ subscription.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Common Params. The value used for this API:
DeleteCmqSubscribe.

Topic name, which must be unique under the same account in the
TopicName

Yes

Stringsame region. It can contain up to 64 letters, digits, and hyphensand must begin with a letter.
Subscription name, which must be unique in the same topic under

SubscriptionName

Yes

Stringthe same account in the same region. It can contain up to 64
letters, digits, and hyphens and must begin with a letter.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 223 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

Name
RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting subscription
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteCmqSubscribe&TopicName=ConnTopic&SubscriptionName=york&<Common request parameters>

Output Example{"Response": {"RequestId": "f8efab10-0ac6-44cf-8d09-67bb228deaf4"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++©2013-2022 Tencent Cloud. All rights reserved.

Page 224 of 450

TDMQ for Apache Pulsar

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.DeleteSubscriptions

Failed to delete the subscription.

FailedOperation.DeleteTopics

Failed to delete the topic.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Topic

The topic does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 225 of 450

TDMQ for Apache Pulsar

DeleteCmqQueue：

Last updated 2023-08-09 14:43:36

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a CMQ queue.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DeleteCmqQueue.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.
Queue name, which must be unique under the same account in theQueueName

Yes

Stringsame region. It can contain up to 64 letters, digits, and hyphens andmust begin with a letter.

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 226 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting a queue
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteCmqQueue&QueueName=test&<Common request parameters>

Output Example{"Response": {"RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 227 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.DeleteCluster

Failed to delete the cluster.

FailedOperation.DeleteTopics

Failed to delete the topic.

ResourceNotFoundThe resource does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 228 of 450

TDMQ for Apache Pulsar

CreateCmqTopic：

Last updated 2023-08-09 14:43:36

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a CMQ topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringRegionNo

StringTopicName

Yes

StringDescription
Common Params. The value used for this API:
CreateCmqTopic.
Common Params. The value used for this API: 2020-02-17.
Common Params. This parameter is not required for thisAPI.
Topic name, which must be unique in the same topic under
the same account in the same region. It can contain up to
64 letters, digits, and hyphens and must begin with a letter.
Maximum message length. Value range: 1024–65536

MaxMsgSize

No

Integer

FilterType

No

Integer

Used to specify the message match policy for the topic. 1:
tag match policy (default value); 2: routing match policy.

MsgRetentionSeconds

No

Integer

Message retention period. Value range: 60–86400 seconds©2013-2022 Tencent Cloud. All rights reserved.

bytes (i.e., 1–64 KB). Default value: 65536.

Page 229 of 450

TDMQ for Apache Pulsar(i.e., 1 minute–1 day). Default value: 86400.
Trace

No

Tags.NNo

BooleanArray of
Tag

Whether to enable message trace. true: yes; false: no. If
this field is left empty, the feature will not be enabled.
Tag array.

3. Output Parameters
Parameter
Name

Type

Description

TopicId

StringTopic ID

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a topic
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateCmqTopic<Common request parameters>{"TopicName": "ConnTopic"}

Output Example{"Response": {"TopicId": "topic-gzz05csc","RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 230 of 450

TDMQ for Apache Pulsar

Example2 Sample
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateCmqTopic<Common request parameters>{"TopicName": "testtopic"}

Output Example{"Response": {"RequestId": "ae412902-bb35-4237-955d-3e1f9901e0cc","TopicId": "cmqt-7jwedr3jqb54"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 231 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.CreateCluster

Failed to create the cluster.

FailedOperation.CreateTopic

Failed to create the topic.

FailedOperation.SetRetentionPolicy

Failed to set the message retention policy.

FailedOperation.SetTTL

Failed to configure the message TTL.

InternalError.BrokerService

The broker service is exceptional.

LimitExceeded.Topics

The number of topics under the instance exceeds the limit.

ResourceInUse

The resource is in use.

ResourceInUse.Topic

A topic with the same name already exists.

ResourceNotFound.Environment

The environment does not exist.

ResourceUnavailable

The resource is unavailable.

ResourceUnavailable.CreateFailed

Assignment exception.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 232 of 450

TDMQ for Apache Pulsar

CreateCmqSubscribe：

Last updated 2023-08-09 14:43:36

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a CMQ subscription.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

StringTopic name, which must be unique in the same topic under thesame account in the same region. It can contain up to 64

TopicName

Yes

Description
Common Params. The value used for this API:
CreateCmqSubscribe.

letters, digits, and hyphens and must begin with a letter.
Subscription name, which must be unique in the same topic
SubscriptionName

Yes

Stringunder the same account in the same region. It can contain up to
64 letters, digits, and hyphens and must begin with a letter.

ProtocolYes

StringSubscription protocol. Currently, two protocols are supported:
HTTP and queue. To use the HTTP protocol, you need to build
your own web server to receive messages. With the queue©2013-2022 Tencent Cloud. All rights reserved.

Page 233 of 450

TDMQ for Apache Pulsar

protocol, messages are automatically pushed to a CMQ queueand you can pull them concurrently.
Endpoint for notification receipt, which is distinguished byProtocol . For http , Endpoint must begin with
http:// and host can be a domain name or IP. For
Endpoint

Yes

StringQueue , enter QueueName . Note that currently the push
service cannot push messages to a VPC; therefore, if a VPC
domain name or address is entered for Endpoint , pushed
messages will not be received. Currently, messages can be
pushed only to the public network and classic network.
CMQ push server retry policy in case an error occurs while
pushing a message to Endpoint . Valid values: 1.
BACKOFF_RETRY: backoff retry, which is to retry at a fixedinterval, discard the message after a certain number of retries,
and continue to push the next message; 2.

NotifyStrategy

No

StringEXPONENTIAL_DECAY_RETRY: exponential decay retry,
which is to retry at an exponentially increasing interval, such as
1s, 2s, 4s, 8s, and so on. As a message can be retained in a
topic for one day, failed messages will be discarded at mostafter one day of retry. Default value:
EXPONENTIAL_DECAY_RETRY.
Message body tag (used for message filtering). The number oftags cannot exceed 5, and each tag can contain up to 16
characters. It is used in conjunction with the MsgTagparameter of (Batch)PublishMessage . Rules: 1. If
FilterTag is not configured, no matter whether MsgTagis configured, the subscription will receive all messages
published to the topic; 2. If the array of FilterTag values

FilterTag.N

No

Array
of

has a value, only when at least one of the values in the arrayalso exists in the array of MsgTag values (i.e.,

StringFilterTag and MsgTag have an intersection) can thesubscription receive messages published to the topic; 3. If thearray of FilterTag values has a value, but MsgTag is
not configured, then no message published to the topic will bereceived, which can be considered as a special case of rule 2
as FilterTag and MsgTag do not intersect in this case.
The overall design idea of rules is based on the intention of thesubscriber.

BindingKey.N

No

Array

The number of BindingKey cannot exceed 5, and theofStringlength of each BindingKey cannot exceed 64 bytes. This

©2013-2022 Tencent Cloud. All rights reserved.

field indicates the filtering policy for subscribing to andPage 234 of 450

TDMQ for Apache Pulsar

receiving messages. Each BindingKey includes up to 15
dots (namely up to 16 segments).
Push content format. Valid values: 1. JSON; 2. SIMPLIFIED,
NotifyContentFormat

No

Stringi.e., the raw format. If Protocol is queue , this value
must be SIMPLIFIED . If Protocol is http , both
options are acceptable, and the default value is JSON .

3. Output Parameters
Parameter

Type

Description

SubscriptionId

StringSubscription ID

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating subscription
Input Example
https://tdmq.tencentcloudapi.com/?Action=CreateCmqSubscribe&TopicName=ConnTopic&SubscriptionName=ConnSubQueue&Protocol=queue&Endpoint=queue_sub&<Common request parameters>

Output Example{"Response": {"SubscriptionId": "subsc-39gyuuhd","RequestId": "1620b635-6071-47c7-ac1e-975afe5104a7"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 235 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.CreateSubscription

Failed to create the subscription.

FailedOperation.CreateTopic

Failed to create the topic.

ResourceInUse

The resource is in use.

ResourceInUse.Subscription

A subscription with the same name already exists.

ResourceUnavailable

The resource is unavailable.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 236 of 450

TDMQ for Apache Pulsar

CreateCmqQueue：

Last updated 2023-08-09 14:43:37

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a CMQ queue.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringRegionNo

StringDescription
Common Params. The value used for this API:
CreateCmqQueue.
Common Params. The value used for this API: 2020-0217.
Common Params. This parameter is not required for thisAPI.
Queue name, which is unique under the same account inQueueName

Yes

Stringa single region. It is a string of up to 64 characters. It cancontain letters, digits, and hyphens (-) and must start witha letter.

MaxMsgHeapNum

No

IntegerMaximum number of heaped messages. The value range
is 1,000,000–10,000,000 during the beta test and can be
1,000,000–1,000,000,000 after the product is officiallyreleased. The default value is 10,000,000 during the beta

©2013-2022 Tencent Cloud. All rights reserved.

Page 237 of 450

TDMQ for Apache Pulsar

test and will be 100,000,000 after the product is officiallyreleased.
PollingWaitSeconds

No

Integer

VisibilityTimeout

No

IntegerMaxMsgSize

No

IntegerLong polling wait time for message reception. Value
range: 0–30 seconds. Default value: 0.
Message visibility timeout period. Value range: 1–43200
seconds (i.e., 12 hours). Default value: 30.
Maximum message length. Value range: 1024–65536
bytes (i.e., 1–64 KB). Default value: 65536.
The max period during which a message is retained

MsgRetentionSeconds

No

Integer

before it is automatically acknowledged. Value range: 3043,200 seconds (30 seconds to 12 hours). Default value:
3600 seconds (1 hour).
Rewindable time of messages in the queue. Value range:

RewindSeconds

No

Integer

0-1,296,000s (if message rewind is enabled). The value“0” indicates that message rewind is not enabled.

Transaction

No

Integer

1: transaction queue; 0: general queueFirstQueryInterval

No

IntegerFirst lookback interval

MaxQueryCountNo

IntegerMaximum number of lookbacks

DeadLetterQueueName

No

StringDead letter queue nameDead letter policy. 0: message has been consumed

PolicyNo

Integer

multiple times but not deleted; 1: Time-To-Live has
elapsedMaxReceiveCountNo

IntegerMaximum receipt times. Value range: 1–1000
Maximum period in seconds before an unconsumed
message expires, which is required if policy is 1.

MaxTimeToLive

No

Integer

Value range: 300–43200. This value should be smaller
than msgRetentionSeconds (maximum message
retention period)

Trace

No

Tags.NNo

RetentionSizeInMB

No

BooleanArray of
Tag
Integer©2013-2022 Tencent Cloud. All rights reserved.

Whether to enable message trace. true: yes; false: no. If
this field is not configured, the feature will not be enabled
Tag array.
Queue storage space configured for message rewind.

Page 238 of 450

TDMQ for Apache Pulsar

Value range: 10,240-512,000 MB (if message rewind isenabled). The value “0” indicates that message rewind is
not enabled.

3. Output Parameters
Parameter

Type

Description

QueueId

StringqueueId of a successfully created queue

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a queueThis example shows you how to create a queue.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateCmqQueue<Common request parameters>{"QueueName": "test"}

Output Example{"Response": {"QueueId": "queue-ges05csc","RequestId": "3e0dff9d-9ed5-47c3-beb2-a42c1d69e1cc"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 239 of 450

TDMQ for Apache Pulsar

Example2 Creating a queueThis example shows you how to create a queue.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateCmqQueue<Common request parameters>{"QueueName": "test789"}

Output Example{"Response": {"RequestId": "864b1295-ed7e-45ed-9602-be53ac23177b","QueueId": "cmqq-rd42drdeaag9"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 240 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.CreateCluster

Failed to create the cluster.

FailedOperation.CreateTopic

Failed to create the topic.

FailedOperation.SetRetentionPolicy

Failed to set the message retention policy.

FailedOperation.SetTTL

Failed to configure the message TTL.

InternalError.BrokerService

The broker service is exceptional.

ResourceInUse

The resource is in use.

ResourceInUse.Queue

The queue already exists.

ResourceNotFound.Environment

The environment does not exist.

ResourceUnavailable

The resource is unavailable.

ResourceUnavailable.CreateFailed

Assignment exception.

ResourceUnavailable.FundRequired

You must top up before proceeding.

UnsupportedOperation

Unsupported operation.

©2013-2022 Tencent Cloud. All rights reserved.

Page 241 of 450

TDMQ for Apache Pulsar

Other APIs
SendRocketMQMessage：

Last updated 2023-08-09 14:43:26

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This document is used to send a TDMQ for RocketMQ message.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

NamespaceId

YesStringNamespace ID

TopicName

Yes

StringTopic name

MsgBody

Yes

StringMessage content

MsgKeyNo

StringMessage key

Name©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
SendRocketMQMessage.

Page 242 of 450

TDMQ for Apache Pulsar

MsgTagNo

StringMessage tag

3. Output Parameters
Parameter
Name
Result

MsgId

Type

Description

BooleanMessage sending result

StringMessage ID
Note: u200dThis field may return null, indicating that no valid values can beobtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Sending a TDMQ for RocketMQ message
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: SendRocketMQMessage<Common request parameters>{"NamespaceId": "xx","ClusterId": "xx","TopicName": "xx","MsgKey": "xx","MsgTag": "xx","MsgBody": "xx"}

Output Example{"Response": {©2013-2022 Tencent Cloud. All rights reserved.

Page 243 of 450

TDMQ for Apache Pulsar"RequestId": "xx","Result": true,"MsgId": "7F0000013AEC18B4AAC278B640D30002"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 244 of 450

TDMQ for Apache Pulsar

DescribeBindVpcs：

Last updated 2023-08-09 14:43:27

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the tenant-VPC binding relationship.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DescribeBindVpcs.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

OffsetNo

Integer

Offset. If this parameter is left empty, 0 will be used by default.

Limit

No

IntegerNumber of results to be returned. If this parameter is left empty, 10 will
be used by default. The maximum value is 20.

ClusterId

No

StringPulsar cluster ID

Name

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 245 of 450

TDMQ for Apache Pulsar

Parameter
Name

Type

Description

TotalCount

IntegerNumber of records.

VpcSets

RequestId

Array of
VpcBindRecord
StringSet of VPCs.
The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Getting the tenant-VPC binding relationship
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeBindVpcs&ClusterId=pulsar-xxxxxxxx&<Common request parameters>

Output Example{"Response": {"VpcSets": [{"UniqueVpcId": "vpc-c96rbu5r","UniqueSubnetId": "subnet-hiqrqjp6","RouterId": "pulsar-xxxxxxxx/vpc-c96rbu5r/subnet-hiqrqjp6","Ip": "192.168.0.1","Port": 6000,"Remark": ""}],"TotalCount": 1,"RequestId": "b9765efb-62dd-4946-b2bd-61e958c0f7a7"}}

5. Developer Resources©2013-2022 Tencent Cloud. All rights reserved.

Page 246 of 450

TDMQ for Apache Pulsar

SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

InvalidParameterValue.NeedMoreParams

A required parameter is missing.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 247 of 450

TDMQ for Apache Pulsar

SendMsg：

Last updated 2023-08-09 14:43:26

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to test message sending. It cannot be used in the production environment.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: SendMsg.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

StringTopic name. If the topic is a partitioned topic, you need to specify thepartition; otherwise, messages will be sent to partition 0 by default,

Name

TopicNameYessuch as my_topic-partition-0 .
MsgContent

Yes

StringClusterId

No

String©2013-2022 Tencent Cloud. All rights reserved.

Message content, which cannot be empty and can contain up to
5,242,880 bytes.
Pulsar cluster ID

Page 248 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name
RequestId

Type

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Sending one message
Input Example
https://tdmq.tencentcloudapi.com/?Action=SendMsg&EnvironmentId=default&TopicName=cloud_test&MsgContent=one_msg&<Common request parameters>

Output Example{"Response": {"RequestId": "3593f784-fcfb-4f23-b3dd-4751cba3aec7"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go©2013-2022 Tencent Cloud. All rights reserved.

Page 249 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.GetTopicPartitionsFailed

Failed to get the number of topic partitions.

FailedOperation.SendMsgFailed

Failed to send the message.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Topic

The topic does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 250 of 450

TDMQ for Apache Pulsar

Environment Role APIs
ModifyRole：

Last updated 2023-08-09 14:43:29

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify a role.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: ModifyRole.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

RoleName

Yes

StringRemarkNo

StringRemarks (up to 128 characters).

ClusterId

No

StringCluster ID (required)

Name

Role name, which can contain up to 32 letters, digits, hyphens, andunderscores.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 251 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

RoleName

StringRole name

RemarkStringRemarks

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Updating role
Input Example
https://tdmq.tencentcloudapi.com/?Action=ModifyRole&RoleName=test_role&Remark=Update role&<Common request parameters>

Output Example{"Response": {"RoleName": "test_role","Remark": "Remark1","RequestId": "gggxxxx"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP©2013-2022 Tencent Cloud. All rights reserved.

Page 252 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation.UpdateRole

Failed to update the role.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Role

The role does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 253 of 450

TDMQ for Apache Pulsar

ModifyEnvironmentRole：

Last updated 2023-08-09 14:43:29

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify an environment role.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

RoleName

Yes

StringRole name.

Permissions.N

Yes

Array of
StringPermissions, which is a non-empty string array of produce

ClusterId

No

StringCluster ID (required)Name©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
ModifyEnvironmentRole.

and consume at the most.

Page 254 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name
RequestId

Type

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying environment role
Input Example
https://tdmq.tencentcloudapi.com/?Action=ModifyEnvironmentRole&RoleName=test_role&EnvironmentId=default&Permissions.0=produce&Permissions.1=consume&<Common request parameters>

Output Example{"Response": {"RequestId": "gggxxxx"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go©2013-2022 Tencent Cloud. All rights reserved.

Page 255 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.UpdateEnvironmentRole

Failed to update the environment role.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.EnvironmentRole

The environment role does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 256 of 450

TDMQ for Apache Pulsar

DescribeRoles：

Last updated 2023-08-09 14:43:30

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of roles.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DescribeRoles.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

RoleName

No

StringFuzzy query by role nameOffsetNo

Integer

Offset. If this parameter is left empty, 0 will be used by default.

Limit

No

Integer

ClusterId

No

StringCluster ID (required)

Filters.N

No

Array

* RoleNameof

Filter by role name for exact query.

Number of results to be returned. If this parameter is left empty, 10 will
be used by default. The maximum value is 20.

Filter©2013-2022 Tencent Cloud. All rights reserved.

Page 257 of 450

TDMQ for Apache Pulsar

Type: String
Required: no3. Output Parameters
Parameter

Type

Description

TotalCount

IntegerNumber of records.

RoleSets

Array of
Role

Array of roles.

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Getting the list of roles
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeRoles&Offset=0&Limit=10&<Common request parameters>

Output Example{"Response": {"TotalCount": 4,"RoleSets": [{"RoleName": "test_role_3","Token": "xxx.eyJzdWIiOiJ0ZXN0X3JvbGVfMyJ9.dbHR8m6gc4L4vZUrodhW_O9bDulZQ6lraNswNL
tcUcY","Remark": "","CreateTime": "2020-08-04 11:59:06","UpdateTime": "2020-08-04 11:59:06"},©2013-2022 Tencent Cloud. All rights reserved.

Page 258 of 450

TDMQ for Apache Pulsar{"RoleName": "test_role_2","Token": "xxx.eyJzdWIiOiJ0ZXN0X3JvbGVfMiJ9.KTbLPg1ax2HDa51vfWmoDK5AQRmEs-_3da8yU0
O61D0","Remark": "","CreateTime": "2020-08-03 20:23:52","UpdateTime": "2020-08-03 20:23:52"},{"RoleName": "test_role_1","Token": "xxx.eyJzdWIiOiJ0ZXN0X3JvbGVfMSJ9.aatGv_WEZK5jqmXNX3dxQA7vWB0igKr_7eQitb
weBoo","Remark": "","CreateTime": "2020-08-03 19:48:36","UpdateTime": "2020-08-03 20:22:21"},{"RoleName": "test_role","Token": "xxxx.eyJzdWIiOiJ0ZXN0X3JvbGUifQ.xeU_xkiB5wSJ8u6sUJWW","Remark": "Remark1","CreateTime": "2020-08-03 17:22:09","UpdateTime": "2020-08-04 15:59:29"}],"RequestId": "gggxxxx"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++©2013-2022 Tencent Cloud. All rights reserved.

Page 259 of 450

TDMQ for Apache Pulsar

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 260 of 450

TDMQ for Apache Pulsar

DeleteEnvironmentRoles：

Last updated 2023-08-09 14:43:30

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete an environment role.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

RoleNames.N

Yes

ClusterId

No

Name

Array of
StringStringDescription
Common Params. The value used for this API:
DeleteEnvironmentRoles.

Array of role names.
Cluster ID (required)

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 261 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

Name
RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting environment role
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteEnvironmentRoles&EnvironmentId=default&RoleNames.0=test_role&<Common request parameters>

Output Example{"Response": {"RequestId": "gggxxxx"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++©2013-2022 Tencent Cloud. All rights reserved.

Page 262 of 450

TDMQ for Apache Pulsar

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.DeleteEnvironmentRoles

Failed to delete the environment role.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.EnvironmentRole

The environment role does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 263 of 450

TDMQ for Apache Pulsar

CreateRole：

Last updated 2023-08-09 14:43:30

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a role.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: CreateRole.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

RoleName

Yes

StringRemarkNo

StringRemarks (up to 128 characters).

ClusterId

No

StringCluster ID (required)

Name

Role name, which can contain up to 32 letters, digits, hyphens, andunderscores.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 264 of 450

TDMQ for Apache Pulsar

Parameter NameType

Description

RoleName

StringRole name

Token

StringRole token
Remarks

RemarkStringNote: this field may return null, indicating that no valid values
can be obtained.

EnvironmentRoleSets

RequestId

Array ofEnvironmentRoleSet

StringNamespaces that are bound in batches
Note: u200dThis field may return null, indicating that no valid
values can be obtained.
The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 Creating a role
This example shows you how to create a role.
Input Example
https://tdmq.tencentcloudapi.com/?Action=CreateRole&RoleName=test_role_123&Remark=Creating a role&<Common request parameters>

Output Example{"Response": {"RoleName": "abc","Token": "abc","Remark": "abc","EnvironmentRoleSets": [{"EnvironmentId": "abc","Permissions": [
"abc"
]
}
],

©2013-2022 Tencent Cloud. All rights reserved.

Page 265 of 450

TDMQ for Apache Pulsar"RequestId": "abc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.CreateRole

Failed to create the role.

FailedOperation.CreateSecretKey

Failed to create the key.

FailedOperation.SaveSecretKey

Failed to save the key.

InternalError.SystemError

System error.

©2013-2022 Tencent Cloud. All rights reserved.

Page 266 of 450

TDMQ for Apache Pulsar

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceInUse.Role

The role already exists.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 267 of 450

TDMQ for Apache Pulsar

CreateEnvironmentRole：

Last updated 2023-08-09 14:43:30

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create an environment role.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
CreateEnvironmentRole.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringEnvironment (namespace) name.

RoleName

Yes

StringRole name.

Permissions.N

Yes

Array of

Permissions, which is a non-empty string array of produce

Stringand consume at the most.

ClusterId

No

StringCluster ID (required)Name©2013-2022 Tencent Cloud. All rights reserved.

Page 268 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name
RequestId

Type

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating environment role
Input Example
https://tdmq.tencentcloudapi.com/?Action=CreateEnvironmentRole&RoleName=test_role_1&EnvironmentId=default&Permissions.0=produce&<Common request parameters>

Output Example{"Response": {"RequestId": "gggxxxx"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go©2013-2022 Tencent Cloud. All rights reserved.

Page 269 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.CreateEnvironmentRole

Failed to create the environment role.

FailedOperation.UpdateEnvironmentRole

Failed to update the environment role.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceInUse

The resource is in use.

ResourceInUse.EnvironmentRole

The environment role already exists.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

ResourceNotFound.Role

The role does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 270 of 450

TDMQ for Apache Pulsar

DeleteRoles：

Last updated 2023-08-09 14:43:30

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete one or multiple roles.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API: DeleteRoles.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringRoleNames.N

Yes

ClusterId

No

Name

Array of
StringStringCommon Params. This parameter is not required for thisAPI.
Array of role names.
Cluster ID (required)

3. Output Parameters
Parameter

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 271 of 450

TDMQ for Apache Pulsar

Name
RoleNames

RequestId

Array of
StringStringName array of roles successfully deleted.
The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Deleting role
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteRoles&RoleNames.0=test_role_1&RoleNames.1=test_role_2&<Common request parameters>

Output Example{"Response": {"RoleNames": ["test_role_1","test_role_2"],"RequestId": "gggxxxx"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP©2013-2022 Tencent Cloud. All rights reserved.

Page 272 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.DeleteRoles

Failed to delete the role.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceInUse.EnvironmentRole

The environment role already exists.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Role

The role does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 273 of 450

TDMQ for Apache Pulsar

TDMQ for RabbitMQ APIs
CreateRabbitMQUser：

Last updated 2023-08-09 14:43:21

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a TDMQ for RabbitMQ user.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

User

Yes

StringUsername, which is used for login.

Password

Yes

StringPassword, which is used for login.

Description

No

StringDescription

Tags.NNo

Array

User tag, which defines a user's permission scope for accessing

Name©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
CreateRabbitMQUser.

Page 274 of 450

TDMQ for Apache PulsarofRabbitMQ Managementu200d.

StringValid values: management (Common console user),monitoring` (Console admin user), other values: Non-console user.

MaxConnections

No

Integer

MaxChannels

No

Integer

The maximum number of connections for the user. If thisparameter is left empty, there's no limit for the number.
The maximum number of channels for the user. If this parameter isleft empty, there's no limit for the number.

3. Output Parameters
Parameter

Type

Description

User

StringUsername, which is used for login.

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a TDMQ for RabbitMQ user
u200dThis example shows you how to create a TDMQ for RabbitMQ user.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRabbitMQUser<Common request parameters>{"InstanceId": "amqp-44w9928j","User": "test_user","Password": "abc123"}

Output Example©2013-2022 Tencent Cloud. All rights reserved.

Page 275 of 450

TDMQ for Apache Pulsar{"Response": {"RequestId": "dsfsdfs","User": "test_user"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

©2013-2022 Tencent Cloud. All rights reserved.

Page 276 of 450

TDMQ for Apache Pulsar

CreateRabbitMQVirtualHost：

Last updated 2023-08-09 14:43:20

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a TDMQ for RabbitMQ vhost.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
CreateRabbitMQVirtualHost.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

VirtualHost

Yes

StringVhost name

Description

No

StringDescription

TraceFlag

No

BooleanName

Message trace flag. Valid values: true (Enabled), false(Disabled, which is the default value).

©2013-2022 Tencent Cloud. All rights reserved.

Page 277 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter

Type

Description

VirtualHost

StringVhost name

RequestId

StringName

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a TDMQ for RabbitMQ vhost
u200dThis example shows you how to create a TDMQ for RabbitMQ vhost.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateRabbitMQVirtualHost<Common request parameters>{"InstanceId": "amqp-44w9928j","VirtualHost": "testVhost","Description": "hello"}

Output Example{"Response": {"RequestId": "dsfsdfs","VirtualHost": "testVhost"}}

5. Developer Resources©2013-2022 Tencent Cloud. All rights reserved.

Page 278 of 450

TDMQ for Apache Pulsar

SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

©2013-2022 Tencent Cloud. All rights reserved.

Page 279 of 450

TDMQ for Apache Pulsar

DeleteRabbitMQUser：

Last updated 2023-08-09 14:43:20

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a TDMQ for RabbitMQ user.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DeleteRabbitMQUser.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

User

Yes

StringUsername, which is used for login.

Name

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 280 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting a TDMQ for RabbitMQ user
u200dThis example shows you how to delete a TDMQ for RabbitMQ user.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DeleteRabbitMQUser<Common request parameters>{"InstanceId": "amqp-xxx","User": "test_user"}

Output Example{"Response": {"RequestId": "dsfsdfs"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go©2013-2022 Tencent Cloud. All rights reserved.

Page 281 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 282 of 450

TDMQ for Apache Pulsar

DeleteRabbitMQVirtualHost：

Last updated 2023-08-09 14:43:20

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a TDMQ for RabbitMQ vhost.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DeleteRabbitMQVirtualHost.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

VirtualHost

Yes

StringVhost nameName

3. Output Parameters
Parameter
Name

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 283 of 450

TDMQ for Apache Pulsar

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting a TDMQ for RabbitMQ vhost
u200dThis example shows you how to delete a TDMQ for RabbitMQ vhost.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DeleteRabbitMQVirtualHost<Common request parameters>{"InstanceId": "amqp-44w9928j","VirtualHost": "testVhost"}

Output Example{"Response": {"RequestId": "dsfsdfs"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go©2013-2022 Tencent Cloud. All rights reserved.

Page 284 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 285 of 450

TDMQ for Apache Pulsar

DescribeRabbitMQUser：

Last updated 2023-08-09 14:43:20

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of TDMQ for RabbitMQ users.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeRabbitMQUser.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

SearchUser

No

StringUsername search by prefix or suffix

OffsetNo

Integer

Pagination offset

Limit

No

Integer

Pagination limit

User

No

StringUsername, which is queried by exact match.

Tags.NNo

Array of

User tag, which is used to filter users.

Name©2013-2022 Tencent Cloud. All rights reserved.

Page 286 of 450

TDMQ for Apache Pulsar

String

3. Output Parameters
Parameter NameType

Description

TotalCount

Integer

Returned number of users

RabbitMQUserList

Array ofRabbitMQUser

The list of the created TDMQ for RabbitMQ users

RequestId

String

The unique request ID, which is returned for each request. RequestId
is required for locating a problem.

4. Example
Example1 Querying the list of TDMQ for RabbitMQ users
This example shows you how to query the list of TDMQ for RabbitMQ users.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRabbitMQUser<Common request parameters>{"InstanceId": "amqp-44w9928j"}

Output Example{"Response": {"RequestId": "dsfsdfs","RabbitMQUserList": [{"InstanceId": "amqp-xxx","User": "testVhost","Password": "123",©2013-2022 Tencent Cloud. All rights reserved.

Page 287 of 450

TDMQ for Apache Pulsar"Description": "hello","Tags": ["shop"]}],"TotalCount": 1}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

©2013-2022 Tencent Cloud. All rights reserved.

Page 288 of 450

TDMQ for Apache Pulsar

ResourceNotFound©2013-2022 Tencent Cloud. All rights reserved.

The resource does not exist.

Page 289 of 450

TDMQ for Apache Pulsar

DescribeRabbitMQVirtualHost：

Last updated 2023-08-09 14:43:19

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of TDMQ for RabbitMQ vhosts.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

VirtualHost

No

StringVhost name. If this parameter is not specified, all will be queried bydefault.

OffsetNo

Integer

Pagination offset

Limit

No

Integer

Pagination limit

Filters

No

FilterFuzzy query by vhost nameName

©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
DescribeRabbitMQVirtualHost.

Page 290 of 450

TDMQ for Apache Pulsar

SortElement

No

StringSortOrder

No

String

3. Output Parameters
Parameter
Name
TotalCount
VirtualHostList

RequestId

Type

Description

Integer

Returned number of vhosts

Array ofRabbitMQVirtualHostInfo
StringList of vhost details
The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 Querying the list of TDMQ for RabbitMQ vhosts
This example shows you how to query the list of TDMQ for RabbitMQ vhosts.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRabbitMQVhost<Common request parameters>{"InstanceId": "amqp-44w9928j"}

Output Example{"Response": {"RequestId": "dsfsdfs","VirtualHostList": [{©2013-2022 Tencent Cloud. All rights reserved.

Page 291 of 450

TDMQ for Apache Pulsar"InstanceId": "amqp-xxx","VirtualHost": "testVhost","Description": "hello","Tags": ["shop"]}],"TotalCount": 1}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

©2013-2022 Tencent Cloud. All rights reserved.

Page 292 of 450

TDMQ for Apache Pulsar

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 293 of 450

TDMQ for Apache Pulsar

ModifyRabbitMQUser：

Last updated 2023-08-09 14:43:19

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify a TDMQ for RabbitMQ user.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

User

Yes

StringUsername, which is used for login.

Password

Yes

StringPassword, which is used for login.

Description

No

StringDescription. If this parameter is not passed in, it won't be modified.

Array

User tag, which defines a user's permission scope for accessing

Tags.N

No

of
StringRabbitMQ Management. If this parameter is not passed in, it won't
be modified.

Name©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
ModifyRabbitMQUser.

Page 294 of 450

TDMQ for Apache Pulsar

MaxConnections

No

Integer

The maximum number of connections for the user. If thisparameter is not passed in, it won't be modified.

MaxChannels

No

Integer

The maximum number of channels for the user. If this parameter is
not passed in, it won't be modified.

3. Output Parameters
Parameter
Name
RequestId

Type

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying a TDMQ for RabbitMQ user
This example shows you how to modify a TDMQ for RabbitMQ user.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyRabbitMQUser<Common request parameters>{"InstanceId": "amqp-44w9928j","User": "test_user","Password": "123"}

Output Example{"Response": {"RequestId": "dsfsdfs"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 295 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 296 of 450

TDMQ for Apache Pulsar

ModifyRabbitMQVirtualHost：

Last updated 2023-08-09 14:43:19

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify a TDMQ for RabbitMQ vhost.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringCluster instance ID

VirtualHost

Yes

StringVhost name

Description

No

StringDescription

TraceFlag

No

Boolean©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
ModifyRabbitMQVirtualHost.

Message trace flag. Valid values: true (Enabled), false(Disabled).

Page 297 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name
RequestId

Type

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying a TDMQ for RabbitMQ vhost
This example shows you how to modify a TDMQ for RabbitMQ vhost.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyRabbitMQVirtualHost<Common request parameters>{"InstanceId": "amqp-44w9928j","VirtualHost": "testVhost","Description": "hello"}

Output Example{"Response": {"RequestId": "dsfsdfs"}}

5. Developer Resources
SDK©2013-2022 Tencent Cloud. All rights reserved.

Page 298 of 450

TDMQ for Apache Pulsar

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 299 of 450

TDMQ for Apache Pulsar

CreateRabbitMQVipInstance：

Last updated 2023-04-18 14:53:03

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a TDMQ for RabbitMQ exclusive instance.
A maximum of 1 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

ActionYes

String

VersionYes

StringRegionNo

StringZoneIds.N

Yes

VpcId

Yes

String

VPC ID

SubnetId

Yes

String

VPC subnet ID

ClusterName

Yes

StringCluster name

NodeSpec

No

StringNode specification ( rabbit-vip-basic-©2013-2022 Tencent Cloud. All rights reserved.

Array ofInteger

Description
Common Params. The value used for this
API: CreateRabbitMQVipInstance.
Common Params. The value used for this
API: 2020-02-17.
Common Params. This parameter is not
required for this API.
AZ

Page 300 of 450

TDMQ for Apache Pulsar

1 : Basic; rabbit-vip-basic-2 :Standard; rabbit-vip-basic-3 :Advanced I; rabbit-vip-basic-4 :Advanced II). If this parameter is left empty,
the default value is rabbit-vip-basic1 .
Number of nodes, which is at least three formulti-AZ deployment. If this parameter is left
NodeNum

No

Integer

empty, the value will be set to 1 for single-AZ
deployment and 3 for multi-AZ deployment bydefault.

StorageSize

No

Integer

EnableCreateDefaultHaMirrorQueue

No

Boolean

AutoRenewFlag

No

Boolean

TimeSpanNo

Integer

Storage capacity of a single node, which is
200 GB by default.
Whether to enable mirrored queue. Default
value: false .
Whether to enable auto-renewal. Default
value: true .
Validity period, which is one month by default.

3. Output Parameters
Parameter
Name

Type

TranIdString

InstanceId

StringRequestId

StringDescription
Order ID
Note: This field may return null, indicating that no valid values can be obtained.
Instance ID
Note: This field may return null, indicating that no valid values can be obtained.
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a TDMQ for RabbitMQ exclusive instanceThis example shows you how to create a TDMQ for RabbitMQ exclusive instance.

©2013-2022 Tencent Cloud. All rights reserved.

Page 301 of 450

TDMQ for Apache Pulsar

Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateRabbitMQVipInstance<Common request parameters>{"ZoneIds": [190001],"NodeSpec": "rabbit-vip-basic-2","NodeNum": 1,"StorageSize": 100,
"VpcId": "vpc-xxx","SubnetId": "subnet-xxx","ClusterName": "ApiCreate","EnableCreateDefaultHaMirrorQueue": false}

Output Example{"Response": {"RequestId": "sadasfdsfs","TranId": "20230110002025620411234","InstanceId": "amqp-aegnagjg"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS©2013-2022 Tencent Cloud. All rights reserved.

Page 302 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

©2013-2022 Tencent Cloud. All rights reserved.

Page 303 of 450

TDMQ for Apache Pulsar

DeleteRabbitMQVipInstance：

Last updated 2023-08-09 14:43:20

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a TDMQ for RabbitMQ exclusive instance.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

String

Instance ID

Name

Description
Common Params. The value used for this API:
DeleteRabbitMQVipInstance.

3. Output Parameters
Parameter
Name
TranIdType

Description

StringOrder ID©2013-2022 Tencent Cloud. All rights reserved.

Page 304 of 450

TDMQ for Apache Pulsar

Note: u200dThis field may return null, indicating that no valid values can beobtained.
Instance ID
InstanceId

StringNote: u200dThis field may return null, indicating that no valid values can beobtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 u200dDeleting a TDMQ for RabbitMQ instance
u200dThis example shows you how to delete a TDMQ for RabbitMQ instance.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DeleteRabbitMQVipInstance<Common request parameters>{"InstanceId": "amqp-xxxxxxxx"}

Output Example{"Response": {"TranId": "abc","InstanceId": "abc","RequestId": "abc"}}

5. Developer Resources
SDK©2013-2022 Tencent Cloud. All rights reserved.

Page 305 of 450

TDMQ for Apache Pulsar

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

©2013-2022 Tencent Cloud. All rights reserved.

Page 306 of 450

TDMQ for Apache Pulsar

DescribeRabbitMQVipInstances：

Last updated 2023-08-09 14:43:19

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of the purchased TDMQ for RabbitMQ exclusive instances.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Filters.N

No

Limit

No

Integer

The maximum number of queried items, which defaults to 20.

OffsetNo

IntegerStart offset for query

Name

Array ofFilterDescription
Common Params. The value used for this API:
DescribeRabbitMQVipInstances.

Query condition filter

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 307 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

Integer

The total number of unpaginated items

Name
TotalCount
Instances

RequestId

Array ofRabbitMQVipInstanceString

Instance information list
The unique request ID, which is returned for each request. RequestId
is required for locating a problem.

4. Example
Example1 Getting the instance list
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRabbitMQVipInstances<Common request parameters>{"Limit": 1,"Filters": [{"Values": ["xx"],"Name": "xx"}],"Offset": 1}

Output Example{"Response": {"TotalCount": 1,"RequestId": "xx","Instances": [{©2013-2022 Tencent Cloud. All rights reserved.

Page 308 of 450

TDMQ for Apache Pulsar"Status": 1,"PayMode": 1,"Remark": "xx","AutoRenewFlag": 1,"InstanceId": "xx","NodeCount": 1,"ExpireTime": 1,"InstanceVersion": "xx","MaxStorage": 1,"MaxBandWidth": 1,"SpecName": "xx","ConfigDisplay": "xx","InstanceName": "xx","MaxTps": 1}]}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code
There is no error code related to the API business logic. For other error codes, please see Common Error Codes.

©2013-2022 Tencent Cloud. All rights reserved.

Page 309 of 450

TDMQ for Apache Pulsar

RocketMQ APIs
DescribeRocketMQVipInstanceDetail：

Last updated 2023-08-09 14:43:22

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the information of a specific TDMQ for RocketMQ exclusive cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeRocketMQVipInstanceDetail.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

Name

3. Output Parameters
Parameter
Name

Type

©2013-2022 Tencent Cloud. All rights reserved.

Description

Page 310 of 450

TDMQ for Apache Pulsar

ClusterInfo

RocketMQClusterInfo

Cluster information

InstanceConfig

RocketMQInstanceConfig

Cluster configuration

RequestId

String

The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 huo
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRocketMQVipInstanceDetail<Common request parameters>{"ClusterId": "rocketmq-rd3545bkkj49"}

Output Example{"Response": {"RequestId": "c6d158b6-89b2-40d1-b1f6-5973f0f00cd5","ClusterInfo": {"ClusterId": "rocketmq-rd3545bkkj49","ClusterName": "test-example","Region": "ap-beijing","CreateTime": 1620321019000,"SupportNamespaceEndpoint": true,"Remark": "modified","PublicEndPoint": "pulsar://xxxxx.com:6650","Vpcs": [{"SubnetId": "xx","VpcId": "xx"}],"IsVip": true,"RocketMQFlag": true,©2013-2022 Tencent Cloud. All rights reserved.

Page 311 of 450

TDMQ for Apache Pulsar"VpcEndPoint": "pulsar://xxxxx.com:6650"},"InstanceConfig": {"MaxTpsPerNamespace": 8000,"UsedNamespaceNum": 1,"MaxTopicNum": 1000,"UsedTopicNum": 2,"MaxGroupNum": 10000,"UsedGroupNum": 1,"MaxNamespaceNum": 10,"ConfigDisplay": "xx","NodeCount": 2,"NodeDistribution": [],"TopicDistribution": []}}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.

©2013-2022 Tencent Cloud. All rights reserved.

Page 312 of 450

TDMQ for Apache Pulsar

Error CodeDescription

FailedOperation

Operation failed.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Instance

The instance doesn’t exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 313 of 450

TDMQ for Apache Pulsar

DescribeRocketMQMsg：

Last updated 2023-08-09 14:43:22

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the TDMQ for RocketMQ message details.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeRocketMQMsg.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

EnvironmentId

Yes

StringNamespace ID

TopicName

Yes

StringTopic name. Pass in the group ID when querying a dead letter
queue.

MsgId

Yes

StringMessage ID

PulsarMsgId

YesStringID of a TDMQ for Pulsar message

Name©2013-2022 Tencent Cloud. All rights reserved.

Page 314 of 450

TDMQ for Apache Pulsar

QueryDlqMsg

No

Boolean

The value of this parameter is true when you query a deadletter queue. It only applies to TDMQ for RocketMQ.

3. Output Parameters
Parameter NameType

Description

Body

StringMessage body

Properties

String

Details parameter

ProduceTime

StringProduction time

MsgId

StringMessage ID

ProducerAddr

StringProducer address

MessageTracks

ShowTopicName

Array ofRocketMQMessageTrack

StringConsumption details of a consumer group
Note: u200dThis field may return null, indicating that no valid
values can be obtained.
Topic name displayed on the details page
Note: u200dThis field may return null, indicating that no valid
values can be obtained.

RequestId

String

The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 Querying the details of a TDMQ for RocketMQ message
This example shows you how to query the details of a TDMQ for RocketMQ message.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRocketMQMsg<Common request parameters>{©2013-2022 Tencent Cloud. All rights reserved.

Page 315 of 450

TDMQ for Apache Pulsar"EnvironmentId": "xx","ClusterId": "xx","TopicName": "xx","PulsarMsgId": "xx","MsgId": "xx","QueryDlqMsg": false}

Output Example{"Response": {"Body": "xx","MsgId": "xx","ProduceTime": "xx","RequestId": "xx","Properties": "xx","ProducerAddr": "xx","ShowTopicName": "xx","MessageTracks": []}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 316 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 317 of 450

TDMQ for Apache Pulsar

ModifyRocketMQTopic：

Last updated 2023-08-09 14:43:21

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to update a RocketMQ topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

NamespaceId

YesStringNamespace name

Topic

Yes

StringTopic name

RemarkYes

StringRemarks (up to 128 characters)

PartitionNum

No

Integer©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
ModifyRocketMQTopic.

Number of partitions, which is invalid for globally sequential
messages and cannot be less than the current number of partitions.

Page 318 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name
RequestId

Type

Description

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying topic
Input Example
https://tdmq.tencentcloudapi.com/?
Action=ModifyRocketMQTopic&ClusterId=rocketmq-2p9vx3ax9jxg&NamespaceId=example&Topic=example-topic&Remark=modified&<Common request parameters>

Output Example{"Response": {"RequestId": "5d41e0f7-5668-46f9-a549-9a7540a9966c"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP©2013-2022 Tencent Cloud. All rights reserved.

Page 319 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

InvalidParameter.Partition

Incorrect partition count.

ResourceInUse

The resource is in use.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 320 of 450

TDMQ for Apache Pulsar

ModifyRocketMQNamespace：

Last updated 2023-08-09 14:43:21

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to update a RocketMQ namespace.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
ModifyRocketMQNamespace.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringClusterId

YesStringCluster ID

NamespaceId

YesStringNamespace name, which can contain 3–64 letters, digits,
hyphens, and underscores

Ttl

No

IntegerThis parameter is disused.

RetentionTime

No

IntegerThis parameter is disused.

RemarkNo

StringRemarks (up to 128 characters)©2013-2022 Tencent Cloud. All rights reserved.

Common Params. This parameter is not required for thisAPI.

Page 321 of 450

TDMQ for Apache Pulsar

PublicAccessEnabled

No

BooleanWhether to enable the public network access3. Output Parameters
Parameter
Name
RequestId

Type

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying the namespace information
This example shows you how to modify the namespace information.
Input Example
https://tdmq.tencentcloudapi.com/?
Action=ModifyRocketMQNamespace&ClusterId=rocketmq-2p9vx3ax9jxg&NamespaceId=example&Ttl=65000&RetentionTime=650000&Remark=example&<Common request parameters>

Output Example{"Response": {"RequestId": "7c995fd0-9a78-4985-8874-244a20a1d47b"}}

5. Developer Resources
SDK©2013-2022 Tencent Cloud. All rights reserved.

Page 322 of 450

TDMQ for Apache Pulsar

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.SetTTL

Failed to configure the message TTL.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

LimitExceeded

The quota limit is exceeded.

ResourceInUse

The resource is in use.

ResourceInsufficientInsufficient resource.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 323 of 450

TDMQ for Apache Pulsar

ModifyRocketMQGroup：

Last updated 2023-08-09 14:43:21

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to update a RocketMQ consumer group.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
ModifyRocketMQGroup.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

NamespaceId

YesStringNamespace

GroupId

Yes

StringConsumer group name

RemarkNo

StringRemarks (up to 128 characters)

ReadEnable

No

BooleanWhether to enable consumption

BroadcastEnable

No

BooleanWhether to enable broadcast consumption

RetryMaxTimesNo

Integer

The maximum number of retries©2013-2022 Tencent Cloud. All rights reserved.

Page 324 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name

Type

RequestId

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying a subscription group
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyRocketMQGroup<Common request parameters>{"Remark": "modified","BroadcastEnable": "false","ClusterId": "rocketmq-2p9vx3ax9jxg","GroupId": "group-example","RetryMaxTimes": "16","ReadEnable": "true","NamespaceId": "example"}

Output Example{"Response": {"RequestId": "1f9e837c-aab9-4f93-a373-48e165758529"}}©2013-2022 Tencent Cloud. All rights reserved.

Page 325 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceInUse

The resource is in use.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 326 of 450

TDMQ for Apache Pulsar

ModifyRocketMQCluster：

Last updated 2023-08-09 14:43:22

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to update a RocketMQ cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
ModifyRocketMQCluster.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringClusterId

YesStringRocketMQ cluster ID

ClusterName

No

String

3–64 letters, digits, hyphens, and underscores

RemarkNo

StringRemarks (up to 128 characters)

PublicAccessEnabled

No

BooleanWhether to enable the HTTP access over the public network

Common Params. This parameter is not required for thisAPI.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 327 of 450

TDMQ for Apache Pulsar

Parameter
Name

Type

RequestId

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying cluster information
This example shows you how to modify the cluster information.
Input Example
https://tdmq.tencentcloudapi.com/?
Action=ModifyRocketMQCluster&ClusterId=rocketmq-rd3545bkkj49&ClusterName=test-example&Remark=modified&<Common request parameters>

Output Example{"Response": {"RequestId": "ccfb8e00-54ac-40ad-9d24-036279fe3ad9"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS©2013-2022 Tencent Cloud. All rights reserved.

Page 328 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

LimitExceeded

The quota limit is exceeded.

ResourceInUse

The resource is in use.

ResourceInsufficientInsufficient resource.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 329 of 450

TDMQ for Apache Pulsar

DescribeRocketMQTopics：

Last updated 2023-08-09 14:43:22

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of RocketMQ topics.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

OffsetYes

Integer

Offset for query.

Limit

Yes

Integer

Query limit.

ClusterId

YesStringCluster ID.

NamespaceId

YesStringNamespace.

FilterType.N

No

Name

Array
of
String©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
DescribeRocketMQTopics.

Filter by topic type. Valid values: Normal , GlobalOrder ,PartitionedOrder , Transaction .

Page 330 of 450

TDMQ for Apache Pulsar

FilterName

No

StringSearch by topic name. Fuzzy query is supported.

3. Output Parameters
Parameter

Type

Description

TotalCount

Integer

The total number of query records.

TopicsArray ofRocketMQTopic

List of topic information

RequestId

StringName

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Getting the topic list
Input Example
https://tdmq.tencentcloudapi.com/?
Action=DescribeRocketMQTopics&Offset=0&Limit=10&ClusterId=rocketmq-2p9vx3ax9jxg&NamespaceId=example&<Common request parameters>

Output Example{"Response": {"RequestId": "c017c4d1-13cb-4f14-ab89-2c6530892f90","TotalCount": 1,"Topics": [{"Name": "example-topic","Type": "Normal","GroupNum": 0,"Remark": "modified",©2013-2022 Tencent Cloud. All rights reserved.

Page 331 of 450

TDMQ for Apache Pulsar"PartitionNum": 3,"CreateTime": 1621308465000,"UpdateTime": 1621308657000}]}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

©2013-2022 Tencent Cloud. All rights reserved.

Page 332 of 450

TDMQ for Apache Pulsar

ResourceNotFoundThe resource does not exist.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 333 of 450

TDMQ for Apache Pulsar

DescribeRocketMQNamespaces：

Last updated 2023-08-09 14:43:22

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of RocketMQ namespaces.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID.

OffsetYes

Integer

Offset.

Limit

Yes

Integer

The max number of returned results.

NameKeyword

No

StringSearch by name.

Name

Description
Common Params. The value used for this API:
DescribeRocketMQNamespaces.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 334 of 450

TDMQ for Apache Pulsar

Parameter
Name
Namespaces

Type
Array ofRocketMQNamespace

Description

List of namespaces

TotalCount

Integer

The total number of returned results.

RequestId

String

The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 Getting the list of the user’s namespaces
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeRocketMQNamespaces&ClusterId=rocketmq-rd3545bkkj49&Offset=0&Limit=10&<Common request parameters>

Output Example{"Response": {"TotalCount": 1,"RequestId": "xx","Namespaces": [{"Remark": "xx","RetentionTime": 1,"VpcEndpoint": "xx","Ttl": 1,"NamespaceId": "xx"}]}}©2013-2022 Tencent Cloud. All rights reserved.

Page 335 of 450

TDMQ for Apache Pulsar

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 336 of 450

TDMQ for Apache Pulsar

DescribeRocketMQGroups：

Last updated 2023-08-09 14:43:23

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of RocketMQ consumer groups.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID.

NamespaceId

YesStringNamespace.

OffsetYes

Integer

Offset.

Limit

Yes

Integer

The max number of returned results.

FilterTopicNo

String©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
DescribeRocketMQGroups.

Topic name, which can be used to query all subscription groups
under the topic

Page 337 of 450

TDMQ for Apache Pulsar

FilterGroupNo

StringConsumer group query by consumer group name. Fuzzy query is
supported

SortedBy

No

StringSort by specified field. Valid values: tps , accumulative .

SortOrder

No

StringFilterOneGroupNo

StringSort in ascending or descending order. Valid values: asc ,desc .
Subscription group name. After it is specified, the information of
only this subscription group will be returned.

Array
Types.N

Noof
StringGroup type

3. Output Parameters
Parameter
Name
TotalCount
GroupsRequestId

Type

Description

Integer

The total number of subscription groups.

Array ofRocketMQGroup
StringList of subscription groups
The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Querying the list of subscription groups
test
Input Example{"ClusterId": "xx","NamespaceId": "xx","Offset": 1,"Limit": 1,"FilterTopic": "xx","FilterGroup": "xx",©2013-2022 Tencent Cloud. All rights reserved.

Page 338 of 450

TDMQ for Apache Pulsar"SortedBy": "xx","SortOrder": "xx","FilterOneGroup": "xx","Types": [
"xx"
]
}

Output Example{"Response": {"RequestId": "1c127300-fcdd-4087-b1d2-fd75a1cefbe4","TotalCount": 1,"Groups": [{"Name": "group-example","ConsumerNum": 0,"TotalAccumulative": 0,"ConsumptionMode": -1,"BroadcastEnabled": false,"ReadEnabled": true,"RetryPartitionNum": 0,"CreateTime": 1621307489000,"UpdateTime": 1621307706000,"ClientProtocol": "TCP","Remark": "modified","ConsumerType": "","TPS": 0,"GroupType": "TCP"}]}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java©2013-2022 Tencent Cloud. All rights reserved.

Page 339 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceInUse

The resource is in use.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceUnavailable

The resource is unavailable.

©2013-2022 Tencent Cloud. All rights reserved.

Page 340 of 450

TDMQ for Apache Pulsar

DescribeRocketMQClusters：

Last updated 2023-08-09 14:43:23

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the list of RocketMQ clusters.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

OffsetYes

Integer

Offset.

Limit

Yes

Integer

The max number of returned results.

IdKeyword

No

StringSearch by cluster ID.

NameKeyword

No

StringSearch by cluster name.

ClusterIdList.N

No

Array of
StringFilter by cluster ID.

Name©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
DescribeRocketMQClusters.

Page 341 of 450

TDMQ for Apache Pulsar

IsTagFilter

No

Boolean

For filtering by tag, this parameter must be set to true .

Filters.N

No

Array ofFilterFilter. Currently, you can filter only by tag.

3. Output Parameters
Parameter
Name

ClusterList

Type

Description

Array ofCluster information.
Note: This field may return null, indicating that no valid values can be

RocketMQClusterDetail

TotalCount

IntegerRequestId

Stringobtained.
The total number of returned results.
The unique request ID, which is returned for each request. RequestId
is required for locating a problem.

4. Example
Example1 Getting the list of created clusters
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRocketMQClusters<Common request parameters>{"Limit": "10","Offset": "0"}

Output Example{"Response": {"RequestId": "1faeceb2-eaa9-407e-bd9a-d3eff76ca882",©2013-2022 Tencent Cloud. All rights reserved.

Page 342 of 450

TDMQ for Apache Pulsar"TotalCount": 1,"ClusterList": [{"Info": {"ClusterId": "rocketmq-xxxx1","ClusterName": "test","Region": "ap-beijing","CreateTime": 1620321019000,"Remark": "String","PublicEndPoint": "pulsar://rocketmq-xxxx1.xxxx.com:5678","VpcEndPoint": "pulsar://rocketmq-xxxx1.xxxx.com:5678","Vpcs": [{"SubnetId": "xx","VpcId": "xx"}],"SupportNamespaceEndpoint": true,"RocketMQFlag": true,"IsVip": true},
"Config": {"MaxTpsPerNamespace": 8000,"UsedNamespaceNum": 1,"MaxTopicNum": 1000,"UsedTopicNum": 2,"MaxGroupNum": 10000,"UsedGroupNum": 1,"MaxRetentionTime": 1296000000,"MaxLatencyTime": 3456000000,"MaxNamespaceNum": 10
}
}
]
}
}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python©2013-2022 Tencent Cloud. All rights reserved.

Page 343 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 344 of 450

TDMQ for Apache Pulsar

DescribeRocketMQCluster：

Last updated 2023-08-09 14:43:23

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to get the information of a specific RocketMQ cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeRocketMQCluster.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

Name

3. Output Parameters
Parameter
Name
ClusterInfo

Type

Description

RocketMQClusterInfo

Cluster information©2013-2022 Tencent Cloud. All rights reserved.

Page 345 of 450

TDMQ for Apache Pulsar

ClusterConfig

RocketMQClusterConfig

Cluster configuration
Recent cluster usage

ClusterStats

RocketMQClusterRecentStats

RequestId

StringNote: this field may return null, indicating that no valid
values can be obtained.
The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 huo
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRocketMQCluster<Common request parameters>{"ClusterId": "rocketmq-rd3545bkkj49"}

Output Example{"Response": {"RequestId": "c6d158b6-89b2-40d1-b1f6-5973f0f00cd5","ClusterInfo": {"ClusterId": "rocketmq-rd3545bkkj49","ClusterName": "test-example","Region": "ap-beijing","CreateTime": 1620321019000,"Remark": "modified","PublicEndPoint": "pulsar://xxxxx.com:6650","VpcEndPoint": "pulsar://xxxxx.com:6650","Vpcs": [{"SubnetId": "xx","VpcId": "xx"}],©2013-2022 Tencent Cloud. All rights reserved.

Page 346 of 450

TDMQ for Apache Pulsar"SupportNamespaceEndpoint": true,"RocketMQFlag": true,"IsVip": true},
"ClusterConfig": {"MaxTpsPerNamespace": 8000,"UsedNamespaceNum": 1,"MaxTopicNum": 1000,"UsedTopicNum": 2,"MaxGroupNum": 10000,"UsedGroupNum": 1,"MaxRetentionTime": 1296000000,"MaxLatencyTime": 3456000000,"MaxNamespaceNum": 10},"ClusterStats": {"TopicNum": 2,"ProducedMsgNum": 0,"ConsumedMsgNum": 0,"AccumulativeMsgNum": 0}}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0©2013-2022 Tencent Cloud. All rights reserved.

Page 347 of 450

TDMQ for Apache Pulsar

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 348 of 450

TDMQ for Apache Pulsar

DeleteRocketMQTopic：

Last updated 2023-08-09 14:43:23

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a RocketMQ topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

NamespaceId

YesStringNamespace name

Topic

Yes

StringTopic name

Description
Common Params. The value used for this API:
DeleteRocketMQTopic.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 349 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

Name
RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting topic
Input Example
https://tdmq.tencentcloudapi.com/?
Action=DeleteRocketMQTopic&ClusterId=rocketmq-2p9vx3ax9jxg&NamespaceId=example&Topic=example&<Common request parameters>

Output Example{"Response": {"RequestId": "5d41e0f7-5668-46f9-a549-9a7540a9966c"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET

©2013-2022 Tencent Cloud. All rights reserved.

Page 350 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.DeleteTopics

Failed to delete the topic.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 351 of 450

TDMQ for Apache Pulsar

DeleteRocketMQGroup：

Last updated 2023-08-09 14:43:24

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a RocketMQ consumer group.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

NamespaceId

YesStringNamespace nameGroupId

Yes

StringConsumer group name

Description
Common Params. The value used for this API:
DeleteRocketMQGroup.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 352 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

Name
RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Deleting subscription group
Input Example
https://tdmq.tencentcloudapi.com/?
Action=DeleteRocketMQGroup&ClusterId=rocketmq-2p9vx3ax9jxg&NamespaceId=example&GroupId=group-example&<Common request parameters>

Output Example{"Response": {"RequestId": "7fb7d925-a5c7-4b8c-add5-8477917a6260"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET

©2013-2022 Tencent Cloud. All rights reserved.

Page 353 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

ResourceInUse

The resource is in use.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 354 of 450

TDMQ for Apache Pulsar

DeleteRocketMQCluster：

Last updated 2023-08-09 14:43:24

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a RocketMQ cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringID of the cluster to be deleted.

Description
Common Params. The value used for this API:
DeleteRocketMQCluster.

3. Output Parameters
Parameter
Name
RequestId

Type

Description

String

The unique request ID, which is returned for each request. RequestId is required for©2013-2022 Tencent Cloud. All rights reserved.

Page 355 of 450

TDMQ for Apache Pulsar

locating a problem.

4. Example
Example1 Deleting a cluster
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DeleteRocketMQCluster<Common request parameters>{"ClusterId": "rocketmq-xjo5nq977ow2"}

Output Example{"Response": {"RequestId": "0d52695d-f4bd-4035-8f31-3c78fa720844"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++©2013-2022 Tencent Cloud. All rights reserved.

Page 356 of 450

TDMQ for Apache Pulsar

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.DeleteCluster

Failed to delete the cluster.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 357 of 450

TDMQ for Apache Pulsar

CreateRocketMQTopic：

Last updated 2023-04-18 14:53:06

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a RocketMQ topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Topic

Yes

StringTopic name, which can contain 3–64 letters, digits, hyphens, andunderscores

Array
Namespaces.N

Yesof
StringType

YesStringClusterId

YesString©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
CreateRocketMQTopic.

Topic namespace. Currently, you can create topics only in one
single namespace.
Topic type. Valid values: Normal , PartitionedOrder ,Transaction , DelayScheduled .
Cluster ID

Page 358 of 450

TDMQ for Apache Pulsar

RemarkNo

StringPartitionNum

No

Integer

Topic remarks (up to 128 characters)
Number of partitions, which doesn't take effect for globally
sequential messages

3. Output Parameters
Parameter
Name
RequestId

Type

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a topic
This example shows you how to create a topic.
Input Example
https://tdmq.tencentcloudapi.com/?
Action=CreateRocketMQTopic&Topic=example-topic&Type=Normal&Remark=example&ClusterId=rocketmq-2p9vx3ax9jxg&Namespaces.0=example&<Common request parameters>

Output Example{"Response": {"RequestId": "f844f173-93ed-4d89-979e-86e4e1d63b8a"}}5. Developer Resources©2013-2022 Tencent Cloud. All rights reserved.

Page 359 of 450

TDMQ for Apache Pulsar

SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.CreateTopic

Failed to create the topic.

InternalError

Internal error.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

InvalidParameter.Partition

Incorrect partition count.

LimitExceeded

The quota limit is exceeded.

ResourceInUse

The resource is in use.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Namespace

The namespace does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 360 of 450

TDMQ for Apache Pulsar

ResourceUnavailable.FundRequired©2013-2022 Tencent Cloud. All rights reserved.

You must top up before proceeding.

Page 361 of 450

TDMQ for Apache Pulsar

CreateRocketMQNamespace：

Last updated 2023-08-09 14:43:24

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a RocketMQ namespace.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID

NamespaceId

YesString

Ttl

No

IntegerThis parameter is disused.

RetentionTime

No

IntegerThis parameter is disused.

RemarkNo

StringRemarks (up to 128 characters)Name©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
CreateRocketMQNamespace.

Namespace name, which can contain 3–64 letters, digits, hyphens,
and underscores

Page 362 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name

Type

RequestId

StringDescription
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a namespace
This example shows you how to create a namespace.
Input Example
https://tdmq.tencentcloudapi.com/?
Action=CreateRocketMQNamespace&ClusterId=rocketmq-2p9vx3ax9jxg&NamespaceId=example&Ttl=60000&RetentionTime=600000&Remark=example&<Common request parameters>

Output Example{"Response": {"RequestId": "bf71e2ae-8b56-4231-87cf-0cbb6f421caa"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python©2013-2022 Tencent Cloud. All rights reserved.

Page 363 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.SetTTL

Failed to configure the message TTL.

InternalError

Internal error.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

LimitExceeded

The quota limit is exceeded.

ResourceInUse

The resource is in use.

ResourceInsufficientInsufficient resource.

ResourceNotFoundThe resource does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 364 of 450

TDMQ for Apache Pulsar

CreateRocketMQGroup：

Last updated 2023-08-09 14:43:24

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a RocketMQ consumer group.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
CreateRocketMQGroup.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

GroupId

Yes

StringGroup name (8–64 characters)

Namespaces.N

Yes

Array of
StringNamespace. Currently, only one namespace is supported

ReadEnable

Yes

BooleanWhether to enable consumption

BroadcastEnable

Yes

BooleanWhether to enable broadcast consumption

ClusterId

YesStringCluster ID

RemarkNo

StringRemarks (up to 128 characters)©2013-2022 Tencent Cloud. All rights reserved.

Page 365 of 450

TDMQ for Apache Pulsar

GroupTypeNo

StringGroup type ( TCP , HTTP )RetryMaxTimesNo

Integer

The maximum number of retries for a group

3. Output Parameters
Parameter
Name

Type

Description

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a subscription group
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateRocketMQGroup<Common request parameters>{"Remark": "example","BroadcastEnable": "true","ClusterId": "rocketmq-2p9vx3ax9jxg","RetryMaxTimes": "16","Namespaces": ["example"],"ReadEnable": "true","GroupType": "TCP","GroupId": "group-example"}

Output Example{"Response": {©2013-2022 Tencent Cloud. All rights reserved.

Page 366 of 450

TDMQ for Apache Pulsar"RequestId": "0604a303-6d5f-40e6-9dfe-6c4ddd8fe2df"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InternalError.IllegalMessage

Internal error.

InvalidParameter

Incorrect parameter.

LimitExceeded

The quota limit is exceeded.

ResourceInUse

The resource is in use.

©2013-2022 Tencent Cloud. All rights reserved.

Page 367 of 450

TDMQ for Apache Pulsar

ResourceNotFound.Cluster©2013-2022 Tencent Cloud. All rights reserved.

The cluster does not exist.

Page 368 of 450

TDMQ for Apache Pulsar

CreateRocketMQCluster：

Last updated 2023-08-09 14:43:24

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a RocketMQ cluster.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Name

Yes

StringCluster name, which can contain 3–64 letters, digits, hyphens, andunderscores

RemarkNo

StringCluster description (up to 128 characters)

Description
Common Params. The value used for this API:
CreateRocketMQCluster.

3. Output Parameters
Parameter

Type

Description©2013-2022 Tencent Cloud. All rights reserved.

Page 369 of 450

TDMQ for Apache Pulsar

Name
ClusterId

StringCluster ID

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Creating a cluster
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateRocketMQCluster<Common request parameters>{"Remark": "remark","Name": "example"}

Output Example{"Response": {"RequestId": "8841a73b-b002-4e92-a76b-123b12cfa9c1","ClusterId": "xx"}}5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python©2013-2022 Tencent Cloud. All rights reserved.

Page 370 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

FailedOperation.CreateCluster

Failed to create the cluster.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

LimitExceeded

The quota limit is exceeded.

LimitExceeded.Clusters

The number of clusters under the instance exceeds the limit.

ResourceInUse

The resource is in use.

ResourceInsufficientInsufficient resource.

ResourceNotFoundThe resource does not exist.

ResourceUnavailable

The resource is unavailable.

ResourceUnavailable.CreateFailed

Assignment exception.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 371 of 450

TDMQ for Apache Pulsar

TDMQ for RocketMQ APIs
ModifyRocketMQInstanceSpec：

Last updated 2023-08-09 14:43:18

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to modify the configurations of a TDMQ for RocketMQ exclusive instance, including the upgrade of
the instance specification, node count, and storage, and the downgrade of the instance specification. After you call this
API to place the order and make payments, the configuration modification will be in progress. You can query whether
the modification has been completed through the DescribeRocketMQVipInstances API`.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

InstanceId

Yes

StringID of the exclusive instanceSpecification

No

String

Instance specification.

Description
Common Params. The value used for this API:
ModifyRocketMQInstanceSpec.

Valid values: rocket-vip-basic-1 (Basic),rocket-vip-basic-2 (Standard),©2013-2022 Tencent Cloud. All rights reserved.

Page 372 of 450

TDMQ for Apache Pulsar

rocket-vip-basic-3 (Advanced I),
rocket-vip-basic-4 (Advanced II).
NodeCountNo

Integer

Node count

StorageSize

No

Integer

Storage space in GB

3. Output Parameters
Parameter
Name

Type

Description
Order ID

OrderId

StringRequestId

StringNote: u200dThis field may return null, indicating that no valid values can beobtained.
The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Modifying the specification of a TDMQ for RocketMQ exclusive instanceThis example shows you how to modify the specification of a TDMQ for RocketMQ exclusive instance.
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyRocketMQInstanceSpec<Common request parameters>{"InstanceId": "abc","Specification": "abc","NodeCount": 1,"StorageSize": 1}

Output Example©2013-2022 Tencent Cloud. All rights reserved.

Page 373 of 450

TDMQ for Apache Pulsar{"Response": {"OrderId": "abc","RequestId": "abc"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation.CallTrade

An exception occurred while calling the transaction service.

FailedOperation.InstanceNotReady

This instance is not ready. Please try again later.

InvalidParameterValue.AtLeastOne
ResourceNotFound.Instance©2013-2022 Tencent Cloud. All rights reserved.

The instance doesn’t exist.

Page 374 of 450

TDMQ for Apache Pulsar

UnsupportedOperation.InstanceDowngrade©2013-2022 Tencent Cloud. All rights reserved.

The instance does not support configuration downgrade.

Page 375 of 450

TDMQ for Apache Pulsar

DescribeRocketMQVipInstances：

Last updated 2023-08-09 14:43:19

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of the purchased TDMQ for RocketMQ exclusive instances.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

Filters.N

No

Limit

No

Integer

The maximum number of queried items, which defaults to 20.

OffsetNo

IntegerStart offset for query

Array ofFilterDescription
Common Params. The value used for this API:
DescribeRocketMQVipInstances.

Query condition filter

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 376 of 450

TDMQ for Apache Pulsar

Parameter

Type

Description

TotalCount

Integer

The total number of unpaginated items

Instances

Array ofRocketMQVipInstance

Instance information list

RequestId

String

The unique request ID, which is returned for each request. RequestId
is required for locating a problem.

Name

4. Example
Example1 Getting the instance list
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRocketMQVipInstances<Common request parameters>{"Limit": 1,"Filters": [{"Values": ["xx"],"Name": "xx"}],"Offset": 1}

Output Example{"Response": {"TotalCount": 1,"RequestId": "xx","Instances": [{©2013-2022 Tencent Cloud. All rights reserved.

Page 377 of 450

TDMQ for Apache Pulsar"Status": 1,"PayMode": 1,"Remark": "xx","AutoRenewFlag": 1,"InstanceId": "xx","NodeCount": 1,"ExpireTime": 1,"InstanceVersion": "xx","MaxStorage": 1,"MaxBandWidth": 1,"SpecName": "xx","ConfigDisplay": "xx","InstanceName": "xx","MaxTps": 1}]}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code
There is no error code related to the API business logic. For other error codes, please see Common Error Codes.

©2013-2022 Tencent Cloud. All rights reserved.

Page 378 of 450

TDMQ for Apache Pulsar

Production and Consumption APIs
DescribeSubscriptions：

Last updated 2023-08-09 14:43:25

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to query the list of subscribers under the specified environment and topic.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DescribeSubscriptions.

VersionYes

StringCommon Params. The value used for this API: 202002-17.

RegionNo

StringEnvironmentId

Yes

StringEnvironment (namespace) name.

TopicName

Yes

StringTopic name.

OffsetNo

Integer

Offset, which defaults to 0 if left empty.

Limit

No

Integer

The number of results to be returned, which defaults
to 10 if left empty. The maximum value is 20.

©2013-2022 Tencent Cloud. All rights reserved.

Common Params. This parameter is not required forthis API.

Page 379 of 450

TDMQ for Apache Pulsar

SubscriptionName

No

StringFuzzy match by subscriber name.

Filters.N

No

Array ofFilterSubscription

Data filter.

ClusterId

No

StringPulsar cluster ID

3. Output Parameters
Parameter
Name
SubscriptionSets

Type
Array ofSubscription

TotalCount

IntegerRequestId

StringDescription

Array of subscriber sets.
The total number of returned results.
The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Getting the consumer subscription list
Input Example
https://tdmq.tencentcloudapi.com/?Action=DescribeSubscriptions&EnvironmentId=test1&TopicName=test&<Common request parameters>

Output Example{"Response": {"TotalCount": 1,"SubscriptionSets": [{"EnvironmentId": "test1","TopicName": "test","ConnectedSince": "",©2013-2022 Tencent Cloud. All rights reserved.

Page 380 of 450

TDMQ for Apache Pulsar"ConsumerAddr": "","ConsumerCount": "6","ConsumerName": "","MsgBacklog": "1087","MsgRateExpired": "0.0","MsgRateOut": "0.0","SubType": "xx","MsgThroughputOut": "0.0","SubscriptionName": "test","BlockedSubscriptionOnUnackedMsgs": true,"MaxUnackedMsgNum": 0,"Remark": "","CreateTime": "2020-09-18 14:32:41","UpdateTime": "2021-01-13 15:23:35","IsOnline": true,"ConsumerSets": [{"ConnectedSince": "2021-01-13T15:19:21.03+08:00","ConsumerAddr": "/9.219.234.200:9056","ConsumerName": "axjoy","ClientVersion": ""},{"ConnectedSince": "2021-01-13T15:22:20.197+08:00","ConsumerAddr": "/9.219.234.202:6374","ConsumerName": "dkhtb","ClientVersion": ""},{"ConnectedSince": "2021-01-13T15:22:50.282+08:00","ConsumerAddr": "/9.219.237.139:57322","ConsumerName": "ejbij","ClientVersion": ""},{"ConnectedSince": "2021-01-13T15:18:50.927+08:00","ConsumerAddr": "/9.219.233.137:62564","ConsumerName": "hijsf","ClientVersion": ""},{"ConnectedSince": "2021-01-13T15:21:50.227+08:00","ConsumerAddr": "/9.219.234.202:11554","ConsumerName": "nbcra","ClientVersion": ""},{©2013-2022 Tencent Cloud. All rights reserved.

Page 381 of 450

TDMQ for Apache Pulsar"ConnectedSince": "2021-01-13T15:19:51.032+08:00","ConsumerAddr": "/9.219.232.202:19345","ConsumerName": "vjmts","ClientVersion": ""}],"ConsumersScheduleSets": [{"NumberOfEntries": 4642,"Partitions": 0,"MsgBacklog": 1087,"MsgRateOut": "0.0","MsgThroughputOut": "0.0","MsgRateExpired": "0.0"}]}],"RequestId": "39ab02af-30c8-41d4-9ac4-46cb519ceac0"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error Code©2013-2022 Tencent Cloud. All rights reserved.

Page 382 of 450

TDMQ for Apache Pulsar

The following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.DescribeSubscription

Failed to query the subscription data.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 383 of 450

TDMQ for Apache Pulsar

DeleteSubscriptions：

Last updated 2023-08-09 14:43:26

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to delete a subscription.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
DeleteSubscriptions.

VersionYes

StringCommon Params. The value used for this API:
2020-02-17.

RegionNo

StringSubscriptionTopicSets.N

Yes

Array ofSubscriptionTopic

Subscription set. Up to 20 subscriptions canbe deleted at a time.

ClusterId

No

StringPulsar cluster ID.

EnvironmentId

No

StringEnvironment (namespace) name.

Force

No

BooleanWhether to forcibly delete a subscription.
Default value: false .

©2013-2022 Tencent Cloud. All rights reserved.

Common Params. This parameter is not
required for this API.

Page 384 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter Name
SubscriptionTopicSets

RequestId

Type
Array ofSubscriptionTopic
StringDescription
Array of successfully deleted subscriptions.
The unique request ID, which is returned for each request.
RequestId is required for locating a problem.

4. Example
Example1 Deleting a subscription
Input Example
https://tdmq.tencentcloudapi.com/?Action=DeleteSubscriptions&SubscriptionTopicSets.0.EnvironmentId=default&SubscriptionTopicSets.0.TopicName=sun_topic&SubscriptionTopicSets.0.SubscriptionName=test_2_1&<Common request parameters>

Output Example{"Response": {"SubscriptionTopicSets": [{"EnvironmentId": "default","SubscriptionName": "test_2_1","TopicName": "sun_topic"}],"RequestId": "cd14f283-ccb5-4b13-b858-a0a38fa6348b"}}

5. Developer Resources
SDK©2013-2022 Tencent Cloud. All rights reserved.

Page 385 of 450

TDMQ for Apache Pulsar

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.DeleteSubscriptions

Failed to delete the subscription.

FailedOperation.GetTopicPartitionsFailed

Failed to get the number of topic partitions.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

OperationDenied.ConsumerRunning

Messages in the subscribed topic are being consumed.

ResourceInUse.Subscription

A subscription with the same name already exists.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Subscription

The subscription does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 386 of 450

TDMQ for Apache Pulsar

ResourceNotFound.Topic©2013-2022 Tencent Cloud. All rights reserved.

The topic does not exist.

Page 387 of 450

TDMQ for Apache Pulsar

CreateSubscription：

Last updated 2023-08-09 14:43:26

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to create a subscription to a topic.
A maximum of 200 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
CreateSubscription.

VersionYes

StringRegionNo

StringCommon Params. This parameter is not required for thisAPI.

EnvironmentId

Yes

StringEnvironment (namespace) name.

TopicName

Yes

StringTopic name.

SubscriptionName

Yes

StringSubscriber name, which can contain up to 128 characters.

IsIdempotent

Yes

BooleanWhether the creation is idempotent; if not, you cannot
create subscriptions with the same name.

RemarkNo

StringRemarks (up to 128 characters).

©2013-2022 Tencent Cloud. All rights reserved.

Common Params. The value used for this API: 2020-0217.

Page 388 of 450

TDMQ for Apache Pulsar

ClusterId

No

StringPulsar cluster ID

AutoCreatePolicyTopicNo

BooleanWhether to automatically create a dead letter topic and a
retry letter topic. true: yes (default value); false: no.
Naming convention for dead letter and retry letter topics.

PostFixPattern

No

StringLEGACY indicates to use the legacy naming convention,
and COMMUNITY indicates to use the naming
convention in the Pulsar community.

3. Output Parameters
Parameter

Type

Description

ResultBooleanCreation result.

RequestId

String

The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

Name

4. Example
Example1 Creating a subscription
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateSubscription<Common request parameters>{"EnvironmentId": "default","Remark": "Create a subscription","IsIdempotent": "true","TopicName": "cloud_test","SubscriptionName": "cloud_sub","AutoCreatePolicyTopic": "true"}©2013-2022 Tencent Cloud. All rights reserved.

Page 389 of 450

TDMQ for Apache Pulsar

Output Example{"Response": {"Result": true,"RequestId": "15288803-dadb-4499-9b5b-ff2f631ca68e"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.CreateSubscription

Failed to create the subscription.

©2013-2022 Tencent Cloud. All rights reserved.

Page 390 of 450

TDMQ for Apache Pulsar

FailedOperation.GetTopicPartitionsFailed

Failed to get the number of topic partitions.

InternalError.Retry

You can try again.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

LimitExceeded.Subscriptions

The number of subscribers under the instance exceeds the limit.

LimitExceeded.Topics

The number of topics under the instance exceeds the limit.

ResourceInUse.Subscription

A subscription with the same name already exists.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Topic

The topic does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 391 of 450

TDMQ for Apache Pulsar

ResetMsgSubOffsetByTimestamp：

Last updated 2023-08-09 14:43:25

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to rewind a message by timestamp, accurate down to the millisecond.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
ResetMsgSubOffsetByTimestamp.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

EnvironmentId

Yes

StringNamespace name.

TopicName

Yes

StringTopic name.

Subscription

Yes

StringSubscriber name.

ToTimestamp

Yes

Integer

Timestamp, accurate down to the millisecond.

ClusterId

No

StringPulsar cluster ID

Name©2013-2022 Tencent Cloud. All rights reserved.

Page 392 of 450

TDMQ for Apache Pulsar

3. Output Parameters
Parameter
Name

Type

ResultBooleanRequestId

StringDescription
Result.
Note: this field may return null, indicating that no valid values can be obtained.
The unique request ID, which is returned for each request. RequestId is required
for locating a problem.

4. Example
Example1 Rewinding message
Input Example
https://tdmq.tencentcloudapi.com/?Action=ResetMsgSubOffsetByTimestamp&EnvironmentId=default&TopicName=cloud_test&Subscription=cloud_sub&ToTimestamp=1585901708600&<Common request parameters>

Output Example{"Response": {"Result": true,"RequestId": "3593f784-fcfb-4f23-b3dd-4751cba3aec7"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to callAPIs.

©2013-2022 Tencent Cloud. All rights reserved.

Page 393 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

AuthFailure.UnauthorizedOperation

CAM authentication failed.

FailedOperation

Operation failed.

FailedOperation.ResetMsgSubOffsetByTimestampFailed

Failed to configure message rewind.

InternalError.SystemError

System error.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

MissingParameter.NeedMoreParams

A required parameter is missing.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Subscription

The subscription does not exist.

ResourceNotFound.Topic

The topic does not exist.

ResourceUnavailable.FundRequired

You must top up before proceeding.

©2013-2022 Tencent Cloud. All rights reserved.

Page 394 of 450

TDMQ for Apache Pulsar

DescribePublishers：

Last updated 2023-08-09 14:43:25

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to obtain the list of producer information.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter
Name

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID.

Namespace

Yes

StringNamespace name.

Topic

Yes

StringTopic name.

Filters.N

No

Array of

Parameter filter. The ProducerName and Address fields

Filterare supported.

OffsetNo

Integer

Offset for query. Default value: 0 .

©2013-2022 Tencent Cloud. All rights reserved.

Description
Common Params. The value used for this API:
DescribePublishers.

Page 395 of 450

TDMQ for Apache Pulsar

Limit

No

Integer

The number of query results displayed per page. Default value:
20 .

Sort

No

Sort

Sort by field.

3. Output Parameters
Parameter

Type

Description

TotalCount

Integer

Total number of query results.

Publishers

Array of
Publisher

Name

RequestId

StringList of producer information.
Note: this field may return null , indicating that no valid values can beobtained.
The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Obtaining producer list
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribePublishers<Common request parameters>{"Sort": {"Name": "xx","Order": "xx"},"ClusterId": "xx","Namespace": "xx","Topic": "xx","Limit": 0,"Filters": [{©2013-2022 Tencent Cloud. All rights reserved.

Page 396 of 450

TDMQ for Apache Pulsar"Values": ["xx"],"Name": "xx"}],"Offset": 0}

Output Example{"Response": {"TotalCount": 0,"RequestId": "xx","Publishers": [{"ConnectedSince": "xx","MsgThroughputIn": 0.0,
"ClientVersion": "xx","ProducerId": 0,"Partition": 0,"AverageMsgSize": 0.0,
"ProducerName": "xx","Address": "xx","MsgRateIn": 0.0}]}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS©2013-2022 Tencent Cloud. All rights reserved.

Page 397 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 398 of 450

TDMQ for Apache Pulsar

DescribePublisherSummary：

Last updated 2023-08-09 14:43:25

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to obtain message production overview information.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter

RequiredType

ActionYes

String

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID.

Namespace

Yes

StringNamespace name.

Topic

Yes

StringTopic name.

Name

Description
Common Params. The value used for this API:
DescribePublisherSummary.

3. Output Parameters©2013-2022 Tencent Cloud. All rights reserved.

Page 399 of 450

TDMQ for Apache Pulsar

Parameter NameType

Description
Production rate (messages/sec).

MsgRateIn

Float

Note: this field may return null , indicating that no valid values can beobtained.
Production rate (byte/sec).

MsgThroughputIn

Float

Note: this field may return null , indicating that no valid values can beobtained.

PublisherCount

Integer

The number of producers.
Note: this field may return null , indicating that no valid values can beobtained.

StorageSize

Integer

Message storage size in bytes.
Note: this field may return null , indicating that no valid values can beobtained.

RequestId

String

The unique request ID, which is returned for each request. RequestId isrequired for locating a problem.

4. Example
Example1 Obtaining producer overview
Input Example
POST / HTTP/1.1
Host: tdmq.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribePublisherSummary<Common request parameters>{"Topic": "xx","Namespace": "xx","ClusterId": "xx"}

Output Example{"Response": {"MsgRateIn": 0.0,

©2013-2022 Tencent Cloud. All rights reserved.

Page 400 of 450

TDMQ for Apache Pulsar"PublisherCount": 0,"StorageSize": 0,"RequestId": "xx","MsgThroughputIn": 0.0}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call
APIs.
Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

ResourceNotFound.Topic

The topic does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 401 of 450

TDMQ for Apache Pulsar

ResetRocketMQConsumerOffSet：

Last updated 2023-08-09 14:43:25

1. API Description
Domain name for API request: tdmq.tencentcloudapi.com.
This API is used to reset the consumption offset of a specified consumer group to a specified timestamp.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try itAPI Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation,
and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters
The following request parameter list only provides API request parameters and some common parameters. For thecomplete common parameter list, see Common Request Parameters.
Parameter Name

RequiredType

Description

ActionYes

StringCommon Params. The value used for this API:
ResetRocketMQConsumerOffSet.

VersionYes

StringCommon Params. The value used for this API: 2020-02-17.

RegionNo

StringCommon Params. This parameter is not required for this API.

ClusterId

YesStringCluster ID.

NamespaceId

YesStringNamespace name.

GroupId

Yes

StringConsumer group name.

Topic

Yes

StringTopic name.

Type

Yes

Integer

Reset method. 0: Start from the latest offset; 1: Start from
specified time point.

ResetTimestamp

No

Integer

The specified timestamp that has been reset, in milliseconds. This

©2013-2022 Tencent Cloud. All rights reserved.

Page 402 of 450

TDMQ for Apache Pulsar

parameter only takes effect when the value of Type is 1 .

3. Output Parameters
Parameter
Name

Type

Description

RequestId

String

The unique request ID, which is returned for each request. RequestId is required forlocating a problem.

4. Example
Example1 Resetting consumption offset
Input Example
https://tdmq.tencentcloudapi.com/?
Action=ResetRocketMQConsumerOffSet&ClusterId=ocketmq-2p9vx3ax9jxg&NamespaceId=example&GroupId=group-example&Topic=example-topic&Type=0&<Common request parameters>

Output Example{"Response": {"RequestId": "def4f676-27fc-4437-b4a3-cf1509726f98"}}

5. Developer Resources
SDK
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to callAPIs.

©2013-2022 Tencent Cloud. All rights reserved.

Page 403 of 450

TDMQ for Apache Pulsar

Tencent Cloud SDK 3.0 for Python
Tencent Cloud SDK 3.0 for Java
Tencent Cloud SDK 3.0 for PHP
Tencent Cloud SDK 3.0 for Go
Tencent Cloud SDK 3.0 for NodeJS
Tencent Cloud SDK 3.0 for .NET
Tencent Cloud SDK 3.0 for C++

Command Line Interface
Tencent Cloud CLI 3.0

6. Error CodeThe following only lists the error codes related to the API business logic. For other error codes, see Common Error
Codes.
Error CodeDescription

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidParameter

Incorrect parameter.

ResourceInUse

The resource is in use.

ResourceNotFoundThe resource does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 404 of 450

TDMQ for Apache Pulsar

Data Types：

Last updated 2023-08-09 14:43:37

BindCluster
Information of dedicated clusters
Used by actions: DescribeBindClusters.
Name

Type

Description

ClusterName

StringName of a physical cluster.

Cluster
Set of cluster information
Used by actions: DescribeClusterDetail, DescribeClusters.
Name

Type

Description

ClusterId

StringCluster ID.

ClusterName

StringCluster name.

RemarkStringRemarks.

EndPointNum

IntegerNumber of access points

CreateTime

StringCreation time

Healthy

Integer

Whether the cluster is healthy. 1: healthy; 0: exceptional

HealthyInfo

StringCluster health information
Note: this field may return null, indicating that no valid values canbe obtained.

StatusInteger

MaxNamespaceNum

IntegerMaximum number of namespaces

MaxTopicNum

IntegerMaximum number of topics©2013-2022 Tencent Cloud. All rights reserved.

Cluster status. 0: creating; 1: normal; 2: terminating; 3: deleted; 4.
isolated; 5. creation failed; 6: deletion failed

Page 405 of 450

TDMQ for Apache Pulsar

MaxQpsIntegerMaximum QPS

MessageRetentionTime

IntegerMaximum message retention period in seconds

MaxStorageCapacity

IntegerMaximum storage capacity
Cluster version

VersionPublicEndPoint

StringStringNote: this field may return null, indicating that no valid values canbe obtained.
Public network access point
Note: this field may return null, indicating that no valid values canbe obtained.

VpcEndPoint

String

VPC access point
Note: this field may return null, indicating that no valid values canbe obtained.
Number of namespaces

NamespaceNum

UsedStorageBudget

Integer

Integer

Note: this field may return null, indicating that no valid values canbe obtained.
Limit of used storage in MB
Note: this field may return null, indicating that no valid values canbe obtained.

MaxPublishRateInMessages

IntegerMaximum message production rate in messages
Note: this field may return null, indicating that no valid values canbe obtained.
Maximum message push rate in messages

MaxDispatchRateInMessages

MaxPublishRateInBytes

Integer

Integer

Note: this field may return null, indicating that no valid values canbe obtained.
Maximum message production rate in bytes
Note: this field may return null, indicating that no valid values canbe obtained.

MaxDispatchRateInBytes

IntegerMaximum message push rate in bytes
Note: this field may return null, indicating that no valid values canbe obtained.

TopicNum

IntegerNumber of created topics
Note: this field may return null, indicating that no valid values canbe obtained.

MaxMessageDelayInSeconds

IntegerMaximum message delay in seconds©2013-2022 Tencent Cloud. All rights reserved.

Page 406 of 450

TDMQ for Apache Pulsar

Note: this field may return null, indicating that no valid values canbe obtained.
Whether to enable public network access. If this parameter is left
PublicAccessEnabled

Booleanempty, the feature will be enabled by default
Note: this field may return null, indicating that no valid values canbe obtained.

Array of
Tag

Tags

Tag
Note: this field may return null, indicating that no valid values canbe obtained.
Billing mode:
0 : Pay-as-you-go

PayModeInteger

1 : Monthly subscription
Note: This field may return null , indicating that no valid
values can be obtained.

CmqDeadLetterPolicy
cmq DeadLetterPolicy
Used by actions: DescribeCmqQueueDetail, DescribeCmqQueues.
Name

Type

Description

DeadLetterQueue

StringDead letter queue.
Note: this field may return null, indicating that no valid values can be obtained.

PolicyInteger

Dead letter queue policy.
Note: this field may return null, indicating that no valid values can be obtained.
Maximum period in seconds before an unconsumed message expires, which is
required if Policy is 1. Value range: 300–43200. This value should be

MaxTimeToLive

Integersmaller than MsgRetentionSeconds (maximum message retention
period)Note: this field may return null, indicating that no valid values can be obtained.

MaxReceiveCount

IntegerMaximum number of receipts.
Note: this field may return null, indicating that no valid values can be obtained.

CmqDeadLetterSource©2013-2022 Tencent Cloud. All rights reserved.

Page 407 of 450

TDMQ for Apache Pulsar

Cmq DeadLetterSource
Used by actions: DescribeCmqDeadLetterSourceQueues, DescribeCmqQueueDetail, DescribeCmqQueues.
Name

Type

QueueId

StringQueueName

StringDescription
Message queue ID.
Note: this field may return null, indicating that no valid values can be obtained.
Message queue name.
Note: this field may return null, indicating that no valid values can be obtained.

CmqQueue
Batch queue attribute information of CMQ
Used by actions: DescribeCmqQueueDetail, DescribeCmqQueues.
Name

Type

Description

QueueId

StringMessage queue ID.

QueueName

StringMessage queue name.
Limit of the number of messages produced per second.

Qps

Integer

The value for consumed messages is 1.1 times this value.
Note: this field may return null, indicating that no valid
values can be obtained.

Bps

Integer

Bandwidth limit.
Note: this field may return null, indicating that no valid
values can be obtained.
Maximum retention period for inflight messages.

MaxDelaySeconds

Integer

Note: this field may return null, indicating that no valid
values can be obtained.
Maximum number of heaped messages. The value range
is 1,000,000–10,000,000 during the beta test and can be

MaxMsgHeapNum

Integer

1,000,000–1,000,000,000 after the product is officiallyreleased. The default value is 10,000,000 during the beta
test and will be 100,000,000 after the product is officiallyreleased.

PollingWaitSeconds

Integer©2013-2022 Tencent Cloud. All rights reserved.

Long polling wait time for message reception. Value
range: 0–30 seconds. Default value: 0.

Page 408 of 450

TDMQ for Apache Pulsar

Note: this field may return null, indicating that no valid
values can be obtained.
Message retention period. Value range: 60–1296000
MsgRetentionSeconds

Integer

seconds (i.e., 1 minute–15 days). Default value: 345600(i.e., 4 days).
Note: this field may return null, indicating that no valid
values can be obtained.

VisibilityTimeout

Integer

Message visibility timeout period. Value range: 1–43200
seconds (i.e., 12 hours). Default value: 30.
Note: this field may return null, indicating that no valid
values can be obtained.

MaxMsgSize

IntegerMaximum message length. Value range: 1024–1048576
bytes (i.e., 1–1024 KB). Default value: 65536.
Note: this field may return null, indicating that no valid
values can be obtained.
Maximum time range during which a message can be
rewound in the queue, which ranges from 0 to 43,200

RewindSeconds

Integer

seconds. 0 indicates that message rewind is disabled.
Note: this field may return null, indicating that no valid
values can be obtained.
Queue creation time. A Unix timestamp accurate down toCreateTime

Integerthe millisecond will be returned.
Note: this field may return null, indicating that no valid
values can be obtained.
Time when the queue attribute is last modified. A Unix

LastModifyTime

Integertimestamp accurate down to the millisecond will be
returned.
Note: this field may return null, indicating that no valid
values can be obtained.
Total number of messages in Active status (i.e.,
unconsumed) in the queue, which is an approximate

ActiveMsgNum

Integervalue.
Note: this field may return null, indicating that no valid
values can be obtained.

InactiveMsgNum

Integer

Total number of messages in Inactive status (i.e.,being consumed) in the queue, which is an approximate
value.
Note: this field may return null, indicating that no valid
values can be obtained.

©2013-2022 Tencent Cloud. All rights reserved.

Page 409 of 450

TDMQ for Apache Pulsar

Number of delayed messages.
DelayMsgNum

Integer

Note: this field may return null, indicating that no valid
values can be obtained.
Number of retained messages which have been deleted
by the DelMsg API but are still within their rewind time

RewindMsgNum

Integerrange.
Note: this field may return null, indicating that no valid
values can be obtained.

MinMsgTime

Integer

Minimum unconsumed time of message in seconds.
Note: this field may return null, indicating that no valid
values can be obtained.
Transaction message queue. true: transaction message

Transaction

DeadLetterSource

DeadLetterPolicy

BooleanArray of
CmqDeadLetterSource

CmqDeadLetterPolicy

type; false: other message types.
Note: this field may return null, indicating that no valid
values can be obtained.
Dead letter queue.
Note: this field may return null, indicating that no valid
values can be obtained.
Dead letter queue policy.
Note: this field may return null, indicating that no valid
values can be obtained.

TransactionPolicy

CmqTransactionPolicy

Transaction message policy.
Note: this field may return null, indicating that no valid
values can be obtained.
Creator Uin .

CreateUin

Integer

Note: this field may return null, indicating that no valid
values can be obtained.
Associated tag.

Tags

Trace

Array of Tag

BooleanNote: this field may return null, indicating that no valid
values can be obtained.
Message trace. true: enabled; false: not enabled
Note: this field may return null, indicating that no valid
values can be obtained.

TenantId

StringTenant ID
Note: this field may return null, indicating that no valid
values can be obtained.

©2013-2022 Tencent Cloud. All rights reserved.

Page 410 of 450

TDMQ for Apache Pulsar

NamespaceName

StringNamespace nameNote: this field may return null, indicating that no valid
values can be obtained.
Cluster status. 0: creating; 1: normal; 2: terminating; 3:

Statusdeleted; 4. isolated; 5. creation failed; 6: deletion failed
Note: this field may return null , indicating that noInteger

valid values can be obtained.
The maximum number of unacknowledged messages.
MaxUnackedMsgNum

Integer

Note: this field may return null , indicating that novalid values can be obtained.
Maximum size of heaped messages in bytes.

MaxMsgBacklogSize

Integer

Note: this field may return null , indicating that novalid values can be obtained.
Queue storage space configured for message rewind.

RetentionSizeInMB

Value range: 1,024-10,240 MB (if message rewind isenabled). The value “0” indicates that message rewind is
not enabled.

Integer

Note: This field may return null , indicating that novalid values can be obtained.

CmqSubscription
Subscription response parameter in CMQ
Used by actions: DescribeCmqSubscriptionDetail.
Name

Type

Description
Subscription name, which must be unique in the same topic under the sameaccount in the same region. It can contain up to 64 letters, digits, andSubscriptionName

Stringhyphens and must begin with a letter.
Note: this field may return null, indicating that no valid values can beobtained.
Subscription ID, which will be used during monitoring data pull.

SubscriptionId

StringNote: this field may return null, indicating that no valid values can beobtained.

TopicOwner

Integer

Subscription owner APPID .
Note: this field may return null, indicating that no valid values can beobtained.

©2013-2022 Tencent Cloud. All rights reserved.

Page 411 of 450

TDMQ for Apache Pulsar

MsgCount

IntegerNumber of messages to be delivered in the subscription.
Note: this field may return null, indicating that no valid values can beobtained.

LastModifyTime

Integer

Time when the subscription attribute is last modified. A Unix timestamp
accurate down to the millisecond will be returned.
Note: this field may return null, indicating that no valid values can beobtained.

CreateTime

Integer

Subscription creation time. A Unix timestamp accurate down to themillisecond will be returned.
Note: this field may return null, indicating that no valid values can beobtained.

BindingKey

Array
of
StringFiltering policy for subscribing to and receiving messages.
Note: this field may return null, indicating that no valid values can beobtained.
Endpoint that receives notifications, which varies by protocol : for
HTTP, the endpoint must start with http:// , and the host can be a

Endpoint

Stringdomain or IP; for queue , queueName should be entered.
Note: this field may return null, indicating that no valid values can beobtained.

FilterTags

Array
of
StringFiltering policy selected when a subscription is created:
If filterType is 1, filterTag will be used for filtering.
If filterType is 2, bindingKey will be used for filtering.
Note: this field may return null, indicating that no valid values can beobtained.
Subscription protocol. Currently, two protocols are supported: HTTP andProtocolStringNotifyStrategy

Stringqueue. To use the HTTP protocol, you need to build your own web server toreceive messages. With the queue protocol, messages are automaticallypushed to a CMQ queue and you can pull them concurrently.
Note: this field may return null, indicating that no valid values can beobtained.
CMQ push server retry policy in case an error occurs while pushing amessage to the endpoint. Valid values:(1) BACKOFF_RETRY: backoff retry, which is to retry at a fixed interval,
discard the message after a certain number of retries, and continue to push
the next message.
(2) EXPONENTIAL_DECAY_RETRY: exponential decay retry, which is toretry at an exponentially increasing interval, such as 1s, 2s, 4s, 8s, and soon. As a message can be retained in a topic for one day, failed messages
will be discarded at most after one day of retry. Default value:©2013-2022 Tencent Cloud. All rights reserved.

Page 412 of 450

TDMQ for Apache Pulsar

EXPONENTIAL_DECAY_RETRY.
Note: this field may return null, indicating that no valid values can beobtained.
Push content format. Valid values: 1. JSON; 2. SIMPLIFIED, i.e., the raw
format. If protocol is queue , this value must be SIMPLIFIED . If
NotifyContentFormat

Stringprotocol is HTTP , both values are acceptable, and the default value
is JSON .
Note: this field may return null, indicating that no valid values can beobtained.

CmqTopic
Display field of the returned CMQ topic information
Used by actions: DescribeCmqTopicDetail, DescribeCmqTopics.
Name

TopicIdType

StringRequired

Description

Yes

Topic ID.
Note: this field may return null, indicating that no valid
values can be obtained.

TopicName

StringYes

Topic name.
Note: this field may return null, indicating that no valid
values can be obtained.
Maximum lifecycle of message in topic. After the period

MsgRetentionSeconds

IntegerYes

specified by this parameter has elapsed since a message
is sent to the topic, the message will be deleted no matter
whether it has been successfully pushed to the user. Thisparameter is measured in seconds and defaulted to one
day (86,400 seconds), which cannot be modified.
Note: this field may return null, indicating that no valid
values can be obtained.
Maximum message size, which ranges from 1,024 to
1,048,576 bytes (i.e., 1–1,024 KB). The default value is

MaxMsgSize

IntegerYes

65,536.
Note: this field may return null, indicating that no valid
values can be obtained.

Qps

IntegerYes

Number of messages published per second.
Note: this field may return null, indicating that no valid
values can be obtained.

©2013-2022 Tencent Cloud. All rights reserved.

Page 413 of 450

TDMQ for Apache Pulsar

Filtering policy selected when a subscription is created:
If filterType is 1, FilterTag will be used for
FilterType

IntegerYesfiltering.
If filterType is 2, BindingKey will be used for
filtering.
Note: this field may return null, indicating that no valid
values can be obtained.

CreateTime

Integer

Yes

Topic creation time. A Unix timestamp accurate down to
the millisecond will be returned.
Note: this field may return null, indicating that no valid
values can be obtained.
Time when the topic attribute is last modified. A Unix
timestamp accurate down to the millisecond will be

LastModifyTime

IntegerYes

returned.
Note: this field may return null, indicating that no valid
values can be obtained.
Number of current messages in the topic (number of

MsgCount

IntegerYesretained messages).
Note: this field may return null, indicating that no valid
values can be obtained.
Creator Uin . The resource field for CAM

CreateUin

IntegerYesauthentication is composed of this field.
Note: this field may return null, indicating that no valid
values can be obtained.

Tags

Array of
Tag

Yes

Associated tag.
Note: this field may return null, indicating that no valid
values can be obtained.
Message trace. true: enabled; false: not enabled

Trace

Boolean

Yes

Note: this field may return null, indicating that no valid
values can be obtained.
Tenant ID

TenantId

NamespaceName

StringString

Yes

Yes

Note: this field may return null, indicating that no valid
values can be obtained.
Namespace nameNote: this field may return null, indicating that no valid
values can be obtained.

StatusIntegerYes©2013-2022 Tencent Cloud. All rights reserved.

Cluster status. 0: creating; 1: normal; 2: terminating; 3:Page 414 of 450

TDMQ for Apache Pulsar

deleted; 4. isolated; 5. creation failed; 6: deletion failed
Note: This field may return null , indicating that no valid
values can be obtained.
Valid values: 0 (Pulsar), 1 (RocketMQ).
BrokerType

Integer

Yes

Note: This field may return null, indicating that no valid
values can be obtained.

CmqTransactionPolicy
cmq TransactionPolicy
Used by actions: DescribeCmqQueueDetail, DescribeCmqQueues.
Name

Type

FirstQueryInterval

Integer

MaxQueryCount

Integer

Description
First lookback time.
Note: this field may return null, indicating that no valid values can be obtained.
Maximum number of queries.
Note: this field may return null, indicating that no valid values can be obtained.

Consumer
Consumer
Used by actions: DescribeSubscriptions.
Name

Type

Description

ConnectedSince

StringConsumerAddr

StringConsumer address.
Note: This field may return null, indicating that no valid values can be obtained.

ConsumerName

StringConsumer name.
Note: This field may return null, indicating that no valid values can be obtained.

ClientVersion

StringPartition

Integer

The time when the consumer started connecting.
Note: This field may return null, indicating that no valid values can be obtained.

Consumer version.
Note: This field may return null, indicating that no valid values can be obtained.
Serial number of the topic partition connected to the consumer.

©2013-2022 Tencent Cloud. All rights reserved.

Page 415 of 450

TDMQ for Apache Pulsar

Note: This field may return null, indicating that no valid values can be obtained.

ConsumersSchedule
Consumption progress details
Used by actions: DescribeSubscriptions.
Name

Type

Description
ID of the current partition.

Partitions

NumberOfEntries

Integer

Integer

Note: This field may return null, indicating that no valid values can beobtained.
The number of messages.
Note: This field may return null, indicating that no valid values can beobtained.

MsgBacklog

Integer

The number of heaped messages.
Note: This field may return null, indicating that no valid values can beobtained.

MsgRateOut

String

The total number of messages delivered by the consumer per second.

MsgThroughputOut

String

The size (in bytes) of messages consumed by the consumer per second.
Percentage of messages discarded due to timeout.

MsgRateExpired

StringNote: This field may return null, indicating that no valid values can beobtained.

Environment
Namespace information
Used by actions: DescribeEnvironments.
Name

Type

Description

EnvironmentId

StringNamespace name.

RemarkStringDescription.

MsgTTL

Integer

Retention period for unconsumed messages in seconds.
Maximum value: 1,296,000 seconds (15 days).

©2013-2022 Tencent Cloud. All rights reserved.

Page 416 of 450

TDMQ for Apache Pulsar

CreateTime

Timestamp

Creation time.

UpdateTime

Timestamp

Last modified.

NamespaceId

StringNamespace ID.

NamespaceName

StringNamespace name.
The number of topics.

TopicNum

Integer

RetentionPolicy

RetentionPolicy

Note: This field may return null, indicating that no valid values
can be obtained.
Message retention policy.
Note: This field may return null, indicating that no valid values
can be obtained.

AutoSubscriptionCreation

BooleanWhether to enable "Auto-Create Subscription"
Note: u200dThis field may return null, indicating that no valid
values can be obtained.

EnvironmentRole
Set of environment roles
Used by actions: DescribeEnvironmentRoles.
Name

Type

Description

EnvironmentId

StringEnvironment (namespace).

RoleName

StringRole name.

Permissions

Array of
StringPermissions, which is a non-empty string array of produce andRoleDescribe

StringRole description.

CreateTime

Timestamp

Creation time.

UpdateTime

Timestamp

Update time.

consume at the most.

EnvironmentRoleSet©2013-2022 Tencent Cloud. All rights reserved.

Page 417 of 450

TDMQ for Apache Pulsar

Relationship between the namespaces that are bound in batches and role permissions
Used by actions: CreateRole.
Name

EnvironmentId

Permissions

Type

Required

StringDescription
The IDs of the bound namespaces cannot be delicate and thenamespaces must contain resources

Yes

Note: u200dThis field may return null, indicating that no valid values
can be obtained.
Permissions to be bound to a namespace. Enumerated values:
consume , produce , and consume, produce . This

Array
of
Stringparameter cannot be left empty.

Yes

Note: u200dThis field may return null, indicating that no valid values
can be obtained.

FilterFilter parameter
Used by actions: DescribeClusters, DescribeCmqQueues, DescribeCmqTopics, DescribeEnvironmentRoles,
DescribeEnvironments, DescribePublishers, DescribePulsarProInstances, DescribeRabbitMQNodeList,
DescribeRabbitMQVipInstances, DescribeRabbitMQVirtualHost, DescribeRocketMQClusters,
DescribeRocketMQVipInstances, DescribeRoles, DescribeTopics.
Name

Type

Required

Description

Name

StringNo

Filter parameter name

ValuesArray of String

No

Value

FilterSubscription
Filter subscriptions
Used by actions: DescribeSubscriptions.
Name

Type

Required

Description

ConsumerHasCount

BooleanNo

Whether to only display subscriptions that include real©2013-2022 Tencent Cloud. All rights reserved.

Page 418 of 450

TDMQ for Apache Pulsar

consumers.
ConsumerHasBacklog

BooleanNo

ConsumerHasExpired

BooleanNo

SubscriptionNames

Array of
StringNo

Whether to only display subscriptions with heaped
messages.
Whether to only display subscriptions with messages
discarded after expiration.
Filter by subscription name for exact query.

InstanceNodeDistribution
Information of instance node distribution
Used by actions: DescribePulsarProInstanceDetail, DescribeRocketMQVipInstanceDetail.
Name

Type

Description

ZoneName

StringAZ

ZoneIdStringAZ ID

NodeCountIntegerNumber of nodes

PartitionsTopic
Partitioned topic
Used by actions: DescribeTopics.
Name

AverageMsgSize

Type

StringDescription
Average size of the messages published in the last interval inbytes.
Note: This field may return null, indicating that no valid values canbe obtained.

ConsumerCount

String

The number of consumers.
Note: This field may return null, indicating that no valid values canbe obtained.

LastConfirmedEntry

String

The total number of recorded messages.
Note: This field may return null, indicating that no valid values can©2013-2022 Tencent Cloud. All rights reserved.

Page 419 of 450

TDMQ for Apache Pulsar

be obtained.

LastLedgerCreatedTimestamp

StringTime when the last ledger was created.
Note: This field may return null, indicating that no valid values canbe obtained.

MsgRateIn

String

The number of messages published by local and replicatedpublishers per second.
Note: This field may return null, indicating that no valid values canbe obtained.

MsgRateOut

MsgThroughputIn

MsgThroughputOut

NumberOfEntries

StringStringStringString

The total number of messages delivered by local and replicatedconsumers per second.
Note: This field may return null, indicating that no valid values canbe obtained.
The size (in bytes) of messages published by local and replicatedpublishers per second.
Note: This field may return null, indicating that no valid values canbe obtained.
The size (in bytes) of messages delivered by local and replicatedconsumers per second.
Note: This field may return null, indicating that no valid values canbe obtained.
The total number of recorded messages.
Note: This field may return null, indicating that no valid values canbe obtained.

Partitions

Integer

Subpartition ID.
Note: This field may return null, indicating that no valid values canbe obtained.
The number of producers.

ProducerCount

TotalSize

StringStringNote: This field may return null, indicating that no valid values canbe obtained.
Total size of all stored messages in bytes.
Note: This field may return null, indicating that no valid values canbe obtained.

TopicType

Integer

Topic type description.
Note: This field may return null, indicating that no valid values canbe obtained.

©2013-2022 Tencent Cloud. All rights reserved.

Page 420 of 450

TDMQ for Apache Pulsar

Publisher
Producer information
Used by actions: DescribePublishers.
Name

ProducerId

Type

Description

Integer

Producer ID.
Note: this field may return null , indicating that no valid values can beobtained.

ProducerName

StringProducer name.
Note: this field may return null , indicating that no valid values can beobtained.

Address

StringProducer address.
Note: this field may return null , indicating that no valid values can beobtained.

ClientVersion

StringClient version.
Note: this field may return null , indicating that no valid values can beobtained.

MsgRateIn

Float

Message production rate (message/sec).
Note: this field may return null , indicating that no valid values can beobtained.

MsgThroughputIn

Float

Message production throughput rate (byte/sec).
Note: this field may return null , indicating that no valid values can beobtained.
Average message size in bytes.

AverageMsgSize

Float

Note: this field may return null , indicating that no valid values can beobtained.
Connection time.

ConnectedSince

StringNote: this field may return null , indicating that no valid values can beobtained.
Serial number of the topic partition connected to the producer.

Partition

Integer

Note: this field may return null , indicating that no valid values can beobtained.

©2013-2022 Tencent Cloud. All rights reserved.

Page 421 of 450

TDMQ for Apache Pulsar

PulsarNetworkAccessPointInfo
TDMQ for Pulsar network access point information
Used by actions: DescribePulsarProInstanceDetail.
Name

VpcId

Type

Description

String

VPC ID. This field is left empty for supporting network and public network accesspoints.
Note: This field may return null, indicating that no valid values can be obtained.

SubnetId

StringSubnet ID. This field is left empty for supporting network and public network accesspoints.
Note: This field may return null, indicating that no valid values can be obtained.

Endpoint

StringAccess address

InstanceId

String

Instance ID

RouteType

Integer

Access point type:
0 : Supporting network access point
1 : VPC access point
2 : Public network access point

PulsarProClusterInfo
TDMQ for Pulsar pro cluster information
Used by actions: DescribePulsarProInstanceDetail.
Name

Type

Description

ClusterId

StringCluster ID

ClusterName

StringCluster name

RemarkStringDescription

CreateTime

StringCreation time

StatusInteger

VersionString©2013-2022 Tencent Cloud. All rights reserved.

Cluster status. Valid values: 0 (Creating), 1 (Normal),
2 (Isolated).
Cluster version

Page 422 of 450

TDMQ for Apache Pulsar

NodeDistribution

Array of
InstanceNodeDistribution

Node distribution
Note: This field may return null, indicating that no valid values
can be obtained.

MaxStorage

Integer

Max storage capacity in MB
Whether the route can be modified

CanEditRoute

BooleanNote: u200dThis field may return null, indicating that no valid
values can be obtained.

PulsarProClusterSpecInfo
TDMQ for Pulsar pro cluster specification information
Used by actions: DescribePulsarProInstanceDetail.
Name

Type

Description

SpecName

StringCluster specification name

MaxTpsInteger

Peak TPS

MaxBandWidthInteger

Peak bandwidth in Mbps

MaxNamespaces

IntegerMaximum number of namespaces

MaxTopics

IntegerMaximum number of topic partitions

ScalableTps

Integer

Elastic TPS beyond the specification
Note: This field may return null, indicating that no valid values can be obtained.

PulsarProInstance
TDMQ for Pulsar pro instance information
Used by actions: DescribePulsarProInstances.
Name

Type

Description

InstanceId

String

Instance ID

InstanceName

String

Instance nameInstanceVersion

String

Instance version©2013-2022 Tencent Cloud. All rights reserved.

Page 423 of 450

TDMQ for Apache Pulsar

Instance status. Valid values: 0 (Creating), 1 (Normal), 2 (Isolated), 3
StatusInteger(Terminated), 4 (Abnormal), 5 (Delivery failed), 6 (Adjusting
configuration), 7 (Configuration adjustment failed).

ConfigDisplay

String

Instance specification name

MaxTpsInteger

Peak TPS

MaxStorage

Integer

Storage capacity in GB

ExpireTime

Integer

Instance expiration time in milliseconds

AutoRenewFlag

Integer

PayModeInteger

Payment mode. Valid values: 0 (Pay-as-you-go), 1 (Monthly subscription).

RemarkStringRemarks
Note: This field may return null, indicating that no valid values can be obtained.

SpecName

String

Instance specification ID

ScalableTps

Integer

Elastic TPS beyond the specification
Note: This field may return null, indicating that no valid values can be obtained.

VpcId

StringSubnetId

StringSubnet ID
Note: This field may return null, indicating that no valid values can be obtained.

MaxBandWidthInteger

Peak bandwidth in Mbps

Renewal mode. Valid values: 0 (Manual renewal, which is the default mode),
1 (Auto-renewal), 2 (Manual renewal, which is specified by users).

VPC ID
Note: This field may return null, indicating that no valid values can be obtained.

RabbitMQPrivateNode
TDMQ for RabbitMQ node information
Used by actions: DescribeRabbitMQNodeList.
Name

Type

NodeName

StringNodeStatus

StringDescription
Node nameNote: This field may return null, indicating that no valid value can be obtained.
Node status©2013-2022 Tencent Cloud. All rights reserved.

Page 424 of 450

TDMQ for Apache Pulsar

Note: This field may return null, indicating that no valid value can be obtained.
CPU utilization

CPUUsage

StringMemoryInteger

DiskUsage

String

Disk utilization
Note: This field may return null, indicating that no valid values can be obtained.

ProcessNumber

Integer

The number of RabbitMQ Erlang processes
Note: This field may return null, indicating that no valid values can be obtained.

Note: This field may return null, indicating that no valid values can be obtained.
Memory usage in MB
Note: This field may return null, indicating that no valid values can be obtained.

RabbitMQPrivateVirtualHost
TDMQ for RabbitMQ exclusive vhost
Used by actions: DescribeRabbitMQVirtualHostList.
Name

VirtualHostName

Type

Description

StringVhost nameNote: u200dThis field may return null, indicating that no valid values can beobtained.

Description

StringVhost description
Note: u200dThis field may return null, indicating that no valid values can beobtained.

RabbitMQUser
TDMQ for RabbitMQ user entity details
Used by actions: DescribeRabbitMQUser.
Name

Type

Description

InstanceId

StringCluster instance ID

UserStringUsername, which is used for login.

Password

StringPassword, which is used for login.

©2013-2022 Tencent Cloud. All rights reserved.

Page 425 of 450

TDMQ for Apache Pulsar

Description

StringUser description
Note: u200dThis field may return null, indicating that no valid values can beobtained.

Tags

User tag, which defines a user's permission scope for accessing RabbitMQ
Managementu200d.

Array of
StringNote: u200dThis field may return null, indicating that no valid values can beobtained.

CreateTime

StringUser creation time

ModifyTime

StringLast user modification time

Type

StringUser type. Valid values: System (Created by system), User (Created byuser).

RabbitMQVipInstance
TDMQ for RabbitMQ exclusive instance information
Used by actions: DescribeRabbitMQVipInstances.
Name

Type

Description

InstanceId

String

Instance ID

InstanceName

String

Instance nameInstance version

InstanceVersion

StringNote: This field may return null, indicating that no valid value can beobtained.

StatusInteger

NodeCountIntegerNumber of nodes

ConfigDisplay

String

Instance specification name

MaxTpsInteger

Peak TPS

MaxBandWidthInteger

Peak bandwidth in Mbps

MaxStorage

Integer

Storage capacity in GB

ExpireTime

Integer

Instance expiration time in milliseconds

Instance status. Valid values: 0 (Creating), 1 (Normal), 2 (Isolated),
3 (Terminated), 4 (Abnormal), 5 (Delivery failed).

©2013-2022 Tencent Cloud. All rights reserved.

Page 426 of 450

TDMQ for Apache Pulsar

AutoRenewFlag

IntegerRenewal mode. Valid values: 0 (Manual renewal, which is the defaultmode), 1 (Auto-renewal), 2 (Manual renewal, which is specified byusers).

PayModeRemarkInteger

Payment mode. 0 : Postpaid; 1 : Prepaid.

StringRemarks
Note: This field may return null, indicating that no valid value can beobtained.

SpecName

String

Instance specification ID
Cluster exception

ExceptionInformation

StringNote: This field may return null, indicating that no valid values can beobtained.
Instance status. Valid values: 0 (Creating), 1 (Normal), 2 (Isolated),

ClusterStatus

Integer

3 (Terminated), 4 (Abnormal), 5 (Delivery failed).
This parameter is used to display the instance status additionally anddistinguish from the Status parameter.

RabbitMQVirtualHostInfo
TDMQ for RabbitMQ vhost details
Used by actions: DescribeRabbitMQVirtualHost.
Name

Type

Description

InstanceId

StringCluster instance ID

VirtualHost

StringVhost name

StringVhost description
Note: u200dThis field may return null, indicating that

Description

no valid values can be obtained.

Tags

Array of String

Vhost tag
Note: u200dThis field may return null, indicating thatno valid values can be obtained.
Creation time

CreateTime

String©2013-2022 Tencent Cloud. All rights reserved.

Note: u200dThis field may return null, indicating thatno valid values can be obtained.

Page 427 of 450

TDMQ for Apache Pulsar

ModifyTime

StringModification time
Note: u200dThis field may return null, indicating thatno valid values can be obtained.
Statistics of vhost overview

VirtualHostStatistics

RabbitMQVirtualHostStatistics

StatusStringMessageHeapCount

Integer

MessageRateIn

Float

MessageRateOut

Float

Note: u200dThis field may return null, indicating thatno valid values can be obtained.

RabbitMQVirtualHostStatistics
Statistics of vhost overview
Used by actions: DescribeRabbitMQVirtualHost.
Name

Type

Description

CurrentQueues

Integer

The number of queues in the current vhost

CurrentExchanges

Integer

The number of exchanges in the current vhost

CurrentConnections

Integer

The number of connections in the current vhost

CurrentChannels

Integer

The number of channels in the current vhost

CurrentUsers

Integer

The number of users in the current vhost

RetentionPolicy
Message retention policy
Used by actions: CreateEnvironment, DescribeEnvironments, ModifyEnvironmentAttributes.
Name

Type

Required

Description

TimeInMinutes

Integer

Yes

Message retention period©2013-2022 Tencent Cloud. All rights reserved.

Page 428 of 450

TDMQ for Apache Pulsar

SizeInMB

Integer

Yes

Message retention size

RocketMQClusterConfig
RocketMQ cluster configuration
Used by actions: DescribeRocketMQCluster, DescribeRocketMQClusters.
Name

Type

Description

MaxTpsPerNamespace

IntegerMaximum TPS per namespace

MaxNamespaceNum

IntegerMaximum number of namespaces

UsedNamespaceNum

IntegerNumber of used namespaces

MaxTopicNum

IntegerMaximum number of topics

UsedTopicNum

IntegerNumber of used topics

MaxGroupNum

IntegerMaximum number of groups

UsedGroupNum

IntegerNumber of used groups

MaxRetentionTime

IntegerMaximum message retention period in milliseconds

MaxLatencyTime

IntegerMaximum message delay in milliseconds
The maximum number of queues in a single topic

MaxQueuesPerTopic

Integer

Note: This field may return null, indicating that no valid values can beobtained.

RocketMQClusterDetail
Details of the tenant’s RocketMQ cluster
Used by actions: DescribeRocketMQClusters.
Name

Type

Description

Info

RocketMQClusterInfo

Basic cluster information.

ConfigRocketMQClusterConfig

Cluster configuration information.

©2013-2022 Tencent Cloud. All rights reserved.

Page 429 of 450

TDMQ for Apache Pulsar

StatusInteger

Cluster status. 0: Creating; 1: Normal; 2: Terminating; 3: Deleted; 4.
Isolated; 5. Creation failed; 6: Deletion failed.
Note: This field may return null, indicating that no valid values can beobtained.

RocketMQClusterInfo
RocketMQ cluster's basic information
Used by actions: DescribeRocketMQCluster, DescribeRocketMQClusters, DescribeRocketMQVipInstanceDetail.
Name

Type

Description

ClusterId

StringCluster ID

ClusterName

StringCluster nameRegionStringRegion information

CreateTime

Integer

Creation time in milliseconds

RemarkStringCluster remarks
Note: this field may return null, indicating that no valid values
can be obtained.

PublicEndPoint

StringPublic network access address

VpcEndPoint

String

VPC access address
Whether the namespace access point is supported.

SupportNamespaceEndpoint

BooleanNote: This field may return null , indicating that no valid
values can be obtained.

Vpcs

IsVip

Array of
VpcConfig

Boolean

VPC Information
Note: This field may return null, indicating that no valid values
can be obtained.
Whether it is an exclusive instance
Note: This field may return null, indicating that no valid values
can be obtained.
TDMQ for RocketMQ cluster type flag

RocketMQFlag

BooleanNote: This field may return null, indicating that no valid values
can be obtained.

StatusInteger

Billing status ( 1 : Normal; 2 : Service suspended; 3 :©2013-2022 Tencent Cloud. All rights reserved.

Page 430 of 450

TDMQ for Apache Pulsar

Terminated)
Note: This field may return null, indicating that no valid values
can be obtained.

IsolateTime

Service suspension time in milliseconds
Note: This field may return null, indicating that no valid values

Integercan be obtained.

HttpPublicEndpoint

HTTP-based public network access address
Note: This field may return null, indicating that no valid values
can be obtained.

StringHTTP-based VPC access address
HttpVpcEndpoint

InternalEndpoint

StringNote: This field may return null, indicating that no valid values
can be obtained.
Internal TCP access address
Note: u200dThis field may return null, indicating that no valid

Stringvalues can be obtained.

HttpInternalEndpoint

Internal HTTP access address
Note: u200dThis field may return null, indicating that no valid

Stringvalues can be obtained.

RocketMQClusterRecentStats
Recent RocketMQ usage
Used by actions: DescribeRocketMQCluster.
Name

Type

Description

TopicNum

IntegerNumber of topics

ProducedMsgNum

IntegerNumber of produced messages

ConsumedMsgNum

IntegerNumber of consumed messages

AccumulativeMsgNum

IntegerNumber of retained messages

RocketMQGroup
RocketMQ consumer group information©2013-2022 Tencent Cloud. All rights reserved.

Page 431 of 450

TDMQ for Apache Pulsar

Used by actions: DescribeRocketMQGroups.
Name

Type

Description

Name

StringConsumer group name.

ConsumerNum

Integer

The number of online consumers.

TPS

Integer

Consumption TPS.

TotalAccumulative

Integer

The total number of heaped messages.

ConsumptionMode

Integer

0: Cluster consumption mode; 1: Broadcast consumption mode; -1:
Unknown.

ReadEnabled

BooleanWhether to allow consumption.
The number of partitions in a retry topic.

RetryPartitionNum

Integer

Note: This field may return null, indicating that no valid values can beobtained.

CreateTime

Integer

Creation time in milliseconds.

UpdateTime

Integer

Modification time in milliseconds.

ClientProtocol

StringClient protocol.

StringDescription.
Note: This field may return null, indicating that no valid values can beobtained.

RemarkConsumer type. Enumerated values: ACTIVELY or PASSIVELY .
ConsumerType

StringNote: This field may return null, indicating that no valid values can beobtained.

BroadcastEnabled

BooleanWhether to enable broadcast consumption.
Group typeGroupType

RetryMaxTimes

StringInteger

Note: This field may return null, indicating that no valid values can beobtained.
The number of retries
Note: This field may return null, indicating that no valid values can beobtained.

RocketMQInstanceConfig©2013-2022 Tencent Cloud. All rights reserved.

Page 432 of 450

TDMQ for Apache Pulsar

Instance configurations of a TDMQ for RocketMQ exclusive cluster
Used by actions: DescribeRocketMQVipInstanceDetail.
Name

Type

Description

MaxTpsPerNamespace

IntegerMaximum TPS per namespace

MaxNamespaceNum

IntegerMaximum number of namespaces

UsedNamespaceNum

IntegerNumber of used namespaces

MaxTopicNum

IntegerMaximum number of topics

UsedTopicNum

IntegerNumber of used topics

MaxGroupNum

IntegerMaximum number of groups

UsedGroupNum

IntegerNumber of used groups

ConfigDisplay

StringCluster type

NodeCountIntegerNumber of nodes in the cluster

NodeDistribution

Array of InstanceNodeDistribution

Node distribution

TopicDistribution

Array of RocketMQTopicDistribution

Topic distribution

MaxQueuesPerTopic

Integer

RocketMQMessageTrack
TDMQ for RocketMQ message trace information
Used by actions: DescribeRocketMQMsg.
Name

Type

Description

Group

StringConsumer group

ConsumeStatus

StringConsumption status

TrackType

StringMessage trace type

StringException information
Note: u200dThis field may return null, indicating that no valid values can be

ExceptionDesc

obtained.

©2013-2022 Tencent Cloud. All rights reserved.

Page 433 of 450

TDMQ for Apache Pulsar

RocketMQNamespace
RocketMQ namespace information
Used by actions: DescribeRocketMQNamespaces.
Name

Type

Description

NamespaceId

StringNamespace name, which can contain 3–64 letters, digits, hyphens, andunderscores.

Ttl

Integer

RetentionTime

Integer

Retention period for persistently stored messages in milliseconds.

RemarkStringDescription.
Note: This field may return null, indicating that no valid values can be obtained.

PublicEndpoint

StringPublic network access point address.
Note: This field may return null, indicating that no valid values can be obtained.

VpcEndpoint

StringInternalEndpoint

StringRetention period for unconsumed messages in milliseconds. Valid range: 60
seconds–15 days. This parameter is disused.

VPC access point address.
Note: This field may return null, indicating that no valid values can be obtained.
Internal access point address
Note: u200dThis field may return null, indicating that no valid values can beobtained.

RocketMQTopic
RocketMQ topic information
Used by actions: DescribeRocketMQTopics.
Name

Type

Description

Name

StringTopic name.

Type

StringGroupNum

Integer

Topic type. Enumerated values: Normal , GlobalOrder ,PartitionedOrder , Transaction , Retry , and DeadLetter .
The number of subscription groups©2013-2022 Tencent Cloud. All rights reserved.

Page 434 of 450

TDMQ for Apache Pulsar

RemarkStringDescription.
Note: This field may return null, indicating that no valid values can be obtained.

PartitionNum

Integer

The number of read/write partitions.

CreateTime

Integer

Creation time in milliseconds.

UpdateTime

Integer

Creation time in milliseconds.

RocketMQTopicDistribution
TDMQ for RocketMQ topic distribution
Used by actions: DescribeRocketMQVipInstanceDetail.
Name

Type

Description

TopicType

StringTopic typeCount

IntegerNumber of topics

RocketMQVipInstance
Information of TDMQ for RocketMQ exclusive instances
Used by actions: DescribeRocketMQVipInstances.
Name

Type

Description

InstanceId

String

Instance ID

InstanceName

String

Instance nameInstanceVersion

String

Instance version
Note: This field may return null, indicating that no valid values can be obtained.

StatusInteger

NodeCountIntegerNumber of nodes

ConfigDisplay

String

Instance specification name

MaxTpsInteger

Peak TPS

Instance status. Valid values: 0 (Creating), 1 (Normal), 2 (Isolated), 3(Terminated), 4 (Abnormal), 5 (Delivery failed).

©2013-2022 Tencent Cloud. All rights reserved.

Page 435 of 450

TDMQ for Apache Pulsar

MaxBandWidthInteger

Peak bandwidth in Mbps

MaxStorage

Integer

Storage capacity in GB

ExpireTime

Integer

Instance expiration time in milliseconds

AutoRenewFlag

Integer

PayModeInteger

RemarkStringSpecName

String

Instance specification ID

Integer

The maximum message retention period in hours
Note: u200dThis field may return null, indicating that no valid values can beobtained.

MaxRetention

Renewal mode. Valid values: 0 (Manual renewal, which is the default mode),
1 (Auto-renewal), 2 (Manual renewal, which is specified by users).
Payment mode. 0: Postpaid; 1: Prepaid.
Remarks
Note: This field may return null, indicating that no valid values can be obtained.

The minimum message retention period in hours
MinRetention

Retention

Integer

Integer

Note: u200dThis field may return null, indicating that no valid values can beobtained.
Instance message retention period in hours
Note: u200dThis field may return null, indicating that no valid values can beobtained.

Role
Role instance
Used by actions: DescribeRoles.
Name

Type

Description

RoleName

StringRole name.

Token

StringValue of the role token.

RemarkStringRemarks.

CreateTime

Timestamp

Creation time.

UpdateTime

Timestamp

Update time.

©2013-2022 Tencent Cloud. All rights reserved.

Page 436 of 450

TDMQ for Apache Pulsar

Sort
Sort by field
Used by actions: DescribePublishers.
Name

Type

Required

Description

Name

StringYes

Sorting field.

Order

StringYes

Ascending order: ASC ; descending order: DESC .

Subscription
Subscriber
Used by actions: DescribeSubscriptions.
Name

Type

Description

TopicName

StringTopic name.

EnvironmentId

StringEnvironment (namespace) name.
The time when the consumer started
connecting.

ConnectedSince

StringNote: This field may return null ,indicating that no valid values can beobtained.

ConsumerAddr

StringConsumer address.
Note: This field may return null, indicatingthat no valid values can be obtained.
The number of consumers.

ConsumerCount

ConsumerName

StringStringNote: This field may return null, indicatingthat no valid values can be obtained.
Consumer name.
Note: This field may return null, indicatingthat no valid values can be obtained.

MsgBacklog

String©2013-2022 Tencent Cloud. All rights reserved.

The number of heaped messages.
Note: This field may return null, indicatingthat no valid values can be obtained.

Page 437 of 450

TDMQ for Apache Pulsar

Percentage of messages under thisMsgRateExpired

Stringsubscription that were discarded but not
sent after TTL.
Note: This field may return null, indicatingthat no valid values can be obtained.

MsgRateOut

MsgThroughputOut

SubscriptionName

StringStringString

The total number of messages delivered by
the consumer per second.
Note: This field may return null, indicatingthat no valid values can be obtained.
The size (in bytes) of messages consumed
by the consumer per second.
Note: This field may return null, indicatingthat no valid values can be obtained.
Subscription name.
Note: This field may return null, indicatingthat no valid values can be obtained.

ConsumerSets

Array of Consumer

Set of consumers.
Note: This field may return null, indicatingthat no valid values can be obtained.
Whether the consumer is online.

IsOnline

ConsumersScheduleSets

RemarkBooleanArray ofConsumersSchedule

StringNote: This field may return null, indicatingthat no valid values can be obtained.
Set of consumption progress information.
Note: This field may return null, indicatingthat no valid values can be obtained.
Remarks.
Note: This field may return null, indicatingthat no valid values can be obtained.

CreateTime

Timestamp

Creation time.
Note: This field may return null, indicatingthat no valid values can be obtained.
Last modified.

UpdateTime

Timestamp

Note: This field may return null, indicatingthat no valid values can be obtained.

SubType

StringSubscription type. Valid values:
Exclusive , Shared , Failover ,and Key_Shared . An empty string or©2013-2022 Tencent Cloud. All rights reserved.

Page 438 of 450

TDMQ for Apache Pulsar

NULL : Unknown.
Note: This field may return null, indicatingthat no valid values can be obtained.
Whether messages are blocked as the limit
of unacknowledged messages has been
BlockedSubscriptionOnUnackedMsgs

Booleanreached.
Note: This field may return null, indicatingthat no valid values can be obtained.
The maximum number of unacknowledged

MaxUnackedMsgNum

Integermessages.
Note: This field may return null, indicatingthat no valid values can be obtained.

SubscriptionTopic
Subscription
Used by actions: DeleteSubscriptions.
Name

Type

Required

Description

EnvironmentId

StringYes

Environment (namespace) name.

TopicName

StringYes

Topic name.

SubscriptionName

StringYes

Subscription name.

Tag
Type of the tag key/value
Used by actions: CreateCluster, CreateCmqQueue, CreateCmqTopic, DescribeClusterDetail, DescribeClusters,
DescribeCmqQueueDetail, DescribeCmqQueues, DescribeCmqTopicDetail, DescribeCmqTopics.
Name

Type

Required

Description

TagKeyStringYes

Value of the tag key

TagValue

StringYes

Value of the tag value©2013-2022 Tencent Cloud. All rights reserved.

Page 439 of 450

TDMQ for Apache Pulsar

Topic
Topic instance
Used by actions: DescribeTopics.
Name

AverageMsgSize

Type

StringDescription
Average size of the messages published in the lastinterval in bytes.
Note: This field may return null , indicating that novalid values can be obtained.
The number of consumers.

ConsumerCount

LastConfirmedEntry

StringStringNote: This field may return null, indicating that no valid
values can be obtained.
The total number of recorded messages.
Note: This field may return null, indicating that no valid
values can be obtained.

LastLedgerCreatedTimestamp

StringTime when the last ledger was created.
Note: This field may return null, indicating that no valid
values can be obtained.
The number of messages published by local and

MsgRateIn

Stringreplicated publishers per second.
Note: This field may return null, indicating that no valid
values can be obtained.
The total number of messages delivered by local and

MsgRateOut

Stringreplicated consumers per second.
Note: This field may return null, indicating that no valid
values can be obtained.
The size (in bytes) of messages published by local and

MsgThroughputIn

Stringreplicated publishers per second.
Note: This field may return null, indicating that no valid
values can be obtained.

MsgThroughputOut

String

The size (in bytes) of messages delivered by local andreplicated consumers per second.
Note: This field may return null, indicating that no valid
values can be obtained.

NumberOfEntries

String©2013-2022 Tencent Cloud. All rights reserved.

The total number of recorded messages.
Note: This field may return null, indicating that no valid

Page 440 of 450

TDMQ for Apache Pulsar

values can be obtained.

Partitions

Integer

Partition count ≤ 0: there are no subpartitions in the topic.
Note: This field may return null, indicating that no valid
values can be obtained.
The number of producers.

ProducerCount

TotalSize

StringStringNote: This field may return null, indicating that no valid
values can be obtained.
The size of all stored messages in bytes.
Note: This field may return null, indicating that no valid
values can be obtained.

SubTopicSets

Array of
PartitionsTopic

Subpartitions in a partitioned topic.
Note: This field may return null, indicating that no valid
values can be obtained.
Topic type description:
0: General message;
1: Globally sequential message;

TopicType

Integer

2: Partitionally sequential message;
3: Retry letter topic;
4: Dead letter topic;
5: Transaction message.
Note: This field may return null, indicating that no valid
values can be obtained.
Environment (namespace) name.

EnvironmentId

TopicName

StringStringNote: This field may return null, indicating that no valid
values can be obtained.
Topic name.
Note: This field may return null, indicating that no valid
values can be obtained.

RemarkStringRemarks (up to 128 characters).
Note: This field may return null, indicating that no valid
values can be obtained.
Creation time.

CreateTime

Timestamp

Note: This field may return null, indicating that no valid
values can be obtained.
Last modified.

UpdateTime

Timestamp©2013-2022 Tencent Cloud. All rights reserved.

Note: This field may return null, indicating that no valid
values can be obtained.

Page 441 of 450

TDMQ for Apache Pulsar

ProducerLimit

String

The maximum number of producers.
Note: This field may return null, indicating that no valid
values can be obtained.

ConsumerLimit

The maximum number of consumers.
Note: This field may return null, indicating that no valid
values can be obtained.

String

0 : Non-persistent and non-partitioned
1 : Non-persistent and partitioned
PulsarTopicType

2 : Persistent and non-partitioned

Integer

3 : Persistent and partitioned
Note: This field may return null, indicating that no valid
values can be obtained.

TopicRecord
Topic's key information
Used by actions: DeleteTopics.
Name

Type

Required

Description

EnvironmentId

StringYes

Environment (namespace) name.

TopicName

StringYes

Topic name.

VpcBindRecord
VPC binding record
Used by actions: DescribeBindVpcs.
Name

Type

Description

UniqueVpcId

StringTenant VPC ID

UniqueSubnetId

StringTenant VPC subnet ID

RouterId

StringRoute ID

Ip

String

VPC ID©2013-2022 Tencent Cloud. All rights reserved.

Page 442 of 450

TDMQ for Apache Pulsar

Port

Integer

RemarkString

VPC port
Remarks (up to 128 characters)
Note: this field may return null, indicating that no valid values can be obtained.

VpcConfig
VPC configuration information
Used by actions: DescribeRocketMQCluster, DescribeRocketMQVipInstanceDetail.
Name

Type

Required

Description

VpcId

StringYes

VPC ID

SubnetId

StringYes

Subnet ID©2013-2022 Tencent Cloud. All rights reserved.

Page 443 of 450

TDMQ for Apache Pulsar

Error Codes：

Last updated 2023-08-09 14:43:37

Feature Description
If there is an Error field in the response, it means that the API call failed. For example:{"Response": {"Error": {"Code": "AuthFailure.SignatureFailure","Message": "The provided credentials could not be validated. Please check your si
gnature is correct."},"RequestId": "ed93f3cb-f35e-473f-b9f3-0d451b8b79c6"}}
Code in Error indicates the error code, and Message indicates the specific information of the error.

Error Code List
Common Error Codes
Error CodeDescription

ActionOffline

This API has been deprecated.

AuthFailure.InvalidAuthorization

Authorization in the request header is invalid.

AuthFailure.InvalidSecretId

Invalid key (not a TencentCloud API key type).

AuthFailure.MFAFailure

MFA failed.
Key does not exist. Check if the key has been

AuthFailure.SecretIdNotFound

AuthFailure.SignatureExpire

deleted or disabled in the console, and if not, checkif the key is correctly entered. Note that whitespaces
should not exist before or after the key.
Signature expired. Timestamp and server timecannot differ by more than five minutes. Please©2013-2022 Tencent Cloud. All rights reserved.

Page 444 of 450

TDMQ for Apache Pulsar

ensure your current local time matches the standard
time.
Invalid signature. Signature calculation error. Please
AuthFailure.SignatureFailure

AuthFailure.TokenFailure
AuthFailure.UnauthorizedOperation

ensure you’ve followed the signature calculation
process described in the Signature API
documentation.
Token error.
The request is not authorized. For more information,
see the CAM documentation.

DryRunOperation

DryRun Operation. It means that the request would
have succeeded, but the DryRun parameter wasused.

FailedOperation

Operation failed.

InternalError

Internal error.

InvalidAction

The API does not exist.

InvalidParameter

Incorrect parameter.

InvalidParameterValue

Invalid parameter value.

InvalidRequest

The multipart format of the request body is incorrect.

IpInBlacklist

Your IP is in uin IP blacklist.

IpNotInWhitelistYour IP is not in uin IP whitelist.

LimitExceeded

Quota limit exceeded.

MissingParameter

A parameter is missing.

NoSuchProduct

The product does not exist.

NoSuchVersion

The API version does not exist.

RequestLimitExceeded

The number of requests exceeds the frequency limit.

RequestLimitExceeded.GlobalRegionUinLimitExceeded

Uin exceeds the frequency limit.

RequestLimitExceeded.IPLimitExceeded
RequestLimitExceeded.UinLimitExceeded©2013-2022 Tencent Cloud. All rights reserved.

The number of ip requests exceeds the frequency
limit.
The number of uin requests exceeds the frequency

Page 445 of 450

TDMQ for Apache Pulsar

limit.
RequestSizeLimitExceeded

The request size exceeds the upper limit.

ResourceInUse

Resource is in use.

ResourceInsufficientInsufficient resource.

ResourceNotFoundThe resource does not exist.

ResourceUnavailable

Resource is unavailable.

ResponseSizeLimitExceeded

The response size exceeds the upper limit.

ServiceUnavailable

Service is unavailable now.

UnauthorizedOperation

Unauthorized operation.

UnknownParameter

Unknown parameter.

UnsupportedOperation

Unsupported operation.

UnsupportedProtocol

HTTP(S) request protocol error; only GET and
POST requests are supported.

UnsupportedRegion

API does not support the requested region.

Service Error Codes
Error Code
FailedOperation.CallTrade

Description
An exception occurred while calling the transaction
service.

FailedOperation.CmqBackendError

CMQ backend error.

FailedOperation.CreateCluster

Failed to create the cluster.

FailedOperation.CreateEnvironment

Failed to create the environment.

FailedOperation.CreateEnvironmentRole

Failed to create the environment role.

FailedOperation.CreateNamespace

Failed to create the namespace.

FailedOperation.CreateProducerError

An error occurred while creating the producer.

FailedOperation.CreatePulsarClientError

An error occurred while creating the TDMQ client.

FailedOperation.CreateRole

Failed to create the role.

©2013-2022 Tencent Cloud. All rights reserved.

Page 446 of 450

TDMQ for Apache Pulsar

FailedOperation.CreateSecretKey

Failed to create the key.

FailedOperation.CreateSubscription

Failed to create the subscription.

FailedOperation.CreateTopic

Failed to create the topic.

FailedOperation.DeleteCluster

Failed to delete the cluster.

FailedOperation.DeleteEnvironmentRoles

Failed to delete the environment role.

FailedOperation.DeleteEnvironments

Failed to delete the environment.

FailedOperation.DeleteNamespace

Failed to delete the namespace.

FailedOperation.DeleteRoles

Failed to delete the role.

FailedOperation.DeleteSubscriptions

Failed to delete the subscription.

FailedOperation.DeleteTopics

Failed to delete the topic.

FailedOperation.DescribeSubscription

Failed to query the subscription data.

FailedOperation.GetEnvironmentAttributesFailed

Failed to get the environment attributes.

FailedOperation.GetTopicPartitionsFailed

Failed to get the number of topic partitions.

FailedOperation.InstanceNotReady

This instance is not ready. Please try again later.

FailedOperation.MaxMessageSizeError

The message size exceeds the upper limit of 1 MB.

FailedOperation.MessageIDError

The uploaded msgID is incorrect.

FailedOperation.NamespaceInUse

You must clear the associated namespace before
proceeding.

FailedOperation.ReceiveError

An error occurred while receiving the message.

FailedOperation.ReceiveTimeout

Message receiving timed out. Please try again.

FailedOperation.ResetMsgSubOffsetByTimestampFailed

Failed to configure message rewind.

FailedOperation.RoleInUse

You must clear the associated role data before
proceeding.

FailedOperation.SaveSecretKey

Failed to save the key.

FailedOperation.SendMessageTimeoutError

Message sending timed out.

FailedOperation.SendMsgFailed

Failed to send the message.

©2013-2022 Tencent Cloud. All rights reserved.

Page 447 of 450

TDMQ for Apache Pulsar

FailedOperation.SetRetentionPolicy

Failed to set the message retention policy.

FailedOperation.SetTTL

Failed to configure the message TTL.

FailedOperation.TopicInUse

You must clear the associated topic data before
proceeding.

FailedOperation.TopicTypeError

Please use a partition topic.

FailedOperation.UpdateEnvironment

Failed to update the environment.

FailedOperation.UpdateEnvironmentRole

Failed to update the environment role.

FailedOperation.UpdateRole

Failed to update the role.

FailedOperation.UpdateTopic

Failed to update the topic.

FailedOperation.VpcInUse

You must clear the associated VPC routing data
before proceeding.

InternalError.BrokerService

The broker service is exceptional.

InternalError.GetAttributesFailed

Failed to get attributes.

InternalError.IllegalMessage

Internal error.

InternalError.Retry

You can try again.

InternalError.SystemError

System error.

InvalidParameter.InvalidAdminUrl

Invalid management API address

InvalidParameter.Partition

Incorrect partition count.

InvalidParameter.TenantNotFoundThe uploaded tenant name is incorrect.

InvalidParameter.TokenNotFoundThe correct token was not obtained.

InvalidParameterValue.AtLeastOne
InvalidParameterValue.ClusterNameDuplication

The cluster name already exists.

InvalidParameterValue.InvalidParams

The parameter value is out of the value range.

InvalidParameterValue.NeedMoreParams

A required parameter is missing.

InvalidParameterValue.TTL

The message TTL value is invalid.

InvalidParameterValue.TopicNotFoundThe uploaded topic name is incorrect.

©2013-2022 Tencent Cloud. All rights reserved.

Page 448 of 450

TDMQ for Apache Pulsar

LimitExceeded.Clusters

The number of clusters under the instance exceeds
the limit.

LimitExceeded.Environments

The number of environments under the instanceexceeds the limit.

LimitExceeded.Namespaces

The number of namespaces under the instanceexceeds the limit.

LimitExceeded.RetentionSize

The remaining quota has been exceeded. Please
enter a valid value.

LimitExceeded.RetentionTime

The message retention period limit has been
exceeded. Please enter a valid value.

LimitExceeded.Subscriptions

The number of subscribers under the instanceexceeds the limit.

LimitExceeded.Topics
MissingParameter.NeedMoreParams
OperationDenied.ConsumerRunning

The number of topics under the instance exceeds
the limit.
A required parameter is missing.
Messages in the subscribed topic are being
consumed.

OperationDenied.DefaultEnvironment

Operations on the default environment are notallowed.

ResourceInUse.Cluster

The cluster already exists.

ResourceInUse.EnvironmentRole

The environment role already exists.

ResourceInUse.Namespace

A namespace with the same name already exists.

ResourceInUse.Queue

The queue already exists.

ResourceInUse.Role

The role already exists.

ResourceInUse.Subscription

A subscription with the same name already exists.

ResourceInUse.Topic

A topic with the same name already exists.

ResourceNotFound.BrokerCluster

The service cluster does not exist.

ResourceNotFound.Cluster

The cluster does not exist.

ResourceNotFound.Environment

The environment does not exist.

©2013-2022 Tencent Cloud. All rights reserved.

Page 449 of 450

TDMQ for Apache Pulsar

ResourceNotFound.EnvironmentRole

The environment role does not exist.

ResourceNotFound.Instance

The instance doesn’t exist.

ResourceNotFound.Namespace

The namespace does not exist.

ResourceNotFound.Role

The role does not exist.

ResourceNotFound.Subscription

The subscription does not exist.

ResourceNotFound.Topic

The topic does not exist.

ResourceUnavailable.CreateFailed

Assignment exception.

ResourceUnavailable.FundRequired

You must top up before proceeding.

ResourceUnavailable.SystemUpgrade

The system is being upgraded.

ResourcesSoldOut

The resources have been sold out.

UnsupportedOperation.InstanceDowngrade©2013-2022 Tencent Cloud. All rights reserved.

The instance does not support configuration
downgrade.

Page 450 of 450