From 595df5dac0a782bfdadab766b4dd62d326b0a383 Mon Sep 17 00:00:00 2001
From: 小飞侠 <8277136+liaoxujun@user.noreply.gitee.com>
Date: 星期二, 21 十月 2025 14:53:04 +0800
Subject: [PATCH] 增加川印设备维修回写
---
cylsg/EzTencentCloud/TencentCloudService.cs | 41 ++++++++++++++++++++++++++++++++++++-----
1 files changed, 36 insertions(+), 5 deletions(-)
diff --git a/cylsg/EzTencentCloud/TencentCloudService.cs b/cylsg/EzTencentCloud/TencentCloudService.cs
index aa364a0..a276174 100644
--- a/cylsg/EzTencentCloud/TencentCloudService.cs
+++ b/cylsg/EzTencentCloud/TencentCloudService.cs
@@ -63,7 +63,7 @@
httpProfile.Endpoint = ("ocr.tencentcloudapi.com");
clientProfile.HttpProfile = httpProfile;
- var _ocrClient = new OcrClient(cred, "ap-chengdu", clientProfile);
+ var _ocrClient = new OcrClient(cred, "ap-shanghai", clientProfile);
IDCardOCRRequest req = new IDCardOCRRequest();
if (isFRONT)
@@ -138,7 +138,7 @@
httpProfile.Endpoint = ("ocr.tencentcloudapi.com");
clientProfile.HttpProfile = httpProfile;
- var _ocrClient = new OcrClient(cred, "ap-chengdu", clientProfile);
+ var _ocrClient = new OcrClient(cred, "ap-shanghai", clientProfile);
var ret = _ocrClient.BizLicenseOCRSync(new BizLicenseOCRRequest()
{
@@ -175,7 +175,7 @@
httpProfile.Endpoint = ("iai.tencentcloudapi.com");
clientProfile.HttpProfile = httpProfile;
- var iaiClient = new IaiClient(cred, "ap-chengdu", clientProfile);
+ var iaiClient = new IaiClient(cred, "ap-shanghai", clientProfile);
try
{
var retinfo = iaiClient.GetGroupInfoSync(new GetGroupInfoRequest
@@ -220,7 +220,7 @@
httpProfile.Endpoint = ("iai.tencentcloudapi.com");
clientProfile.HttpProfile = httpProfile;
- var iaiClient = new IaiClient(cred, "ap-chengdu", clientProfile);
+ var iaiClient = new IaiClient(cred, "ap-shanghai", clientProfile);
var ret= iaiClient.CreatePerson(new TencentCloud.Iai.V20200303.Models.CreatePersonRequest
{
GroupId = App.Configuration["IAIGroupSet:ID"],
@@ -256,7 +256,7 @@
httpProfile.Endpoint = ("iai.tencentcloudapi.com");
clientProfile.HttpProfile = httpProfile;
- var iaiClient = new IaiClient(cred, "ap-chengdu", clientProfile);
+ var iaiClient = new IaiClient(cred, "ap-shanghai", clientProfile);
var ret = iaiClient.CreateFace( new TencentCloud.Iai.V20200303.Models.CreateFaceRequest
{
@@ -275,6 +275,37 @@
}
+
+
+ public VerifyFaceResponse VerifyFace(string img64, string PersonNameId)
+ {
+ Credential cred = new Credential
+ {
+ SecretId = App.Configuration["TencentCloud:SecretId"] ?? "AKIDIPFp9CyThfMmvoQlpeCl34pKYVBahY9T",
+ SecretKey = App.Configuration["TencentCloud:SecretKey"] ?? "4rNcaHhrkMhmb9QQ9bmgKipfFZcOt86n"
+ };
+
+ ClientProfile clientProfile = new ClientProfile();
+ HttpProfile httpProfile = new HttpProfile();
+
+
+ httpProfile.Endpoint = ("iai.tencentcloudapi.com");
+ clientProfile.HttpProfile = httpProfile;
+ var iaiClient = new IaiClient(cred, "ap-shanghai", clientProfile);
+ var ret = iaiClient.VerifyFaceSync(new TencentCloud.Iai.V20200303.Models.VerifyFaceRequest
+ {
+
+ PersonId = PersonNameId,
+ Image= img64
+
+
+
+ });
+ return ret;
+
+
+
+ }
#endregion
}
--
Gitblit v1.9.1