2 Star 10 Fork 0

tencentcloud/tencentcloud-sdk-go

加入 Gitee
与超过 1400万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
client.go 80.64 KB
一键复制 编辑 原始数据 按行查看 历史
tencentcloud 提交于 2025-07-29 23:49 +08:00 . release v1.1.0
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162
// Copyright (c) 2017-2025 Tencent. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package v20210416
import (
"context"
"errors"
"github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common"
tchttp "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/http"
"github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/profile"
)
const APIVersion = "2021-04-16"
type Client struct {
common.Client
}
// Deprecated
func NewClientWithSecretId(secretId, secretKey, region string) (client *Client, err error) {
cpf := profile.NewClientProfile()
client = &Client{}
client.Init(region).WithSecretId(secretId, secretKey).WithProfile(cpf)
return
}
func NewClient(credential common.CredentialIface, region string, clientProfile *profile.ClientProfile) (client *Client, err error) {
client = &Client{}
client.Init(region).
WithCredential(credential).
WithProfile(clientProfile)
return
}
func NewCheckRuleRequest() (request *CheckRuleRequest) {
request = &CheckRuleRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "CheckRule")
return
}
func NewCheckRuleResponse() (response *CheckRuleResponse) {
response = &CheckRuleResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CheckRule
// 检验规则
//
// 可能返回的错误码:
// FAILEDOPERATION_ERRORFILTER = "FailedOperation.ErrorFilter"
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INTERNALERROR_UNKNOWNINTERNALERROR = "InternalError.UnknownInternalError"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDFILTERRULE = "InvalidParameterValue.InvalidFilterRule"
// INVALIDPARAMETERVALUE_INVALIDPATTERN = "InvalidParameterValue.InvalidPattern"
func (c *Client) CheckRule(request *CheckRuleRequest) (response *CheckRuleResponse, err error) {
return c.CheckRuleWithContext(context.Background(), request)
}
// CheckRule
// 检验规则
//
// 可能返回的错误码:
// FAILEDOPERATION_ERRORFILTER = "FailedOperation.ErrorFilter"
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INTERNALERROR_UNKNOWNINTERNALERROR = "InternalError.UnknownInternalError"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDFILTERRULE = "InvalidParameterValue.InvalidFilterRule"
// INVALIDPARAMETERVALUE_INVALIDPATTERN = "InvalidParameterValue.InvalidPattern"
func (c *Client) CheckRuleWithContext(ctx context.Context, request *CheckRuleRequest) (response *CheckRuleResponse, err error) {
if request == nil {
request = NewCheckRuleRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "CheckRule")
if c.GetCredential() == nil {
return nil, errors.New("CheckRule require credential")
}
request.SetContext(ctx)
response = NewCheckRuleResponse()
err = c.Send(request, response)
return
}
func NewCheckTransformationRequest() (request *CheckTransformationRequest) {
request = &CheckTransformationRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "CheckTransformation")
return
}
func NewCheckTransformationResponse() (response *CheckTransformationResponse) {
response = &CheckTransformationResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CheckTransformation
// 用于在ETL配置页面, 测试规则和数据.
//
// 可能返回的错误码:
// FAILEDOPERATION_ERRORFILTER = "FailedOperation.ErrorFilter"
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INTERNALERROR_UNKNOWNINTERNALERROR = "InternalError.UnknownInternalError"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDFILTERRULE = "InvalidParameterValue.InvalidFilterRule"
// INVALIDPARAMETERVALUE_INVALIDPATTERN = "InvalidParameterValue.InvalidPattern"
func (c *Client) CheckTransformation(request *CheckTransformationRequest) (response *CheckTransformationResponse, err error) {
return c.CheckTransformationWithContext(context.Background(), request)
}
// CheckTransformation
// 用于在ETL配置页面, 测试规则和数据.
//
// 可能返回的错误码:
// FAILEDOPERATION_ERRORFILTER = "FailedOperation.ErrorFilter"
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INTERNALERROR_UNKNOWNINTERNALERROR = "InternalError.UnknownInternalError"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDFILTERRULE = "InvalidParameterValue.InvalidFilterRule"
// INVALIDPARAMETERVALUE_INVALIDPATTERN = "InvalidParameterValue.InvalidPattern"
func (c *Client) CheckTransformationWithContext(ctx context.Context, request *CheckTransformationRequest) (response *CheckTransformationResponse, err error) {
if request == nil {
request = NewCheckTransformationRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "CheckTransformation")
if c.GetCredential() == nil {
return nil, errors.New("CheckTransformation require credential")
}
request.SetContext(ctx)
response = NewCheckTransformationResponse()
err = c.Send(request, response)
return
}
func NewCreateConnectionRequest() (request *CreateConnectionRequest) {
request = &CreateConnectionRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "CreateConnection")
return
}
func NewCreateConnectionResponse() (response *CreateConnectionResponse) {
response = &CreateConnectionResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CreateConnection
// 创建事件连接器
//
// 可能返回的错误码:
// FAILEDOPERATION = "FailedOperation"
// FAILEDOPERATION_SERVICEERROR = "FailedOperation.ServiceError"
// INTERNALERROR_OSSEXCEPTION = "InternalError.OssException"
// INVALIDPARAMETERVALUE_CONNECTIONDESCRIPTION = "InvalidParameterValue.ConnectionDescription"
// INVALIDPARAMETERVALUE_CONNECTIONNAME = "InvalidParameterValue.ConnectionName"
// INVALIDPARAMETERVALUE_DTSPARAMS = "InvalidParameterValue.DTSParams"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_EVENTBUSNAME = "InvalidParameterValue.EventBusName"
// INVALIDPARAMETERVALUE_INVALIDAPIREQUESTCONFIG = "InvalidParameterValue.InvalidApiRequestConfig"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_CONNECTION = "LimitExceeded.Connection"
// LIMITEXCEEDED_ROUTEOVERLIMIT = "LimitExceeded.RouteOverLimit"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// OPERATIONDENIED_UNSUPPORTEDOPERATION = "OperationDenied.UnsupportedOperation"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_INVALIDSERVICE = "ResourceNotFound.InvalidService"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
// RESOURCEUNAVAILABLE_CONNECTION = "ResourceUnavailable.Connection"
// UNSUPPORTEDOPERATION = "UnsupportedOperation"
// UNSUPPORTEDOPERATION_INVALIDACTION = "UnsupportedOperation.InvalidAction"
// UNSUPPORTEDOPERATION_INVALIDENDPOINTTYPE = "UnsupportedOperation.InvalidEndpointType"
func (c *Client) CreateConnection(request *CreateConnectionRequest) (response *CreateConnectionResponse, err error) {
return c.CreateConnectionWithContext(context.Background(), request)
}
// CreateConnection
// 创建事件连接器
//
// 可能返回的错误码:
// FAILEDOPERATION = "FailedOperation"
// FAILEDOPERATION_SERVICEERROR = "FailedOperation.ServiceError"
// INTERNALERROR_OSSEXCEPTION = "InternalError.OssException"
// INVALIDPARAMETERVALUE_CONNECTIONDESCRIPTION = "InvalidParameterValue.ConnectionDescription"
// INVALIDPARAMETERVALUE_CONNECTIONNAME = "InvalidParameterValue.ConnectionName"
// INVALIDPARAMETERVALUE_DTSPARAMS = "InvalidParameterValue.DTSParams"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_EVENTBUSNAME = "InvalidParameterValue.EventBusName"
// INVALIDPARAMETERVALUE_INVALIDAPIREQUESTCONFIG = "InvalidParameterValue.InvalidApiRequestConfig"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_CONNECTION = "LimitExceeded.Connection"
// LIMITEXCEEDED_ROUTEOVERLIMIT = "LimitExceeded.RouteOverLimit"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// OPERATIONDENIED_UNSUPPORTEDOPERATION = "OperationDenied.UnsupportedOperation"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_INVALIDSERVICE = "ResourceNotFound.InvalidService"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
// RESOURCEUNAVAILABLE_CONNECTION = "ResourceUnavailable.Connection"
// UNSUPPORTEDOPERATION = "UnsupportedOperation"
// UNSUPPORTEDOPERATION_INVALIDACTION = "UnsupportedOperation.InvalidAction"
// UNSUPPORTEDOPERATION_INVALIDENDPOINTTYPE = "UnsupportedOperation.InvalidEndpointType"
func (c *Client) CreateConnectionWithContext(ctx context.Context, request *CreateConnectionRequest) (response *CreateConnectionResponse, err error) {
if request == nil {
request = NewCreateConnectionRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "CreateConnection")
if c.GetCredential() == nil {
return nil, errors.New("CreateConnection require credential")
}
request.SetContext(ctx)
response = NewCreateConnectionResponse()
err = c.Send(request, response)
return
}
func NewCreateEventBusRequest() (request *CreateEventBusRequest) {
request = &CreateEventBusRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "CreateEventBus")
return
}
func NewCreateEventBusResponse() (response *CreateEventBusResponse) {
response = &CreateEventBusResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CreateEventBus
// 用于创建事件集
//
// 可能返回的错误码:
// FAILEDOPERATION_REGISTERCLSSERVICE = "FailedOperation.RegisterCLSService"
// FAILEDOPERATION_TAGRESOURCE = "FailedOperation.TagResource"
// FAILEDOPERATION_TAGRESOURCEALLOCATEQUOTAS = "FailedOperation.TagResourceAllocateQuotas"
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSNAME = "InvalidParameterValue.EventBusName"
// INVALIDPARAMETERVALUE_EVENTTRACECONFIG = "InvalidParameterValue.EventTraceConfig"
// INVALIDPARAMETERVALUE_LINKMODE = "InvalidParameterValue.LinkMode"
// INVALIDPARAMETERVALUE_TAGS = "InvalidParameterValue.Tags"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_EVENTBUS = "LimitExceeded.EventBus"
// LIMITEXCEEDED_INSUFFICIENTBALANCE = "LimitExceeded.InsufficientBalance"
// OPERATIONDENIED_DEFAULTCLSRESOURCEUNSUPPORTED = "OperationDenied.DefaultCLSResourceUnsupported"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// RESOURCEINUSE_DEFAULTEVENTBUS = "ResourceInUse.DefaultEventBus"
// RESOURCEINUSE_EVENTBUS = "ResourceInUse.EventBus"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
// RESOURCEUNAVAILABLE_TARGET = "ResourceUnavailable.Target"
func (c *Client) CreateEventBus(request *CreateEventBusRequest) (response *CreateEventBusResponse, err error) {
return c.CreateEventBusWithContext(context.Background(), request)
}
// CreateEventBus
// 用于创建事件集
//
// 可能返回的错误码:
// FAILEDOPERATION_REGISTERCLSSERVICE = "FailedOperation.RegisterCLSService"
// FAILEDOPERATION_TAGRESOURCE = "FailedOperation.TagResource"
// FAILEDOPERATION_TAGRESOURCEALLOCATEQUOTAS = "FailedOperation.TagResourceAllocateQuotas"
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSNAME = "InvalidParameterValue.EventBusName"
// INVALIDPARAMETERVALUE_EVENTTRACECONFIG = "InvalidParameterValue.EventTraceConfig"
// INVALIDPARAMETERVALUE_LINKMODE = "InvalidParameterValue.LinkMode"
// INVALIDPARAMETERVALUE_TAGS = "InvalidParameterValue.Tags"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_EVENTBUS = "LimitExceeded.EventBus"
// LIMITEXCEEDED_INSUFFICIENTBALANCE = "LimitExceeded.InsufficientBalance"
// OPERATIONDENIED_DEFAULTCLSRESOURCEUNSUPPORTED = "OperationDenied.DefaultCLSResourceUnsupported"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// RESOURCEINUSE_DEFAULTEVENTBUS = "ResourceInUse.DefaultEventBus"
// RESOURCEINUSE_EVENTBUS = "ResourceInUse.EventBus"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
// RESOURCEUNAVAILABLE_TARGET = "ResourceUnavailable.Target"
func (c *Client) CreateEventBusWithContext(ctx context.Context, request *CreateEventBusRequest) (response *CreateEventBusResponse, err error) {
if request == nil {
request = NewCreateEventBusRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "CreateEventBus")
if c.GetCredential() == nil {
return nil, errors.New("CreateEventBus require credential")
}
request.SetContext(ctx)
response = NewCreateEventBusResponse()
err = c.Send(request, response)
return
}
func NewCreateRuleRequest() (request *CreateRuleRequest) {
request = &CreateRuleRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "CreateRule")
return
}
func NewCreateRuleResponse() (response *CreateRuleResponse) {
response = &CreateRuleResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CreateRule
// 创建事件规则
//
// 可能返回的错误码:
// FAILEDOPERATION_TAGRESOURCE = "FailedOperation.TagResource"
// FAILEDOPERATION_TAGRESOURCEALLOCATEQUOTAS = "FailedOperation.TagResourceAllocateQuotas"
// INVALIDPARAMETERVALUE_DEADLETTERCONFIG = "InvalidParameterValue.DeadLetterConfig"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTPATTERN = "InvalidParameterValue.EventPattern"
// INVALIDPARAMETERVALUE_RULENAME = "InvalidParameterValue.RuleName"
// INVALIDPARAMETERVALUE_TAGS = "InvalidParameterValue.Tags"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_RULE = "LimitExceeded.Rule"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
func (c *Client) CreateRule(request *CreateRuleRequest) (response *CreateRuleResponse, err error) {
return c.CreateRuleWithContext(context.Background(), request)
}
// CreateRule
// 创建事件规则
//
// 可能返回的错误码:
// FAILEDOPERATION_TAGRESOURCE = "FailedOperation.TagResource"
// FAILEDOPERATION_TAGRESOURCEALLOCATEQUOTAS = "FailedOperation.TagResourceAllocateQuotas"
// INVALIDPARAMETERVALUE_DEADLETTERCONFIG = "InvalidParameterValue.DeadLetterConfig"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTPATTERN = "InvalidParameterValue.EventPattern"
// INVALIDPARAMETERVALUE_RULENAME = "InvalidParameterValue.RuleName"
// INVALIDPARAMETERVALUE_TAGS = "InvalidParameterValue.Tags"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_RULE = "LimitExceeded.Rule"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
func (c *Client) CreateRuleWithContext(ctx context.Context, request *CreateRuleRequest) (response *CreateRuleResponse, err error) {
if request == nil {
request = NewCreateRuleRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "CreateRule")
if c.GetCredential() == nil {
return nil, errors.New("CreateRule require credential")
}
request.SetContext(ctx)
response = NewCreateRuleResponse()
err = c.Send(request, response)
return
}
func NewCreateTargetRequest() (request *CreateTargetRequest) {
request = &CreateTargetRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "CreateTarget")
return
}
func NewCreateTargetResponse() (response *CreateTargetResponse) {
response = &CreateTargetResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CreateTarget
// 创建事件目标
//
// 可能返回的错误码:
// FAILEDOPERATION = "FailedOperation"
// FAILEDOPERATION_ADDPRIVATELINK = "FailedOperation.AddPrivateLink"
// FAILEDOPERATION_AUTHENTICATEUSERFAILED = "FailedOperation.AuthenticateUserFailed"
// FAILEDOPERATION_CREATETRIGGER = "FailedOperation.CreateTrigger"
// FAILEDOPERATION_ESINTERNALERROR = "FailedOperation.ESInternalError"
// FAILEDOPERATION_ESREQUESTFAILED = "FailedOperation.ESRequestFailed"
// FAILEDOPERATION_ESTEMPLATECONFLICT = "FailedOperation.ESTemplateConflict"
// INVALIDPARAMETER_PAYLOAD = "InvalidParameter.Payload"
// INVALIDPARAMETERVALUE_AMPPARAMS = "InvalidParameterValue.AMPParams"
// INVALIDPARAMETERVALUE_BATCHEVENTCOUNT = "InvalidParameterValue.BatchEventCount"
// INVALIDPARAMETERVALUE_BATCHTIMEOUT = "InvalidParameterValue.BatchTimeout"
// INVALIDPARAMETERVALUE_CKAFKATARGETPARAMS = "InvalidParameterValue.CKafkaTargetParams"
// INVALIDPARAMETERVALUE_CALLBACKTYPE = "InvalidParameterValue.CallbackType"
// INVALIDPARAMETERVALUE_CALLBACKWECOMURL = "InvalidParameterValue.CallbackWeComURL"
// INVALIDPARAMETERVALUE_ELASTICSEARCHTARGETPARAMS = "InvalidParameterValue.ElasticSearchTargetParams"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_NOTICERECEIVERCHANNEL = "InvalidParameterValue.NoticeReceiverChannel"
// INVALIDPARAMETERVALUE_NOTICERECEIVERTIMEWINDOW = "InvalidParameterValue.NoticeReceiverTimeWindow"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERIDS = "InvalidParameterValue.NoticeReceiverUserIds"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERTYPE = "InvalidParameterValue.NoticeReceiverUserType"
// INVALIDPARAMETERVALUE_QUALIFIER = "InvalidParameterValue.Qualifier"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETDESCRIPTION = "InvalidParameterValue.TargetDescription"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_CLUSTERPRIVATELINKEXCEEDED = "LimitExceeded.ClusterPrivateLinkExceeded"
// LIMITEXCEEDED_LOGSET = "LimitExceeded.Logset"
// LIMITEXCEEDED_TARGET = "LimitExceeded.Target"
// LIMITEXCEEDED_TRIGGER = "LimitExceeded.Trigger"
// LIMITEXCEEDED_USERPRIVATELINKEXCEEDED = "LimitExceeded.UserPrivateLinkExceeded"
// OPERATIONDENIED_ACCOUNTNOTEXISTS = "OperationDenied.AccountNotExists"
// OPERATIONDENIED_DEFAULTCLSRESOURCEUNSUPPORTED = "OperationDenied.DefaultCLSResourceUnsupported"
// OPERATIONDENIED_ESVERSIONUNSUPPORTED = "OperationDenied.ESVersionUnsupported"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// OPERATIONDENIED_UNSUPPORTEDOPERATION = "OperationDenied.UnsupportedOperation"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_FUNCTION = "ResourceNotFound.Function"
// RESOURCENOTFOUND_NAMESPACE = "ResourceNotFound.Namespace"
// RESOURCENOTFOUND_PRIVATELINKRESOURCE = "ResourceNotFound.PrivateLinkResource"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
// RESOURCENOTFOUND_VERSION = "ResourceNotFound.Version"
// RESOURCEUNAVAILABLE_ESUNHEALTH = "ResourceUnavailable.ESUnhealth"
// RESOURCEUNAVAILABLE_TARGET = "ResourceUnavailable.Target"
func (c *Client) CreateTarget(request *CreateTargetRequest) (response *CreateTargetResponse, err error) {
return c.CreateTargetWithContext(context.Background(), request)
}
// CreateTarget
// 创建事件目标
//
// 可能返回的错误码:
// FAILEDOPERATION = "FailedOperation"
// FAILEDOPERATION_ADDPRIVATELINK = "FailedOperation.AddPrivateLink"
// FAILEDOPERATION_AUTHENTICATEUSERFAILED = "FailedOperation.AuthenticateUserFailed"
// FAILEDOPERATION_CREATETRIGGER = "FailedOperation.CreateTrigger"
// FAILEDOPERATION_ESINTERNALERROR = "FailedOperation.ESInternalError"
// FAILEDOPERATION_ESREQUESTFAILED = "FailedOperation.ESRequestFailed"
// FAILEDOPERATION_ESTEMPLATECONFLICT = "FailedOperation.ESTemplateConflict"
// INVALIDPARAMETER_PAYLOAD = "InvalidParameter.Payload"
// INVALIDPARAMETERVALUE_AMPPARAMS = "InvalidParameterValue.AMPParams"
// INVALIDPARAMETERVALUE_BATCHEVENTCOUNT = "InvalidParameterValue.BatchEventCount"
// INVALIDPARAMETERVALUE_BATCHTIMEOUT = "InvalidParameterValue.BatchTimeout"
// INVALIDPARAMETERVALUE_CKAFKATARGETPARAMS = "InvalidParameterValue.CKafkaTargetParams"
// INVALIDPARAMETERVALUE_CALLBACKTYPE = "InvalidParameterValue.CallbackType"
// INVALIDPARAMETERVALUE_CALLBACKWECOMURL = "InvalidParameterValue.CallbackWeComURL"
// INVALIDPARAMETERVALUE_ELASTICSEARCHTARGETPARAMS = "InvalidParameterValue.ElasticSearchTargetParams"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_NOTICERECEIVERCHANNEL = "InvalidParameterValue.NoticeReceiverChannel"
// INVALIDPARAMETERVALUE_NOTICERECEIVERTIMEWINDOW = "InvalidParameterValue.NoticeReceiverTimeWindow"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERIDS = "InvalidParameterValue.NoticeReceiverUserIds"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERTYPE = "InvalidParameterValue.NoticeReceiverUserType"
// INVALIDPARAMETERVALUE_QUALIFIER = "InvalidParameterValue.Qualifier"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETDESCRIPTION = "InvalidParameterValue.TargetDescription"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// LIMITEXCEEDED_CLUSTERPRIVATELINKEXCEEDED = "LimitExceeded.ClusterPrivateLinkExceeded"
// LIMITEXCEEDED_LOGSET = "LimitExceeded.Logset"
// LIMITEXCEEDED_TARGET = "LimitExceeded.Target"
// LIMITEXCEEDED_TRIGGER = "LimitExceeded.Trigger"
// LIMITEXCEEDED_USERPRIVATELINKEXCEEDED = "LimitExceeded.UserPrivateLinkExceeded"
// OPERATIONDENIED_ACCOUNTNOTEXISTS = "OperationDenied.AccountNotExists"
// OPERATIONDENIED_DEFAULTCLSRESOURCEUNSUPPORTED = "OperationDenied.DefaultCLSResourceUnsupported"
// OPERATIONDENIED_ESVERSIONUNSUPPORTED = "OperationDenied.ESVersionUnsupported"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// OPERATIONDENIED_UNSUPPORTEDOPERATION = "OperationDenied.UnsupportedOperation"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_FUNCTION = "ResourceNotFound.Function"
// RESOURCENOTFOUND_NAMESPACE = "ResourceNotFound.Namespace"
// RESOURCENOTFOUND_PRIVATELINKRESOURCE = "ResourceNotFound.PrivateLinkResource"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
// RESOURCENOTFOUND_VERSION = "ResourceNotFound.Version"
// RESOURCEUNAVAILABLE_ESUNHEALTH = "ResourceUnavailable.ESUnhealth"
// RESOURCEUNAVAILABLE_TARGET = "ResourceUnavailable.Target"
func (c *Client) CreateTargetWithContext(ctx context.Context, request *CreateTargetRequest) (response *CreateTargetResponse, err error) {
if request == nil {
request = NewCreateTargetRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "CreateTarget")
if c.GetCredential() == nil {
return nil, errors.New("CreateTarget require credential")
}
request.SetContext(ctx)
response = NewCreateTargetResponse()
err = c.Send(request, response)
return
}
func NewCreateTransformationRequest() (request *CreateTransformationRequest) {
request = &CreateTransformationRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "CreateTransformation")
return
}
func NewCreateTransformationResponse() (response *CreateTransformationResponse) {
response = &CreateTransformationResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CreateTransformation
// 用于创建转换器
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_TRANSFORMATIONS = "InvalidParameterValue.Transformations"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) CreateTransformation(request *CreateTransformationRequest) (response *CreateTransformationResponse, err error) {
return c.CreateTransformationWithContext(context.Background(), request)
}
// CreateTransformation
// 用于创建转换器
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_TRANSFORMATIONS = "InvalidParameterValue.Transformations"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) CreateTransformationWithContext(ctx context.Context, request *CreateTransformationRequest) (response *CreateTransformationResponse, err error) {
if request == nil {
request = NewCreateTransformationRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "CreateTransformation")
if c.GetCredential() == nil {
return nil, errors.New("CreateTransformation require credential")
}
request.SetContext(ctx)
response = NewCreateTransformationResponse()
err = c.Send(request, response)
return
}
func NewDeleteConnectionRequest() (request *DeleteConnectionRequest) {
request = &DeleteConnectionRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "DeleteConnection")
return
}
func NewDeleteConnectionResponse() (response *DeleteConnectionResponse) {
response = &DeleteConnectionResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DeleteConnection
// 删除事件连接器
//
// 可能返回的错误码:
// FAILEDOPERATION_DELETECONNECTION = "FailedOperation.DeleteConnection"
// FAILEDOPERATION_SERVICEERROR = "FailedOperation.ServiceError"
// INTERNALERROR_OSSEXCEPTION = "InternalError.OssException"
// INVALIDPARAMETERVALUE_CONNECTIONDESCRIPTION = "InvalidParameterValue.ConnectionDescription"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_CONNECTION = "ResourceNotFound.Connection"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_INVALIDAPI = "ResourceNotFound.InvalidApi"
// RESOURCENOTFOUND_INVALIDSERVICE = "ResourceNotFound.InvalidService"
// UNSUPPORTEDOPERATION_INVALIDACTION = "UnsupportedOperation.InvalidAction"
func (c *Client) DeleteConnection(request *DeleteConnectionRequest) (response *DeleteConnectionResponse, err error) {
return c.DeleteConnectionWithContext(context.Background(), request)
}
// DeleteConnection
// 删除事件连接器
//
// 可能返回的错误码:
// FAILEDOPERATION_DELETECONNECTION = "FailedOperation.DeleteConnection"
// FAILEDOPERATION_SERVICEERROR = "FailedOperation.ServiceError"
// INTERNALERROR_OSSEXCEPTION = "InternalError.OssException"
// INVALIDPARAMETERVALUE_CONNECTIONDESCRIPTION = "InvalidParameterValue.ConnectionDescription"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_CONNECTION = "ResourceNotFound.Connection"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_INVALIDAPI = "ResourceNotFound.InvalidApi"
// RESOURCENOTFOUND_INVALIDSERVICE = "ResourceNotFound.InvalidService"
// UNSUPPORTEDOPERATION_INVALIDACTION = "UnsupportedOperation.InvalidAction"
func (c *Client) DeleteConnectionWithContext(ctx context.Context, request *DeleteConnectionRequest) (response *DeleteConnectionResponse, err error) {
if request == nil {
request = NewDeleteConnectionRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "DeleteConnection")
if c.GetCredential() == nil {
return nil, errors.New("DeleteConnection require credential")
}
request.SetContext(ctx)
response = NewDeleteConnectionResponse()
err = c.Send(request, response)
return
}
func NewDeleteEventBusRequest() (request *DeleteEventBusRequest) {
request = &DeleteEventBusRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "DeleteEventBus")
return
}
func NewDeleteEventBusResponse() (response *DeleteEventBusResponse) {
response = &DeleteEventBusResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DeleteEventBus
// 删除事件集
//
// 可能返回的错误码:
// FAILEDOPERATION_UNTAGRESOURCE = "FailedOperation.UnTagResource"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCEINUSE_EVENTBUS = "ResourceInUse.EventBus"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
func (c *Client) DeleteEventBus(request *DeleteEventBusRequest) (response *DeleteEventBusResponse, err error) {
return c.DeleteEventBusWithContext(context.Background(), request)
}
// DeleteEventBus
// 删除事件集
//
// 可能返回的错误码:
// FAILEDOPERATION_UNTAGRESOURCE = "FailedOperation.UnTagResource"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCEINUSE_EVENTBUS = "ResourceInUse.EventBus"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
func (c *Client) DeleteEventBusWithContext(ctx context.Context, request *DeleteEventBusRequest) (response *DeleteEventBusResponse, err error) {
if request == nil {
request = NewDeleteEventBusRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "DeleteEventBus")
if c.GetCredential() == nil {
return nil, errors.New("DeleteEventBus require credential")
}
request.SetContext(ctx)
response = NewDeleteEventBusResponse()
err = c.Send(request, response)
return
}
func NewDeleteRuleRequest() (request *DeleteRuleRequest) {
request = &DeleteRuleRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "DeleteRule")
return
}
func NewDeleteRuleResponse() (response *DeleteRuleResponse) {
response = &DeleteRuleResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DeleteRule
// 删除事件规则
//
// 可能返回的错误码:
// FAILEDOPERATION_DELETERULE = "FailedOperation.DeleteRule"
// FAILEDOPERATION_UNTAGRESOURCE = "FailedOperation.UnTagResource"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// RESOURCEINUSE_RULE = "ResourceInUse.Rule"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
func (c *Client) DeleteRule(request *DeleteRuleRequest) (response *DeleteRuleResponse, err error) {
return c.DeleteRuleWithContext(context.Background(), request)
}
// DeleteRule
// 删除事件规则
//
// 可能返回的错误码:
// FAILEDOPERATION_DELETERULE = "FailedOperation.DeleteRule"
// FAILEDOPERATION_UNTAGRESOURCE = "FailedOperation.UnTagResource"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// RESOURCEINUSE_RULE = "ResourceInUse.Rule"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TAG = "ResourceNotFound.Tag"
func (c *Client) DeleteRuleWithContext(ctx context.Context, request *DeleteRuleRequest) (response *DeleteRuleResponse, err error) {
if request == nil {
request = NewDeleteRuleRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "DeleteRule")
if c.GetCredential() == nil {
return nil, errors.New("DeleteRule require credential")
}
request.SetContext(ctx)
response = NewDeleteRuleResponse()
err = c.Send(request, response)
return
}
func NewDeleteTargetRequest() (request *DeleteTargetRequest) {
request = &DeleteTargetRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "DeleteTarget")
return
}
func NewDeleteTargetResponse() (response *DeleteTargetResponse) {
response = &DeleteTargetResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DeleteTarget
// 删除事件目标
//
// 可能返回的错误码:
// FAILEDOPERATION_AUTHENTICATEUSERFAILED = "FailedOperation.AuthenticateUserFailed"
// FAILEDOPERATION_DELETEPRIVATELINK = "FailedOperation.DeletePrivateLink"
// FAILEDOPERATION_ESINTERNALERROR = "FailedOperation.ESInternalError"
// FAILEDOPERATION_ESREQUESTFAILED = "FailedOperation.ESRequestFailed"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETID = "InvalidParameterValue.TargetId"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// OPERATIONDENIED_ESVERSIONUNSUPPORTED = "OperationDenied.ESVersionUnsupported"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_NETASSOCIATION = "ResourceNotFound.NetAssociation"
// RESOURCENOTFOUND_PRIVATELINKRESOURCE = "ResourceNotFound.PrivateLinkResource"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
func (c *Client) DeleteTarget(request *DeleteTargetRequest) (response *DeleteTargetResponse, err error) {
return c.DeleteTargetWithContext(context.Background(), request)
}
// DeleteTarget
// 删除事件目标
//
// 可能返回的错误码:
// FAILEDOPERATION_AUTHENTICATEUSERFAILED = "FailedOperation.AuthenticateUserFailed"
// FAILEDOPERATION_DELETEPRIVATELINK = "FailedOperation.DeletePrivateLink"
// FAILEDOPERATION_ESINTERNALERROR = "FailedOperation.ESInternalError"
// FAILEDOPERATION_ESREQUESTFAILED = "FailedOperation.ESRequestFailed"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETID = "InvalidParameterValue.TargetId"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// OPERATIONDENIED_ESVERSIONUNSUPPORTED = "OperationDenied.ESVersionUnsupported"
// OPERATIONDENIED_EVENTBUSRESOURCEISLOCKED = "OperationDenied.EventBusResourceIsLocked"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_NETASSOCIATION = "ResourceNotFound.NetAssociation"
// RESOURCENOTFOUND_PRIVATELINKRESOURCE = "ResourceNotFound.PrivateLinkResource"
// RESOURCENOTFOUND_ROLE = "ResourceNotFound.Role"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
func (c *Client) DeleteTargetWithContext(ctx context.Context, request *DeleteTargetRequest) (response *DeleteTargetResponse, err error) {
if request == nil {
request = NewDeleteTargetRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "DeleteTarget")
if c.GetCredential() == nil {
return nil, errors.New("DeleteTarget require credential")
}
request.SetContext(ctx)
response = NewDeleteTargetResponse()
err = c.Send(request, response)
return
}
func NewDeleteTransformationRequest() (request *DeleteTransformationRequest) {
request = &DeleteTransformationRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "DeleteTransformation")
return
}
func NewDeleteTransformationResponse() (response *DeleteTransformationResponse) {
response = &DeleteTransformationResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DeleteTransformation
// 用于删除转换器
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_TRANSFORMATIONID = "InvalidParameterValue.TransformationID"
// RESOURCENOTFOUND_TRANSFORMATION = "ResourceNotFound.Transformation"
func (c *Client) DeleteTransformation(request *DeleteTransformationRequest) (response *DeleteTransformationResponse, err error) {
return c.DeleteTransformationWithContext(context.Background(), request)
}
// DeleteTransformation
// 用于删除转换器
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_TRANSFORMATIONID = "InvalidParameterValue.TransformationID"
// RESOURCENOTFOUND_TRANSFORMATION = "ResourceNotFound.Transformation"
func (c *Client) DeleteTransformationWithContext(ctx context.Context, request *DeleteTransformationRequest) (response *DeleteTransformationResponse, err error) {
if request == nil {
request = NewDeleteTransformationRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "DeleteTransformation")
if c.GetCredential() == nil {
return nil, errors.New("DeleteTransformation require credential")
}
request.SetContext(ctx)
response = NewDeleteTransformationResponse()
err = c.Send(request, response)
return
}
func NewDescribeLogTagValueRequest() (request *DescribeLogTagValueRequest) {
request = &DescribeLogTagValueRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "DescribeLogTagValue")
return
}
func NewDescribeLogTagValueResponse() (response *DescribeLogTagValueResponse) {
response = &DescribeLogTagValueResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DescribeLogTagValue
// 前置条件:需开启事件存储;事件查询维度值
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
// RESOURCENOTFOUND = "ResourceNotFound"
func (c *Client) DescribeLogTagValue(request *DescribeLogTagValueRequest) (response *DescribeLogTagValueResponse, err error) {
return c.DescribeLogTagValueWithContext(context.Background(), request)
}
// DescribeLogTagValue
// 前置条件:需开启事件存储;事件查询维度值
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
// RESOURCENOTFOUND = "ResourceNotFound"
func (c *Client) DescribeLogTagValueWithContext(ctx context.Context, request *DescribeLogTagValueRequest) (response *DescribeLogTagValueResponse, err error) {
if request == nil {
request = NewDescribeLogTagValueRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "DescribeLogTagValue")
if c.GetCredential() == nil {
return nil, errors.New("DescribeLogTagValue require credential")
}
request.SetContext(ctx)
response = NewDescribeLogTagValueResponse()
err = c.Send(request, response)
return
}
func NewGetEventBusRequest() (request *GetEventBusRequest) {
request = &GetEventBusRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "GetEventBus")
return
}
func NewGetEventBusResponse() (response *GetEventBusResponse) {
response = &GetEventBusResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// GetEventBus
// 获取事件集详情
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) GetEventBus(request *GetEventBusRequest) (response *GetEventBusResponse, err error) {
return c.GetEventBusWithContext(context.Background(), request)
}
// GetEventBus
// 获取事件集详情
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) GetEventBusWithContext(ctx context.Context, request *GetEventBusRequest) (response *GetEventBusResponse, err error) {
if request == nil {
request = NewGetEventBusRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "GetEventBus")
if c.GetCredential() == nil {
return nil, errors.New("GetEventBus require credential")
}
request.SetContext(ctx)
response = NewGetEventBusResponse()
err = c.Send(request, response)
return
}
func NewGetPlatformEventTemplateRequest() (request *GetPlatformEventTemplateRequest) {
request = &GetPlatformEventTemplateRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "GetPlatformEventTemplate")
return
}
func NewGetPlatformEventTemplateResponse() (response *GetPlatformEventTemplateResponse) {
response = &GetPlatformEventTemplateResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// GetPlatformEventTemplate
// 获取平台产品事件模板
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
func (c *Client) GetPlatformEventTemplate(request *GetPlatformEventTemplateRequest) (response *GetPlatformEventTemplateResponse, err error) {
return c.GetPlatformEventTemplateWithContext(context.Background(), request)
}
// GetPlatformEventTemplate
// 获取平台产品事件模板
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
func (c *Client) GetPlatformEventTemplateWithContext(ctx context.Context, request *GetPlatformEventTemplateRequest) (response *GetPlatformEventTemplateResponse, err error) {
if request == nil {
request = NewGetPlatformEventTemplateRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "GetPlatformEventTemplate")
if c.GetCredential() == nil {
return nil, errors.New("GetPlatformEventTemplate require credential")
}
request.SetContext(ctx)
response = NewGetPlatformEventTemplateResponse()
err = c.Send(request, response)
return
}
func NewGetRuleRequest() (request *GetRuleRequest) {
request = &GetRuleRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "GetRule")
return
}
func NewGetRuleResponse() (response *GetRuleResponse) {
response = &GetRuleResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// GetRule
// 获取事件规则详情
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) GetRule(request *GetRuleRequest) (response *GetRuleResponse, err error) {
return c.GetRuleWithContext(context.Background(), request)
}
// GetRule
// 获取事件规则详情
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) GetRuleWithContext(ctx context.Context, request *GetRuleRequest) (response *GetRuleResponse, err error) {
if request == nil {
request = NewGetRuleRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "GetRule")
if c.GetCredential() == nil {
return nil, errors.New("GetRule require credential")
}
request.SetContext(ctx)
response = NewGetRuleResponse()
err = c.Send(request, response)
return
}
func NewGetTransformationRequest() (request *GetTransformationRequest) {
request = &GetTransformationRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "GetTransformation")
return
}
func NewGetTransformationResponse() (response *GetTransformationResponse) {
response = &GetTransformationResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// GetTransformation
// 用于获取转换器详情
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TRANSFORMATIONID = "InvalidParameterValue.TransformationID"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_TRANSFORMATION = "ResourceNotFound.Transformation"
func (c *Client) GetTransformation(request *GetTransformationRequest) (response *GetTransformationResponse, err error) {
return c.GetTransformationWithContext(context.Background(), request)
}
// GetTransformation
// 用于获取转换器详情
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TRANSFORMATIONID = "InvalidParameterValue.TransformationID"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_TRANSFORMATION = "ResourceNotFound.Transformation"
func (c *Client) GetTransformationWithContext(ctx context.Context, request *GetTransformationRequest) (response *GetTransformationResponse, err error) {
if request == nil {
request = NewGetTransformationRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "GetTransformation")
if c.GetCredential() == nil {
return nil, errors.New("GetTransformation require credential")
}
request.SetContext(ctx)
response = NewGetTransformationResponse()
err = c.Send(request, response)
return
}
func NewListConnectionsRequest() (request *ListConnectionsRequest) {
request = &ListConnectionsRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "ListConnections")
return
}
func NewListConnectionsResponse() (response *ListConnectionsResponse) {
response = &ListConnectionsResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// ListConnections
// 获取事件连接器列表
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_OFFSET = "InvalidParameterValue.Offset"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) ListConnections(request *ListConnectionsRequest) (response *ListConnectionsResponse, err error) {
return c.ListConnectionsWithContext(context.Background(), request)
}
// ListConnections
// 获取事件连接器列表
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_OFFSET = "InvalidParameterValue.Offset"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) ListConnectionsWithContext(ctx context.Context, request *ListConnectionsRequest) (response *ListConnectionsResponse, err error) {
if request == nil {
request = NewListConnectionsRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "ListConnections")
if c.GetCredential() == nil {
return nil, errors.New("ListConnections require credential")
}
request.SetContext(ctx)
response = NewListConnectionsResponse()
err = c.Send(request, response)
return
}
func NewListEventBusesRequest() (request *ListEventBusesRequest) {
request = &ListEventBusesRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "ListEventBuses")
return
}
func NewListEventBusesResponse() (response *ListEventBusesResponse) {
response = &ListEventBusesResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// ListEventBuses
// 获取事件集列表
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_FILTERS = "InvalidParameterValue.Filters"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_OFFSET = "InvalidParameterValue.Offset"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// UNAUTHORIZEDOPERATION_CAM = "UnauthorizedOperation.CAM"
func (c *Client) ListEventBuses(request *ListEventBusesRequest) (response *ListEventBusesResponse, err error) {
return c.ListEventBusesWithContext(context.Background(), request)
}
// ListEventBuses
// 获取事件集列表
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_FILTERS = "InvalidParameterValue.Filters"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_OFFSET = "InvalidParameterValue.Offset"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// UNAUTHORIZEDOPERATION_CAM = "UnauthorizedOperation.CAM"
func (c *Client) ListEventBusesWithContext(ctx context.Context, request *ListEventBusesRequest) (response *ListEventBusesResponse, err error) {
if request == nil {
request = NewListEventBusesRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "ListEventBuses")
if c.GetCredential() == nil {
return nil, errors.New("ListEventBuses require credential")
}
request.SetContext(ctx)
response = NewListEventBusesResponse()
err = c.Send(request, response)
return
}
func NewListPlatformEventNamesRequest() (request *ListPlatformEventNamesRequest) {
request = &ListPlatformEventNamesRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "ListPlatformEventNames")
return
}
func NewListPlatformEventNamesResponse() (response *ListPlatformEventNamesResponse) {
response = &ListPlatformEventNamesResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// ListPlatformEventNames
// 获取平台产品事件名称
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
func (c *Client) ListPlatformEventNames(request *ListPlatformEventNamesRequest) (response *ListPlatformEventNamesResponse, err error) {
return c.ListPlatformEventNamesWithContext(context.Background(), request)
}
// ListPlatformEventNames
// 获取平台产品事件名称
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
func (c *Client) ListPlatformEventNamesWithContext(ctx context.Context, request *ListPlatformEventNamesRequest) (response *ListPlatformEventNamesResponse, err error) {
if request == nil {
request = NewListPlatformEventNamesRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "ListPlatformEventNames")
if c.GetCredential() == nil {
return nil, errors.New("ListPlatformEventNames require credential")
}
request.SetContext(ctx)
response = NewListPlatformEventNamesResponse()
err = c.Send(request, response)
return
}
func NewListPlatformEventPatternsRequest() (request *ListPlatformEventPatternsRequest) {
request = &ListPlatformEventPatternsRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "ListPlatformEventPatterns")
return
}
func NewListPlatformEventPatternsResponse() (response *ListPlatformEventPatternsResponse) {
response = &ListPlatformEventPatternsResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// ListPlatformEventPatterns
// 获取平台产品事件匹配规则
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
func (c *Client) ListPlatformEventPatterns(request *ListPlatformEventPatternsRequest) (response *ListPlatformEventPatternsResponse, err error) {
return c.ListPlatformEventPatternsWithContext(context.Background(), request)
}
// ListPlatformEventPatterns
// 获取平台产品事件匹配规则
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
func (c *Client) ListPlatformEventPatternsWithContext(ctx context.Context, request *ListPlatformEventPatternsRequest) (response *ListPlatformEventPatternsResponse, err error) {
if request == nil {
request = NewListPlatformEventPatternsRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "ListPlatformEventPatterns")
if c.GetCredential() == nil {
return nil, errors.New("ListPlatformEventPatterns require credential")
}
request.SetContext(ctx)
response = NewListPlatformEventPatternsResponse()
err = c.Send(request, response)
return
}
func NewListPlatformProductsRequest() (request *ListPlatformProductsRequest) {
request = &ListPlatformProductsRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "ListPlatformProducts")
return
}
func NewListPlatformProductsResponse() (response *ListPlatformProductsResponse) {
response = &ListPlatformProductsResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// ListPlatformProducts
// 获取平台产品列表
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
func (c *Client) ListPlatformProducts(request *ListPlatformProductsRequest) (response *ListPlatformProductsResponse, err error) {
return c.ListPlatformProductsWithContext(context.Background(), request)
}
// ListPlatformProducts
// 获取平台产品列表
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
func (c *Client) ListPlatformProductsWithContext(ctx context.Context, request *ListPlatformProductsRequest) (response *ListPlatformProductsResponse, err error) {
if request == nil {
request = NewListPlatformProductsRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "ListPlatformProducts")
if c.GetCredential() == nil {
return nil, errors.New("ListPlatformProducts require credential")
}
request.SetContext(ctx)
response = NewListPlatformProductsResponse()
err = c.Send(request, response)
return
}
func NewListRulesRequest() (request *ListRulesRequest) {
request = &ListRulesRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "ListRules")
return
}
func NewListRulesResponse() (response *ListRulesResponse) {
response = &ListRulesResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// ListRules
// 获取事件规则列表
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_FILTERS = "InvalidParameterValue.Filters"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) ListRules(request *ListRulesRequest) (response *ListRulesResponse, err error) {
return c.ListRulesWithContext(context.Background(), request)
}
// ListRules
// 获取事件规则列表
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_FILTERS = "InvalidParameterValue.Filters"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) ListRulesWithContext(ctx context.Context, request *ListRulesRequest) (response *ListRulesResponse, err error) {
if request == nil {
request = NewListRulesRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "ListRules")
if c.GetCredential() == nil {
return nil, errors.New("ListRules require credential")
}
request.SetContext(ctx)
response = NewListRulesResponse()
err = c.Send(request, response)
return
}
func NewListTargetsRequest() (request *ListTargetsRequest) {
request = &ListTargetsRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "ListTargets")
return
}
func NewListTargetsResponse() (response *ListTargetsResponse) {
response = &ListTargetsResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// ListTargets
// 获取事件目标列表
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_OFFSET = "InvalidParameterValue.Offset"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETID = "InvalidParameterValue.TargetId"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) ListTargets(request *ListTargetsRequest) (response *ListTargetsResponse, err error) {
return c.ListTargetsWithContext(context.Background(), request)
}
// ListTargets
// 获取事件目标列表
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_LIMIT = "InvalidParameterValue.Limit"
// INVALIDPARAMETERVALUE_OFFSET = "InvalidParameterValue.Offset"
// INVALIDPARAMETERVALUE_ORDER = "InvalidParameterValue.Order"
// INVALIDPARAMETERVALUE_ORDERBY = "InvalidParameterValue.OrderBy"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETID = "InvalidParameterValue.TargetId"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) ListTargetsWithContext(ctx context.Context, request *ListTargetsRequest) (response *ListTargetsResponse, err error) {
if request == nil {
request = NewListTargetsRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "ListTargets")
if c.GetCredential() == nil {
return nil, errors.New("ListTargets require credential")
}
request.SetContext(ctx)
response = NewListTargetsResponse()
err = c.Send(request, response)
return
}
func NewPublishEventRequest() (request *PublishEventRequest) {
request = &PublishEventRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "PublishEvent")
return
}
func NewPublishEventResponse() (response *PublishEventResponse) {
response = &PublishEventResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// PublishEvent
// (已废弃)用于Event事件投递
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_INVALIDEVENT = "InvalidParameterValue.InvalidEvent"
// INVALIDPARAMETERVALUE_INVALIDEVENTBUS = "InvalidParameterValue.InvalidEventBus"
// LIMITEXCEEDED_RESOURCELIMIT = "LimitExceeded.ResourceLimit"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_EVENTBUSNOTFOUND = "ResourceNotFound.EventBusNotFound"
func (c *Client) PublishEvent(request *PublishEventRequest) (response *PublishEventResponse, err error) {
return c.PublishEventWithContext(context.Background(), request)
}
// PublishEvent
// (已废弃)用于Event事件投递
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_INVALIDEVENT = "InvalidParameterValue.InvalidEvent"
// INVALIDPARAMETERVALUE_INVALIDEVENTBUS = "InvalidParameterValue.InvalidEventBus"
// LIMITEXCEEDED_RESOURCELIMIT = "LimitExceeded.ResourceLimit"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_EVENTBUSNOTFOUND = "ResourceNotFound.EventBusNotFound"
func (c *Client) PublishEventWithContext(ctx context.Context, request *PublishEventRequest) (response *PublishEventResponse, err error) {
if request == nil {
request = NewPublishEventRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "PublishEvent")
if c.GetCredential() == nil {
return nil, errors.New("PublishEvent require credential")
}
request.SetContext(ctx)
response = NewPublishEventResponse()
err = c.Send(request, response)
return
}
func NewPutEventsRequest() (request *PutEventsRequest) {
request = &PutEventsRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "PutEvents")
return
}
func NewPutEventsResponse() (response *PutEventsResponse) {
response = &PutEventsResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// PutEvents
// 用于Event事件投递
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INTERNALERROR_UNKNOWNINTERNALERROR = "InternalError.UnknownInternalError"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_INVALIDEVENT = "InvalidParameterValue.InvalidEvent"
// INVALIDPARAMETERVALUE_INVALIDEVENTBUS = "InvalidParameterValue.InvalidEventBus"
// LIMITEXCEEDED_BANNEDACCOUNT = "LimitExceeded.BannedAccount"
// LIMITEXCEEDED_RESOURCELIMIT = "LimitExceeded.ResourceLimit"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_EVENTBUSNOTFOUND = "ResourceNotFound.EventBusNotFound"
func (c *Client) PutEvents(request *PutEventsRequest) (response *PutEventsResponse, err error) {
return c.PutEventsWithContext(context.Background(), request)
}
// PutEvents
// 用于Event事件投递
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INTERNALERROR_SYSTEM = "InternalError.System"
// INTERNALERROR_UNKNOWNINTERNALERROR = "InternalError.UnknownInternalError"
// INVALIDPARAMETER = "InvalidParameter"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_INVALIDEVENT = "InvalidParameterValue.InvalidEvent"
// INVALIDPARAMETERVALUE_INVALIDEVENTBUS = "InvalidParameterValue.InvalidEventBus"
// LIMITEXCEEDED_BANNEDACCOUNT = "LimitExceeded.BannedAccount"
// LIMITEXCEEDED_RESOURCELIMIT = "LimitExceeded.ResourceLimit"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_EVENTBUSNOTFOUND = "ResourceNotFound.EventBusNotFound"
func (c *Client) PutEventsWithContext(ctx context.Context, request *PutEventsRequest) (response *PutEventsResponse, err error) {
if request == nil {
request = NewPutEventsRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "PutEvents")
if c.GetCredential() == nil {
return nil, errors.New("PutEvents require credential")
}
request.SetContext(ctx)
response = NewPutEventsResponse()
err = c.Send(request, response)
return
}
func NewSearchLogRequest() (request *SearchLogRequest) {
request = &SearchLogRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "SearchLog")
return
}
func NewSearchLogResponse() (response *SearchLogResponse) {
response = &SearchLogResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// SearchLog
// 前置条件:开启事件存储;查询历史推送事件
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
// RESOURCENOTFOUND = "ResourceNotFound"
func (c *Client) SearchLog(request *SearchLogRequest) (response *SearchLogResponse, err error) {
return c.SearchLogWithContext(context.Background(), request)
}
// SearchLog
// 前置条件:开启事件存储;查询历史推送事件
//
// 可能返回的错误码:
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_ACTION = "InvalidParameterValue.Action"
// RESOURCENOTFOUND = "ResourceNotFound"
func (c *Client) SearchLogWithContext(ctx context.Context, request *SearchLogRequest) (response *SearchLogResponse, err error) {
if request == nil {
request = NewSearchLogRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "SearchLog")
if c.GetCredential() == nil {
return nil, errors.New("SearchLog require credential")
}
request.SetContext(ctx)
response = NewSearchLogResponse()
err = c.Send(request, response)
return
}
func NewUpdateConnectionRequest() (request *UpdateConnectionRequest) {
request = &UpdateConnectionRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "UpdateConnection")
return
}
func NewUpdateConnectionResponse() (response *UpdateConnectionResponse) {
response = &UpdateConnectionResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// UpdateConnection
// 更新事件连接器
//
// 可能返回的错误码:
// FAILEDOPERATION_UPDATECONNECTION = "FailedOperation.UpdateConnection"
// INVALIDPARAMETER_ENABLEAPIGATEWAY = "InvalidParameter.EnableAPIGateway"
// INVALIDPARAMETERVALUE_CONNECTIONID = "InvalidParameterValue.ConnectionId"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND_CONNECTION = "ResourceNotFound.Connection"
func (c *Client) UpdateConnection(request *UpdateConnectionRequest) (response *UpdateConnectionResponse, err error) {
return c.UpdateConnectionWithContext(context.Background(), request)
}
// UpdateConnection
// 更新事件连接器
//
// 可能返回的错误码:
// FAILEDOPERATION_UPDATECONNECTION = "FailedOperation.UpdateConnection"
// INVALIDPARAMETER_ENABLEAPIGATEWAY = "InvalidParameter.EnableAPIGateway"
// INVALIDPARAMETERVALUE_CONNECTIONID = "InvalidParameterValue.ConnectionId"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND_CONNECTION = "ResourceNotFound.Connection"
func (c *Client) UpdateConnectionWithContext(ctx context.Context, request *UpdateConnectionRequest) (response *UpdateConnectionResponse, err error) {
if request == nil {
request = NewUpdateConnectionRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "UpdateConnection")
if c.GetCredential() == nil {
return nil, errors.New("UpdateConnection require credential")
}
request.SetContext(ctx)
response = NewUpdateConnectionResponse()
err = c.Send(request, response)
return
}
func NewUpdateEventBusRequest() (request *UpdateEventBusRequest) {
request = &UpdateEventBusRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "UpdateEventBus")
return
}
func NewUpdateEventBusResponse() (response *UpdateEventBusResponse) {
response = &UpdateEventBusResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// UpdateEventBus
// 更新事件集
//
// 可能返回的错误码:
// FAILEDOPERATION_REGISTERCLSSERVICE = "FailedOperation.RegisterCLSService"
// INVALIDPARAMETER_PAYLOAD = "InvalidParameter.Payload"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSNAME = "InvalidParameterValue.EventBusName"
// INVALIDPARAMETERVALUE_EVENTTRACECONFIG = "InvalidParameterValue.EventTraceConfig"
// OPERATIONDENIED_DEFAULTCLSRESOURCEUNSUPPORTED = "OperationDenied.DefaultCLSResourceUnsupported"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) UpdateEventBus(request *UpdateEventBusRequest) (response *UpdateEventBusResponse, err error) {
return c.UpdateEventBusWithContext(context.Background(), request)
}
// UpdateEventBus
// 更新事件集
//
// 可能返回的错误码:
// FAILEDOPERATION_REGISTERCLSSERVICE = "FailedOperation.RegisterCLSService"
// INVALIDPARAMETER_PAYLOAD = "InvalidParameter.Payload"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSNAME = "InvalidParameterValue.EventBusName"
// INVALIDPARAMETERVALUE_EVENTTRACECONFIG = "InvalidParameterValue.EventTraceConfig"
// OPERATIONDENIED_DEFAULTCLSRESOURCEUNSUPPORTED = "OperationDenied.DefaultCLSResourceUnsupported"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) UpdateEventBusWithContext(ctx context.Context, request *UpdateEventBusRequest) (response *UpdateEventBusResponse, err error) {
if request == nil {
request = NewUpdateEventBusRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "UpdateEventBus")
if c.GetCredential() == nil {
return nil, errors.New("UpdateEventBus require credential")
}
request.SetContext(ctx)
response = NewUpdateEventBusResponse()
err = c.Send(request, response)
return
}
func NewUpdateRuleRequest() (request *UpdateRuleRequest) {
request = &UpdateRuleRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "UpdateRule")
return
}
func NewUpdateRuleResponse() (response *UpdateRuleResponse) {
response = &UpdateRuleResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// UpdateRule
// 更新事件规则
//
// 可能返回的错误码:
// FAILEDOPERATION_UPDATERULE = "FailedOperation.UpdateRule"
// INVALIDPARAMETER_PAYLOAD = "InvalidParameter.Payload"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_EVENTPATTERN = "InvalidParameterValue.EventPattern"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_RULENAME = "InvalidParameterValue.RuleName"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) UpdateRule(request *UpdateRuleRequest) (response *UpdateRuleResponse, err error) {
return c.UpdateRuleWithContext(context.Background(), request)
}
// UpdateRule
// 更新事件规则
//
// 可能返回的错误码:
// FAILEDOPERATION_UPDATERULE = "FailedOperation.UpdateRule"
// INVALIDPARAMETER_PAYLOAD = "InvalidParameter.Payload"
// INVALIDPARAMETERVALUE_DESCRIPTION = "InvalidParameterValue.Description"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_EVENTPATTERN = "InvalidParameterValue.EventPattern"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_RULENAME = "InvalidParameterValue.RuleName"
// INVALIDPARAMETERVALUE_TYPE = "InvalidParameterValue.Type"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
func (c *Client) UpdateRuleWithContext(ctx context.Context, request *UpdateRuleRequest) (response *UpdateRuleResponse, err error) {
if request == nil {
request = NewUpdateRuleRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "UpdateRule")
if c.GetCredential() == nil {
return nil, errors.New("UpdateRule require credential")
}
request.SetContext(ctx)
response = NewUpdateRuleResponse()
err = c.Send(request, response)
return
}
func NewUpdateTargetRequest() (request *UpdateTargetRequest) {
request = &UpdateTargetRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "UpdateTarget")
return
}
func NewUpdateTargetResponse() (response *UpdateTargetResponse) {
response = &UpdateTargetResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// UpdateTarget
// 更新事件目标
//
// 可能返回的错误码:
// AUTHFAILURE = "AuthFailure"
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_BATCHTIMEOUT = "InvalidParameterValue.BatchTimeout"
// INVALIDPARAMETERVALUE_CALLBACKTYPE = "InvalidParameterValue.CallbackType"
// INVALIDPARAMETERVALUE_CALLBACKWECOMURL = "InvalidParameterValue.CallbackWeComURL"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_NOTICERECEIVERCHANNEL = "InvalidParameterValue.NoticeReceiverChannel"
// INVALIDPARAMETERVALUE_NOTICERECEIVERTIMEWINDOW = "InvalidParameterValue.NoticeReceiverTimeWindow"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERIDS = "InvalidParameterValue.NoticeReceiverUserIds"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERTYPE = "InvalidParameterValue.NoticeReceiverUserType"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETID = "InvalidParameterValue.TargetId"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
func (c *Client) UpdateTarget(request *UpdateTargetRequest) (response *UpdateTargetResponse, err error) {
return c.UpdateTargetWithContext(context.Background(), request)
}
// UpdateTarget
// 更新事件目标
//
// 可能返回的错误码:
// AUTHFAILURE = "AuthFailure"
// INTERNALERROR = "InternalError"
// INVALIDPARAMETERVALUE_BATCHTIMEOUT = "InvalidParameterValue.BatchTimeout"
// INVALIDPARAMETERVALUE_CALLBACKTYPE = "InvalidParameterValue.CallbackType"
// INVALIDPARAMETERVALUE_CALLBACKWECOMURL = "InvalidParameterValue.CallbackWeComURL"
// INVALIDPARAMETERVALUE_EVENTBUSID = "InvalidParameterValue.EventBusId"
// INVALIDPARAMETERVALUE_NOTICERECEIVERCHANNEL = "InvalidParameterValue.NoticeReceiverChannel"
// INVALIDPARAMETERVALUE_NOTICERECEIVERTIMEWINDOW = "InvalidParameterValue.NoticeReceiverTimeWindow"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERIDS = "InvalidParameterValue.NoticeReceiverUserIds"
// INVALIDPARAMETERVALUE_NOTICERECEIVERUSERTYPE = "InvalidParameterValue.NoticeReceiverUserType"
// INVALIDPARAMETERVALUE_RULEID = "InvalidParameterValue.RuleId"
// INVALIDPARAMETERVALUE_TARGETID = "InvalidParameterValue.TargetId"
// OPERATIONDENIED_RESOURCEIMMUTABLE = "OperationDenied.ResourceImmutable"
// RESOURCENOTFOUND = "ResourceNotFound"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
// RESOURCENOTFOUND_RULE = "ResourceNotFound.Rule"
// RESOURCENOTFOUND_TARGET = "ResourceNotFound.Target"
func (c *Client) UpdateTargetWithContext(ctx context.Context, request *UpdateTargetRequest) (response *UpdateTargetResponse, err error) {
if request == nil {
request = NewUpdateTargetRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "UpdateTarget")
if c.GetCredential() == nil {
return nil, errors.New("UpdateTarget require credential")
}
request.SetContext(ctx)
response = NewUpdateTargetResponse()
err = c.Send(request, response)
return
}
func NewUpdateTransformationRequest() (request *UpdateTransformationRequest) {
request = &UpdateTransformationRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("eb", APIVersion, "UpdateTransformation")
return
}
func NewUpdateTransformationResponse() (response *UpdateTransformationResponse) {
response = &UpdateTransformationResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// UpdateTransformation
// 用于更新转换器
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_TRANSFORMATIONID = "InvalidParameterValue.TransformationID"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) UpdateTransformation(request *UpdateTransformationRequest) (response *UpdateTransformationResponse, err error) {
return c.UpdateTransformationWithContext(context.Background(), request)
}
// UpdateTransformation
// 用于更新转换器
//
// 可能返回的错误码:
// INVALIDPARAMETERVALUE_TRANSFORMATIONID = "InvalidParameterValue.TransformationID"
// RESOURCENOTFOUND_EVENTBUS = "ResourceNotFound.EventBus"
func (c *Client) UpdateTransformationWithContext(ctx context.Context, request *UpdateTransformationRequest) (response *UpdateTransformationResponse, err error) {
if request == nil {
request = NewUpdateTransformationRequest()
}
c.InitBaseRequest(&request.BaseRequest, "eb", APIVersion, "UpdateTransformation")
if c.GetCredential() == nil {
return nil, errors.New("UpdateTransformation require credential")
}
request.SetContext(ctx)
response = NewUpdateTransformationResponse()
err = c.Send(request, response)
return
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/tencentcloud/tencentcloud-sdk-go.git
git@gitee.com:tencentcloud/tencentcloud-sdk-go.git
tencentcloud
tencentcloud-sdk-go
tencentcloud-sdk-go
master

搜索帮助