diff --git a/docs/smn/api-ref/ALL_META.TXT.json b/docs/smn/api-ref/ALL_META.TXT.json new file mode 100644 index 00000000..2e024b41 --- /dev/null +++ b/docs/smn/api-ref/ALL_META.TXT.json @@ -0,0 +1,482 @@ +[ + { + "uri":"en-us_topic_0036017316.html", + "product_code":"smn", + "code":"1", + "des":"Public cloud APIs comply with the RESTful API design principles. REST-based Web services are organized into resources. Each resource is identified by one or more Uniform ", + "doc_type":"api", + "kw":"API Usage Guidelines,API Reference", + "title":"API Usage Guidelines", + "githuburl":"" + }, + { + "uri":"smn_api_50000.html", + "product_code":"smn", + "code":"2", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"APIs", + "title":"APIs", + "githuburl":"" + }, + { + "uri":"smn_api_51000.html", + "product_code":"smn", + "code":"3", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Topic Operations", + "title":"Topic Operations", + "githuburl":"" + }, + { + "uri":"smn_api_51001.html", + "product_code":"smn", + "code":"4", + "des":"API nameCreateTopicCreateTopicFunctionCreate a topic. Each user can create 3000 topics at most. In the high-concurrent scenario, a user may create a few topics more than ", + "doc_type":"api", + "kw":"Creating a Topic,Topic Operations,API Reference", + "title":"Creating a Topic", + "githuburl":"" + }, + { + "uri":"smn_api_51002.html", + "product_code":"smn", + "code":"5", + "des":"API nameUpdateTopicUpdateTopicFunctionUpdate the topic display name.Update the topic display name.URI formatPUT /v2/{project_id}/notifications/topics/{topic_urn}PUT /v2/{", + "doc_type":"api", + "kw":"Modifying a Topic,Topic Operations,API Reference", + "title":"Modifying a Topic", + "githuburl":"" + }, + { + "uri":"smn_api_51003.html", + "product_code":"smn", + "code":"6", + "des":"API nameDeleteTopicDeleteTopicFunctionDelete a topic and its subscribers. If a topic is deleted, a pending message will fail to deliver to the topic subscribers.Delete a ", + "doc_type":"api", + "kw":"Deleting a Topic,Topic Operations,API Reference", + "title":"Deleting a Topic", + "githuburl":"" + }, + { + "uri":"smn_api_51004.html", + "product_code":"smn", + "code":"7", + "des":"API nameListTopicsListTopicsFunctionQuery the topic list by page. The list is sorted by the topic creation time in descending order. If no topic has been created, an empt", + "doc_type":"api", + "kw":"Querying Topics,Topic Operations,API Reference", + "title":"Querying Topics", + "githuburl":"" + }, + { + "uri":"smn_api_51005.html", + "product_code":"smn", + "code":"8", + "des":"API nameQueryTopicDetailQueryTopicDetailFunctionQuery the detailed information about a topic.Query the detailed information about a topic.URI formatGET /v2/{project_id}/n", + "doc_type":"api", + "kw":"Querying Topic Details,Topic Operations,API Reference", + "title":"Querying Topic Details", + "githuburl":"" + }, + { + "uri":"smn_api_51006.html", + "product_code":"smn", + "code":"9", + "des":"API nameListTopicAttributesListTopicAttributesFunctionQuery the topic attribute information.Query the topic attribute information.URI formatGET /v2/{project_id}/notificat", + "doc_type":"api", + "kw":"Querying Topic Attributes,Topic Operations,API Reference", + "title":"Querying Topic Attributes", + "githuburl":"" + }, + { + "uri":"smn_api_51007.html", + "product_code":"smn", + "code":"10", + "des":"API nameUpdateTopicAttributeUpdateTopicAttributeFunctionModify the topic attributes.Modify the topic attributes.URI formatPUT /v2/{project_id}/notifications/topics/{topic", + "doc_type":"api", + "kw":"Modifying Topic Attributes,Topic Operations,API Reference", + "title":"Modifying Topic Attributes", + "githuburl":"" + }, + { + "uri":"smn_api_51008.html", + "product_code":"smn", + "code":"11", + "des":"API nameDeleteTopicAttributeByNameDeleteTopicAttributeByNameFunctionDelete a specified topic attribute.Delete a specified topic attribute.URI formatDELETE /v2/{project_id", + "doc_type":"api", + "kw":"Deleting a Specified Topic Attribute,Topic Operations,API Reference", + "title":"Deleting a Specified Topic Attribute", + "githuburl":"" + }, + { + "uri":"smn_api_51009.html", + "product_code":"smn", + "code":"12", + "des":"API nameDeleteTopicAttributesDeleteTopicAttributesFunctionDelete all topic attributes.Delete all topic attributes.URI formatDELETE /v2/{project_id}/notifications/topics/{", + "doc_type":"api", + "kw":"Deleting All Topic Attributes,Topic Operations,API Reference", + "title":"Deleting All Topic Attributes", + "githuburl":"" + }, + { + "uri":"smn_api_52000.html", + "product_code":"smn", + "code":"13", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Subscription Operations", + "title":"Subscription Operations", + "githuburl":"" + }, + { + "uri":"smn_api_52001.html", + "product_code":"smn", + "code":"14", + "des":"API nameListSubscriptionsListSubscriptionsFunctionQuery the list of all subscriptions by page. The list is sorted by the subscription adding time in ascending order. If n", + "doc_type":"api", + "kw":"Querying Subscriptions,Subscription Operations,API Reference", + "title":"Querying Subscriptions", + "githuburl":"" + }, + { + "uri":"smn_api_52002.html", + "product_code":"smn", + "code":"15", + "des":"API nameListSubscriptionsByTopicListSubscriptionsByTopicFunctionQuery the list of subscriptions of a specified topic by page. The list is sorted by the subscription addin", + "doc_type":"api", + "kw":"Querying Subscriptions of a Specified Topic,Subscription Operations,API Reference", + "title":"Querying Subscriptions of a Specified Topic", + "githuburl":"" + }, + { + "uri":"smn_api_52003.html", + "product_code":"smn", + "code":"16", + "des":"API nameSubscribeSubscribeFunctionAdd a subscription to a specified topic. If the status of the subscription is unconfirmed, a confirmation message is sent to the subscri", + "doc_type":"api", + "kw":"Adding a Subscription,Subscription Operations,API Reference", + "title":"Adding a Subscription", + "githuburl":"" + }, + { + "uri":"smn_api_52004.html", + "product_code":"smn", + "code":"17", + "des":"API nameUnsubscribeUnsubscribeFunctionDelete a specified subscription.Delete a specified subscription.URI formatDELETE /v2/{project_id}/notifications/subscriptions/{subsc", + "doc_type":"api", + "kw":"Deleting a Subscription,Subscription Operations,API Reference", + "title":"Deleting a Subscription", + "githuburl":"" + }, + { + "uri":"smn_api_53000.html", + "product_code":"smn", + "code":"18", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Template Operation", + "title":"Template Operation", + "githuburl":"" + }, + { + "uri":"smn_api_53001.html", + "product_code":"smn", + "code":"19", + "des":"API nameCreateMessageTemplateCreateMessageTemplateFunctionCreate a message template for quick message sending to reduce the request data volume.By default, a user can cre", + "doc_type":"api", + "kw":"Creating a Message Template,Template Operation,API Reference", + "title":"Creating a Message Template", + "githuburl":"" + }, + { + "uri":"smn_api_53002.html", + "product_code":"smn", + "code":"20", + "des":"API nameUpdateMessageTemplateUpdateMessageTemplateFunctionModify the message template content.Modify the message template content.URI formatPUT /v2/{project_id}/notificat", + "doc_type":"api", + "kw":"Modifying a Message Template,Template Operation,API Reference", + "title":"Modifying a Message Template", + "githuburl":"" + }, + { + "uri":"smn_api_53003.html", + "product_code":"smn", + "code":"21", + "des":"API nameDeleteMessageTemplateDeleteMessageTemplateFunctionDelete a message template. After you delete the template, you cannot use it to publish messages any more.Delete ", + "doc_type":"api", + "kw":"Deleting a Message Template,Template Operation,API Reference", + "title":"Deleting a Message Template", + "githuburl":"" + }, + { + "uri":"smn_api_53004.html", + "product_code":"smn", + "code":"22", + "des":"API nameListMessageTemplatesListMessageTemplatesFunctionQuery the template list by page. The list is sorted by the template creation time in ascending order. If no templa", + "doc_type":"api", + "kw":"Querying Message Templates,Template Operation,API Reference", + "title":"Querying Message Templates", + "githuburl":"" + }, + { + "uri":"smn_api_53005.html", + "product_code":"smn", + "code":"23", + "des":"API nameQueryMessageTemplateDetailQueryMessageTemplateDetailFunctionQuery the template details, including the template content.Query the template details, including the t", + "doc_type":"api", + "kw":"Querying the Message Template Details,Template Operation,API Reference", + "title":"Querying the Message Template Details", + "githuburl":"" + }, + { + "uri":"smn_api_54000.html", + "product_code":"smn", + "code":"24", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Message Publishing", + "title":"Message Publishing", + "githuburl":"" + }, + { + "uri":"smn_api_54001.html", + "product_code":"smn", + "code":"25", + "des":"API namePublishPublishFunctionPublish messages in the text format to a topic. After the message ID is returned, the message has been saved and is to be pushed to the subs", + "doc_type":"api", + "kw":"Publishing Messages in the Text Format,Message Publishing,API Reference", + "title":"Publishing Messages in the Text Format", + "githuburl":"" + }, + { + "uri":"smn_api_54002.html", + "product_code":"smn", + "code":"26", + "des":"API namePublishPublishFunctionUse the message structure to publish a message to the topic. After the message ID is returned, the message has been saved and is to be pushe", + "doc_type":"api", + "kw":"Publishing Messages Using a Message Structure,Message Publishing,API Reference", + "title":"Publishing Messages Using a Message Structure", + "githuburl":"" + }, + { + "uri":"smn_api_54003.html", + "product_code":"smn", + "code":"27", + "des":"API namePublishPublishFunctionUse the message template to publish a message to a topic. After the message ID is returned, the message has been saved and is to be pushed t", + "doc_type":"api", + "kw":"Publishing Messages Using a Template,Message Publishing,API Reference", + "title":"Publishing Messages Using a Template", + "githuburl":"" + }, + { + "uri":"smn_api_55000.html", + "product_code":"smn", + "code":"28", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"SMS Message Operations", + "title":"SMS Message Operations", + "githuburl":"" + }, + { + "uri":"smn_api_55001.html", + "product_code":"smn", + "code":"29", + "des":"Direct SMS messaging is not available to new users. If you want to use these APIs, go to Cloud Communications > Message&SMS.API nameSmsPublishSmsPublishFunctionSend a tra", + "doc_type":"api", + "kw":"Sending a Transactional SMS Message to a Phone Number,SMS Message Operations,API Reference", + "title":"Sending a Transactional SMS Message to a Phone Number", + "githuburl":"" + }, + { + "uri":"smn_api_56000.html", + "product_code":"smn", + "code":"30", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Resource Tag Operations", + "title":"Resource Tag Operations", + "githuburl":"" + }, + { + "uri":"smn_api_56001.html", + "product_code":"smn", + "code":"31", + "des":"API nameGetResourceInstancesGetResourceInstancesFunctionQuery SMN resources by tag.Query SMN resources by tag.URI formatPOST /v2/{project_id}/{resource_type}/resource_ins", + "doc_type":"api", + "kw":"Querying Resources by Tag,Resource Tag Operations,API Reference", + "title":"Querying Resources by Tag", + "githuburl":"" + }, + { + "uri":"smn_api_56002.html", + "product_code":"smn", + "code":"32", + "des":"API nameBatchCreateOrDeleteResourceTagsBatchCreateOrDeleteResourceTagsFunctionAdd or delete tags for a specified resource in batches.You can add a maximum of 10 tags to a", + "doc_type":"api", + "kw":"Adding or Deleting Resource Tags in Batches,Resource Tag Operations,API Reference", + "title":"Adding or Deleting Resource Tags in Batches", + "githuburl":"" + }, + { + "uri":"smn_api_56003.html", + "product_code":"smn", + "code":"33", + "des":"API nameCreateResourceTagCreateResourceTagFunctionYou can add a maximum of 10 tags to a resource.The API is idempotent. If a to-be-created tag has the same key as an exis", + "doc_type":"api", + "kw":"Adding a Resource Tag,Resource Tag Operations,API Reference", + "title":"Adding a Resource Tag", + "githuburl":"" + }, + { + "uri":"smn_api_56004.html", + "product_code":"smn", + "code":"34", + "des":"API nameDeleteResourceTagDeleteResourceTagFunctionThe API is idempotent. When deleting a tag, the system does not check its character set. The tag key cannot be left blan", + "doc_type":"api", + "kw":"Deleting a Resource Tag,Resource Tag Operations,API Reference", + "title":"Deleting a Resource Tag", + "githuburl":"" + }, + { + "uri":"smn_api_56005.html", + "product_code":"smn", + "code":"35", + "des":"API nameListResourceTagsListResourceTagsFunctionQuery tags of a specified resource.Query tags of a specified resource.URI formatGET /v2/{project_id}/{resource_type}/{reso", + "doc_type":"api", + "kw":"Querying Resource Tags,Resource Tag Operations,API Reference", + "title":"Querying Resource Tags", + "githuburl":"" + }, + { + "uri":"smn_api_56006.html", + "product_code":"smn", + "code":"36", + "des":"API nameGetProjectTagsGetProjectTagsFunctionQuery all tags of a resource type in a specified project.Query all tags of a resource type in a specified project.URI formatGE", + "doc_type":"api", + "kw":"Querying Tags in a Specified Project,Resource Tag Operations,API Reference", + "title":"Querying Tags in a Specified Project", + "githuburl":"" + }, + { + "uri":"smn_api_510000.html", + "product_code":"smn", + "code":"37", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Version Querying", + "title":"Version Querying", + "githuburl":"" + }, + { + "uri":"smn_api_510001.html", + "product_code":"smn", + "code":"38", + "des":"API nameQueryApiSupportVersionsQueryApiSupportVersionsFunctionList all SMN API versions.List all SMN API versions.URI formatGET /GET /Request exampleGET https://{SMN_Endp", + "doc_type":"api", + "kw":"Listing All SMN API Versions,Version Querying,API Reference", + "title":"Listing All SMN API Versions", + "githuburl":"" + }, + { + "uri":"smn_api_510002.html", + "product_code":"smn", + "code":"39", + "des":"API nameQueryV2ApiInfoQueryV2ApiInfoFunctionQuery the SMN API v2 version information.Query the SMN API v2 version information.URI formatGET /{api_version}GET /{api_versio", + "doc_type":"api", + "kw":"Querying the SMN API v2 Version,Version Querying,API Reference", + "title":"Querying the SMN API v2 Version", + "githuburl":"" + }, + { + "uri":"smn_api_60000.html", + "product_code":"smn", + "code":"40", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Public Parameters", + "title":"Public Parameters", + "githuburl":"" + }, + { + "uri":"smn_api_63000.html", + "product_code":"smn", + "code":"41", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"General Request Return Code", + "title":"General Request Return Code", + "githuburl":"" + }, + { + "uri":"smn_api_63001.html", + "product_code":"smn", + "code":"42", + "des":"Parameter descriptionParameterTypeDescriptionrequest_idStringRequest IDcodeStringSee section Error Code.messageStringSee section Error Code.Example{\n \"request_id\": \"aa", + "doc_type":"api", + "kw":"Exception Response,General Request Return Code,API Reference", + "title":"Exception Response", + "githuburl":"" + }, + { + "uri":"smn_api_63002.html", + "product_code":"smn", + "code":"43", + "des":"NormalReturned ValueDescription200The task is submitted successfully.201Resource creation succeeds.AbnormalReturned ValueDescription400 Bad RequestIncorrect request param", + "doc_type":"api", + "kw":"Returned Value,General Request Return Code,API Reference", + "title":"Returned Value", + "githuburl":"" + }, + { + "uri":"smn_api_64000.html", + "product_code":"smn", + "code":"44", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Error Code,Public Parameters,API Reference", + "title":"Error Code", + "githuburl":"" + }, + { + "uri":"smn_api_66000.html", + "product_code":"smn", + "code":"45", + "des":"A project ID needs to be specified in the URIs of some APIs. Therefore, you need to obtain the project ID before calling APIs. The following procedure describes how to ob", + "doc_type":"api", + "kw":"Obtaining a Project ID,Public Parameters,API Reference", + "title":"Obtaining a Project ID", + "githuburl":"" + }, + { + "uri":"smn_api_a0000.html", + "product_code":"smn", + "code":"46", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Appendix", + "title":"Appendix", + "githuburl":"" + }, + { + "uri":"smn_api_a1000.html", + "product_code":"smn", + "code":"47", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Topic Attribute List,Appendix,API Reference", + "title":"Topic Attribute List", + "githuburl":"" + }, + { + "uri":"smn_api_b0000.html", + "product_code":"smn", + "code":"48", + "des":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "doc_type":"api", + "kw":"Change History,API Reference", + "title":"Change History", + "githuburl":"" + } +] \ No newline at end of file diff --git a/docs/smn/api-ref/CLASS.TXT.json b/docs/smn/api-ref/CLASS.TXT.json new file mode 100644 index 00000000..106d1c6a --- /dev/null +++ b/docs/smn/api-ref/CLASS.TXT.json @@ -0,0 +1,434 @@ +[ + { + "desc":"Public cloud APIs comply with the RESTful API design principles. REST-based Web services are organized into resources. Each resource is identified by one or more Uniform ", + "product_code":"smn", + "title":"API Usage Guidelines", + "uri":"en-us_topic_0036017316.html", + "doc_type":"api", + "p_code":"", + "code":"1" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"APIs", + "uri":"smn_api_50000.html", + "doc_type":"api", + "p_code":"", + "code":"2" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Topic Operations", + "uri":"smn_api_51000.html", + "doc_type":"api", + "p_code":"2", + "code":"3" + }, + { + "desc":"API nameCreateTopicCreateTopicFunctionCreate a topic. Each user can create 3000 topics at most. In the high-concurrent scenario, a user may create a few topics more than ", + "product_code":"smn", + "title":"Creating a Topic", + "uri":"smn_api_51001.html", + "doc_type":"api", + "p_code":"3", + "code":"4" + }, + { + "desc":"API nameUpdateTopicUpdateTopicFunctionUpdate the topic display name.Update the topic display name.URI formatPUT /v2/{project_id}/notifications/topics/{topic_urn}PUT /v2/{", + "product_code":"smn", + "title":"Modifying a Topic", + "uri":"smn_api_51002.html", + "doc_type":"api", + "p_code":"3", + "code":"5" + }, + { + "desc":"API nameDeleteTopicDeleteTopicFunctionDelete a topic and its subscribers. If a topic is deleted, a pending message will fail to deliver to the topic subscribers.Delete a ", + "product_code":"smn", + "title":"Deleting a Topic", + "uri":"smn_api_51003.html", + "doc_type":"api", + "p_code":"3", + "code":"6" + }, + { + "desc":"API nameListTopicsListTopicsFunctionQuery the topic list by page. The list is sorted by the topic creation time in descending order. If no topic has been created, an empt", + "product_code":"smn", + "title":"Querying Topics", + "uri":"smn_api_51004.html", + "doc_type":"api", + "p_code":"3", + "code":"7" + }, + { + "desc":"API nameQueryTopicDetailQueryTopicDetailFunctionQuery the detailed information about a topic.Query the detailed information about a topic.URI formatGET /v2/{project_id}/n", + "product_code":"smn", + "title":"Querying Topic Details", + "uri":"smn_api_51005.html", + "doc_type":"api", + "p_code":"3", + "code":"8" + }, + { + "desc":"API nameListTopicAttributesListTopicAttributesFunctionQuery the topic attribute information.Query the topic attribute information.URI formatGET /v2/{project_id}/notificat", + "product_code":"smn", + "title":"Querying Topic Attributes", + "uri":"smn_api_51006.html", + "doc_type":"api", + "p_code":"3", + "code":"9" + }, + { + "desc":"API nameUpdateTopicAttributeUpdateTopicAttributeFunctionModify the topic attributes.Modify the topic attributes.URI formatPUT /v2/{project_id}/notifications/topics/{topic", + "product_code":"smn", + "title":"Modifying Topic Attributes", + "uri":"smn_api_51007.html", + "doc_type":"api", + "p_code":"3", + "code":"10" + }, + { + "desc":"API nameDeleteTopicAttributeByNameDeleteTopicAttributeByNameFunctionDelete a specified topic attribute.Delete a specified topic attribute.URI formatDELETE /v2/{project_id", + "product_code":"smn", + "title":"Deleting a Specified Topic Attribute", + "uri":"smn_api_51008.html", + "doc_type":"api", + "p_code":"3", + "code":"11" + }, + { + "desc":"API nameDeleteTopicAttributesDeleteTopicAttributesFunctionDelete all topic attributes.Delete all topic attributes.URI formatDELETE /v2/{project_id}/notifications/topics/{", + "product_code":"smn", + "title":"Deleting All Topic Attributes", + "uri":"smn_api_51009.html", + "doc_type":"api", + "p_code":"3", + "code":"12" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Subscription Operations", + "uri":"smn_api_52000.html", + "doc_type":"api", + "p_code":"2", + "code":"13" + }, + { + "desc":"API nameListSubscriptionsListSubscriptionsFunctionQuery the list of all subscriptions by page. The list is sorted by the subscription adding time in ascending order. If n", + "product_code":"smn", + "title":"Querying Subscriptions", + "uri":"smn_api_52001.html", + "doc_type":"api", + "p_code":"13", + "code":"14" + }, + { + "desc":"API nameListSubscriptionsByTopicListSubscriptionsByTopicFunctionQuery the list of subscriptions of a specified topic by page. The list is sorted by the subscription addin", + "product_code":"smn", + "title":"Querying Subscriptions of a Specified Topic", + "uri":"smn_api_52002.html", + "doc_type":"api", + "p_code":"13", + "code":"15" + }, + { + "desc":"API nameSubscribeSubscribeFunctionAdd a subscription to a specified topic. If the status of the subscription is unconfirmed, a confirmation message is sent to the subscri", + "product_code":"smn", + "title":"Adding a Subscription", + "uri":"smn_api_52003.html", + "doc_type":"api", + "p_code":"13", + "code":"16" + }, + { + "desc":"API nameUnsubscribeUnsubscribeFunctionDelete a specified subscription.Delete a specified subscription.URI formatDELETE /v2/{project_id}/notifications/subscriptions/{subsc", + "product_code":"smn", + "title":"Deleting a Subscription", + "uri":"smn_api_52004.html", + "doc_type":"api", + "p_code":"13", + "code":"17" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Template Operation", + "uri":"smn_api_53000.html", + "doc_type":"api", + "p_code":"2", + "code":"18" + }, + { + "desc":"API nameCreateMessageTemplateCreateMessageTemplateFunctionCreate a message template for quick message sending to reduce the request data volume.By default, a user can cre", + "product_code":"smn", + "title":"Creating a Message Template", + "uri":"smn_api_53001.html", + "doc_type":"api", + "p_code":"18", + "code":"19" + }, + { + "desc":"API nameUpdateMessageTemplateUpdateMessageTemplateFunctionModify the message template content.Modify the message template content.URI formatPUT /v2/{project_id}/notificat", + "product_code":"smn", + "title":"Modifying a Message Template", + "uri":"smn_api_53002.html", + "doc_type":"api", + "p_code":"18", + "code":"20" + }, + { + "desc":"API nameDeleteMessageTemplateDeleteMessageTemplateFunctionDelete a message template. After you delete the template, you cannot use it to publish messages any more.Delete ", + "product_code":"smn", + "title":"Deleting a Message Template", + "uri":"smn_api_53003.html", + "doc_type":"api", + "p_code":"18", + "code":"21" + }, + { + "desc":"API nameListMessageTemplatesListMessageTemplatesFunctionQuery the template list by page. The list is sorted by the template creation time in ascending order. If no templa", + "product_code":"smn", + "title":"Querying Message Templates", + "uri":"smn_api_53004.html", + "doc_type":"api", + "p_code":"18", + "code":"22" + }, + { + "desc":"API nameQueryMessageTemplateDetailQueryMessageTemplateDetailFunctionQuery the template details, including the template content.Query the template details, including the t", + "product_code":"smn", + "title":"Querying the Message Template Details", + "uri":"smn_api_53005.html", + "doc_type":"api", + "p_code":"18", + "code":"23" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Message Publishing", + "uri":"smn_api_54000.html", + "doc_type":"api", + "p_code":"2", + "code":"24" + }, + { + "desc":"API namePublishPublishFunctionPublish messages in the text format to a topic. After the message ID is returned, the message has been saved and is to be pushed to the subs", + "product_code":"smn", + "title":"Publishing Messages in the Text Format", + "uri":"smn_api_54001.html", + "doc_type":"api", + "p_code":"24", + "code":"25" + }, + { + "desc":"API namePublishPublishFunctionUse the message structure to publish a message to the topic. After the message ID is returned, the message has been saved and is to be pushe", + "product_code":"smn", + "title":"Publishing Messages Using a Message Structure", + "uri":"smn_api_54002.html", + "doc_type":"api", + "p_code":"24", + "code":"26" + }, + { + "desc":"API namePublishPublishFunctionUse the message template to publish a message to a topic. After the message ID is returned, the message has been saved and is to be pushed t", + "product_code":"smn", + "title":"Publishing Messages Using a Template", + "uri":"smn_api_54003.html", + "doc_type":"api", + "p_code":"24", + "code":"27" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"SMS Message Operations", + "uri":"smn_api_55000.html", + "doc_type":"api", + "p_code":"2", + "code":"28" + }, + { + "desc":"Direct SMS messaging is not available to new users. If you want to use these APIs, go to Cloud Communications > Message&SMS.API nameSmsPublishSmsPublishFunctionSend a tra", + "product_code":"smn", + "title":"Sending a Transactional SMS Message to a Phone Number", + "uri":"smn_api_55001.html", + "doc_type":"api", + "p_code":"28", + "code":"29" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Resource Tag Operations", + "uri":"smn_api_56000.html", + "doc_type":"api", + "p_code":"2", + "code":"30" + }, + { + "desc":"API nameGetResourceInstancesGetResourceInstancesFunctionQuery SMN resources by tag.Query SMN resources by tag.URI formatPOST /v2/{project_id}/{resource_type}/resource_ins", + "product_code":"smn", + "title":"Querying Resources by Tag", + "uri":"smn_api_56001.html", + "doc_type":"api", + "p_code":"30", + "code":"31" + }, + { + "desc":"API nameBatchCreateOrDeleteResourceTagsBatchCreateOrDeleteResourceTagsFunctionAdd or delete tags for a specified resource in batches.You can add a maximum of 10 tags to a", + "product_code":"smn", + "title":"Adding or Deleting Resource Tags in Batches", + "uri":"smn_api_56002.html", + "doc_type":"api", + "p_code":"30", + "code":"32" + }, + { + "desc":"API nameCreateResourceTagCreateResourceTagFunctionYou can add a maximum of 10 tags to a resource.The API is idempotent. If a to-be-created tag has the same key as an exis", + "product_code":"smn", + "title":"Adding a Resource Tag", + "uri":"smn_api_56003.html", + "doc_type":"api", + "p_code":"30", + "code":"33" + }, + { + "desc":"API nameDeleteResourceTagDeleteResourceTagFunctionThe API is idempotent. When deleting a tag, the system does not check its character set. The tag key cannot be left blan", + "product_code":"smn", + "title":"Deleting a Resource Tag", + "uri":"smn_api_56004.html", + "doc_type":"api", + "p_code":"30", + "code":"34" + }, + { + "desc":"API nameListResourceTagsListResourceTagsFunctionQuery tags of a specified resource.Query tags of a specified resource.URI formatGET /v2/{project_id}/{resource_type}/{reso", + "product_code":"smn", + "title":"Querying Resource Tags", + "uri":"smn_api_56005.html", + "doc_type":"api", + "p_code":"30", + "code":"35" + }, + { + "desc":"API nameGetProjectTagsGetProjectTagsFunctionQuery all tags of a resource type in a specified project.Query all tags of a resource type in a specified project.URI formatGE", + "product_code":"smn", + "title":"Querying Tags in a Specified Project", + "uri":"smn_api_56006.html", + "doc_type":"api", + "p_code":"30", + "code":"36" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Version Querying", + "uri":"smn_api_510000.html", + "doc_type":"api", + "p_code":"2", + "code":"37" + }, + { + "desc":"API nameQueryApiSupportVersionsQueryApiSupportVersionsFunctionList all SMN API versions.List all SMN API versions.URI formatGET /GET /Request exampleGET https://{SMN_Endp", + "product_code":"smn", + "title":"Listing All SMN API Versions", + "uri":"smn_api_510001.html", + "doc_type":"api", + "p_code":"37", + "code":"38" + }, + { + "desc":"API nameQueryV2ApiInfoQueryV2ApiInfoFunctionQuery the SMN API v2 version information.Query the SMN API v2 version information.URI formatGET /{api_version}GET /{api_versio", + "product_code":"smn", + "title":"Querying the SMN API v2 Version", + "uri":"smn_api_510002.html", + "doc_type":"api", + "p_code":"37", + "code":"39" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Public Parameters", + "uri":"smn_api_60000.html", + "doc_type":"api", + "p_code":"", + "code":"40" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"General Request Return Code", + "uri":"smn_api_63000.html", + "doc_type":"api", + "p_code":"40", + "code":"41" + }, + { + "desc":"Parameter descriptionParameterTypeDescriptionrequest_idStringRequest IDcodeStringSee section Error Code.messageStringSee section Error Code.Example{\n \"request_id\": \"aa", + "product_code":"smn", + "title":"Exception Response", + "uri":"smn_api_63001.html", + "doc_type":"api", + "p_code":"41", + "code":"42" + }, + { + "desc":"NormalReturned ValueDescription200The task is submitted successfully.201Resource creation succeeds.AbnormalReturned ValueDescription400 Bad RequestIncorrect request param", + "product_code":"smn", + "title":"Returned Value", + "uri":"smn_api_63002.html", + "doc_type":"api", + "p_code":"41", + "code":"43" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Error Code", + "uri":"smn_api_64000.html", + "doc_type":"api", + "p_code":"40", + "code":"44" + }, + { + "desc":"A project ID needs to be specified in the URIs of some APIs. Therefore, you need to obtain the project ID before calling APIs. The following procedure describes how to ob", + "product_code":"smn", + "title":"Obtaining a Project ID", + "uri":"smn_api_66000.html", + "doc_type":"api", + "p_code":"40", + "code":"45" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Appendix", + "uri":"smn_api_a0000.html", + "doc_type":"api", + "p_code":"", + "code":"46" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Topic Attribute List", + "uri":"smn_api_a1000.html", + "doc_type":"api", + "p_code":"46", + "code":"47" + }, + { + "desc":"HUAWEI CLOUD Help Center presents technical documents to help you quickly get started with HUAWEI CLOUD services. The technical documents include Service Overview, Price Details, Purchase Guide, User Guide, API Reference, Best Practices, FAQs, and Videos.", + "product_code":"smn", + "title":"Change History", + "uri":"smn_api_b0000.html", + "doc_type":"api", + "p_code":"", + "code":"48" + } +] \ No newline at end of file diff --git a/docs/smn/api-ref/PARAMETERS.txt b/docs/smn/api-ref/PARAMETERS.txt new file mode 100644 index 00000000..6da8d5f0 --- /dev/null +++ b/docs/smn/api-ref/PARAMETERS.txt @@ -0,0 +1,3 @@ +version="" +language="en-us" +type="" \ No newline at end of file diff --git a/docs/smn/api-ref/en-us_image_0257882142.jpg b/docs/smn/api-ref/en-us_image_0257882142.jpg new file mode 100644 index 00000000..b0e263d9 Binary files /dev/null and b/docs/smn/api-ref/en-us_image_0257882142.jpg differ diff --git a/docs/smn/api-ref/en-us_topic_0036017316.html b/docs/smn/api-ref/en-us_topic_0036017316.html new file mode 100644 index 00000000..ee98ebe8 --- /dev/null +++ b/docs/smn/api-ref/en-us_topic_0036017316.html @@ -0,0 +1,8 @@ + + +
Public cloud APIs comply with the RESTful API design principles. REST-based Web services are organized into resources. Each resource is identified by one or more Uniform Resource Identifiers (URIs). An application accesses a resource based on the resource's Unified Resource Locator (URL). A URL is usually in the following format: https://Endpoint/uri. In the URL, uri indicates the resource path, that is, the API access path.
+Public cloud APIs use HTTPS as the transmission protocol. Requests/Responses are transmitted by using JSON messages, with media type represented by Application/json.
+For details about how to use APIs, see API Usage Guidelines.
+QueryApiSupportVersions
+List all SMN API versions.
+GET /
+GET https://{SMN_Endpoint}/+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
versions + |
+Versions structure + |
+Version object list. For details, see Table 1. + |
+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
id + |
+String + |
+Version number, for example, v2 + |
+
min_version + |
+String + |
+Minimum micro-version number. If the APIs do not support micro-versions, no information will be returned. + |
+
status + |
+String + |
+Version status, which can be the following: +
|
+
updated + |
+String + |
+Version release time, which must be UTC time. For example, the release time of v2 is 2014-06-28T12:20:21Z. + |
+
version + |
+String + |
+Maximum micro-version number. If the APIs do not support micro-versions, no information will be returned. + |
+
links + |
+Links structure array + |
+URL of an API. For details, see Table 2. + |
+
{ + "versions": [ + { + "id": "v2", + "links": [ + { + "href": "https://127.0.0.1/v2", + "rel": "self" + } + ], + "min_version": "", + "status": "CURRENT", + "updated": "2018-09-19T00:00:00Z", + "version": "" + } + ] +}+
See section Returned Value.
+See section Error Code.
+QueryV2ApiInfo
+Query the SMN API v2 version information.
+GET /{api_version}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
api_version + |
+Yes + |
+String + |
+Version to be queried + NOTE:
+Currently, only v2 is supported. + |
+
GET https://{SMN_Endpoint}/v2+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
version + |
+Object + |
+Version object + |
+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
id + |
+String + |
+Version number, for example, v2 + |
+
links + |
+Links structure array + |
+URL of an API. For details, see Table 3. + |
+
min_version + |
+String + |
+Minimum micro-version number. If the APIs do not support micro-versions, no information will be returned. + |
+
status + |
+String + |
+Version status, which can be the following: +
|
+
updated + |
+String + |
+Version release time, which must be UTC time. For example, the release time of v2 is 2014-06-28T12:20:21Z. + |
+
version + |
+String + |
+Maximum micro-version number. If the APIs do not support micro-versions, no information will be returned. + |
+
{ + "version": + { + "id": "v2", + "links": [ + { + "href": "https://127.0.0.1/v2", + "rel": "self" + } + ], + "min_version": "", + "status": "CURRENT", + "updated": "2018-09-19T00:00:00Z", + "version": "" + } +}+
See section Returned Value.
+See section Error Code.
+CreateTopic
+Create a topic. Each user can create 3000 topics at most. In the high-concurrent scenario, a user may create a few topics more than 3000.
+The API is idempotent. It returns a successful result after creating a topic. If a topic of the same name already exists, the status code is 200. Otherwise, the status code is 201.
+POST /v2/{project_id}/notifications/topics
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
name + |
+Yes + |
+String + |
+Name of the topic to be created +The topic name is a string of 1 to 255 characters. It must contain letters, digits, hyphens (-), and underscores (_), and must start with a letter or digit. + |
+
display_name + |
+No + |
+String + |
+Topic display name, which is presented as the name of the email sender in email messages +The display name cannot exceed 192 bytes. +The value is left blank by default. + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/notifications/topics+
{ + "name": "test_topic_v2", + "display_name": "testtest" +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
topic_urn + |
+String + |
+Unique resource ID of a topic. You can obtain it based on Querying Topics. + |
+
{ + "request_id": "6a63a18b8bab40ffb71ebd9cb80d0085", + "topic_urn": "urn:smn:regionId:f96188c7ccaf4ffba0c9aa149ab2bd57:test_topic_v2" +}+
See Returned Value.
+See Error Code.
+UpdateTopic
+Update the topic display name.
+PUT /v2/{project_id}/notifications/topics/{topic_urn}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
display_name + |
+No + |
+String + |
+Topic display name, which is presented as the name of the email sender in email messages +The display name cannot exceed 192 bytes. + |
+
PUT https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId:f96188c7ccaf4ffba0c9aa149ab2bd57:test_topic_v2 +{ + "display_name":"testtest222" +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id": "6a63a18b8bab40ffb71ebd9cb80d0085" +}+
See section Returned Value.
+See section Error Code.
+DeleteTopic
+Delete a topic and its subscribers. If a topic is deleted, a pending message will fail to deliver to the topic subscribers.
+DELETE /v2/{project_id}/notifications/topics/{topic_urn}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
DELETE https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId:f96188c7ccaf4ffba0c9aa149ab2bd57:test_topic_v2+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id": " 5fcba32bd2814ea39431829c22bda94b", +}+
See section Returned Value.
+See section Error Code.
+ListTopics
+Query the topic list by page. The list is sorted by the topic creation time in descending order. If no topic has been created, an empty list is returned.
+GET /v2/{project_id}/notifications/topics?offset={offset}&limit={limit}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
offset + |
+No + |
+int + |
+Offset +If the value is an integer greater than 0 but less than the number of resources, all resources after this offset will be queried. The default value is 0. + |
+
limit + |
+No + |
+int + |
+
|
+
GET https://{SMN_Endpoint}/v2/{project_id}/notifications/topics?offset=0&limit=100+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
topic_count + |
+int + |
+Number of topics in your account + NOTE:
+No matter what offset and limit values you have set in the request, this parameter always returns the total number of topics. + |
+
topics + |
+Topic structure array + |
+Topic details +See Table 1. + |
+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
topic_urn + |
+String + |
+Resource identifier of a topic, which is unique + |
+
name + |
+String + |
+Topic name + |
+
display_name + |
+String + |
+Topic display name, which is presented as the name of the email sender in email messages + |
+
push_policy + |
+Int + |
+Message push policy +
|
+
{ + "request_id": "70bb40bef50e4a14b116a5a527fd7432", + "topic_count": 1, + "topics": [ + { + "topic_urn": "urn:smn:regionId:8bad8a40e0f7462f8c1676e3f93a8183:test_topic_v2", + "display_name": "testtest", + "name": "test_topic_v1", + "push_policy": 0 + } + ] +}+
See section Returned Value.
+See section Error Code.
+QueryTopicDetail
+Query the detailed information about a topic.
+GET /v2/{project_id}/notifications/topics/{topic_urn}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
GET https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId:8bad8a40e0f7462f8c1676e3f93a8183:test_create_topic_v2+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
name + |
+String + |
+Name of the topic + |
+
topic_urn + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
display_name + |
+String + |
+Topic display name, which is presented as the name of the email sender in email messages + |
+
push_policy + |
+int + |
+Message pushing policy +0 indicates that the message sending fails and the message is cached in the queue. 1 indicates that the failed message is discarded. + |
+
create_time + |
+String + |
+Time when the topic was created +The UTC time is in YYYY-MM-DDTHH:MM:SSZ format. + |
+
update_time + |
+String + |
+Time when the topic was updated +The UTC time is in YYYY-MM-DDTHH:MM:SSZ format. + |
+
{ + "update_time":"2016-08-01T02:16:38Z", + "push_policy":0, + "create_time":"2016-08-01T02:16:38Z", + "name":"test_create_topic_v2", + "topic_urn":"urn:smn:regionId:8bad8a40e0f7462f8c1676e3f93a8183:test_create_topic_v2", + "display_name":"test create topic v2", + "request_id":"6837531fd3f54550927b930180a706bf" +}+
See section Returned Value.
+See section Error Code.
+ListTopicAttributes
+Query the topic attribute information.
+GET /v2/{project_id}/notifications/topics/{topic_urn}/attributes?name={name}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
name + |
+No + |
+String + |
+Attribute name +Only specified attribute names are supported. For details, see section Topic Attribute List. + |
+
If the name parameter is not specified, all attribute values of the topic are queried. The supported attribute values are provided in section Topic Attribute List.
+GET https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId:8bad8a40e0f7462f8c1676e3f93a8183:test_create_topic_v2/attributes?name=access_policy+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
attributes + |
+Map + |
+Attribute key-value pair +access_policy: topic access policy +introduction: description of a topic + |
+
{ + "request_id":"6837531fd3f54550927b930180a706bf", + "attributes": { + "access_policy": "{ + "Version": "2016-09-07", + "Id": "__default_policy_ID", + "Statement": [ + { + "Sid": "__user_pub_0", + "Effect": "Allow", + "Principal": { + "CSP": [ + "urn:csp:iam::93dc1b4697ac493d9b7d089569f86b32:root" + ] + }, + "Action": ["SMN:Publish","SMN:QueryTopicDetail"], + "Resource": "urn:smn:regionId:8bad8a40e0f7462f8c1676e3f93a8183:aaa" + }, + { + "Sid": "__service_pub_0", + "Effect": "Allow", + "Principal": { + "Service": ["obs"] + }, + "Action": ["SMN:Publish","SMN:QueryTopicDetail"], + "Resource": "urn:smn:regionId:8bad8a40e0f7462f8c1676e3f93a8183:aaa" + } + ] + }" + } + }+
The value of access_policy is a JSON character string, which requires escape characters. While in the preceding example, the characters are not escaped. You need to escape them before using the policy.
+See section Returned Value.
+See section Error Code.
+UpdateTopicAttribute
+Modify the topic attributes.
+PUT /v2/{project_id}/notifications/topics/{topic_urn}/attributes/{name}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
name + |
+Yes + |
+String + |
+Attribute name +Only specified attribute names are supported. For details, see Topic Attribute List. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
value + |
+Yes + |
+String + |
+Topic attribute value +The value cannot exceed 30 KB. For details, see Table 1. + |
+
Name + |
+Description + |
+Restriction + |
+
---|---|---|
Version + |
+Policy specification version + |
+Currently, only 2016-09-07 is supported. + |
+
Id + |
+Policy ID, which uniquely identifies a policy + |
+The value cannot be empty. + |
+
Statement + |
+Statements used to configure a topic policy. Each topic policy may contain one or more statements. You can use statements to grant topic permissions to other users or cloud services. + |
+A policy must contain at least one statement. For details about elements in a statement, see Table 2. + |
+
Element + |
+Description + |
+Restriction + |
+
---|---|---|
Sid + |
+Statement ID + |
+The statement ID must be unique, for example, statement01 or statement02. + |
+
Effect + |
+Statement effect + |
+The value can be Allow or Deny. + |
+
Principal +NotPrincipal + |
+
|
+Either the Principal or NotPrincipal element must be configured. +
|
+
Action +NotAction + |
+
|
+Either the Action or NotAction element must be configured. +The following actions are supported: +
|
+
Resource +NotResource + |
+
|
+Either the Resource or NotResource element must be configured. +You need to enter a topic URN. + |
+
PUT https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/{topic_urn}/attributes/access_policy+
{ + "value": "{ + \"Version\": \"2016-09-07\", + \"Id\": \"__default_policy_ID\", + \"Statement\": [ + { + \"Sid\": \"__user_pub_0\", + \"Effect\": \"Allow\", + \"Principal\": { + \"CSP\": [ + \"urn:csp:iam::{domainID}:root\" + ] + }, + \"Action\": [\"SMN:Publish\",\"SMN:QueryTopicDetail\"], + \"Resource\": \"{topic_urn}\" + }, + { + \"Sid\": \"__service_pub_0\", + \"Effect\": \"Allow\", + \"Principal\": { + \"Service\": [\"obs\"] + }, + \"Action\": [\"SMN:Publish\",\"SMN:QueryTopicDetail\"], + \"Resource\": \"{topic_urn}\" + } + ] + }" + }+
You need to replace {project_id}, {domainID}, and {topic_urn} with the actual values.
+domainID indicates the user's domain ID. To obtain it, log in to the SMN console, click My Credential in the username drop-down list on the upper right.
+Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id":"6837531fd3f54550927b930180a706bf" +}+
See Returned Value.
+See Error Code.
+DeleteTopicAttributeByName
+Delete a specified topic attribute.
+DELETE /v2/{project_id}/notifications/topics/{topic_urn}/attributes/{name}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
name + |
+Yes + |
+String + |
+Attribute name +Only specified attribute names are supported. For details, see section Topic Attribute List. + |
+
DELETE https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/{topic_urn}/attributes/access_policy+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id":"6837531fd3f54550927b930180a706bf" +}+
See Returned Value.
+See Error Code.
+DeleteTopicAttributes
+Delete all topic attributes.
+DELETE /v2/{project_id}/notifications/topics/{topic_urn}/attributes
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
DELETE https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/{topic_urn}/attributes+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id":"6837531fd3f54550927b930180a706bf" +}+
See section Returned Value.
+See section Error Code.
+ListSubscriptions
+Query the list of all subscriptions by page. The list is sorted by the subscription adding time in ascending order. If no subscription has been added, an empty list is returned.
+GET /v2/{project_id}/notifications/subscriptions?offset={offset}&limit={limit}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
offset + |
+No + |
+int + |
+Offset +If the value is an integer greater than 0 but less than the number of resources, all resources after this offset will be queried. The default value is 0. + |
+
limit + |
+No + |
+int + |
+
The default value is 100. + |
+
GET https://{SMN_Endpoint}/v2/{project_id}/notifications/subscriptions?offset=0&limit=2+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
subscription_count + |
+int + |
+Number of subscriptions + |
+
subscriptions + |
+Subscription structure array + |
+See Table 1. + |
+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
topic_urn + |
+String + |
+Resource identifier of a topic, which is unique + |
+
protocol + |
+String + |
+Subscription protocol (Different protocols indicate different types of endpoints to receive messages.) +Currently, the following protocols are supported: +
|
+
subscription_urn + |
+String + |
+Resource identifier of a subscription, which is unique + |
+
owner + |
+String + |
+Project ID of the topic creator + |
+
endpoint + |
+String + |
+Message receiving endpoint + |
+
remark + |
+String + |
+Remarks + |
+
status + |
+Int + |
+Subscription status +
|
+
{ + "request_id": "4650b14bf221492fb819c231d167e6fe", + "subscription_count": 2, + "subscriptions": [ + { + "topic_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1", + "protocol": "sms", + "subscription_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1:2e778e84408e44058e6cbc6d3c377837", + "owner": "762bdb3251034f268af0e395c53ea09b", + "endpoint": "xxxxxxxxxxx", + "remark": "", + "status": 0 + }, + { + "topic_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1", + "protocol": "email", + "subscription_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1:a2d52a9f5c3b47f48c3fafb177a58796", + "owner": "762bdb3251034f268af0e395c53ea09b", + "endpoint": "xx@xx.com", + "remark": "", + "status": 0 + } +] +}+
See section Returned Value.
+See section Error Code.
+ListSubscriptionsByTopic
+Query the list of subscriptions of a specified topic by page. The list is sorted by the subscription adding time in ascending order. If no subscription has been added to the topic, an empty list is returned.
+GET /v2/{project_id}/notifications/topics/{topic_urn}/subscriptions?offset={offset}&limit={limit}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
offset + |
+No + |
+int + |
+Offset +If the value is an integer greater than 0 but less than the number of resources, all resources after this offset will be queried. The default value is 0. + |
+
limit + |
+No + |
+int + |
+
|
+
GET https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1/subscriptions?offset=0&limit=100+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
subscription_count + |
+int + |
+Number of subscriptions + |
+
subscriptions + |
+Subscription structure array + |
+For details, see Table 1. + |
+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
topic_urn + |
+String + |
+Resource identifier of a topic, which is unique + |
+
protocol + |
+String + |
+Subscription protocol (Different protocols indicate different types of endpoints to receive messages.) +Currently, the following protocols are supported: +
|
+
subscription_urn + |
+String + |
+Resource identifier of a subscription, which is unique + |
+
owner + |
+String + |
+Project ID of the topic creator + |
+
endpoint + |
+String + |
+Message receiving endpoint + |
+
remark + |
+String + |
+Remarks + |
+
status + |
+Int + |
+Subscription status +
|
+
{ + "request_id": "4650b14bf221492fb819c231d167e6fe", + "subscription_count": 2, + "subscriptions": [ + { + "topic_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1", + "protocol": "sms", + "subscription_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1:2e778e84408e44058e6cbc6d3c377837", + "owner": "762bdb3251034f268af0e395c53ea09b", + "endpoint": "xxxxxxxxxx", + "remark": "", + "status": 0 + }, + { + "topic_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1", + "protocol": "email", + "subscription_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1:a2d52a9f5c3b47f48c3fafb177a58796", + "owner": "762bdb3251034f268af0e395c53ea09b", + "endpoint": "xx@xx.com", + "remark": "", + "status": 0 + } +] +}+
See section Returned Value.
+See section Error Code.
+Subscribe
+Add a subscription to a specified topic. If the status of the subscription is unconfirmed, a confirmation message is sent to the subscriber. After confirming the subscription, the subscriber can receive notification messages published to the topic.
+By default, 10000 subscriptions can be added to a topic. However, in a high-concurrency scenario, which is rare, extra subscriptions may be added successfully.
+The API is idempotent. If the added subscription already exists, a successful result and status code 200 are returned. Otherwise, the status code is 201.
+POST /v2/{project_id}/notifications/topics/{topic_urn}/subscriptions
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
endpoint + |
+Yes + |
+String + |
+Message endpoint + NOTE:
+For an HTTP subscription, the endpoint starts with http://. +For an HTTPS subscription, the endpoint starts with https://. +For an email subscription, the endpoint is an email address. +For an SMS subscription, the endpoint is a phone number. +For a DMS subscription, the endpoint is a message queue. + |
+
protocol + |
+Yes + |
+String + |
+Subscription protocol (Different protocols indicate different types of endpoints to receive messages.) +Currently, the following protocols are supported: +
|
+
remark + |
+No + |
+String + |
+Description of the subscription +The remarks must be a UTF-8-coded character string containing 128 bytes at most. + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1/subscriptions+
{ + "protocol": "email", + "endpoint": "xxx@xxx.com", + "remark": "O&M" +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
subscription_urn + |
+String + |
+Resource identifier of a subscription, which is unique + |
+
{ + "request_id": "fdbabe38ead6482b8574f82a3d1168e9", + "subscription_urn": "urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1:2e778e84408e44058e6cbc6d3c377837" +}+
See section Returned Value.
+See section Error Code.
+Unsubscribe
+Delete a specified subscription.
+DELETE /v2/{project_id}/notifications/subscriptions/{subscription_urn}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
subscription_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Subscriptions. + |
+
DELETE https://{SMN_Endpoint}/v2/{project_id}/notifications/subscriptions/urn:smn:regionId:762bdb3251034f268af0e395c53ea09b:test_topic_v1:2e778e84408e44058e6cbc6d3c377837+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id":"f3197b274a6b473a8007eed79e716c30" +}+
See section Returned Value.
+See section Error Code.
+CreateMessageTemplate
+Create a message template for quick message sending to reduce the request data volume.
+By default, a user can create a maximum of 100 message templates. However, in a high-concurrency scenario, which is rare, extra templates may be successfully created.
+POST /v2/{project_id}/notifications/message_template
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
message_template_name + |
+Yes + |
+String + |
+Template name +The template name is a string of 1 to 64 characters. It must contain upper- or lower-case letters, digits, hyphens (-), and underscores (_), and must start with a letter or digit. + |
+
content + |
+Yes + |
+String + |
+Template content, which currently supports plain text only +The template content cannot be left blank or larger than 256 KB. + |
+
protocol + |
+No + |
+String + |
+Protocol supported by the template +Currently, the following protocols are supported: +
|
+
POST https://{SMN_Endpoint}/v2/{project_id}/notifications/message_template+
{ + "message_template_name": "confirm_message", + "protocol": "https", + "content": "(1/2)You are invited to subscribe to topic({topic_id}). Click the following URL to confirm subscription:(If you do not want to subscribe to this topic, ignore this message.)" +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
message_template_id + |
+String + |
+Resource identifier of the template, which is unique + |
+
{ + "request_id":"ca03efa691624d8eb2dfeba01a1bcf6e", + "message_template_id":"57ba8dcecda844878c5dd5815b65d10f" +}+
See section Returned Value.
+See section Error Code.
+UpdateMessageTemplate
+Modify the message template content.
+PUT /v2/{project_id}/notifications/message_template/{message_template_id}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
message_template_id + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Message Templates. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
content + |
+Yes + |
+String + |
+Template content, which currently supports plain text only +The template content cannot be left blank or larger than 256 KB. + |
+
PUT https://{SMN_Endpoint}/v2/{project_id}/notifications/message_template/b3ffa2cdda574168826316f0628f774f+
{ + "content": "(1/22)You are invited to subscribe to topic({topic_id_id1}). Click the following URL to confirm subscription:(If you do not want to subscribe to this topic, ignore this message.)" +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id": "5fcba32bd2814ea39431829c22bda94b" +}+
See section Returned Value.
+See section Error Code.
+DeleteMessageTemplate
+Delete a message template. After you delete the template, you cannot use it to publish messages any more.
+DELETE /v2/{project_id}/notifications/message_template/{message_template_id}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
message_template_id + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Message Templates. + |
+
DELETE https://{SMN_Endpoint}/v2/{project_id}/notifications/message_template/b3ffa2cdda574168826316f0628f774e+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "request_id": " 5fcba32bd2814ea39431829c22bda94b" +}+
See section Returned Value.
+See section Error Code.
+ListMessageTemplates
+Query the template list by page. The list is sorted by the template creation time in ascending order. If no template has been created, an empty list is returned. The parameters message_template_name and protocol are added.
+The template list provides only brief information. To query the template details, see section Querying the Message Template Details.
+GET /v2/{project_id}/notifications/message_template?offset={offset}&limit={limit}&message_template_name={message_template_name}&protocol={protocol}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
offset + |
+No + |
+int + |
+Offset +If the value is an integer greater than 0 but less than the number of resources, all resources after this offset will be queried. The default value is 0. + |
+
limit + |
+No + |
+int + |
+
|
+
message_template_name + |
+No + |
+String + |
+Template name +The template name is a string of 1 to 64 characters. It must contain upper- or lower-case letters, digits, hyphens (-), and underscores (_), and must start with a letter or digit. + |
+
protocol + |
+No + |
+String + |
+Protocol supported by the template +Currently, the following protocols are supported: +
|
+
GET https://{SMN_Endpoint}/v2/{project_id}/notifications/message_template?offset=0&limit=2&message_template_name=test1&protocol=email+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
message_template_count + |
+int + |
+Number of returned templates + |
+
message_templates + |
+Message template structure array + |
+For details, see Table 1. + |
+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
message_template_id + |
+String + |
+Template ID + |
+
message_template_name + |
+String + |
+Template name + |
+
protocol + |
+String + |
+Protocol supported by the template +Currently, the following protocols are supported: +
|
+
tag_names + |
+String array + |
+Template variable list + |
+
create_time + |
+String + |
+Time when the template was created +The UTC time is in YYYY-MM-DDTHH:MM:SSZ format. + |
+
update_time + |
+String + |
+Last time when the template was updated +The UTC time is in YYYY-MM-DDTHH:MM:SSZ format. + |
+
{ + "message_templates":[ + { + "message_template_name":"confirm_message", + "update_time":"2016-08-02T08:22:18Z", + "create_time":"2016-08-02T08:22:18Z", + "tag_names":[ + "topic_urn" + ], + "message_template_id":"79227dfdf88d4e52a1820ca1eb411635" + }, + { + "message_template_name":"confirm_message", + "protocol":"email", + "update_time":"2016-08-02T08:22:19Z", + "create_time":"2016-08-02T08:22:19Z", + "tag_names":[ + "topic_id" + ], + "message_template_id":"ecf63465804a4b10a0573980be78ffba" + }, + { + "message_template_name":"confirm_message", + "protocol":"https", + "update_time":"2016-08-02T08:22:20Z", + "create_time":"2016-08-02T08:22:20Z", + "tag_names":[ + "topic_id" + ], + "message_template_id":"57ba8dcecda844878c5dd5815b65d10f" + } + ], + "request_id":"ce7f2f7343224f8c9597b05a9a0bcc2e", + "message_template_count":3 +}+
See section Returned Value.
+See section Error Code.
+QueryMessageTemplateDetail
+Query the template details, including the template content.
+GET /v2/{project_id}/notifications/message_template/{message_template_id}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
message_template_id + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Message Templates. + |
+
GET https://{SMN_Endpoint}/v2/{project_id}/notifications/message_template/57ba8dcecda844878c5dd5815b65d10f+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
message_template_id + |
+String + |
+Template ID + |
+
message_template_name + |
+String + |
+Template name + |
+
protocol + |
+String + |
+Protocol supported by the template +Currently, the following protocols are supported: +
|
+
tag_names + |
+String + |
+Variable list +The variable name will be quoted in braces ({}) in the template. When you use a template to send messages, you can replace the variable with any content. + |
+
create_time + |
+String + |
+Time when the template was created +The UTC time is in YYYY-MM-DDTHH:MM:SSZ format. + |
+
update_time + |
+String + |
+Last time when the template was updated +The UTC time is in YYYY-MM-DDTHH:MM:SSZ format. + |
+
content + |
+String + |
+Template content + |
+
request_id + |
+String + |
+Request ID, which is unique + |
+
{ + "message_template_name": "confirm_message", + "protocol": "https", + "update_time": "2016-08-02T08:22:25Z", + "create_time": "2016-08-02T08:22:20Z", + "request_id":"ba79ca8f794f4f50985ce7b98a401b47", + "tag_names": [ + "topic_id_id4" + ], + "content": "(1/24)You are invited to subscribe to topic({topic_id_id4}). Click the following URL to confirm subscription:(If you do not want to subscribe to this topic, ignore this message.)", + "message_template_id": "57ba8dcecda844878c5dd5815b65d10f" +}+
See section Returned Value.
+See section Error Code.
+Publish
+Publish messages in the text format to a topic. After the message ID is returned, the message has been saved and is to be pushed to the subscribers of the topic.
+POST /v2/{project_id}/notifications/topics/{topic_urn}/publish
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
subject + |
+Yes + |
+String + |
+Message subject, which is used as the email subject when you publish email messages. The value cannot exceed 512 characters. + |
+
message + |
+Yes + |
+String + |
+Message content +The message content is a UTF-8-coded character string of no more than 256 KB. For SMS subscribers, if the content exceeds 256 bytes, the system will divide it into multiple messages and send only the first two. + + |
+
time_to_live + |
+No + |
+String + |
+Time-to-live (TTL) of a message, specifically, the maximum time period for retaining the message in the system +If the period expires, the system will discard the message. The time period is measured in seconds, and the default TTL is 3600s (one hour). +The value must be a positive integer less than or equal to 604,800 (3600 x 24 x 7). + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId: f96188c7ccaf4ffba0c9aa149ab2bd57:test_create_topic_v2/publish+
{ + "subject": "test message v2", + "message": "Message test message v2", + "time_to_live":"3600" +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
message_id + |
+String + |
+Message ID, which is unique + |
+
{ + "message_id": "bf94b63a5dfb475994d3ac34664e24f2", + "request_id": "9974c07f6d554a6d827956acbeb4be5f" +}+
See section Returned Value.
+See section Error Code.
+Publish
+Use the message structure to publish a message to the topic. After the message ID is returned, the message has been saved and is to be pushed to the subscribers of the topic. This API allows you to send different message content to different types of subscribers.
+POST /v2/{project_id}/notifications/topics/{topic_urn}/publish
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
subject + |
+Yes + |
+String + |
+Message subject, which is presented as the email subject when SMN sends massages to email subscribers +The message subject cannot exceed 512 bytes. + |
+
message_structure + |
+Yes + |
+String + |
+Message structure, which contains JSON character strings. Specify protocols in the structure, which can be http, https, email, dms, and sms. +The default protocol is mandatory. If the system fails to match any other protocols, the default message is sent. + NOTE:
+Three message formats are supported: +
If the three formats are specified at the same time, they take effect in the following sequence: message_structure > message_template_name > message. + |
+
time_to_live + |
+No + |
+String + |
+TTL of a message, specifically, the maximum time period for retaining the message in the system +If the period expires, the system will discard the message. The time period is measured in seconds, and the default TTL is 3600s (one hour). +The value must be a positive integer less than or equal to 604,800 (3600 x 24 x 7). + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId: f96188c7ccaf4ffba0c9aa149ab2bd57:test_create_topic_v2/publish+
{ + "subject": "test message v2", + "time_to_live":"3600", + "message_structure": "{"default":"test v2 default", "email":"abc"}" +}+
For example, a topic has two types of subscriptions, SMS and email. After the API is called to publish messages, the email subscriber will receive message "abc", and the SMS subscriber will receive the default message "test v2 default".
+Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
message_id + |
+String + |
+Message ID, which is unique + |
+
{ + "message_id": "bf94b63a5dfb475994d3ac34664e24f2", + "request_id": "9974c07f6d554a6d827956acbeb4be5f" +}+
See section Returned Value.
+See section Error Code.
+Publish
+Use the message template to publish a message to a topic. After the message ID is returned, the message has been saved and is to be pushed to the subscribers of the topic. This API allows you to send messages to different types of subscribers using different template protocols with the same name.
+POST /v2/{project_id}/notifications/topics/{topic_urn}/publish
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
topic_urn + |
+Yes + |
+String + |
+Unique resource ID of a topic. You can obtain it according to Querying Topics. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
subject + |
+Yes + |
+String + |
+Message subject, which is presented as the email subject when SMN sends massages to email subscribers +The message subject cannot exceed 512 bytes. + |
+
message_template_name + |
+Yes + |
+String + |
+Message template name, which can be obtained according to Querying Message Templates + NOTE:
+Three message formats are supported: +
If the three formats are specified at the same time, they take effect in the following sequence: +message_structure>message_template_name>message + |
+
tags + |
+Yes + |
+JSON key-value pair + |
+Variable parameters and values +The value cannot be left blank. + |
+
time_to_live + |
+No + |
+String + |
+TTL of a message, specifically, the maximum time period for retaining the message in the system +If the period expires, the system will discard the message. The time period is measured in seconds, and the default TTL is 3600s (one hour). +The value must be a positive integer less than or equal to 604,800 (3600 x 24 x 7). + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/notifications/topics/urn:smn:regionId: f96188c7ccaf4ffba0c9aa149ab2bd57:test_create_topic_v2/publish+
{ + "subject": "test message template v2", + "message_template_name": "confirm_message", + "time_to_live":"3600", + "tags": { + "topic_urn": "topic_urn3331", + "topic_id": "topic_id3332" + } +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
message_id + |
+String + |
+Message ID, which is unique + |
+
{ + "message_id": "bf94b63a5dfb475994d3ac34664e24f2", + "request_id": "9974c07f6d554a6d827956acbeb4be5f" +}+
See section Returned Value.
+See section Error Code.
+Direct SMS messaging is not available to new users. If you want to use these APIs, go to Cloud Communications > Message&SMS.
+SmsPublish
+Send a transactional SMS message to a specified phone number, usually used for verification code or notification.
+POST /v2/{project_id}/notifications/sms
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
endpoint + |
+Yes + |
+String + |
+Phone number +The phone number must be preceded by a plus sign (+) and a country code. + |
+
message + |
+Yes + |
+String + |
+SMS message content +If the content exceeds 256 bytes, the system will divide it into multiple messages, each containing 256 bytes at most and send only the first two. + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/notifications/sms +{ + "endpoint": "+00111****1990", + "message": "SMS message test" +}+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID, which is unique + |
+
message_id + |
+String + |
+Message ID, which is unique + |
+
{ + "message_id": "bf94b63a5dfb475994d3ac34664e24f2", + "request_id": "9974c07f6d554a6d827956acbeb4be5f" +}+
See section Returned Value.
+See section Error Code.
+GetResourceInstances
+Query SMN resources by tag.
+POST /v2/{project_id}/{resource_type}/resource_instances/action
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
resource_type + |
+Yes + |
+String + |
+Resource type +The value can be the following: +smn_topic: topic + + + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
tags + |
+No + |
+Tags structure array + |
+Includes specified tags. For details, see Table 1. + NOTE:
+The structure body is mandatory. A maximum of 10 tag keys are allowed in each query operation. The tag key cannot be left blank or set to the empty string. Each tag key can have up to 10 tag values. Each tag key and tag values of one key must be unique. Resources identified by different keys are in AND relationship. + |
+
tags_any + |
+No + |
+Tags structure array + |
+Includes any of the specified tags. For details, see Table 1. + NOTE:
+The structure body is mandatory. A maximum of 10 tag keys are allowed in each query operation. The tag key cannot be left blank or set to the empty string. Each tag key can have up to 10 tag values. Each tag key and tag values of one key must be unique. Resources identified by different keys are in OR relationship. + |
+
not_tags + |
+No + |
+Tags structure array + |
+Excludes specified tags. For details, see Table 1. + NOTE:
+The structure body is mandatory. A maximum of 10 tag keys are allowed in each query operation. The tag key cannot be left blank or set to the empty string. Each tag key can have up to 10 tag values. Each tag key and tag values of one key must be unique. Resources identified by different keys are in NAND relationship. + |
+
not_tags_any + |
+No + |
+Tags structure array + |
+Excludes any of the specified tags. For details, see Table 1. + NOTE:
+The structure body is mandatory. A maximum of 10 tag keys are allowed in each query operation. The tag key cannot be left blank or set to the empty string. Each tag key can have up to 10 tag values. Each tag key and tag values of one key must be unique. Resources identified by different keys are in NOR relationship. + |
+
limit + |
+No + |
+String + |
+Maximum number of resources to be queried +
|
+
offset + |
+No + |
+String + |
+Start location of pagination query. The query starts from the next resource of the specified location. You do not need to specify this parameter when querying resources on the first page. When you query resources on subsequent pages, set this parameter to the location returned in the response body for the previous query. +
|
+
action + |
+Yes + |
+String + |
+Operation to be performed. The value can be filter or count (case-sensitive). +filter: queries resources in pages based on filter conditions. +count: queries the total number of resources meeting filter conditions. + |
+
matches + |
+No + |
+Match condition structure array + |
+Key-value pair to be matched +The key can only be resource_name. +The value will be exactly matched. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+Constraint + |
+
---|---|---|---|---|
key + |
+Yes + |
+String + |
+Tag key + |
+A key contains 127 Unicode characters and cannot be blank. + |
+
values + |
+Yes + |
+String list + |
+Value list + |
+Each value contains a maximum of 255 Unicode characters. If the value starts with an asterisk (*), the character string following the asterisk is fuzzy-matched. The values field cannot be missing, but can be an empty list. If it is empty, any value will be matched. The values are in OR relationship. + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/{resource_type}/resource_instances/action+
{ + "offset": "100", + "limit": "100", + "action": "filter", + "matches":[ + { + "key": "resource_name", + "value": "resource1" + } + ], + "not_tags": [ + { + "key": "key1", + "values": ["*value1","value2"] + }, + { + "key": "key2", + "values": ["*value21","value22"] + } + ], + "tags": [ + { + "key": "key1", + "values": ["*value1","value2"] + } + ], + "tags_any": [ + { + "key": "key1", + "values": ["value1", "value2"] + } + ], + "not_tags_any": [ + { + "key": "key1", + "values": ["value1", "value2"] + } + ] +}+
{ + "action": "count", + "not_tags": [ + { + "key": "key1", + "values": ["value1", "*value2"] + } + ], + "tags": [ + { + "key": "key1", + "values": ["value1", "value2"] + } + ], + "tags_any": [ + { + "key": "key1", + "values": [ "value1", "value2"] + } + ], + "not_tags_any": [ + { + "key": "key1", + "values": ["value1", "value2"] + } + ], + "matches":[ + { + "key": "resource_name", + "value": "resouurce" + } + ] +}+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
resources + |
+Yes + |
+Resource structure array + |
+For details, see Table 2. + |
+
total_count + |
+Yes + |
+Integer + |
+Total number of resources + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
resource_id + |
+Yes + |
+String + |
+Resource ID + |
+
resource_detail + |
+Yes + |
+Object + |
+Resource details. Resource object used for extension. The value is left blank by default. +For topic resources, the value of this field is {"topic_urn":"${TopicUrn}","display_name":"display name"}. +For other resources, the value is null. + |
+
tags + |
+Yes + |
+Resource_tag structure array + |
+List of queried tags. If no tag is matched, an empty array is returned. For details, see Table 3. + |
+
resource_name + |
+Yes + |
+String + |
+Resource name + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+Constraint + |
+
---|---|---|---|---|
key + |
+Yes + |
+String + |
+Tag key + |
+The key contains 36 Unicode characters at most and cannot be blank or an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
value + |
+Yes + |
+String + |
+Tag value + |
+Each value contains 43 Unicode characters at most and can be an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
Response body when action is set to filter
+{ + "resources": [ + { + "resource_detail": { + "topic_urn":"urn:smn:regionId:f96188c7ccaf4ffba0c9aa149ab2bd57:resouece1", + "display_name":"testtest" + }, + "resource_id": "cffe4fc4c9a54219b60dbaf7b586e132", + "resource_name": "resouece1", + "tags": [ + { + "key": "key1", + "value": "value1" + } + ] + } + ], + "total_count": 1000 +}+
Response body when action is set to count
+{ + "total_count": 1000 +}+
See section Returned Value.
+See section Error Code.
+BatchCreateOrDeleteResourceTags
+Add or delete tags for a specified resource in batches.
+You can add a maximum of 10 tags to a resource.
+The API is idempotent. When you are to create tags, if there are duplicate keys in the request body, an error is reported.
+If a to-be-created tag has the same key as an existing tag, the tag will be created and overwrite the existing one.
+When tags are being deleted and some tags do not exist, the operation is considered successful by default. The character set of the tags will not be checked.
+POST /v2/{project_id}/{resource_type}/{resource_id}/tags/action
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
resource_type + |
+Yes + |
+String + |
+Resource type +The value can be the following: +smn_topic: topic + + + |
+
resource_id + |
+Yes + |
+String + |
+Resource ID +Obtain a resource ID: +
|
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
tags + |
+Yes + |
+Resource_tag structure array + |
+Tag list. For details, see Table 1. +When you delete tags, the tag structure cannot be missing, and the key cannot be left blank or be an empty string. The system does not check the character set when deleting a tag. + |
+
action + |
+Yes + |
+String + |
+Operation to be performed, which can be create or delete + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+Constraint + |
+
---|---|---|---|---|
key + |
+Yes + |
+String + |
+Tag key + |
+The key contains 36 Unicode characters at most and cannot be blank or an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
value + |
+Yes + |
+String + |
+Tag value + |
+Each value contains 43 Unicode characters at most and can be an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/{resource_type}/{resource_id}/tags/action+
{ + "action": "create", + "tags": [ + { + "key": "key1", + "value": "value1" + }, + { + "key": "key", + "value": "value3" + } + ] +}+
Request body when action is set to delete
+{ + "action": "delete", + "tags": [ + { + "key": "key1" + }, + { + "key": "key2", + "value": "value3" + } + ] +}+
None
+See Returned Value.
+See section Error Code.
+CreateResourceTag
+You can add a maximum of 10 tags to a resource.
+The API is idempotent. If a to-be-created tag has the same key as an existing tag, the tag will be created and overwrite the existing one.
+POST /v2/{project_id}/{resource_type}/{resource_id}/tags
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
resource_type + |
+Yes + |
+String + |
+Resource type +The value can be the following: +smn_topic: topic + + + |
+
resource_id + |
+Yes + |
+String + |
+Resource ID +Obtain a resource ID: +
|
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
tag + |
+Yes + |
+Resource tag structure + |
+Resource tag to be added. For details, see Table 1. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+Constraint + |
+
---|---|---|---|---|
key + |
+Yes + |
+String + |
+Tag key + |
+The key contains 36 Unicode characters at most and cannot be blank or an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
value + |
+Yes + |
+String + |
+Tag value + |
+Each value contains 43 Unicode characters at most and can be an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
POST https://{SMN_Endpoint}/v2/{project_id}/{resource_type}/{resource_id}/tags+
{ + "tag": + { + "key":"DEV", + "value":"DEV1" + } +}+
None
+See Returned Value.
+See section Error Code.
+DeleteResourceTag
+The API is idempotent. When deleting a tag, the system does not check its character set. The tag key cannot be left blank or be an empty string. If the key of the tag to be deleted does not exist, 404 will be returned.
+DELETE /v2/{project_id}/{resource_type}/{resource_id}/tags/{key}
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
resource_type + |
+Yes + |
+String + |
+Resource type +The value can be the following: +smn_topic: topic + + + |
+
resource_id + |
+Yes + |
+String + |
+Resource ID +Obtain a resource ID: +
|
+
DELETE https://{SMN_Endpoint}/v2/{project_id}/{resource_type}/{resource_id}/tags/{key}+
None
+See Returned Value.
+See section Error Code.
+ListResourceTags
+Query tags of a specified resource.
+GET /v2/{project_id}/{resource_type}/{resource_id}/tags
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
resource_type + |
+Yes + |
+String + |
+Resource type +The value can be the following: +smn_topic: topic + + + |
+
resource_id + |
+Yes + |
+String + |
+Resource ID +Obtain a resource ID: +
|
+
None
+GET https://{SMN_Endpoint}/v2/{project_id}/{resource_type}/{resource_id}/tags+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
tags + |
+Resource_tag structure array + |
+Tag list. For details, see Table 1. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+Constraint + |
+
---|---|---|---|---|
key + |
+Yes + |
+String + |
+Tag key + |
+The key contains 36 Unicode characters at most and cannot be blank or an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
value + |
+Yes + |
+String + |
+Tag value + |
+Each value contains 43 Unicode characters at most and can be an empty string. It can contain only digits, letters, hyphens (-), and underscores (_) and must not start or end with a space. + |
+
{ + "tags": [ + { + "key": "key1", + "value": "value1" + }, + { + "key": "key2", + "value": "value3" + } + ] +}+
See section Returned Value.
+See section Error Code.
+GetProjectTags
+Query all tags of a resource type in a specified project.
+GET /v2/{project_id}/{resource_type}/tags
+Parameter + |
+Mandatory + |
+Type + |
+Description + |
+
---|---|---|---|
project_id + |
+Yes + |
+String + |
+Project ID + + |
+
resource_type + |
+Yes + |
+String + |
+Resource type +The value can be the following: +smn_topic: topic + + + |
+
None
+GET https://{SMN_Endpoint}/v2/{project_id}/{resource_type}/tags+
Parameter + |
+Type + |
+Description + |
+
---|---|---|
tags + |
+Tags structure array + |
+Tag list. For details, see Table 1. + |
+
Parameter + |
+Mandatory + |
+Type + |
+Description + |
+Constraint + |
+
---|---|---|---|---|
key + |
+Yes + |
+String + |
+Tag key + |
+A key contains 127 Unicode characters and cannot be blank. + |
+
values + |
+Yes + |
+String list + |
+Value list + |
+Each value contains a maximum of 255 Unicode characters. If the value starts with an asterisk (*), the character string following the asterisk is fuzzy-matched. The values field cannot be missing, but can be an empty list. If it is empty, any value will be matched. The values are in OR relationship. + |
+
{ + "tags": [ + { + "key": "key1", + "values": ["value1""value2"] + }, + { + "key": "key2", + "values": ["value1","value2"] + } + ] +}+
See section Returned Value.
+See section Error Code.
+Parameter + |
+Type + |
+Description + |
+
---|---|---|
request_id + |
+String + |
+Request ID + |
+
code + |
+String + |
+See section Error Code. + |
+
message + |
+String + |
+See section Error Code. + |
+
{ + "request_id": "aad0860d089c482b943971f802a6718e", + "code": "SMN.0006", + "message": "Topic not found." +}+
Returned Value + |
+Description + |
+
---|---|
200 + |
+The task is submitted successfully. + |
+
201 + |
+Resource creation succeeds. + |
+
Returned Value + |
+Description + |
+
---|---|
400 Bad Request + |
+Incorrect request parameters. + |
+
401 Unauthorized + |
+Authentication failed. + |
+
403 Forbidden + |
+No permission to access the requested resource. + |
+
404 Not Found + |
+The requested resource does not exist. + |
+
500 Internal Server Error + |
+The request fails because the server is abnormal. + |
+
501 Not Implemented + |
+The request fails because the server does not support the requested function. + |
+
502 Bad Gateway + |
+The request fails because the returned response is invalid. + |
+
503 Service Unavailable + |
+The request fails because the system is abnormal. + |
+
504 Gateway Timeout + |
+Gateway times out. + |
+
Module + |
+HTTP Status Code + |
+Error Code + |
+Error Message + |
+Handling Measure + |
+
---|---|---|---|---|
Tag management + |
+400 + |
+SMN.0038 + |
+Parameter: tag is invalid. + |
+Enter a valid value for tag. + |
+
Tag management + |
+403 + |
+SMN.0075 + |
+Parameter: tags are too many. + |
+A message template can contain a maximum of 90 non-repeated variables. + |
+
Direct SMS messaging + |
+403 + |
+SMN.0057 + |
+The number of SMS messages exceeds the limit. + |
+You can send at most 60 SMS messages to a single phone number within one hour and 200 within 12 hours. +This limit is applicable only to direct SMS message sending. There is no limit on the number of messages you can publish to a topic. + |
+
Public + |
+403 + |
+SMN.0001 + |
+No permission to request resources. + |
+Add the required permission. + |
+
Public + |
+400 + |
+SMN.0015 + |
+Parameter: Offset or limit is invalid. + |
+Enter a valid offset and limit. + |
+
Public + |
+500 + |
+SMN.0016 + |
+Database Exceptions. + |
+Contact customer service for technical support. + |
+
Public + |
+400 + |
+SMN.0017 + |
+Parameter: Remark is invalid. + |
+Enter a valid value for remark. + |
+
Public + |
+500 + |
+SMN.0018 + |
+Service internal error. + |
+Contact customer service for technical support. + |
+
Public + |
+403 + |
+SMN.0022 + |
+Parameter: token is invalid. + |
+Specify a valid token. + |
+
Public + |
+400 + |
+SMN.0033 + |
+Parameter: push_policy is invalid. + |
+Enter a valid value for push_policy. + |
+
Public + |
+400 + |
+SMN.0034 + |
+Parameter: subscription_auth_policy is invalid. + |
+Enter a valid value for subscription_auth_policy. + |
+
Public + |
+400 + |
+SMN.0035 + |
+Parameter: validation_policy is invalid. + |
+Enter a valid value for validation_policy. + |
+
Public + |
+400 + |
+SMN.0036 + |
+Parameter: xdomain_type is invalid. + |
+Enter a valid value for xdomain_type. + |
+
Public + |
+400 + |
+SMN.0059 + |
+Parameter: job_id is invalid. + |
+Contact customer service for technical support. + |
+
Public + |
+404 + |
+SMN.0060 + |
+Job not found. + |
+Contact customer service for technical support. + |
+
Public + |
+400 + |
+SMN.0061 + |
+Parameter: Service name is invalid. + |
+Contact customer service for technical support. + |
+
Public + |
+400 + |
+SMN.0062 + |
+Parameter: Show name is invalid. + |
+Contact customer service for technical support. + |
+
Public + |
+404 + |
+SMN.0063 + |
+Cloud service not found. + |
+Contact customer service for technical support. + |
+
Public + |
+403 + |
+SMN.0065 + |
+The number of email messages exceeds the limit. + |
+Contact customer service for technical support. + |
+
Public + |
+400 + |
+SMN.0066 + |
+Parameter: System parameter name is invalid. + |
+Contact customer service for technical support. + |
+
Public + |
+400 + |
+SMN.0067 + |
+Parameter: System parameter value is invalid. + |
+Contact customer service for technical support. + |
+
Public + |
+404 + |
+SMN.0068 + |
+System parameter not found. + |
+Contact customer service for technical support. + |
+
Public + |
+403 + |
+SMN.0069 + |
+Not authorized to subscribe internal endpoints. + |
+Enter a correct HTTP/HTTPS endpoint. + |
+
Public + |
+403 + |
+SMN.0070 + |
+No permission to request resources. The role is op_restricted. Contact customer service. + |
+Check the account balance and top up your account. If the fault persists, contact customer service. + |
+
Public + |
+403 + |
+SMN.0071 + |
+No permission to request resources. The role is op_suspended. + |
+Check whether your account has been frozen. + |
+
Public + |
+400 + |
+SMN.0074 + |
+Failed to add permission. + |
+Contact customer service for technical support. + |
+
Public + |
+400 + |
+SMN.0077 + |
+Parameter: Status is invalid. + |
+Enter a valid value for status. + |
+
Subscription management + |
+400 + |
+SMN.0011 + |
+Parameter: Protocol is invalid. + |
+Specify a correct protocol. + |
+
Subscription management + |
+400 + |
+SMN.0012 + |
+Parameter: Endpoint is invalid. + |
+Specify a valid endpoint. + |
+
Subscription management + |
+404 + |
+SMN.0013 + |
+Subscription resource not found. + |
+Specify an existing subscription endpoint. + |
+
Subscription management + |
+400 + |
+SMN.0014 + |
+Parameter: SubscriptionUrn is invalid. + |
+Enter a valid subscription URN. + |
+
Subscription management + |
+400 + |
+SMN.0043 + |
+Parameter: subscription is invalid. + |
+Enter a valid value for subscription. + |
+
Subscription management + |
+403 + |
+SMN.0078 + |
+The maximum number of subscriptions has been reached. + |
+The number of subscriptions has reached the limit. + |
+
Publishing a message + |
+403 + |
+SMN.0008 + |
+Parameter: Subject is invalid. + |
+Enter a valid value for subject. + |
+
Publishing a message + |
+403 + |
+SMN.0009 + |
+Parameter: Message is invalid. + |
+Enter a valid message. + |
+
Publishing a message + |
+400 + |
+SMN.0019 + |
+Producer Exceptions. + |
+Contact customer service for technical support. + |
+
Publishing a message + |
+400 + |
+SMN.0021 + |
+MessageStructure is invalid. + |
+Specify a correct message structure. + |
+
Message template + |
+400 + |
+SMN.0024 + |
+Parameter: content is invalid. + |
+Enter valid message template content. + |
+
Message template + |
+200 + |
+SMN.0025 + |
+Template already exists. + |
+You cannot create the same template twice. + |
+
Message template + |
+404 + |
+SMN.0027 + |
+Template not found. + |
+Specify an existing message template. + |
+
Message template + |
+400 + |
+SMN.0031 + |
+Parameter: template_id is invalid. + |
+Enter a valid template ID. + |
+
Message template + |
+400 + |
+SMN.0032 + |
+Parameter: message_template_name is invalid. + |
+Enter a valid value for message_template_name. + |
+
Message template + |
+400 + |
+SMN.0042 + |
+Parameter: Message_template_name is invalid. + |
+Enter a valid value for message_template_name. + |
+
Message template + |
+400 + |
+SMN.0044 + |
+Exceeded template limit. + |
+You can create a maximum of 100 text message templates. + |
+
Message template + |
+404 + |
+SMN.0076 + |
+Default message template not found. + |
+Create a default message template using the same template name. + |
+
Topic management + |
+400 + |
+SMN.0002 + |
+Parameter: Name is invalid. + |
+Enter a valid topic name. + |
+
Topic management + |
+400 + |
+SMN.0003 + |
+Parameter: DisplayName is invalid. + |
+Enter a valid topic display name. + |
+
Topic management + |
+403 + |
+SMN.0004 + |
+Exceeded topic limit. + |
+You can create a maximum of 3000 topics. + |
+
Topic management + |
+400 + |
+SMN.0005 + |
+Parameter: TopicUrn is invalid. + |
+Enter a valid topic URN. + |
+
Topic management + |
+404 + |
+SMN.0006 + |
+Topic not found. + |
+The topic does not exist. + |
+
Topic management + |
+403 + |
+SMN.0007 + |
+Exceeded subscription limit. + |
+A maximum of 10,000 subscriptions can be added to a topic. + |
+
Topic management + |
+404 + |
+SMN.0045 + |
+Attribute not found. + |
+Specify an existing attribute. + |
+
Topic management + |
+400 + |
+SMN.0046 + |
+Parameter: Attribute name is invalid. + |
+Enter a valid attribute name. + |
+
Topic management + |
+403 + |
+SMN.0047 + |
+Parameter: Value exceeds the maximum length. + |
+Enter a valid value. + |
+
Topic management + |
+400 + |
+SMN.0048 + |
+Parameter: Access policy is invalid. + |
+Enter a valid value for access_policy. + |
+
Topic management + |
+400 + |
+SMN.0049 + |
+Parameter: Access policy version is invalid. + |
+Enter a valid access policy version. + |
+
Topic management + |
+400 + |
+SMN.0050 + |
+Parameter: Access policy ID is invalid. + |
+Enter a valid policy ID. + |
+
Topic management + |
+400 + |
+SMN.0051 + |
+Parameter: Access policy statement is invalid. + |
+Enter a valid policy statement. + |
+
Topic management + |
+400 + |
+SMN.0052 + |
+Parameter: Access policy statement ID is invalid. + |
+Enter a valid policy statement ID. + |
+
Topic management + |
+400 + |
+SMN.0053 + |
+Parameter: Access policy statement resource is invalid. + |
+Enter a valid policy statement resource. + |
+
Topic management + |
+400 + |
+SMN.0054 + |
+Parameter: Access policy statement effect is invalid. + |
+Enter a valid policy statement effect. + |
+
Topic management + |
+400 + |
+SMN.0055 + |
+Parameter: Access policy statement action is invalid. + |
+Enter a valid policy statement action. + |
+
Topic management + |
+400 + |
+SMN.0056 + |
+Parameter: Access policy statement principal is invalid. + |
+Enter a valid policy statement principal. + |
+
Topic management + |
+400 + |
+SMN.0058 + |
+Parameter: Access policy statement condition is invalid. + |
+Enter a valid policy statement condition. + |
+
Topic management + |
+400 + |
+SMN.0072 + |
+Parameter: Service is invalid. + |
+Enter a valid value for service. + |
+
Topic management + |
+400 + |
+SMN.0073 + |
+Parameter: Invalid action. + |
+Enter a valid value for action. + |
+
A project ID needs to be specified in the URIs of some APIs. Therefore, you need to obtain the project ID before calling APIs. The following procedure describes how to obtain a project ID:
+On the My Credential page, view project IDs in the project list.
+In multi-project scenarios, expand the region, and obtain your sub-project ID from the Project ID column.
+Attribute Name + |
+Function + |
+Default Value + |
+
---|---|---|
access_policy + |
+Configures topic access policy, which is used to limit the access permission of other users. + |
+Empty string + |
+
Date + |
+Description + |
+
---|---|
2019-02-15 + |
+This issue incorporates the following changes: +
|
+
2018-09-30 + |
+This issue incorporates the following changes: +Added Version Querying. + |
+
2018-06-21 + |
+This issue incorporates the following changes: +Accepted in OTC-3.1 + |
+
2018-06-05 + |
+This issue incorporates the following changes: +Updated the description for resource_type. (Currently, only smn_topic is supported). + |
+
2018-05-24 + |
+This issue incorporates the following changes: +Added the way to obtain a resource ID. + |
+
2018-04-30 + |
+This issue incorporates the following changes: +
|
+
2018-03-30 + |
+This issue incorporates the following changes: +Added the DMS subscription protocol. + |
+
2017-08-30 + |
+This issue incorporates the following changes: +Added description for obtaining a project ID. + |
+
2017-06-30 + |
+This issue incorporates the following changes: +Added Error Code. + |
+
2016-12-30 + |
+This issue is the first official release. + |
+