百度智能云卡证文字识别API文档 - 出生医学证明识别
文档简介:
接口描述:
支持对出生医学证明的23个关键字段进行结构化识别,包括新生儿姓名、性别、出生时间、父亲姓名、母亲姓名、出生证编号等。
在线调试:
您可以在 示例代码中心 中调试该接口,可进行签名验证、查看在线调用的请求内容和返回结果、示例代码的自动生成。
【百度智能云】通用场景文字识别
【百度智能云】卡证文字识别
【百度智能云】财务票据文字识别
【百度智能云】医疗票据文字识别
【百度智能云】交通场景文字识别
【百度智能云】教育场景文字识别
【百度智能云】其他场景文字识别
【百度智能云】iOCR自定义模板文字识别
【百度智能云】通用文字识别(标准版)
【百度智能云】通用文字识别(高精度版)
【百度智能云】网络图片文字识别
【百度智能云】手写文字识别
【百度智能云】门脸文字识别
接口描述
支持对出生医学证明的23个关键字段进行结构化识别,包括新生儿姓名、性别、出生时间、父亲姓名、母亲姓名、出生证编号等。
在线调试
您可以在 示例代码中心 中调试该接口,可进行签名验证、查看在线调用的请求内容和返回结果、示例代码的自动生成。
请求说明
请求示例
HTTP 方法:POST
请求URL: https://aip.baidubce.com/rest/2.0/ocr/v1/birth_certificate
URL参数:
参数 | 值 |
---|---|
access_token | 通过API Key和Secret Key获取的access_token,参考“Access Token获取” |
Header如下:
参数 | 值 |
---|---|
Content-Type | application/x-www-form-urlencoded |
Body中放置请求参数,参数详情如下:
请求参数
参数 | 是否必选 | 类型 | 可选值范围 | 说明 |
---|---|---|---|---|
image | 和url二选一 | string | - | 图像数据,base64编码后进行urlencode,要求base64编码和urlencode后大小不超过4M,最短边至少15px,最长边最大4096px,支持jpg/jpeg/png/bmp格式 |
url | 和image二选一 | string | - |
图片完整URL,URL长度不超过1024字节,URL对应的图片base64编码后大小不超过4M,最短边至少15px,最长边最大4096px,支持jpg/jpeg/png/bmp格式,当image字段存在时url字段失效 请注意关闭URL防盗链 |
请求代码示例
提示一:使用示例代码前,请记得替换其中的示例Token、图片地址或Base64信息。
提示二:部分语言依赖的类或库,请在代码注释中查看下载地址。
curl -i -k 'https://aip.baidubce.com/rest/2.0/ocr/v1/birth_certificate?access_token=
【调用鉴权接口获取的token】' --data 'image=【图片Base64编码,需UrlEncode】
' -H 'Content-Type:application/x-www-form-urlencoded'
返回说明
返回参数
字段 | 是否必选 | 类型 | 说明 |
---|---|---|---|
log_id | 是 | uint64 | 唯一的log id,用于问题定位 |
direction | int32 | 是 |
图像方向。 - - 1:未定义; - 0:正向; - 1:逆时针90度; - 2:逆时针180度; - 3:逆时针270度 |
words_result_num | 是 | uint32 | 识别结果数,表示words_result的元素个数 |
words_result | 是 | object | 识别结果数组 |
+ BabyBirthday | 是 | string | 出生时间 |
+ BirthProvince | 是 | string | 出生地点_省 |
+ BirthCity | 是 | string | 出生地点_市 |
+ BirthCounty | 是 | string | 出生地点_县(区) |
+ BirthWeight | 是 | string | 出生体重 |
+ BirthLength | 是 | string | 出生身长 |
+ GestationalAge | 是 | string | 出生孕周 |
+ BabyName | 是 | string | 姓名 |
+ BabySex | 是 | string | 性别 |
+ Code | 是 | string | 出生证编号 |
+ Hospital | 是 | string | 出生医院/医疗机构名称 |
+ FatherName | 是 | string | 父亲姓名 |
+ FatherID | 是 | string | 父亲身份证号 |
+ FatherNationality | 是 | string | 父亲国籍 |
+ FatherEthnic | 是 | string | 父亲民族 |
+ FatherAddress | 是 | string | 父亲住址 |
+ FatherAge | 是 | string | 父亲年龄 |
+ MotherName | 是 | string | 母亲姓名 |
+ MotherID | 是 | string | 母亲身份证号 |
+ MotherNationality | 是 | string | 母亲国籍 |
+ MotherEthnic | 是 | string | 母亲民族 |
+ MotherAddress | 是 | string | 母亲地址 |
+ MotherAge | 是 | string | 母亲年龄 |
返回示例
{ "words_result": { "BirthProvince": { "words": "山东" }, "BirthWeight": { "words": "3450克" },
"MotherNationality": { "words": "中国" }, "FatherAddress": { "words": "山东省青岛市" },
"MotherEthnic": { "words": "汉族" }, "MotherAddress": { "words": "山东省青岛市" },
"Code": { "words": "U370073333" }, "BabySex": { "words": "女" }, "BirthCounty":
{ "words": "黄岛区" }, "BabyBirthday": { "words": "2020年06月19日17时00分" },
"BabyName": { "words": "安琪" }, "FatherAge": { "words": "30岁" }, "FatherEthnic":
{ "words": "汉族" }, "MotherName": { "words": "田田" }, "MotherID":
{ "words": "370284199509086021" }, "BirthLength": { "words": "50厘米" },
"GestationalAge": { "words": "41+1周" }, "BirthCity": { "words": "青岛" },
"MotherAge": { "words": "25岁" }, "Hospital": { "words": "青岛市黄岛区医院" },
"FatherNationality": { "words": "中国" }, "FatherID": { "words": "370284199207126034" },
"FatherName": { "words": "王军" } }, "log_id": 1420219665606852609,
"words_result_num": 23, "direction": 0 }