Documentation ¶
Index ¶
- func GenReqDefForAddSubscription() *def.HttpRequestDef
- func GenReqDefForBatchCreateOrDeleteResourceTags() *def.HttpRequestDef
- func GenReqDefForCancelSubscription() *def.HttpRequestDef
- func GenReqDefForCreateApplication() *def.HttpRequestDef
- func GenReqDefForCreateApplicationEndpoint() *def.HttpRequestDef
- func GenReqDefForCreateMessageTemplate() *def.HttpRequestDef
- func GenReqDefForCreateResourceTag() *def.HttpRequestDef
- func GenReqDefForCreateTopic() *def.HttpRequestDef
- func GenReqDefForDeleteApplication() *def.HttpRequestDef
- func GenReqDefForDeleteApplicationEndpoint() *def.HttpRequestDef
- func GenReqDefForDeleteMessageTemplate() *def.HttpRequestDef
- func GenReqDefForDeleteResourceTag() *def.HttpRequestDef
- func GenReqDefForDeleteTopic() *def.HttpRequestDef
- func GenReqDefForDeleteTopicAttributeByName() *def.HttpRequestDef
- func GenReqDefForDeleteTopicAttributes() *def.HttpRequestDef
- func GenReqDefForListApplicationAttributes() *def.HttpRequestDef
- func GenReqDefForListApplicationEndpointAttributes() *def.HttpRequestDef
- func GenReqDefForListApplicationEndpoints() *def.HttpRequestDef
- func GenReqDefForListApplications() *def.HttpRequestDef
- func GenReqDefForListMessageTemplateDetails() *def.HttpRequestDef
- func GenReqDefForListMessageTemplates() *def.HttpRequestDef
- func GenReqDefForListProjectTags() *def.HttpRequestDef
- func GenReqDefForListResourceInstances() *def.HttpRequestDef
- func GenReqDefForListResourceTags() *def.HttpRequestDef
- func GenReqDefForListSubscriptions() *def.HttpRequestDef
- func GenReqDefForListSubscriptionsByTopic() *def.HttpRequestDef
- func GenReqDefForListTopicAttributes() *def.HttpRequestDef
- func GenReqDefForListTopicDetails() *def.HttpRequestDef
- func GenReqDefForListTopics() *def.HttpRequestDef
- func GenReqDefForListVersion() *def.HttpRequestDef
- func GenReqDefForListVersions() *def.HttpRequestDef
- func GenReqDefForPublishAppMessage() *def.HttpRequestDef
- func GenReqDefForPublishMessage() *def.HttpRequestDef
- func GenReqDefForUpdateApplication() *def.HttpRequestDef
- func GenReqDefForUpdateApplicationEndpoint() *def.HttpRequestDef
- func GenReqDefForUpdateMessageTemplate() *def.HttpRequestDef
- func GenReqDefForUpdateTopic() *def.HttpRequestDef
- func GenReqDefForUpdateTopicAttribute() *def.HttpRequestDef
- func SmnClientBuilder() *http_client.HcHttpClientBuilder
- type SmnClient
- func (c *SmnClient) AddSubscription(request *model.AddSubscriptionRequest) (*model.AddSubscriptionResponse, error)
- func (c *SmnClient) BatchCreateOrDeleteResourceTags(request *model.BatchCreateOrDeleteResourceTagsRequest) (*model.BatchCreateOrDeleteResourceTagsResponse, error)
- func (c *SmnClient) CancelSubscription(request *model.CancelSubscriptionRequest) (*model.CancelSubscriptionResponse, error)
- func (c *SmnClient) CreateApplication(request *model.CreateApplicationRequest) (*model.CreateApplicationResponse, error)
- func (c *SmnClient) CreateApplicationEndpoint(request *model.CreateApplicationEndpointRequest) (*model.CreateApplicationEndpointResponse, error)
- func (c *SmnClient) CreateMessageTemplate(request *model.CreateMessageTemplateRequest) (*model.CreateMessageTemplateResponse, error)
- func (c *SmnClient) CreateResourceTag(request *model.CreateResourceTagRequest) (*model.CreateResourceTagResponse, error)
- func (c *SmnClient) CreateTopic(request *model.CreateTopicRequest) (*model.CreateTopicResponse, error)
- func (c *SmnClient) DeleteApplication(request *model.DeleteApplicationRequest) (*model.DeleteApplicationResponse, error)
- func (c *SmnClient) DeleteApplicationEndpoint(request *model.DeleteApplicationEndpointRequest) (*model.DeleteApplicationEndpointResponse, error)
- func (c *SmnClient) DeleteMessageTemplate(request *model.DeleteMessageTemplateRequest) (*model.DeleteMessageTemplateResponse, error)
- func (c *SmnClient) DeleteResourceTag(request *model.DeleteResourceTagRequest) (*model.DeleteResourceTagResponse, error)
- func (c *SmnClient) DeleteTopic(request *model.DeleteTopicRequest) (*model.DeleteTopicResponse, error)
- func (c *SmnClient) DeleteTopicAttributeByName(request *model.DeleteTopicAttributeByNameRequest) (*model.DeleteTopicAttributeByNameResponse, error)
- func (c *SmnClient) DeleteTopicAttributes(request *model.DeleteTopicAttributesRequest) (*model.DeleteTopicAttributesResponse, error)
- func (c *SmnClient) ListApplicationAttributes(request *model.ListApplicationAttributesRequest) (*model.ListApplicationAttributesResponse, error)
- func (c *SmnClient) ListApplicationEndpointAttributes(request *model.ListApplicationEndpointAttributesRequest) (*model.ListApplicationEndpointAttributesResponse, error)
- func (c *SmnClient) ListApplicationEndpoints(request *model.ListApplicationEndpointsRequest) (*model.ListApplicationEndpointsResponse, error)
- func (c *SmnClient) ListApplications(request *model.ListApplicationsRequest) (*model.ListApplicationsResponse, error)
- func (c *SmnClient) ListMessageTemplateDetails(request *model.ListMessageTemplateDetailsRequest) (*model.ListMessageTemplateDetailsResponse, error)
- func (c *SmnClient) ListMessageTemplates(request *model.ListMessageTemplatesRequest) (*model.ListMessageTemplatesResponse, error)
- func (c *SmnClient) ListProjectTags(request *model.ListProjectTagsRequest) (*model.ListProjectTagsResponse, error)
- func (c *SmnClient) ListResourceInstances(request *model.ListResourceInstancesRequest) (*model.ListResourceInstancesResponse, error)
- func (c *SmnClient) ListResourceTags(request *model.ListResourceTagsRequest) (*model.ListResourceTagsResponse, error)
- func (c *SmnClient) ListSubscriptions(request *model.ListSubscriptionsRequest) (*model.ListSubscriptionsResponse, error)
- func (c *SmnClient) ListSubscriptionsByTopic(request *model.ListSubscriptionsByTopicRequest) (*model.ListSubscriptionsByTopicResponse, error)
- func (c *SmnClient) ListTopicAttributes(request *model.ListTopicAttributesRequest) (*model.ListTopicAttributesResponse, error)
- func (c *SmnClient) ListTopicDetails(request *model.ListTopicDetailsRequest) (*model.ListTopicDetailsResponse, error)
- func (c *SmnClient) ListTopics(request *model.ListTopicsRequest) (*model.ListTopicsResponse, error)
- func (c *SmnClient) ListVersion(request *model.ListVersionRequest) (*model.ListVersionResponse, error)
- func (c *SmnClient) ListVersions(request *model.ListVersionsRequest) (*model.ListVersionsResponse, error)
- func (c *SmnClient) PublishAppMessage(request *model.PublishAppMessageRequest) (*model.PublishAppMessageResponse, error)
- func (c *SmnClient) PublishMessage(request *model.PublishMessageRequest) (*model.PublishMessageResponse, error)
- func (c *SmnClient) UpdateApplication(request *model.UpdateApplicationRequest) (*model.UpdateApplicationResponse, error)
- func (c *SmnClient) UpdateApplicationEndpoint(request *model.UpdateApplicationEndpointRequest) (*model.UpdateApplicationEndpointResponse, error)
- func (c *SmnClient) UpdateMessageTemplate(request *model.UpdateMessageTemplateRequest) (*model.UpdateMessageTemplateResponse, error)
- func (c *SmnClient) UpdateTopic(request *model.UpdateTopicRequest) (*model.UpdateTopicResponse, error)
- func (c *SmnClient) UpdateTopicAttribute(request *model.UpdateTopicAttributeRequest) (*model.UpdateTopicAttributeResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenReqDefForAddSubscription ¶
func GenReqDefForAddSubscription() *def.HttpRequestDef
func GenReqDefForBatchCreateOrDeleteResourceTags ¶
func GenReqDefForBatchCreateOrDeleteResourceTags() *def.HttpRequestDef
func GenReqDefForCancelSubscription ¶
func GenReqDefForCancelSubscription() *def.HttpRequestDef
func GenReqDefForCreateApplication ¶
func GenReqDefForCreateApplication() *def.HttpRequestDef
func GenReqDefForCreateApplicationEndpoint ¶
func GenReqDefForCreateApplicationEndpoint() *def.HttpRequestDef
func GenReqDefForCreateMessageTemplate ¶
func GenReqDefForCreateMessageTemplate() *def.HttpRequestDef
func GenReqDefForCreateResourceTag ¶
func GenReqDefForCreateResourceTag() *def.HttpRequestDef
func GenReqDefForCreateTopic ¶
func GenReqDefForCreateTopic() *def.HttpRequestDef
func GenReqDefForDeleteApplication ¶
func GenReqDefForDeleteApplication() *def.HttpRequestDef
func GenReqDefForDeleteApplicationEndpoint ¶
func GenReqDefForDeleteApplicationEndpoint() *def.HttpRequestDef
func GenReqDefForDeleteMessageTemplate ¶
func GenReqDefForDeleteMessageTemplate() *def.HttpRequestDef
func GenReqDefForDeleteResourceTag ¶
func GenReqDefForDeleteResourceTag() *def.HttpRequestDef
func GenReqDefForDeleteTopic ¶
func GenReqDefForDeleteTopic() *def.HttpRequestDef
func GenReqDefForDeleteTopicAttributeByName ¶
func GenReqDefForDeleteTopicAttributeByName() *def.HttpRequestDef
func GenReqDefForDeleteTopicAttributes ¶
func GenReqDefForDeleteTopicAttributes() *def.HttpRequestDef
func GenReqDefForListApplicationAttributes ¶
func GenReqDefForListApplicationAttributes() *def.HttpRequestDef
func GenReqDefForListApplicationEndpointAttributes ¶
func GenReqDefForListApplicationEndpointAttributes() *def.HttpRequestDef
func GenReqDefForListApplicationEndpoints ¶
func GenReqDefForListApplicationEndpoints() *def.HttpRequestDef
func GenReqDefForListApplications ¶
func GenReqDefForListApplications() *def.HttpRequestDef
func GenReqDefForListMessageTemplateDetails ¶
func GenReqDefForListMessageTemplateDetails() *def.HttpRequestDef
func GenReqDefForListMessageTemplates ¶
func GenReqDefForListMessageTemplates() *def.HttpRequestDef
func GenReqDefForListProjectTags ¶
func GenReqDefForListProjectTags() *def.HttpRequestDef
func GenReqDefForListResourceInstances ¶
func GenReqDefForListResourceInstances() *def.HttpRequestDef
func GenReqDefForListResourceTags ¶
func GenReqDefForListResourceTags() *def.HttpRequestDef
func GenReqDefForListSubscriptions ¶
func GenReqDefForListSubscriptions() *def.HttpRequestDef
func GenReqDefForListSubscriptionsByTopic ¶
func GenReqDefForListSubscriptionsByTopic() *def.HttpRequestDef
func GenReqDefForListTopicAttributes ¶
func GenReqDefForListTopicAttributes() *def.HttpRequestDef
func GenReqDefForListTopicDetails ¶
func GenReqDefForListTopicDetails() *def.HttpRequestDef
func GenReqDefForListTopics ¶
func GenReqDefForListTopics() *def.HttpRequestDef
func GenReqDefForListVersion ¶
func GenReqDefForListVersion() *def.HttpRequestDef
func GenReqDefForListVersions ¶
func GenReqDefForListVersions() *def.HttpRequestDef
func GenReqDefForPublishAppMessage ¶
func GenReqDefForPublishAppMessage() *def.HttpRequestDef
func GenReqDefForPublishMessage ¶
func GenReqDefForPublishMessage() *def.HttpRequestDef
func GenReqDefForUpdateApplication ¶
func GenReqDefForUpdateApplication() *def.HttpRequestDef
func GenReqDefForUpdateApplicationEndpoint ¶
func GenReqDefForUpdateApplicationEndpoint() *def.HttpRequestDef
func GenReqDefForUpdateMessageTemplate ¶
func GenReqDefForUpdateMessageTemplate() *def.HttpRequestDef
func GenReqDefForUpdateTopic ¶
func GenReqDefForUpdateTopic() *def.HttpRequestDef
func GenReqDefForUpdateTopicAttribute ¶
func GenReqDefForUpdateTopicAttribute() *def.HttpRequestDef
func SmnClientBuilder ¶
func SmnClientBuilder() *http_client.HcHttpClientBuilder
Types ¶
type SmnClient ¶
type SmnClient struct {
HcClient *http_client.HcHttpClient
}
func NewSmnClient ¶
func NewSmnClient(hcClient *http_client.HcHttpClient) *SmnClient
func (*SmnClient) AddSubscription ¶
func (c *SmnClient) AddSubscription(request *model.AddSubscriptionRequest) (*model.AddSubscriptionResponse, error)
订阅
为指定Topic添加一个订阅者,如果订阅者的状态为未确认,则向订阅者发送一个确认的消息。待订阅者进行ConfirmSubscription确认后,该订阅者才能收到Topic发布的消息。单Topic默认可添加10000个订阅者,高并发场景下,可能会出现订阅者数量超过10000仍添加成功的情况,此为正常现象。接口是幂等的,如果添加已存在的订阅者,则返回成功,且status code为200,否则status code为201。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) BatchCreateOrDeleteResourceTags ¶
func (c *SmnClient) BatchCreateOrDeleteResourceTags(request *model.BatchCreateOrDeleteResourceTagsRequest) (*model.BatchCreateOrDeleteResourceTagsResponse, error)
批量添加删除资源标签
为指定实例批量添加或删除标签。一个资源上最多有10个标签。 此接口为幂等接口:创建时如果请求体中存在重复key则报错。 创建时,不允许重复key,如果数据库存在就覆盖。 删除时,如果删除的标签不存在,默认处理成功,删除时不对标签字符集范围做校验。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) CancelSubscription ¶
func (c *SmnClient) CancelSubscription(request *model.CancelSubscriptionRequest) (*model.CancelSubscriptionResponse, error)
取消订阅
删除指定的订阅者。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) CreateApplication ¶
func (c *SmnClient) CreateApplication(request *model.CreateApplicationRequest) (*model.CreateApplicationResponse, error)
创建Application
创建平台应用。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) CreateApplicationEndpoint ¶
func (c *SmnClient) CreateApplicationEndpoint(request *model.CreateApplicationEndpointRequest) (*model.CreateApplicationEndpointResponse, error)
创建Application endpoint
创建应用平台的endpoint终端。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) CreateMessageTemplate ¶
func (c *SmnClient) CreateMessageTemplate(request *model.CreateMessageTemplateRequest) (*model.CreateMessageTemplateResponse, error)
创建消息模板
创建一个模板,用户可以按照模板去发送消息,这样可以减少请求的数据量。 单用户默认可创建100个消息模板,高并发场景下,可能会出现消息模板数量超过100仍创建成功的情况,此为正常现象。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) CreateResourceTag ¶
func (c *SmnClient) CreateResourceTag(request *model.CreateResourceTagRequest) (*model.CreateResourceTagResponse, error)
添加资源标签
一个资源上最多有10个标签。此接口为幂等接口:创建时,如果创建的标签已经存在(key相同),则覆盖。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) CreateTopic ¶
func (c *SmnClient) CreateTopic(request *model.CreateTopicRequest) (*model.CreateTopicResponse, error)
创建主题
创建Topic,单用户默认配额为3000。高并发场景下,可能会出现Topic数量超过3000仍创建成功的情况,此为正常现象。 接口是幂等的,接口调用返回成功时,若已存在同名的Topic,返回的status code为200,否则返回的status code为201
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) DeleteApplication ¶
func (c *SmnClient) DeleteApplication(request *model.DeleteApplicationRequest) (*model.DeleteApplicationResponse, error)
删除Application
删除平台应用。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) DeleteApplicationEndpoint ¶
func (c *SmnClient) DeleteApplicationEndpoint(request *model.DeleteApplicationEndpointRequest) (*model.DeleteApplicationEndpointResponse, error)
删除Application endpoint
删除设备。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) DeleteMessageTemplate ¶
func (c *SmnClient) DeleteMessageTemplate(request *model.DeleteMessageTemplateRequest) (*model.DeleteMessageTemplateResponse, error)
删除消息模板
删除消息模板。删除模板之前的消息请求都可以使用该模板发送,删除之后无法再使用该模板发送消息。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) DeleteResourceTag ¶
func (c *SmnClient) DeleteResourceTag(request *model.DeleteResourceTagRequest) (*model.DeleteResourceTagResponse, error)
删除资源标签
幂等接口:删除时,不对标签做校验。删除的key不存在报404,key不能为空或者空字符串。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) DeleteTopic ¶
func (c *SmnClient) DeleteTopic(request *model.DeleteTopicRequest) (*model.DeleteTopicResponse, error)
删除主题
删除主题。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) DeleteTopicAttributeByName ¶
func (c *SmnClient) DeleteTopicAttributeByName(request *model.DeleteTopicAttributeByNameRequest) (*model.DeleteTopicAttributeByNameResponse, error)
删除指定名称的主题策略
删除指定名称的主题策略。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) DeleteTopicAttributes ¶
func (c *SmnClient) DeleteTopicAttributes(request *model.DeleteTopicAttributesRequest) (*model.DeleteTopicAttributesResponse, error)
删除所有主题策略
删除所有主题策略。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListApplicationAttributes ¶
func (c *SmnClient) ListApplicationAttributes(request *model.ListApplicationAttributesRequest) (*model.ListApplicationAttributesResponse, error)
查询Application属性
获取应用平台属性。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListApplicationEndpointAttributes ¶
func (c *SmnClient) ListApplicationEndpointAttributes(request *model.ListApplicationEndpointAttributesRequest) (*model.ListApplicationEndpointAttributesResponse, error)
查询Application的Endpoint属性
获取endpoint的属性。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListApplicationEndpoints ¶
func (c *SmnClient) ListApplicationEndpoints(request *model.ListApplicationEndpointsRequest) (*model.ListApplicationEndpointsResponse, error)
查询Application的Endpoint列表
查询平台的endpoint列表。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListApplications ¶
func (c *SmnClient) ListApplications(request *model.ListApplicationsRequest) (*model.ListApplicationsResponse, error)
查询Application
查询应用平台列表。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListMessageTemplateDetails ¶
func (c *SmnClient) ListMessageTemplateDetails(request *model.ListMessageTemplateDetailsRequest) (*model.ListMessageTemplateDetailsResponse, error)
查询消息模板详情
查询模板详情,包括模板内容。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListMessageTemplates ¶
func (c *SmnClient) ListMessageTemplates(request *model.ListMessageTemplatesRequest) (*model.ListMessageTemplatesResponse, error)
查询消息模板列表
分页查询模板列表,模板列表按照创建时间进行升序排列。分页查询可以指定offset以及limit。如果不存在模板,则返回空列表。额外的查询参数分别有message_template_name和protocol。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListProjectTags ¶
func (c *SmnClient) ListProjectTags(request *model.ListProjectTagsRequest) (*model.ListProjectTagsResponse, error)
查询项目标签
查询租户在指定Region和实例类型的所有标签集合。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListResourceInstances ¶
func (c *SmnClient) ListResourceInstances(request *model.ListResourceInstancesRequest) (*model.ListResourceInstancesResponse, error)
查询资源实例
使用标签过滤实例。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListResourceTags ¶
func (c *SmnClient) ListResourceTags(request *model.ListResourceTagsRequest) (*model.ListResourceTagsResponse, error)
查询资源标签
查询指定实例的标签信息。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListSubscriptions ¶
func (c *SmnClient) ListSubscriptions(request *model.ListSubscriptionsRequest) (*model.ListSubscriptionsResponse, error)
查询订阅者列表
分页返回请求者的所有的订阅列表,订阅列表按照订阅创建时间进行升序排列。分页查询可以指定offset以及limit。如果订阅者不存在,返回空列表。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListSubscriptionsByTopic ¶
func (c *SmnClient) ListSubscriptionsByTopic(request *model.ListSubscriptionsByTopicRequest) (*model.ListSubscriptionsByTopicResponse, error)
查询指定Topic的订阅者列表
分页获取特定Topic的订阅列表,订阅列表按照订阅创建时间进行升序排列。分页查询可以指定offset以及limit。如果指定Topic不存在订阅者,返回空列表。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListTopicAttributes ¶
func (c *SmnClient) ListTopicAttributes(request *model.ListTopicAttributesRequest) (*model.ListTopicAttributesResponse, error)
查询主题策略
查询主题的策略信息。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListTopicDetails ¶
func (c *SmnClient) ListTopicDetails(request *model.ListTopicDetailsRequest) (*model.ListTopicDetailsResponse, error)
查询主题详情
查询Topic的详细信息。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListTopics ¶
func (c *SmnClient) ListTopics(request *model.ListTopicsRequest) (*model.ListTopicsResponse, error)
查询主题列表
分页查询Topic列表,Topic列表按照Topic创建时间进行降序排列。分页查询可以指定offset以及limit。如果不存在Topic,则返回空列表。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListVersion ¶
func (c *SmnClient) ListVersion(request *model.ListVersionRequest) (*model.ListVersionResponse, error)
查询SMN API V2版本信息
查询SMN API V2版本信息。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) ListVersions ¶
func (c *SmnClient) ListVersions(request *model.ListVersionsRequest) (*model.ListVersionsResponse, error)
查询SMN支持的API版本号信息
查询SMN开放API支持的版本号。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) PublishAppMessage ¶
func (c *SmnClient) PublishAppMessage(request *model.PublishAppMessageRequest) (*model.PublishAppMessageResponse, error)
App消息发布
将消息直发给endpoint设备。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) PublishMessage ¶
func (c *SmnClient) PublishMessage(request *model.PublishMessageRequest) (*model.PublishMessageResponse, error)
消息发布
将消息发送给Topic的所有订阅端点。当返回消息ID时,该消息已被保存并开始尝试将其推送给Topic的订阅者。三种消息发送方式
message
message_structure
message_template_name
只需要设置其中一个,如果同时设置,生效的优先级为 message_structure > message_template_name > message。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) UpdateApplication ¶
func (c *SmnClient) UpdateApplication(request *model.UpdateApplicationRequest) (*model.UpdateApplicationResponse, error)
更新Application
更新应用平台。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) UpdateApplicationEndpoint ¶
func (c *SmnClient) UpdateApplicationEndpoint(request *model.UpdateApplicationEndpointRequest) (*model.UpdateApplicationEndpointResponse, error)
更新Application endpoint
更新设备属性。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) UpdateMessageTemplate ¶
func (c *SmnClient) UpdateMessageTemplate(request *model.UpdateMessageTemplateRequest) (*model.UpdateMessageTemplateResponse, error)
更新消息模板
修改消息模板的内容。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) UpdateTopic ¶
func (c *SmnClient) UpdateTopic(request *model.UpdateTopicRequest) (*model.UpdateTopicResponse, error)
更新主题
更新显示名。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.
func (*SmnClient) UpdateTopicAttribute ¶
func (c *SmnClient) UpdateTopicAttribute(request *model.UpdateTopicAttributeRequest) (*model.UpdateTopicAttributeResponse, error)
更新主题策略
更新主题的策略信息。
详细说明请参考华为云API Explorer。 Please refer to Huawei cloud API Explorer for details.