用友 t6 凭证http API

API服务器支持日记录功能,方便网管查询调用记录

 

 API采用的是http +JSON方式,方便与各种语言对接

API加入token验证,目前token由服务器固定生成,可以手工更新,更新后,调用方需将调用的token更新,否则不予调用API,这样将更加的安全。

生前的凭证科目支持供应商辅助,客户辅助核算,部门辅助核算,人员辅助核算。项目辅助核算。

对于传入的档案也将进行验校,对于法非数据将不写入凭证。避免数据错误

例如,调用API的数据为

{"main":{"cbill":"demo1","dbill_date":"2012-04-29","iperiod":"4","csign":"记","code":"800001"},"detail":[{"ccode":"1008","md":"10","ctext1":"ctext1","ctext2":"EC21080001","cdigest":"借方摘要","cdept_id":"01"},{"ccode":"100101","md":"15","ctext1":"ctext1","ctext2":"EC21080001","cdigest":"借方摘要"},{"ccode":"2008","mc":"20","cperson_id":"030201","cdigest":"借方摘要","ctext1":"ctext1","ctext2":"EC21080001"},{"ccode":"5001","mc":"5","ctext1":"ctext1","ctext2":"EC21080001","cdept_id":"02","cdigest":"借方摘要"},{"ccode":"1008","md":"30","cdept_id":"02","ctext1":"ctext1","ctext2":"EC21080001","cdigest":"借方摘要"},{"ccode":"2008","mc":"30","ctext1":"ctext1","ctext2":"EC21080001","cdigest":"借方摘要","cperson_id":"030201"}],"token":"hHYql4JTmBzku=g1EJzBgCapL8LV5dGR"}

其中token取自服务器的设置

 

 调用成功能,返回一个json内容如下,

{"state":200,"sMng":"\u8BB018","code":"800001"}

解析后为

 

其中sMng为凭证信息,如记 为记账证,后面的18为凭证号 18,Code是客户端写入的ID,服务端生成凭证后将把Code回传。

此时,日记录里己详细记录了该调用记录

 

 打开用友,生成的凭证为

 

 目前我己实现了各种业务单据的API,和凭证的API,如有商务合作,联系我,QQ 961138505

 

posted @ 2021-08-12 21:48  似水@流年  阅读(125)  评论(0编辑  收藏  举报
悠悠记得当天笑 仿佛入迷 又带一点惘 种种喜悦 令人为你鼓掌 眉飞色舞千千样 你是个妙人 是个少年狂