diff --git a/CHANGELOG b/CHANGELOG index 05ee8d9ee..e3ef2547f 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +2021-01-27 Version: patch +- DetectFaceAttributes Add Score. + 2021-01-26 Version: patch - Support ModifyDBClusterPrimaryZone timer task. diff --git a/cloudauth/CMakeLists.txt b/cloudauth/CMakeLists.txt index 0a7031d45..5ff4af56d 100644 --- a/cloudauth/CMakeLists.txt +++ b/cloudauth/CMakeLists.txt @@ -27,6 +27,8 @@ set(cloudauth_public_header_model include/alibabacloud/cloudauth/model/CompareFacesResult.h include/alibabacloud/cloudauth/model/ContrastFaceVerifyRequest.h include/alibabacloud/cloudauth/model/ContrastFaceVerifyResult.h + include/alibabacloud/cloudauth/model/ContrastSmartVerifyRequest.h + include/alibabacloud/cloudauth/model/ContrastSmartVerifyResult.h include/alibabacloud/cloudauth/model/CreateAuthKeyRequest.h include/alibabacloud/cloudauth/model/CreateAuthKeyResult.h include/alibabacloud/cloudauth/model/CreateFaceConfigRequest.h @@ -37,6 +39,10 @@ set(cloudauth_public_header_model include/alibabacloud/cloudauth/model/CreateVerifySDKResult.h include/alibabacloud/cloudauth/model/CreateVerifySettingRequest.h include/alibabacloud/cloudauth/model/CreateVerifySettingResult.h + include/alibabacloud/cloudauth/model/CreateWhitelistRequest.h + include/alibabacloud/cloudauth/model/CreateWhitelistResult.h + include/alibabacloud/cloudauth/model/DeleteWhitelistRequest.h + include/alibabacloud/cloudauth/model/DeleteWhitelistResult.h include/alibabacloud/cloudauth/model/DescribeAppInfoRequest.h include/alibabacloud/cloudauth/model/DescribeAppInfoResult.h include/alibabacloud/cloudauth/model/DescribeDeviceInfoRequest.h @@ -73,6 +79,8 @@ set(cloudauth_public_header_model include/alibabacloud/cloudauth/model/DescribeVerifyTokenResult.h include/alibabacloud/cloudauth/model/DescribeVerifyUsageRequest.h include/alibabacloud/cloudauth/model/DescribeVerifyUsageResult.h + include/alibabacloud/cloudauth/model/DescribeWhitelistRequest.h + include/alibabacloud/cloudauth/model/DescribeWhitelistResult.h include/alibabacloud/cloudauth/model/DetectFaceAttributesRequest.h include/alibabacloud/cloudauth/model/DetectFaceAttributesResult.h include/alibabacloud/cloudauth/model/ElementSmartVerifyRequest.h @@ -118,6 +126,8 @@ set(cloudauth_src src/model/CompareFacesResult.cc src/model/ContrastFaceVerifyRequest.cc src/model/ContrastFaceVerifyResult.cc + src/model/ContrastSmartVerifyRequest.cc + src/model/ContrastSmartVerifyResult.cc src/model/CreateAuthKeyRequest.cc src/model/CreateAuthKeyResult.cc src/model/CreateFaceConfigRequest.cc @@ -128,6 +138,10 @@ set(cloudauth_src src/model/CreateVerifySDKResult.cc src/model/CreateVerifySettingRequest.cc src/model/CreateVerifySettingResult.cc + src/model/CreateWhitelistRequest.cc + src/model/CreateWhitelistResult.cc + src/model/DeleteWhitelistRequest.cc + src/model/DeleteWhitelistResult.cc src/model/DescribeAppInfoRequest.cc src/model/DescribeAppInfoResult.cc src/model/DescribeDeviceInfoRequest.cc @@ -164,6 +178,8 @@ set(cloudauth_src src/model/DescribeVerifyTokenResult.cc src/model/DescribeVerifyUsageRequest.cc src/model/DescribeVerifyUsageResult.cc + src/model/DescribeWhitelistRequest.cc + src/model/DescribeWhitelistResult.cc src/model/DetectFaceAttributesRequest.cc src/model/DetectFaceAttributesResult.cc src/model/ElementSmartVerifyRequest.cc diff --git a/cloudauth/include/alibabacloud/cloudauth/CloudauthClient.h b/cloudauth/include/alibabacloud/cloudauth/CloudauthClient.h index 43e206b59..67b527358 100644 --- a/cloudauth/include/alibabacloud/cloudauth/CloudauthClient.h +++ b/cloudauth/include/alibabacloud/cloudauth/CloudauthClient.h @@ -28,6 +28,8 @@ #include "model/CompareFacesResult.h" #include "model/ContrastFaceVerifyRequest.h" #include "model/ContrastFaceVerifyResult.h" +#include "model/ContrastSmartVerifyRequest.h" +#include "model/ContrastSmartVerifyResult.h" #include "model/CreateAuthKeyRequest.h" #include "model/CreateAuthKeyResult.h" #include "model/CreateFaceConfigRequest.h" @@ -38,6 +40,10 @@ #include "model/CreateVerifySDKResult.h" #include "model/CreateVerifySettingRequest.h" #include "model/CreateVerifySettingResult.h" +#include "model/CreateWhitelistRequest.h" +#include "model/CreateWhitelistResult.h" +#include "model/DeleteWhitelistRequest.h" +#include "model/DeleteWhitelistResult.h" #include "model/DescribeAppInfoRequest.h" #include "model/DescribeAppInfoResult.h" #include "model/DescribeDeviceInfoRequest.h" @@ -74,6 +80,8 @@ #include "model/DescribeVerifyTokenResult.h" #include "model/DescribeVerifyUsageRequest.h" #include "model/DescribeVerifyUsageResult.h" +#include "model/DescribeWhitelistRequest.h" +#include "model/DescribeWhitelistResult.h" #include "model/DetectFaceAttributesRequest.h" #include "model/DetectFaceAttributesResult.h" #include "model/ElementSmartVerifyRequest.h" @@ -128,6 +136,9 @@ namespace AlibabaCloud typedef Outcome ContrastFaceVerifyOutcome; typedef std::future ContrastFaceVerifyOutcomeCallable; typedef std::function&)> ContrastFaceVerifyAsyncHandler; + typedef Outcome ContrastSmartVerifyOutcome; + typedef std::future ContrastSmartVerifyOutcomeCallable; + typedef std::function&)> ContrastSmartVerifyAsyncHandler; typedef Outcome CreateAuthKeyOutcome; typedef std::future CreateAuthKeyOutcomeCallable; typedef std::function&)> CreateAuthKeyAsyncHandler; @@ -143,6 +154,12 @@ namespace AlibabaCloud typedef Outcome CreateVerifySettingOutcome; typedef std::future CreateVerifySettingOutcomeCallable; typedef std::function&)> CreateVerifySettingAsyncHandler; + typedef Outcome CreateWhitelistOutcome; + typedef std::future CreateWhitelistOutcomeCallable; + typedef std::function&)> CreateWhitelistAsyncHandler; + typedef Outcome DeleteWhitelistOutcome; + typedef std::future DeleteWhitelistOutcomeCallable; + typedef std::function&)> DeleteWhitelistAsyncHandler; typedef Outcome DescribeAppInfoOutcome; typedef std::future DescribeAppInfoOutcomeCallable; typedef std::function&)> DescribeAppInfoAsyncHandler; @@ -197,6 +214,9 @@ namespace AlibabaCloud typedef Outcome DescribeVerifyUsageOutcome; typedef std::future DescribeVerifyUsageOutcomeCallable; typedef std::function&)> DescribeVerifyUsageAsyncHandler; + typedef Outcome DescribeWhitelistOutcome; + typedef std::future DescribeWhitelistOutcomeCallable; + typedef std::function&)> DescribeWhitelistAsyncHandler; typedef Outcome DetectFaceAttributesOutcome; typedef std::future DetectFaceAttributesOutcomeCallable; typedef std::function&)> DetectFaceAttributesAsyncHandler; @@ -265,6 +285,9 @@ namespace AlibabaCloud ContrastFaceVerifyOutcome contrastFaceVerify(const Model::ContrastFaceVerifyRequest &request)const; void contrastFaceVerifyAsync(const Model::ContrastFaceVerifyRequest& request, const ContrastFaceVerifyAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; ContrastFaceVerifyOutcomeCallable contrastFaceVerifyCallable(const Model::ContrastFaceVerifyRequest& request) const; + ContrastSmartVerifyOutcome contrastSmartVerify(const Model::ContrastSmartVerifyRequest &request)const; + void contrastSmartVerifyAsync(const Model::ContrastSmartVerifyRequest& request, const ContrastSmartVerifyAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ContrastSmartVerifyOutcomeCallable contrastSmartVerifyCallable(const Model::ContrastSmartVerifyRequest& request) const; CreateAuthKeyOutcome createAuthKey(const Model::CreateAuthKeyRequest &request)const; void createAuthKeyAsync(const Model::CreateAuthKeyRequest& request, const CreateAuthKeyAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateAuthKeyOutcomeCallable createAuthKeyCallable(const Model::CreateAuthKeyRequest& request) const; @@ -280,6 +303,12 @@ namespace AlibabaCloud CreateVerifySettingOutcome createVerifySetting(const Model::CreateVerifySettingRequest &request)const; void createVerifySettingAsync(const Model::CreateVerifySettingRequest& request, const CreateVerifySettingAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateVerifySettingOutcomeCallable createVerifySettingCallable(const Model::CreateVerifySettingRequest& request) const; + CreateWhitelistOutcome createWhitelist(const Model::CreateWhitelistRequest &request)const; + void createWhitelistAsync(const Model::CreateWhitelistRequest& request, const CreateWhitelistAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateWhitelistOutcomeCallable createWhitelistCallable(const Model::CreateWhitelistRequest& request) const; + DeleteWhitelistOutcome deleteWhitelist(const Model::DeleteWhitelistRequest &request)const; + void deleteWhitelistAsync(const Model::DeleteWhitelistRequest& request, const DeleteWhitelistAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteWhitelistOutcomeCallable deleteWhitelistCallable(const Model::DeleteWhitelistRequest& request) const; DescribeAppInfoOutcome describeAppInfo(const Model::DescribeAppInfoRequest &request)const; void describeAppInfoAsync(const Model::DescribeAppInfoRequest& request, const DescribeAppInfoAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DescribeAppInfoOutcomeCallable describeAppInfoCallable(const Model::DescribeAppInfoRequest& request) const; @@ -334,6 +363,9 @@ namespace AlibabaCloud DescribeVerifyUsageOutcome describeVerifyUsage(const Model::DescribeVerifyUsageRequest &request)const; void describeVerifyUsageAsync(const Model::DescribeVerifyUsageRequest& request, const DescribeVerifyUsageAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DescribeVerifyUsageOutcomeCallable describeVerifyUsageCallable(const Model::DescribeVerifyUsageRequest& request) const; + DescribeWhitelistOutcome describeWhitelist(const Model::DescribeWhitelistRequest &request)const; + void describeWhitelistAsync(const Model::DescribeWhitelistRequest& request, const DescribeWhitelistAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeWhitelistOutcomeCallable describeWhitelistCallable(const Model::DescribeWhitelistRequest& request) const; DetectFaceAttributesOutcome detectFaceAttributes(const Model::DetectFaceAttributesRequest &request)const; void detectFaceAttributesAsync(const Model::DetectFaceAttributesRequest& request, const DetectFaceAttributesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DetectFaceAttributesOutcomeCallable detectFaceAttributesCallable(const Model::DetectFaceAttributesRequest& request) const; diff --git a/cloudauth/include/alibabacloud/cloudauth/model/ContrastSmartVerifyRequest.h b/cloudauth/include/alibabacloud/cloudauth/model/ContrastSmartVerifyRequest.h new file mode 100644 index 000000000..c4d8984b5 --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/ContrastSmartVerifyRequest.h @@ -0,0 +1,81 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_CONTRASTSMARTVERIFYREQUEST_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_CONTRASTSMARTVERIFYREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT ContrastSmartVerifyRequest : public RpcServiceRequest + { + + public: + ContrastSmartVerifyRequest(); + ~ContrastSmartVerifyRequest(); + + std::string getFacePicFile()const; + void setFacePicFile(const std::string& facePicFile); + std::string getIp()const; + void setIp(const std::string& ip); + std::string getCertName()const; + void setCertName(const std::string& certName); + std::string getFacePicString()const; + void setFacePicString(const std::string& facePicString); + std::string getMobile()const; + void setMobile(const std::string& mobile); + std::string getUserId()const; + void setUserId(const std::string& userId); + std::string getMode()const; + void setMode(const std::string& mode); + std::string getCertNo()const; + void setCertNo(const std::string& certNo); + std::string getOuterOrderNo()const; + void setOuterOrderNo(const std::string& outerOrderNo); + std::string getFacePicUrl()const; + void setFacePicUrl(const std::string& facePicUrl); + std::string getCertType()const; + void setCertType(const std::string& certType); + long getSceneId()const; + void setSceneId(long sceneId); + + private: + std::string facePicFile_; + std::string ip_; + std::string certName_; + std::string facePicString_; + std::string mobile_; + std::string userId_; + std::string mode_; + std::string certNo_; + std::string outerOrderNo_; + std::string facePicUrl_; + std::string certType_; + long sceneId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_CONTRASTSMARTVERIFYREQUEST_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/ContrastSmartVerifyResult.h b/cloudauth/include/alibabacloud/cloudauth/model/ContrastSmartVerifyResult.h new file mode 100644 index 000000000..d0c0424bb --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/ContrastSmartVerifyResult.h @@ -0,0 +1,63 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_CONTRASTSMARTVERIFYRESULT_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_CONTRASTSMARTVERIFYRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT ContrastSmartVerifyResult : public ServiceResult + { + public: + struct ResultObject + { + std::string passed; + std::string certifyId; + std::string subCode; + std::string verifyInfo; + std::string riskInfo; + }; + + + ContrastSmartVerifyResult(); + explicit ContrastSmartVerifyResult(const std::string &payload); + ~ContrastSmartVerifyResult(); + ResultObject getResultObject()const; + std::string getMessage()const; + std::string getCode()const; + + protected: + void parse(const std::string &payload); + private: + ResultObject resultObject_; + std::string message_; + std::string code_; + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_CONTRASTSMARTVERIFYRESULT_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/CreateWhitelistRequest.h b/cloudauth/include/alibabacloud/cloudauth/model/CreateWhitelistRequest.h new file mode 100644 index 000000000..f8b764073 --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/CreateWhitelistRequest.h @@ -0,0 +1,63 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_CREATEWHITELISTREQUEST_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_CREATEWHITELISTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT CreateWhitelistRequest : public RpcServiceRequest + { + + public: + CreateWhitelistRequest(); + ~CreateWhitelistRequest(); + + std::string getValidDay()const; + void setValidDay(const std::string& validDay); + std::string getBizType()const; + void setBizType(const std::string& bizType); + std::string getIdCardNum()const; + void setIdCardNum(const std::string& idCardNum); + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + std::string getBizId()const; + void setBizId(const std::string& bizId); + std::string getLang()const; + void setLang(const std::string& lang); + + private: + std::string validDay_; + std::string bizType_; + std::string idCardNum_; + std::string sourceIp_; + std::string bizId_; + std::string lang_; + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_CREATEWHITELISTREQUEST_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/CreateWhitelistResult.h b/cloudauth/include/alibabacloud/cloudauth/model/CreateWhitelistResult.h new file mode 100644 index 000000000..ecdc3bb88 --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/CreateWhitelistResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_CREATEWHITELISTRESULT_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_CREATEWHITELISTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT CreateWhitelistResult : public ServiceResult + { + public: + + + CreateWhitelistResult(); + explicit CreateWhitelistResult(const std::string &payload); + ~CreateWhitelistResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_CREATEWHITELISTRESULT_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/DeleteWhitelistRequest.h b/cloudauth/include/alibabacloud/cloudauth/model/DeleteWhitelistRequest.h new file mode 100644 index 000000000..2c88e3651 --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/DeleteWhitelistRequest.h @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_DELETEWHITELISTREQUEST_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_DELETEWHITELISTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT DeleteWhitelistRequest : public RpcServiceRequest + { + + public: + DeleteWhitelistRequest(); + ~DeleteWhitelistRequest(); + + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + std::string getIds()const; + void setIds(const std::string& ids); + std::string getLang()const; + void setLang(const std::string& lang); + + private: + std::string sourceIp_; + std::string ids_; + std::string lang_; + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_DELETEWHITELISTREQUEST_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/DeleteWhitelistResult.h b/cloudauth/include/alibabacloud/cloudauth/model/DeleteWhitelistResult.h new file mode 100644 index 000000000..d63eab512 --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/DeleteWhitelistResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_DELETEWHITELISTRESULT_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_DELETEWHITELISTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT DeleteWhitelistResult : public ServiceResult + { + public: + + + DeleteWhitelistResult(); + explicit DeleteWhitelistResult(const std::string &payload); + ~DeleteWhitelistResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_DELETEWHITELISTRESULT_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/DescribeFaceVerifyRequest.h b/cloudauth/include/alibabacloud/cloudauth/model/DescribeFaceVerifyRequest.h index b4d22b5d2..b2cd89df0 100644 --- a/cloudauth/include/alibabacloud/cloudauth/model/DescribeFaceVerifyRequest.h +++ b/cloudauth/include/alibabacloud/cloudauth/model/DescribeFaceVerifyRequest.h @@ -35,14 +35,17 @@ namespace AlibabaCloud DescribeFaceVerifyRequest(); ~DescribeFaceVerifyRequest(); - long getSceneId()const; - void setSceneId(long sceneId); std::string getCertifyId()const; void setCertifyId(const std::string& certifyId); + std::string getPictureReturnType()const; + void setPictureReturnType(const std::string& pictureReturnType); + long getSceneId()const; + void setSceneId(long sceneId); private: - long sceneId_; std::string certifyId_; + std::string pictureReturnType_; + long sceneId_; }; } diff --git a/cloudauth/include/alibabacloud/cloudauth/model/DescribeSmartVerifyRequest.h b/cloudauth/include/alibabacloud/cloudauth/model/DescribeSmartVerifyRequest.h index 3b319f3e4..9e4d82bf4 100644 --- a/cloudauth/include/alibabacloud/cloudauth/model/DescribeSmartVerifyRequest.h +++ b/cloudauth/include/alibabacloud/cloudauth/model/DescribeSmartVerifyRequest.h @@ -35,14 +35,17 @@ namespace AlibabaCloud DescribeSmartVerifyRequest(); ~DescribeSmartVerifyRequest(); - long getSceneId()const; - void setSceneId(long sceneId); std::string getCertifyId()const; void setCertifyId(const std::string& certifyId); + std::string getPictureReturnType()const; + void setPictureReturnType(const std::string& pictureReturnType); + long getSceneId()const; + void setSceneId(long sceneId); private: - long sceneId_; std::string certifyId_; + std::string pictureReturnType_; + long sceneId_; }; } diff --git a/cloudauth/include/alibabacloud/cloudauth/model/DescribeWhitelistRequest.h b/cloudauth/include/alibabacloud/cloudauth/model/DescribeWhitelistRequest.h new file mode 100644 index 000000000..e8d82d506 --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/DescribeWhitelistRequest.h @@ -0,0 +1,75 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_DESCRIBEWHITELISTREQUEST_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_DESCRIBEWHITELISTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT DescribeWhitelistRequest : public RpcServiceRequest + { + + public: + DescribeWhitelistRequest(); + ~DescribeWhitelistRequest(); + + std::string getValidEndDate()const; + void setValidEndDate(const std::string& validEndDate); + std::string getValid()const; + void setValid(const std::string& valid); + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + int getPageSize()const; + void setPageSize(int pageSize); + std::string getLang()const; + void setLang(const std::string& lang); + int getCurrentPage()const; + void setCurrentPage(int currentPage); + std::string getBizType()const; + void setBizType(const std::string& bizType); + std::string getIdCardNum()const; + void setIdCardNum(const std::string& idCardNum); + std::string getBizId()const; + void setBizId(const std::string& bizId); + std::string getValidStartDate()const; + void setValidStartDate(const std::string& validStartDate); + + private: + std::string validEndDate_; + std::string valid_; + std::string sourceIp_; + int pageSize_; + std::string lang_; + int currentPage_; + std::string bizType_; + std::string idCardNum_; + std::string bizId_; + std::string validStartDate_; + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_DESCRIBEWHITELISTREQUEST_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/DescribeWhitelistResult.h b/cloudauth/include/alibabacloud/cloudauth/model/DescribeWhitelistResult.h new file mode 100644 index 000000000..33dfd954e --- /dev/null +++ b/cloudauth/include/alibabacloud/cloudauth/model/DescribeWhitelistResult.h @@ -0,0 +1,70 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#ifndef ALIBABACLOUD_CLOUDAUTH_MODEL_DESCRIBEWHITELISTRESULT_H_ +#define ALIBABACLOUD_CLOUDAUTH_MODEL_DESCRIBEWHITELISTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Cloudauth + { + namespace Model + { + class ALIBABACLOUD_CLOUDAUTH_EXPORT DescribeWhitelistResult : public ServiceResult + { + public: + struct Item + { + long startDate; + long uid; + long gmtCreate; + int valid; + long gmtModified; + std::string bizType; + long id; + long endDate; + std::string bizId; + std::string idCardNum; + }; + + + DescribeWhitelistResult(); + explicit DescribeWhitelistResult(const std::string &payload); + ~DescribeWhitelistResult(); + int getTotalCount()const; + int getPageSize()const; + int getCurrentPage()const; + std::vector getItems()const; + + protected: + void parse(const std::string &payload); + private: + int totalCount_; + int pageSize_; + int currentPage_; + std::vector items_; + + }; + } + } +} +#endif // !ALIBABACLOUD_CLOUDAUTH_MODEL_DESCRIBEWHITELISTRESULT_H_ \ No newline at end of file diff --git a/cloudauth/include/alibabacloud/cloudauth/model/VerifyDeviceRequest.h b/cloudauth/include/alibabacloud/cloudauth/model/VerifyDeviceRequest.h index 741cf506d..51407b5b2 100644 --- a/cloudauth/include/alibabacloud/cloudauth/model/VerifyDeviceRequest.h +++ b/cloudauth/include/alibabacloud/cloudauth/model/VerifyDeviceRequest.h @@ -41,6 +41,8 @@ namespace AlibabaCloud void setCertifyData(const std::string& certifyData); std::string getAppVersion()const; void setAppVersion(const std::string& appVersion); + std::string getDeviceToken()const; + void setDeviceToken(const std::string& deviceToken); std::string getCertifyId()const; void setCertifyId(const std::string& certifyId); @@ -48,6 +50,7 @@ namespace AlibabaCloud std::string extInfo_; std::string certifyData_; std::string appVersion_; + std::string deviceToken_; std::string certifyId_; }; diff --git a/cloudauth/src/CloudauthClient.cc b/cloudauth/src/CloudauthClient.cc index e8514d64a..7e7321666 100644 --- a/cloudauth/src/CloudauthClient.cc +++ b/cloudauth/src/CloudauthClient.cc @@ -159,6 +159,42 @@ CloudauthClient::ContrastFaceVerifyOutcomeCallable CloudauthClient::contrastFace return task->get_future(); } +CloudauthClient::ContrastSmartVerifyOutcome CloudauthClient::contrastSmartVerify(const ContrastSmartVerifyRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ContrastSmartVerifyOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ContrastSmartVerifyOutcome(ContrastSmartVerifyResult(outcome.result())); + else + return ContrastSmartVerifyOutcome(outcome.error()); +} + +void CloudauthClient::contrastSmartVerifyAsync(const ContrastSmartVerifyRequest& request, const ContrastSmartVerifyAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, contrastSmartVerify(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +CloudauthClient::ContrastSmartVerifyOutcomeCallable CloudauthClient::contrastSmartVerifyCallable(const ContrastSmartVerifyRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->contrastSmartVerify(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + CloudauthClient::CreateAuthKeyOutcome CloudauthClient::createAuthKey(const CreateAuthKeyRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -339,6 +375,78 @@ CloudauthClient::CreateVerifySettingOutcomeCallable CloudauthClient::createVerif return task->get_future(); } +CloudauthClient::CreateWhitelistOutcome CloudauthClient::createWhitelist(const CreateWhitelistRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateWhitelistOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateWhitelistOutcome(CreateWhitelistResult(outcome.result())); + else + return CreateWhitelistOutcome(outcome.error()); +} + +void CloudauthClient::createWhitelistAsync(const CreateWhitelistRequest& request, const CreateWhitelistAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createWhitelist(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +CloudauthClient::CreateWhitelistOutcomeCallable CloudauthClient::createWhitelistCallable(const CreateWhitelistRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createWhitelist(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +CloudauthClient::DeleteWhitelistOutcome CloudauthClient::deleteWhitelist(const DeleteWhitelistRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteWhitelistOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteWhitelistOutcome(DeleteWhitelistResult(outcome.result())); + else + return DeleteWhitelistOutcome(outcome.error()); +} + +void CloudauthClient::deleteWhitelistAsync(const DeleteWhitelistRequest& request, const DeleteWhitelistAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteWhitelist(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +CloudauthClient::DeleteWhitelistOutcomeCallable CloudauthClient::deleteWhitelistCallable(const DeleteWhitelistRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteWhitelist(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + CloudauthClient::DescribeAppInfoOutcome CloudauthClient::describeAppInfo(const DescribeAppInfoRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -987,6 +1095,42 @@ CloudauthClient::DescribeVerifyUsageOutcomeCallable CloudauthClient::describeVer return task->get_future(); } +CloudauthClient::DescribeWhitelistOutcome CloudauthClient::describeWhitelist(const DescribeWhitelistRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeWhitelistOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeWhitelistOutcome(DescribeWhitelistResult(outcome.result())); + else + return DescribeWhitelistOutcome(outcome.error()); +} + +void CloudauthClient::describeWhitelistAsync(const DescribeWhitelistRequest& request, const DescribeWhitelistAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeWhitelist(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +CloudauthClient::DescribeWhitelistOutcomeCallable CloudauthClient::describeWhitelistCallable(const DescribeWhitelistRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeWhitelist(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + CloudauthClient::DetectFaceAttributesOutcome CloudauthClient::detectFaceAttributes(const DetectFaceAttributesRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); diff --git a/cloudauth/src/model/ContrastSmartVerifyRequest.cc b/cloudauth/src/model/ContrastSmartVerifyRequest.cc new file mode 100644 index 000000000..352ea8d0b --- /dev/null +++ b/cloudauth/src/model/ContrastSmartVerifyRequest.cc @@ -0,0 +1,161 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include + +using AlibabaCloud::Cloudauth::Model::ContrastSmartVerifyRequest; + +ContrastSmartVerifyRequest::ContrastSmartVerifyRequest() : + RpcServiceRequest("cloudauth", "2020-06-18", "ContrastSmartVerify") +{ + setMethod(HttpRequest::Method::Post); +} + +ContrastSmartVerifyRequest::~ContrastSmartVerifyRequest() +{} + +std::string ContrastSmartVerifyRequest::getFacePicFile()const +{ + return facePicFile_; +} + +void ContrastSmartVerifyRequest::setFacePicFile(const std::string& facePicFile) +{ + facePicFile_ = facePicFile; + setBodyParameter("FacePicFile", facePicFile); +} + +std::string ContrastSmartVerifyRequest::getIp()const +{ + return ip_; +} + +void ContrastSmartVerifyRequest::setIp(const std::string& ip) +{ + ip_ = ip; + setBodyParameter("Ip", ip); +} + +std::string ContrastSmartVerifyRequest::getCertName()const +{ + return certName_; +} + +void ContrastSmartVerifyRequest::setCertName(const std::string& certName) +{ + certName_ = certName; + setBodyParameter("CertName", certName); +} + +std::string ContrastSmartVerifyRequest::getFacePicString()const +{ + return facePicString_; +} + +void ContrastSmartVerifyRequest::setFacePicString(const std::string& facePicString) +{ + facePicString_ = facePicString; + setBodyParameter("FacePicString", facePicString); +} + +std::string ContrastSmartVerifyRequest::getMobile()const +{ + return mobile_; +} + +void ContrastSmartVerifyRequest::setMobile(const std::string& mobile) +{ + mobile_ = mobile; + setBodyParameter("Mobile", mobile); +} + +std::string ContrastSmartVerifyRequest::getUserId()const +{ + return userId_; +} + +void ContrastSmartVerifyRequest::setUserId(const std::string& userId) +{ + userId_ = userId; + setBodyParameter("UserId", userId); +} + +std::string ContrastSmartVerifyRequest::getMode()const +{ + return mode_; +} + +void ContrastSmartVerifyRequest::setMode(const std::string& mode) +{ + mode_ = mode; + setBodyParameter("Mode", mode); +} + +std::string ContrastSmartVerifyRequest::getCertNo()const +{ + return certNo_; +} + +void ContrastSmartVerifyRequest::setCertNo(const std::string& certNo) +{ + certNo_ = certNo; + setBodyParameter("CertNo", certNo); +} + +std::string ContrastSmartVerifyRequest::getOuterOrderNo()const +{ + return outerOrderNo_; +} + +void ContrastSmartVerifyRequest::setOuterOrderNo(const std::string& outerOrderNo) +{ + outerOrderNo_ = outerOrderNo; + setBodyParameter("OuterOrderNo", outerOrderNo); +} + +std::string ContrastSmartVerifyRequest::getFacePicUrl()const +{ + return facePicUrl_; +} + +void ContrastSmartVerifyRequest::setFacePicUrl(const std::string& facePicUrl) +{ + facePicUrl_ = facePicUrl; + setBodyParameter("FacePicUrl", facePicUrl); +} + +std::string ContrastSmartVerifyRequest::getCertType()const +{ + return certType_; +} + +void ContrastSmartVerifyRequest::setCertType(const std::string& certType) +{ + certType_ = certType; + setBodyParameter("CertType", certType); +} + +long ContrastSmartVerifyRequest::getSceneId()const +{ + return sceneId_; +} + +void ContrastSmartVerifyRequest::setSceneId(long sceneId) +{ + sceneId_ = sceneId; + setBodyParameter("SceneId", std::to_string(sceneId)); +} + diff --git a/cloudauth/src/model/ContrastSmartVerifyResult.cc b/cloudauth/src/model/ContrastSmartVerifyResult.cc new file mode 100644 index 000000000..0d03f759a --- /dev/null +++ b/cloudauth/src/model/ContrastSmartVerifyResult.cc @@ -0,0 +1,74 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include +#include + +using namespace AlibabaCloud::Cloudauth; +using namespace AlibabaCloud::Cloudauth::Model; + +ContrastSmartVerifyResult::ContrastSmartVerifyResult() : + ServiceResult() +{} + +ContrastSmartVerifyResult::ContrastSmartVerifyResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ContrastSmartVerifyResult::~ContrastSmartVerifyResult() +{} + +void ContrastSmartVerifyResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto resultObjectNode = value["ResultObject"]; + if(!resultObjectNode["CertifyId"].isNull()) + resultObject_.certifyId = resultObjectNode["CertifyId"].asString(); + if(!resultObjectNode["Passed"].isNull()) + resultObject_.passed = resultObjectNode["Passed"].asString(); + if(!resultObjectNode["SubCode"].isNull()) + resultObject_.subCode = resultObjectNode["SubCode"].asString(); + if(!resultObjectNode["VerifyInfo"].isNull()) + resultObject_.verifyInfo = resultObjectNode["VerifyInfo"].asString(); + if(!resultObjectNode["RiskInfo"].isNull()) + resultObject_.riskInfo = resultObjectNode["RiskInfo"].asString(); + if(!value["Message"].isNull()) + message_ = value["Message"].asString(); + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + +} + +ContrastSmartVerifyResult::ResultObject ContrastSmartVerifyResult::getResultObject()const +{ + return resultObject_; +} + +std::string ContrastSmartVerifyResult::getMessage()const +{ + return message_; +} + +std::string ContrastSmartVerifyResult::getCode()const +{ + return code_; +} + diff --git a/cloudauth/src/model/CreateWhitelistRequest.cc b/cloudauth/src/model/CreateWhitelistRequest.cc new file mode 100644 index 000000000..81ddd7950 --- /dev/null +++ b/cloudauth/src/model/CreateWhitelistRequest.cc @@ -0,0 +1,95 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include + +using AlibabaCloud::Cloudauth::Model::CreateWhitelistRequest; + +CreateWhitelistRequest::CreateWhitelistRequest() : + RpcServiceRequest("cloudauth", "2019-03-07", "CreateWhitelist") +{ + setMethod(HttpRequest::Method::Post); +} + +CreateWhitelistRequest::~CreateWhitelistRequest() +{} + +std::string CreateWhitelistRequest::getValidDay()const +{ + return validDay_; +} + +void CreateWhitelistRequest::setValidDay(const std::string& validDay) +{ + validDay_ = validDay; + setParameter("ValidDay", validDay); +} + +std::string CreateWhitelistRequest::getBizType()const +{ + return bizType_; +} + +void CreateWhitelistRequest::setBizType(const std::string& bizType) +{ + bizType_ = bizType; + setParameter("BizType", bizType); +} + +std::string CreateWhitelistRequest::getIdCardNum()const +{ + return idCardNum_; +} + +void CreateWhitelistRequest::setIdCardNum(const std::string& idCardNum) +{ + idCardNum_ = idCardNum; + setParameter("IdCardNum", idCardNum); +} + +std::string CreateWhitelistRequest::getSourceIp()const +{ + return sourceIp_; +} + +void CreateWhitelistRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +std::string CreateWhitelistRequest::getBizId()const +{ + return bizId_; +} + +void CreateWhitelistRequest::setBizId(const std::string& bizId) +{ + bizId_ = bizId; + setParameter("BizId", bizId); +} + +std::string CreateWhitelistRequest::getLang()const +{ + return lang_; +} + +void CreateWhitelistRequest::setLang(const std::string& lang) +{ + lang_ = lang; + setParameter("Lang", lang); +} + diff --git a/cloudauth/src/model/CreateWhitelistResult.cc b/cloudauth/src/model/CreateWhitelistResult.cc new file mode 100644 index 000000000..41f84f044 --- /dev/null +++ b/cloudauth/src/model/CreateWhitelistResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include +#include + +using namespace AlibabaCloud::Cloudauth; +using namespace AlibabaCloud::Cloudauth::Model; + +CreateWhitelistResult::CreateWhitelistResult() : + ServiceResult() +{} + +CreateWhitelistResult::CreateWhitelistResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateWhitelistResult::~CreateWhitelistResult() +{} + +void CreateWhitelistResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/cloudauth/src/model/DeleteWhitelistRequest.cc b/cloudauth/src/model/DeleteWhitelistRequest.cc new file mode 100644 index 000000000..dd55ac56f --- /dev/null +++ b/cloudauth/src/model/DeleteWhitelistRequest.cc @@ -0,0 +1,62 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include + +using AlibabaCloud::Cloudauth::Model::DeleteWhitelistRequest; + +DeleteWhitelistRequest::DeleteWhitelistRequest() : + RpcServiceRequest("cloudauth", "2019-03-07", "DeleteWhitelist") +{ + setMethod(HttpRequest::Method::Post); +} + +DeleteWhitelistRequest::~DeleteWhitelistRequest() +{} + +std::string DeleteWhitelistRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DeleteWhitelistRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +std::string DeleteWhitelistRequest::getIds()const +{ + return ids_; +} + +void DeleteWhitelistRequest::setIds(const std::string& ids) +{ + ids_ = ids; + setParameter("Ids", ids); +} + +std::string DeleteWhitelistRequest::getLang()const +{ + return lang_; +} + +void DeleteWhitelistRequest::setLang(const std::string& lang) +{ + lang_ = lang; + setParameter("Lang", lang); +} + diff --git a/cloudauth/src/model/DeleteWhitelistResult.cc b/cloudauth/src/model/DeleteWhitelistResult.cc new file mode 100644 index 000000000..2c88148ed --- /dev/null +++ b/cloudauth/src/model/DeleteWhitelistResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include +#include + +using namespace AlibabaCloud::Cloudauth; +using namespace AlibabaCloud::Cloudauth::Model; + +DeleteWhitelistResult::DeleteWhitelistResult() : + ServiceResult() +{} + +DeleteWhitelistResult::DeleteWhitelistResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteWhitelistResult::~DeleteWhitelistResult() +{} + +void DeleteWhitelistResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/cloudauth/src/model/DescribeFaceVerifyRequest.cc b/cloudauth/src/model/DescribeFaceVerifyRequest.cc index 3f219c521..ef2ab4e95 100644 --- a/cloudauth/src/model/DescribeFaceVerifyRequest.cc +++ b/cloudauth/src/model/DescribeFaceVerifyRequest.cc @@ -27,17 +27,6 @@ DescribeFaceVerifyRequest::DescribeFaceVerifyRequest() : DescribeFaceVerifyRequest::~DescribeFaceVerifyRequest() {} -long DescribeFaceVerifyRequest::getSceneId()const -{ - return sceneId_; -} - -void DescribeFaceVerifyRequest::setSceneId(long sceneId) -{ - sceneId_ = sceneId; - setParameter("SceneId", std::to_string(sceneId)); -} - std::string DescribeFaceVerifyRequest::getCertifyId()const { return certifyId_; @@ -49,3 +38,25 @@ void DescribeFaceVerifyRequest::setCertifyId(const std::string& certifyId) setParameter("CertifyId", certifyId); } +std::string DescribeFaceVerifyRequest::getPictureReturnType()const +{ + return pictureReturnType_; +} + +void DescribeFaceVerifyRequest::setPictureReturnType(const std::string& pictureReturnType) +{ + pictureReturnType_ = pictureReturnType; + setParameter("PictureReturnType", pictureReturnType); +} + +long DescribeFaceVerifyRequest::getSceneId()const +{ + return sceneId_; +} + +void DescribeFaceVerifyRequest::setSceneId(long sceneId) +{ + sceneId_ = sceneId; + setParameter("SceneId", std::to_string(sceneId)); +} + diff --git a/cloudauth/src/model/DescribeSmartVerifyRequest.cc b/cloudauth/src/model/DescribeSmartVerifyRequest.cc index 9102ce451..8e41911d1 100644 --- a/cloudauth/src/model/DescribeSmartVerifyRequest.cc +++ b/cloudauth/src/model/DescribeSmartVerifyRequest.cc @@ -27,17 +27,6 @@ DescribeSmartVerifyRequest::DescribeSmartVerifyRequest() : DescribeSmartVerifyRequest::~DescribeSmartVerifyRequest() {} -long DescribeSmartVerifyRequest::getSceneId()const -{ - return sceneId_; -} - -void DescribeSmartVerifyRequest::setSceneId(long sceneId) -{ - sceneId_ = sceneId; - setBodyParameter("SceneId", std::to_string(sceneId)); -} - std::string DescribeSmartVerifyRequest::getCertifyId()const { return certifyId_; @@ -49,3 +38,25 @@ void DescribeSmartVerifyRequest::setCertifyId(const std::string& certifyId) setBodyParameter("CertifyId", certifyId); } +std::string DescribeSmartVerifyRequest::getPictureReturnType()const +{ + return pictureReturnType_; +} + +void DescribeSmartVerifyRequest::setPictureReturnType(const std::string& pictureReturnType) +{ + pictureReturnType_ = pictureReturnType; + setBodyParameter("PictureReturnType", pictureReturnType); +} + +long DescribeSmartVerifyRequest::getSceneId()const +{ + return sceneId_; +} + +void DescribeSmartVerifyRequest::setSceneId(long sceneId) +{ + sceneId_ = sceneId; + setBodyParameter("SceneId", std::to_string(sceneId)); +} + diff --git a/cloudauth/src/model/DescribeWhitelistRequest.cc b/cloudauth/src/model/DescribeWhitelistRequest.cc new file mode 100644 index 000000000..402931d0d --- /dev/null +++ b/cloudauth/src/model/DescribeWhitelistRequest.cc @@ -0,0 +1,139 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include + +using AlibabaCloud::Cloudauth::Model::DescribeWhitelistRequest; + +DescribeWhitelistRequest::DescribeWhitelistRequest() : + RpcServiceRequest("cloudauth", "2019-03-07", "DescribeWhitelist") +{ + setMethod(HttpRequest::Method::Post); +} + +DescribeWhitelistRequest::~DescribeWhitelistRequest() +{} + +std::string DescribeWhitelistRequest::getValidEndDate()const +{ + return validEndDate_; +} + +void DescribeWhitelistRequest::setValidEndDate(const std::string& validEndDate) +{ + validEndDate_ = validEndDate; + setParameter("ValidEndDate", validEndDate); +} + +std::string DescribeWhitelistRequest::getValid()const +{ + return valid_; +} + +void DescribeWhitelistRequest::setValid(const std::string& valid) +{ + valid_ = valid; + setParameter("Valid", valid); +} + +std::string DescribeWhitelistRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeWhitelistRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +int DescribeWhitelistRequest::getPageSize()const +{ + return pageSize_; +} + +void DescribeWhitelistRequest::setPageSize(int pageSize) +{ + pageSize_ = pageSize; + setParameter("PageSize", std::to_string(pageSize)); +} + +std::string DescribeWhitelistRequest::getLang()const +{ + return lang_; +} + +void DescribeWhitelistRequest::setLang(const std::string& lang) +{ + lang_ = lang; + setParameter("Lang", lang); +} + +int DescribeWhitelistRequest::getCurrentPage()const +{ + return currentPage_; +} + +void DescribeWhitelistRequest::setCurrentPage(int currentPage) +{ + currentPage_ = currentPage; + setParameter("CurrentPage", std::to_string(currentPage)); +} + +std::string DescribeWhitelistRequest::getBizType()const +{ + return bizType_; +} + +void DescribeWhitelistRequest::setBizType(const std::string& bizType) +{ + bizType_ = bizType; + setParameter("BizType", bizType); +} + +std::string DescribeWhitelistRequest::getIdCardNum()const +{ + return idCardNum_; +} + +void DescribeWhitelistRequest::setIdCardNum(const std::string& idCardNum) +{ + idCardNum_ = idCardNum; + setParameter("IdCardNum", idCardNum); +} + +std::string DescribeWhitelistRequest::getBizId()const +{ + return bizId_; +} + +void DescribeWhitelistRequest::setBizId(const std::string& bizId) +{ + bizId_ = bizId; + setParameter("BizId", bizId); +} + +std::string DescribeWhitelistRequest::getValidStartDate()const +{ + return validStartDate_; +} + +void DescribeWhitelistRequest::setValidStartDate(const std::string& validStartDate) +{ + validStartDate_ = validStartDate; + setParameter("ValidStartDate", validStartDate); +} + diff --git a/cloudauth/src/model/DescribeWhitelistResult.cc b/cloudauth/src/model/DescribeWhitelistResult.cc new file mode 100644 index 000000000..481736ef8 --- /dev/null +++ b/cloudauth/src/model/DescribeWhitelistResult.cc @@ -0,0 +1,96 @@ +/* + * Copyright 2009-2017 Alibaba Cloud 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. + */ + +#include +#include + +using namespace AlibabaCloud::Cloudauth; +using namespace AlibabaCloud::Cloudauth::Model; + +DescribeWhitelistResult::DescribeWhitelistResult() : + ServiceResult() +{} + +DescribeWhitelistResult::DescribeWhitelistResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeWhitelistResult::~DescribeWhitelistResult() +{} + +void DescribeWhitelistResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allItemsNode = value["Items"]["Item"]; + for (auto valueItemsItem : allItemsNode) + { + Item itemsObject; + if(!valueItemsItem["Id"].isNull()) + itemsObject.id = std::stol(valueItemsItem["Id"].asString()); + if(!valueItemsItem["Uid"].isNull()) + itemsObject.uid = std::stol(valueItemsItem["Uid"].asString()); + if(!valueItemsItem["BizType"].isNull()) + itemsObject.bizType = valueItemsItem["BizType"].asString(); + if(!valueItemsItem["StartDate"].isNull()) + itemsObject.startDate = std::stol(valueItemsItem["StartDate"].asString()); + if(!valueItemsItem["EndDate"].isNull()) + itemsObject.endDate = std::stol(valueItemsItem["EndDate"].asString()); + if(!valueItemsItem["IdCardNum"].isNull()) + itemsObject.idCardNum = valueItemsItem["IdCardNum"].asString(); + if(!valueItemsItem["BizId"].isNull()) + itemsObject.bizId = valueItemsItem["BizId"].asString(); + if(!valueItemsItem["Valid"].isNull()) + itemsObject.valid = std::stoi(valueItemsItem["Valid"].asString()); + if(!valueItemsItem["GmtCreate"].isNull()) + itemsObject.gmtCreate = std::stol(valueItemsItem["GmtCreate"].asString()); + if(!valueItemsItem["GmtModified"].isNull()) + itemsObject.gmtModified = std::stol(valueItemsItem["GmtModified"].asString()); + items_.push_back(itemsObject); + } + if(!value["TotalCount"].isNull()) + totalCount_ = std::stoi(value["TotalCount"].asString()); + if(!value["CurrentPage"].isNull()) + currentPage_ = std::stoi(value["CurrentPage"].asString()); + if(!value["PageSize"].isNull()) + pageSize_ = std::stoi(value["PageSize"].asString()); + +} + +int DescribeWhitelistResult::getTotalCount()const +{ + return totalCount_; +} + +int DescribeWhitelistResult::getPageSize()const +{ + return pageSize_; +} + +int DescribeWhitelistResult::getCurrentPage()const +{ + return currentPage_; +} + +std::vector DescribeWhitelistResult::getItems()const +{ + return items_; +} + diff --git a/cloudauth/src/model/VerifyDeviceRequest.cc b/cloudauth/src/model/VerifyDeviceRequest.cc index cfedbb67b..24a908803 100644 --- a/cloudauth/src/model/VerifyDeviceRequest.cc +++ b/cloudauth/src/model/VerifyDeviceRequest.cc @@ -60,6 +60,17 @@ void VerifyDeviceRequest::setAppVersion(const std::string& appVersion) setParameter("AppVersion", appVersion); } +std::string VerifyDeviceRequest::getDeviceToken()const +{ + return deviceToken_; +} + +void VerifyDeviceRequest::setDeviceToken(const std::string& deviceToken) +{ + deviceToken_ = deviceToken; + setBodyParameter("DeviceToken", deviceToken); +} + std::string VerifyDeviceRequest::getCertifyId()const { return certifyId_;