/** * Description: Demo接口,返回当输入的值 * Summary: 返回输入值 */ public async Task <EchoGatewayCheckResponse> EchoGatewayCheckExAsync(EchoGatewayCheckRequest request, Dictionary <string, string> headers, AlibabaCloud.TeaUtil.Models.RuntimeOptions runtime) { if (!AlibabaCloud.TeaUtil.Common.IsUnset(request.FileObject)) { CreateAntcloudGatewayxFileUploadRequest uploadReq = new CreateAntcloudGatewayxFileUploadRequest { ApiCode = "demo.gateway.check.echo", }; CreateAntcloudGatewayxFileUploadResponse uploadResp = await CreateAntcloudGatewayxFileUploadExAsync(uploadReq, headers, runtime); if (!AntChain.AlipayUtil.AntchainUtils.IsSuccess(uploadResp.ResultCode, "OK")) { EchoGatewayCheckResponse echoGatewayCheckResponse = new EchoGatewayCheckResponse { ReqMsgId = uploadResp.ReqMsgId, ResultCode = uploadResp.ResultCode, ResultMsg = uploadResp.ResultMsg, }; return(echoGatewayCheckResponse); } Dictionary <string, string> uploadHeaders = AntChain.AlipayUtil.AntchainUtils.ParseUploadHeaders(uploadResp.UploadHeaders); AntChain.AlipayUtil.AntchainUtils.PutObject(request.FileObject, uploadHeaders, uploadResp.UploadUrl); request.FileId = uploadResp.FileId; } AlibabaCloud.TeaUtil.Common.ValidateModel(request); return(TeaModel.ToObject <EchoGatewayCheckResponse>(await DoRequestAsync("1.0", "demo.gateway.check.echo", "HTTPS", "POST", "/gateway.do", request.ToMap(), headers, runtime))); }
/** * Description: Demo接口,返回当输入的值 * Summary: 返回输入值 */ public async Task <EchoGatewayCheckResponse> EchoGatewayCheckAsync(EchoGatewayCheckRequest request) { AlibabaCloud.TeaUtil.Models.RuntimeOptions runtime = new AlibabaCloud.TeaUtil.Models.RuntimeOptions(); Dictionary <string, string> headers = new Dictionary <string, string>() { }; return(await EchoGatewayCheckExAsync(request, headers, runtime)); }
/** * Description: Demo接口,返回当输入的值 * Summary: 返回输入值 */ public EchoGatewayCheckResponse EchoGatewayCheck(EchoGatewayCheckRequest request) { AlibabaCloud.TeaUtil.Models.RuntimeOptions runtime = new AlibabaCloud.TeaUtil.Models.RuntimeOptions(); Dictionary <string, string> headers = new Dictionary <string, string>() { }; return(EchoGatewayCheckEx(request, headers, runtime)); }