This topic lists the mappings between the Message Service (MNS) API operations and the Resource Access Management (RAM) permissions. You can grant access permissions to different RAM users based on the mapping table in this topic to ensure the data security of MNS.

Notice To ensure data security, SMS messages or emails are sent for verification when you create a RAM user, create a permission policy, and attach the policy to the RAM user.

Mappings between MNS API operations and RAM permissions

MNS API Action Resource
ListQueue mns:ListQueue acs:mns:$region:$accountid:/queues
CreateQueue mns:CreateQueue acs:mns:$region:$accountid:/queues/$queueName
DeleteQueue mns:DeleteQueue acs:mns:$region:$accountid:/queues/$queueName
SetQueueAttributes mns:SetQueueAttributes acs:mns:$region:$accountid:/queues/$queueName
GetQueueAttributes mns:GetQueueAttributes acs:mns:$region:$accountid:/queues/$queueName
SendMessage or BatchSendMessage mns:SendMessage acs:mns:$region:$accountid:/queues/$queueName/messages
ReceiveMessage or BatchReceiveMessage mns:ReceiveMessage acs:mns:$region:$accountid:/queues/$queueName/messages
DeleteMessage mns:DeleteMessage acs:mns:$region:$accountid:/queues/$queueName/messages
PeekMessage or BatchPeekMessage mns:PeekMessage acs:mns:$region:$accountid:/queues/$queueName/messages
ChangeMessageVisibility mns:ChangeMessageVisibility acs:mns:$region:$accountid:/queues/$queueName/messsages
ListTopic mns:ListTopic acs:mns:$region:$accountid:/topics
CreateTopic mns:CreateTopic acs:mns:$region:$accountid:/topics/$topicName
DeleteTopic mns:DeleteTopic acs:mns:$region:$accountid:/topics/$topicName
SetTopicAttributes mns:SetTopicAttributes acs:mns:$region:$accountid:/topics/$topicName
GetTopicAttributes mns:GetTopicAttributes acs:mns:$region:$accountid:/topics/$topicName
ListSubscriptionByTopic mns:ListSubscriptionByTopic acs:mns:$region:$accountid:/topics/$topicName/subscriptions
Subscribe mns:Subscribe acs:mns:$region:$accountid:/topics/$topicName/subscriptions/$subscriptionName
Unsubscribe mns:Unsubscribe acs:mns:$region:$accountid:/topics/$topicName/subscriptions/$subscriptionName
SetSubscriptionAttributes mns:SetSubscriptionAttributes acs:mns:$region:$accountid:/topics/$topicName/subscriptions/$subscriptionName
GetSubscriptionAttributes mns:GetSubscriptionAttributes acs:mns:$region:$accountid:/topics/$topicName/subscriptions/$subscriptionName
PublishMessage mns:PublishMessage acs:mns:$region:$accountid:/topics/$topicName/messages