当前位置: 首页 > wzjs >正文

企业数字化平台seo优化技术培训

企业数字化平台,seo优化技术培训,电脑编程,站长之家网站OCR身份证识别 官网地址&#xff1a;https://cloud.tencent.com/document/product/866/33524 身份信息认证&#xff08;二要素核验&#xff09; 官网地址&#xff1a;https://cloud.tencent.com/document/product/1007/33188 代码实现 引入依赖 <dependency><…

OCR身份证识别

官网地址:https://cloud.tencent.com/document/product/866/33524
在这里插入图片描述

身份信息认证(二要素核验)

官网地址:https://cloud.tencent.com/document/product/1007/33188
在这里插入图片描述

代码实现

引入依赖

<dependency><groupId>com.tencentcloudapi</groupId><artifactId>tencentcloud-sdk-java</artifactId><version>4.0.11</version>
</dependency>

工具类

package com.qiangesoft.ocr.utils;import com.tencentcloudapi.common.Credential;
import com.tencentcloudapi.common.exception.TencentCloudSDKException;
import com.tencentcloudapi.common.profile.ClientProfile;
import com.tencentcloudapi.common.profile.HttpProfile;
import com.tencentcloudapi.faceid.v20180301.FaceidClient;
import com.tencentcloudapi.faceid.v20180301.models.IdCardVerificationRequest;
import com.tencentcloudapi.faceid.v20180301.models.IdCardVerificationResponse;
import com.tencentcloudapi.ocr.v20181119.OcrClient;
import com.tencentcloudapi.ocr.v20181119.models.IDCardOCRRequest;
import com.tencentcloudapi.ocr.v20181119.models.IDCardOCRResponse;/*** 腾讯云ocr识别** @author qiangesoft* @date 2025-03-27*/
public class TencentCloudOcr {private static final String SECRET_ID = "xxx";private static final String SECRET_KEY = "xxx ";private static final String REGION_NAME = "ap-shanghai";/*** 调用OCR识别身份证信息* https://cloud.tencent.com/document/product/866/33524** @param imgUrl* @return* @throws TencentCloudSDKException*/public static IDCardOCRResponse idCardOCR(String imgUrl) throws TencentCloudSDKException {Credential cred = new Credential(SECRET_ID, SECRET_KEY);HttpProfile httpProfile = new HttpProfile();httpProfile.setEndpoint("ocr.tencentcloudapi.com");ClientProfile clientProfile = new ClientProfile();clientProfile.setHttpProfile(httpProfile);OcrClient client = new OcrClient(cred, REGION_NAME, clientProfile);IDCardOCRRequest req = new IDCardOCRRequest();req.setImageUrl(imgUrl);req.setCardSide("FRONT");
//        req.setCardSide("BACK");return client.IDCardOCR(req);}/*** 调用身份信息核验API* https://cloud.tencent.com/document/product/1007/33188** @param name* @param idCard* @return* @throws TencentCloudSDKException*/public static IdCardVerificationResponse idCardVerification(String name, String idCard) throws TencentCloudSDKException {Credential cred = new Credential(SECRET_ID, SECRET_KEY);HttpProfile httpProfile = new HttpProfile();httpProfile.setEndpoint("faceid.tencentcloudapi.com");ClientProfile clientProfile = new ClientProfile();clientProfile.setHttpProfile(httpProfile);FaceidClient client = new FaceidClient(cred, REGION_NAME, clientProfile);IdCardVerificationRequest req = new IdCardVerificationRequest();req.setName(name);req.setIdCard(idCard);return client.IdCardVerification(req);}public static void main(String[] args) throws TencentCloudSDKException {IDCardOCRResponse idCardOCRResponse = idCardOCR("https://www.fsf.com");IdCardVerificationResponse idCardVerificationResponse = idCardVerification("xxx", "22222");}}
http://www.dtcms.com/wzjs/14085.html

相关文章:

  • 做网站包括什么软件加强服务保障 满足群众急需需求
  • 网站建设的文章google官方下载
  • 教育课程网站建设磁力猫torrent kitty
  • 网站教人做核能灯西安百度
  • 网站优化策划书搜索排名
  • 南京网站设计案例营销的概念是什么
  • 单位网站建设与管理我国的网络营销公司
  • 网站制作目的百度竞价一个月5000够吗
  • 上海做网站优化公司邢台网站公司
  • 滕州 网站 建设最新的网络营销方式
  • 灵山网站建设企业网络营销策划书
  • 福州网站定制设计孔宇seo
  • html网站制作答辩问题cps推广平台有哪些
  • wordpress手机端网站模板下载上海专业seo排名优化
  • 学做招投标的网站查询网入口
  • 专业邯郸做网站性能优化工具
  • 做网站图片链接到天猫网站建设的六个步骤
  • 网站建设佰金手指科杰三十湖南百度seo排名点击软件
  • 石家庄微信网站建设seo搜索引擎优化是什么
  • 企业做产品网站费用大概是多少百度关键词优化曝光行者seo
  • 网站建设管理中se是什么意思网站收录平台
  • 做系统用什么网站好相亲网站排名前十名
  • 免费成品网站模板下载外链link
  • 香港注册公司流程及费用seo咨询顾问
  • 加强机关门户网站建设深圳市龙华区
  • 河南省建设监理协会网站seo关键词优化软件手机
  • 网站设计布局的重要性企业网站模板
  • 做网站开发教程品牌推广方式
  • 哈尔滨最新搜索引擎优化行业
  • 网站策划哪里找搜索大全引擎入口网站