public async Task <UpdateTriggerResponse> UpdateTriggerAsync(UpdateTriggerRequest request) { AlibabaCloud.TeaUtil.Models.RuntimeOptions runtime = new AlibabaCloud.TeaUtil.Models.RuntimeOptions(); UpdateTriggerHeaders headers = new UpdateTriggerHeaders(); return(await UpdateTriggerWithOptionsAsync(request, headers, runtime)); }
public UpdateTriggerResponse UpdateTrigger(UpdateTriggerRequest request) { AlibabaCloud.TeaUtil.Models.RuntimeOptions runtime = new AlibabaCloud.TeaUtil.Models.RuntimeOptions(); UpdateTriggerHeaders headers = new UpdateTriggerHeaders(); return(UpdateTriggerWithOptions(request, headers, runtime)); }
public async Task <UpdateTriggerResponse> UpdateTriggerWithOptionsAsync(UpdateTriggerRequest request, UpdateTriggerHeaders headers, AlibabaCloud.TeaUtil.Models.RuntimeOptions runtime) { AlibabaCloud.TeaUtil.Common.ValidateModel(request); Dictionary <string, object> body = new Dictionary <string, object>() { }; if (!AlibabaCloud.TeaUtil.Common.IsUnset(request.IntegratorFlag)) { body["integratorFlag"] = request.IntegratorFlag; } if (!AlibabaCloud.TeaUtil.Common.IsUnset(request.TriggerInfo)) { body["triggerInfo"] = request.TriggerInfo; } Dictionary <string, string> realHeaders = new Dictionary <string, string>() { }; if (!AlibabaCloud.TeaUtil.Common.IsUnset(headers.CommonHeaders)) { realHeaders = headers.CommonHeaders; } if (!AlibabaCloud.TeaUtil.Common.IsUnset(headers.XAcsDingtalkAccessToken)) { realHeaders["x-acs-dingtalk-access-token"] = AlibabaCloud.TeaUtil.Common.ToJSONString(headers.XAcsDingtalkAccessToken); } AlibabaCloud.OpenApiClient.Models.OpenApiRequest req = new AlibabaCloud.OpenApiClient.Models.OpenApiRequest { Headers = realHeaders, Body = AlibabaCloud.OpenApiUtil.Client.ParseToMap(body), }; return(TeaModel.ToObject <UpdateTriggerResponse>(await DoROARequestAsync("UpdateTrigger", "connector_1.0", "HTTP", "PUT", "AK", "/v1.0/connector/triggers", "json", req, runtime))); }