我的--实名认证--修改--修改百度智能云身份证识别的接口

This commit is contained in:
haotian 2025-02-17 10:16:21 +08:00
parent d418aa9e8e
commit 11e3efb7ed
2 changed files with 4 additions and 4 deletions

View File

@ -47,7 +47,7 @@ public class OcrIdCardBAI {
// 注意这里仅为了简化编码每一次请求都去获取access_token线上环境access_token有过期时间 客户端可自行缓存过期后重新获取
// 使用之前要通过GetToken方法获取token token默认30天有效
String accessToken = "24.d4cb1b0dfb102b84da76038ec87a7265.2592000.1732067411.282335-115883169";
String accessToken = "24.001b9417059a9d3c9643d26df82f6e4d.2592000.1742109506.282335-115883169";
String result = HttpUtil.post(url, accessToken, param);
// System.out.println(result);

View File

@ -6,9 +6,9 @@ public class TestBaidu {
public static void main(String[] args) throws Exception
{
// OcrIdCardBAI ocrIdCardBAI = new OcrIdCardBAI();
// String result = ocrIdCardBAI.idcard("D:/ruoyi/uploadPath/id_card/18321826195_card_front.jpg", "front", "true", "true", "true", "false");
// System.out.println(result);
OcrIdCardBAI ocrIdCardBAI = new OcrIdCardBAI();
String result = ocrIdCardBAI.idcard("D:/ruoyi/uploadPath/id_card/18321826195_card_front.jpg", "front", "true", "true", "true", "false");
System.out.println(result);
long currentTimeMillis = System.currentTimeMillis();
// 利用毫秒值构造Date对象
Date calculationTime = new Date(currentTimeMillis-1000000000);