RecognizeTollInvoice - 过路过桥费发票识别

支持包括发票代码、发票号码、金额、日期、车型、出口、入口等关键字段结构化识别输出。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息

下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:

  • 操作:是指具体的权限点。
  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:
    • 对于必选的资源类型,用背景高亮的方式表示。
    • 对于不支持资源级授权的操作,用全部资源表示。
  • 条件关键字:是指云产品自身定义的条件关键字。
  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
操作访问级别资源类型条件关键字关联操作
ocr:RecognizeTollInvoiceget
  • 全部资源
    *

请求参数

名称类型必填描述示例值
Urlstring

图片链接(长度不超 2048 字节,不支持 base64)

https://img.alicdn.com/imgextra/i3/O1CN01uUHo411DCwPsBWDMJ_!!6000000000181-0-tps-199-254.jpg
bodybyte

图片二进制字节流,最大 10MB

图片二进制

支持的图片格式

  • PNG、JPG、JPEG、BMP、GIF、TIFF、WebP

返回参数

名称类型描述示例值
object

Schema of Response

RequestIdstring

请求唯一 ID

43A29C77-405E-4CC0-BC55-EE694AD00655
Datastring

返回数据

{"angle":0,"data":{"title":"苏宁用打发","formType":"发票联","invoiceCode":"132001681414","invoiceNumber":"53184969","date":"","time":"","vehicleType":"客1","entranceName":"江","exitName":"","totalAmount":"0.00"},"ftype":0,"height":254,"orgHeight":254,"orgWidth":199,"prism_keyValueInfo":[{"key":"title","keyProb":98,"value":"苏宁用打发","valuePos":[{"x":174,"y":20},{"x":174,"y":35},{"x":24,"y":34},{"x":24,"y":19}],"valueProb":98},{"key":"formType","keyProb":89,"value":"发票联","valuePos":[{"x":50,"y":41},{"x":131,"y":37},{"x":131,"y":52},{"x":50,"y":56}],"valueProb":89},{"key":"invoiceCode","keyProb":100,"value":"132001681414","valuePos":[{"x":150,"y":94},{"x":150,"y":105},{"x":63,"y":105},{"x":63,"y":94}],"valueProb":100},{"key":"invoiceNumber","keyProb":100,"value":"53184969","valuePos":[{"x":119,"y":109},{"x":119,"y":120},{"x":63,"y":120},{"x":63,"y":109}],"valueProb":100},{"key":"date","keyProb":100,"value":"","valueProb":100},{"key":"time","keyProb":100,"value":"","valueProb":100},{"key":"vehicleType","keyProb":95,"value":"客1","valuePos":[{"x":40,"y":180},{"x":40,"y":192},{"x":28,"y":192},{"x":28,"y":180}],"valueProb":95},{"key":"entranceName","keyProb":98,"value":"江","valuePos":[{"x":96,"y":128},{"x":96,"y":140},{"x":39,"y":140},{"x":39,"y":128}],"valueProb":98},{"key":"exitName","keyProb":100,"value":"","valueProb":100},{"key":"totalAmount","keyProb":85,"value":"0.00","valuePos":[{"x":70,"y":181},{"x":70,"y":190},{"x":55,"y":190},{"x":55,"y":181}],"valueProb":85}],"sliceRect":{"x0":0,"y0":2,"x1":196,"y1":1,"x2":198,"y2":251,"x3":0,"y3":252},"width":199}
Codestring

错误码

noPermission
Messagestring

错误提示

You are not authorized to perform this operation.

中英文映射字段

title           标题  
formType           联次  
invoiceCode           发票代码  
invoiceNumber           发票号码 
date           日期  
time           时间  
vehicleType           车型
entranceName           入口  
exitName           出口 
totalAmount          总金额 
ftype           是否是复印件(1:是,0:否)

示例

正常返回示例

JSON格式

{
  "RequestId": "43A29C77-405E-4CC0-BC55-EE694AD00655",
  "Data": "{\"angle\":0,\"data\":{\"title\":\"苏宁用打发\",\"formType\":\"发票联\",\"invoiceCode\":\"132001681414\",\"invoiceNumber\":\"53184969\",\"date\":\"\",\"time\":\"\",\"vehicleType\":\"客1\",\"entranceName\":\"江\",\"exitName\":\"\",\"totalAmount\":\"0.00\"},\"ftype\":0,\"height\":254,\"orgHeight\":254,\"orgWidth\":199,\"prism_keyValueInfo\":[{\"key\":\"title\",\"keyProb\":98,\"value\":\"苏宁用打发\",\"valuePos\":[{\"x\":174,\"y\":20},{\"x\":174,\"y\":35},{\"x\":24,\"y\":34},{\"x\":24,\"y\":19}],\"valueProb\":98},{\"key\":\"formType\",\"keyProb\":89,\"value\":\"发票联\",\"valuePos\":[{\"x\":50,\"y\":41},{\"x\":131,\"y\":37},{\"x\":131,\"y\":52},{\"x\":50,\"y\":56}],\"valueProb\":89},{\"key\":\"invoiceCode\",\"keyProb\":100,\"value\":\"132001681414\",\"valuePos\":[{\"x\":150,\"y\":94},{\"x\":150,\"y\":105},{\"x\":63,\"y\":105},{\"x\":63,\"y\":94}],\"valueProb\":100},{\"key\":\"invoiceNumber\",\"keyProb\":100,\"value\":\"53184969\",\"valuePos\":[{\"x\":119,\"y\":109},{\"x\":119,\"y\":120},{\"x\":63,\"y\":120},{\"x\":63,\"y\":109}],\"valueProb\":100},{\"key\":\"date\",\"keyProb\":100,\"value\":\"\",\"valueProb\":100},{\"key\":\"time\",\"keyProb\":100,\"value\":\"\",\"valueProb\":100},{\"key\":\"vehicleType\",\"keyProb\":95,\"value\":\"客1\",\"valuePos\":[{\"x\":40,\"y\":180},{\"x\":40,\"y\":192},{\"x\":28,\"y\":192},{\"x\":28,\"y\":180}],\"valueProb\":95},{\"key\":\"entranceName\",\"keyProb\":98,\"value\":\"江\",\"valuePos\":[{\"x\":96,\"y\":128},{\"x\":96,\"y\":140},{\"x\":39,\"y\":140},{\"x\":39,\"y\":128}],\"valueProb\":98},{\"key\":\"exitName\",\"keyProb\":100,\"value\":\"\",\"valueProb\":100},{\"key\":\"totalAmount\",\"keyProb\":85,\"value\":\"0.00\",\"valuePos\":[{\"x\":70,\"y\":181},{\"x\":70,\"y\":190},{\"x\":55,\"y\":190},{\"x\":55,\"y\":181}],\"valueProb\":85}],\"sliceRect\":{\"x0\":0,\"y0\":2,\"x1\":196,\"y1\":1,\"x2\":198,\"y2\":251,\"x3\":0,\"y3\":252},\"width\":199}",
  "Code": "noPermission",
  "Message": "You are not authorized to perform this operation."
}

错误码

访问错误中心查看更多错误码。

变更历史

变更时间变更内容概要操作
暂无变更历史