本文档主要提供给互亿平台的用户对接接口的使用说明,开发者可以利用互亿无线提供的 HTTP 接口,调用互亿无线的实名认证服务。
GET / POST
1、采用HTTPS协议提交请求
2、通过MD5动态签名方式加密
登录用户中心,进入【实名认证】模块,在【产品总览】页面右侧,如下图所示:
通过POST、 GET 方式进行提交,数据编码采用utf-8格式,24小时全天提交。
内容格式为:Content-Type: application/x-www-form-urlencoded
https://api.ihuyi.com/idcard/entmark/Submit.json
| 参数名称 | 参数值描述 | 必填 |
| account | APIID(用户中心【实名认证】-【产品总览】查看) | 是 |
| password | 1、APIKEY(用户中心【实名认证】-【产品总览】查看) 2、动态密码(生成动态密码方式请看该文档末尾的说明) |
是 |
| ent_name | 企业名称。企业名称 、统代、组织机构代码、工商注册号四选一 | 否 |
| ent_code | 社会信用代码。企业名称、统代、组织机构代码、工商注册号四选一 | 否 |
| organization_code | 组织机构代码。企业名称、统代、组织机构代码、工商注册号四选一 | 否 |
| reg_no | 注册号。企业名称、统代、组织机构代码、工商注册号四选一 | 否 |
| begin_date | 申请开始日(格式yyyy-MM-DD,如2025-01-01) | 否 |
| end_date | 申请结束日(格式yyyy-MM-DD,如2025-01-01) | 否 |
| int_category | 国际分类代码(参考附件商标国际分类,如1、2...) | 否 |
| application_number | 申请/注册号 | 否 |
| page_index | 页码,默认第一页 | 否 |
| page_size | 每页条数(默认20条,最大20条) | 否 |
| time | Unix时间戳(10位整型数字,当使用动态密码方式时为必填) | 否 |
用户通过http 或 https提交请求到服务器后,服务器会返回一串json格式的字符串,SubmitResult结构说明如下:
| 参数名称 | 类型 | 描述 |
| code | int | 返回值为2时,表示提交成功 |
| idcardid | string | 当提交成功后,此字段为流水号,否则为0 |
| msg | string | 提交结果描述 |
| result | object | 查询结果 |
| result.total | string | 总数 |
| result.list+ | array | 列表 |
| applicationNumber | string | 申请号 |
| applicant | string | 申请人名称 |
| internationalCategory | string | 国际分类 |
| isHistory | string | 是否历史 |
| applicationDate | string | 申请日期 |
| applicationYear | string | 申请注册年份 |
| trademarkName | string | 商标名称 |
| applicantEn | string | 申请人名称(英文) |
| applicantAddressCn | string | 申请人地址(中文) |
| applicantAddressEn | string | 申请人地址(英文) |
| agencyEntity | string | 代理机构 |
| agencyEntityId | string | 代理机构ID |
| agencyEntityType | string | 代理机构类型 |
| isShared | string | 是否共有商标 |
| applicantShare | string | 共有申请人 |
| applicantShareId | string | 共有申请人ID |
| firstAuditNumber | string | 初审公告期号 |
| firstAuditDate | string | 初审公告日期 |
| regPublishNumber | string | 注册公告期号 |
| regPublishDate | string | 注册公告日期 |
| trademarkType | string | 商标类型 |
| trademarkTypeTag | string | 商标类型标识 |
| exclusivePeriod | string | 专用权期限 |
| startDate | string | 开始时间 |
| endDate | string | 结束时间 |
| trademarkForm | string | 商标形式 |
| internationalRegDate | string | 国际注册日期 |
| appointDate | string | 后期指定日期 |
| priorityDate | string | 优先权日期 |
| trademarkStatus | string | 商标状态 |
| nowStatus | string | 当前状态 |
| isStereoscopic | string | 是否立体商标 |
| geographySign | string | 地理标志信息 |
| colorTag | string | 颜色标志 |
| product | string | 商标商品(productName:商品名称;productType:商品 类似群;isOverrule:是否驳回) |
| flow | string | 商标流程(businessName:业务名称;stepName:环节名称;processDate:日期;processConclusion:结果) |
| announce | string | 商标公告(announcementNumber:公告期号;publishDate:公告日期;announcementType:公告类型;announcementContent:公告内容;announcementImg:原始公告图片;transferor:商标转让人;assignee:商标受让人) |
示例(成功)
{
"code": 2,
"msg": "提交成功",
"idcardid": "25071713393242455",
"result": {
"total": 25,
"list": [
{
"isStereoscopic": "0",
"applicationNumber": "81477709",
"endDate": "2035-06-13",
"applicationYear": "2024",
"regPublishDate": "2025-06-14",
"trademarkType": "一般",
"geographySign": "",
"trademarkTypeTag": "0",
"appointDate": "",
"applicantAddressEn": "",
"applicantAddressCn": "上海市金山区亭林镇寺平南路16号444室",
"agencyEntity": "郑州凯派尔知识产权代理有限公司",
"trademarkStatus": "注册公告",
"trademarkName": "图形",
"exclusivePeriod": "2025年06月14日至2035年06月13日",
"flow": "[{"applicationNumber":"81477709","businessName":"商标注册申请","internationalCategory":"20","processConclusion":"结束","processDate":"2024-10-19","stepName":"申请收文"},{"applicationNumber":"81477709","businessName":"商标注册申请","internationalCategory":"20","processConclusion":"结束","processDate":"2024-11-08","stepName":"等待受理通知书发文"}]",
"product": "[{"applicationNumber":"81477709","internationalCategory":"20","isOverrule":"0","productName":"非金属梯凳","productType":"2003"}]",
"applicantShare": "",
"agencyEntityId": "195164394",
"trademarkForm": "",
"applicantEn": "",
"nowStatus": "",
"announce": "[{"announcementContent":"2025-06-13 商标注册公告(一) 第1939期","announcementImg":"https://sbggwj.sbj.cnipa.gov.cn:9443/tmann/group3/M00/AC/EF/CgoDIWhKTKuAdImoAAF6CTMR73U098.pdf","announcementNumber":"1939","announcementType":"商标注册公告(一)","applicationNumber":"81477709","assignee":"","internationalCategory":"20","publishDate":"2025-06-13","transferor":""}]",
"regPublishNumber": "1939",
"applicant": "上海思锐信息技术有限公司",
"agencyEntityType": "0",
"firstAuditNumber": "1927",
"colorTag": "",
"internationalRegDate": "",
"applicantShareId": "",
"priorityDate": "",
"firstAuditDate": "2025-03-13",
"internationalCategory": "20",
"isHistory": "0",
"isShared": "0",
"startDate": "2025-06-14",
"applicationDate": "2024-10-19"
}
]
}
}
示例(失败)
{
"code": 405,
"msg": "用户名或密码不正确",
"idcardid": "0"
}
| code | msg |
| 0 | 未知错误 |
| 1 | 提交失败 |
| 2 | 提交成功 |
| 400 | 非法ip访问 |
| 401 | 帐号不能为空 |
| 402 | 密码不能为空 |
| 403 | 应用不存在 |
| 407 | 手机号不能为空 |
| 4071 | 手机格式不正确 |
| 408 | 查询无结果 |
| 405 | API ID或API KEY不正确 |
| 4050 | 账号被冻结 |
| 40501 | 动态密码已过期 |
| 40502 | 动态密码校验失败 |
| 40505 | 没有签定合同 |
| 4051 | 剩余条数不足 |
| 4052 | 访问ip与备案ip不符 |
| 4086 | 通道无效 |
| 4010 | 通道错误 |
https://api.ihuyi.com/idcard/entmark/Submit.json?account=APIID&password=APIKEY&ent_name=企业名称time=time
通过接口可以方便的查询你的账户剩余条数。
内容格式为:Content-Type: application/x-www-form-urlencoded
https://api.ihuyi.com/idcard/entmark/GetNum.json
| 参数名称 | 参数值描述 | 必填 |
| account | APIID(用户中心【实名认证】-【产品总览】查看) | 是 |
| password | 1、APIKEY(用户中心【实名认证】-【产品总览】查看) 2、动态密码(生成动态密码方式请看该文档末尾的说明) |
是 |
| time | Unix时间戳(10位整型数字,当使用动态密码方式时为必填) | 否 |
用户通过http 或 https提交请求到服务器后,服务器会返回一串json格式的字符串,GetNumResult结构说明如下:
| 参数名称 | 类型 | 描述 |
| code | int | 状态返回值 |
| msg | string | 查询结果描述 |
| num | string | 剩余数量 |
示例(成功)
{"code":2,"msg":"查询成功","num":123}
示例(失败)
{"code":405,"msg":"用户名或密码不正确","num":0}
| code | msg |
| 2 | 查询成功 |
| 400 | 非法ip访问 |
| 401 | 帐号不能为空 |
| 402 | 密码不能为空 |
| 403 | 应用不存在 |
| 405 | API ID或API KEY不正确 |
| 406 | 企业名称、统代、组织机构代码、工商注册号四选一 |
| 407 | 每页条数最大20 |
| 4050 | 账号被冻结 |
| 40501 | 动态密码已过期 |
| 40502 | 动态密码校验失败 |
| 4052 | 访问ip与备案ip不符 |
https://api.ihuyi.com/idcard/entmark/GetNum.json?account=APIID&password=APIKEY
$time = time(); $password = md5($account.$apikey.$app.$ent_name.$ent_code.$time);
示例:
APIID: test APIKEY:1q784322b****** app:entmark //固定值 ent_name:上海** ent_code:123** time:1651544941 结果:$password=md5("test1q784322b******entmark上海**123**1651544941");
注意:所以字符编码统一为UTF-8
$time = time(); $password = md5($account.$apikey.$app.$time);
示例:
APIID: test APIKEY:1q784322ba1****** app:entmark //固定值 time:1651544941 结果:$password=md5("test1q784322ba1******entmark1651544941");
Unix时间戳参考地址:http://tool.chinaz.com/Tools/unixtime.aspx
| 语言 | 代码 |
| JAVA | String date = new java.text.SimpleDateFormat("dd/MM/yyyy HH:mm:ss").format(new java.util.Date(Unix timestamp *1000)) |
| Linux | date -d @Unix timestamp |
| C | strptime(datetime, "%Y-%m-%d %H:%M:%S", &tm_time); unixtime = mktime(&tm_time); |
| C++ | std::time_t t = std::time(0); |
| DELPHI | uses DateUtils; DateTimeToUnix(Now) |
| GO | import "time" cur := time.Now() timestamp := cur.UnixNano() / 1000000 |
| Perl | 先 my $time = Unix timestamp 然后 my ($sec, $min, $hour, $day, $month, $year) = (localtime($time))[0,1,2,3,4,5,6] |
| PHP | date("r", Unix timestamp) |
| Node.js | var date = new Date( time * 1000 ); var time = date.getTime()/1000; |
| Python | 先 import time 然后 time.gmtime(Unix timestamp) |
| Ruby | Time.at(Unix timestamp) |
| SHELL | date +%s //UNIX 的时间戳; |
| VBScript / ASP | DateAdd("s", Unix timestamp, "01/01/1970 00:00:00") |
| VB6 | DateDiff("s", "1970-1-1 0:0:0", ToUnixTime) |
| 易语言 | 时间_到时间戳() |