Appearance
比亚迪项目
变更日志
| 版本 | 变更人 | 变更时间 | 变更内容 |
|---|---|---|---|
| v1 | 孙强 | 2021/11/11 | 初始版本 |
1、查询发票明细(发票号+发票代码)
接口说明:
| Method | URL | ContentType |
|---|---|---|
| GET | api/restful/apiBill/invoice?invoicenum=XXXX&invoicecode=XXXX | application/json |
PostData请求参数说明:
| 参数名 | 类型说明 | 是否必须 | 长度 | 描述 |
|---|---|---|---|---|
| invoicenum | String | 是 | 50 | 发票号码 |
| invoicecode | String | 是 | 50 | 发票代码 |
返回结果说明:
| 参数名 | 类型说明 | 描述 |
|---|---|---|
| invoice_code | String | 发票代码 |
| invoice_num | String | 发票号码 |
| taxpayer | String | 纳税人识别号 |
| state | int | 发票状态【0:作废,1:正常,2:冲红】 |
| invoice_date | String | 发票日期 |
| invoice_naked_amount | double | 发票金额(裸价) |
| invoice_tax_rate | double | 发票税率 |
| invoice_tax_amount | double | 发票税额 |
| invoice_amount | double | 价税合计 |
| invoice_type | int | 发票类型1:增票 2:普票 |
| invoice_title | String | 发票抬头 |
| skuDetails | List< InvoiceSkuDetail > | 商品明细 |
InvoiceSkuDetail :
| 参数名 | 类型说明 | 描述 |
|---|---|---|
| yggc_order | String | 订单号 |
| skuId | String | 商品id |
| skuName | String | 商品名称 |
| price | BigDecimal | 单价 |
| num | int | 数量 |
响应结果示例:
json
{
"result": [{
"invoice_code": "A0001",
"invoice_num": "1001",
"state":1,
"invoice_date": "2018-06-11 00:00:00",
"invoice_naked_amount": 100,
"invoice_tax_rate": 1.5,
"invoice_tax_amount": 1,
"invoice_amount": 100,
"invoice_type": 1,
"taxpayer:"12345678945124512",
"invoice_title":"上海晨光科力普办公用品有限公司",
"skuDetails": [
{
"yggc_order": "00001",
"skuId": "100000177696",
"skuName": "Apple iPhone 13ProMax 256GB 银色 ",
"price": 6755,
"num": 1
},
{
"yggc_order": "00002",
"skuId": "100000177697",
"skuName": "Apple iPhone 13ProMax 256GB 黑色",
"price": 6755,
"num": 1
}
]
}],
"success": true,
"errormsg": "",
"errorcode": "",
"requestId": "9245fe4a-d402-451c-b9ed-9c1a04247482"
}2、查询历史开票(订单号)
接口说明:
| Method | URL | ContentType |
|---|---|---|
| GET | api/restful/apiBill/historyinvoice?yggc_order=XXXX | application/json |
PostData请求参数说明:
| 参数名 | 类型说明 | 是否必须 | 长度 | 描述 |
|---|---|---|---|---|
| yggc_order | String | 是 | 50 | 订单号 |
返回结果说明:
| 参数名 | 类型说明 | 描述 |
|---|---|---|
| yggc_order | String | 订单号 |
| invoice_code | String | 发票代码 |
| invoice_num | String | 发票号码 |
| invoice_type | int | 发票类型1:增票 2:普票 |
| invoice_title | String | 发票抬头 |
| iflag | int | 发票类别(1.正数;2.负数)1代表蓝票 2代表红票 |
| invoice_time | String | 开票日期 |
| total_price | BigDecimal | 开票金额,订单在本发票中的总金额 |
| totalTaxPrice | BigDecimal | 税额,订单在本发票中的总税额 |
| file_url | String | 电子票下载地址(预留字段) |
| remark | String | 备注 |
响应结果示例:
json
{
"success": true,
"resultMessage": "操作成功",
"resultCode": "0000",
"result": [
{
"yggc_order":"MG20124542",
"invoice_code": "044001800311",
"invoice_num": "62575216",
"invoice_type": 1,
"invoice_title": "上海晨光科力普办公用品有限公司",
"iflag": 1,
"invoice_time": "2019-03-01 17:14:00",
"total_price": 17.00000000,
"totalTaxPrice": 0.000000,
"remark": "发票备注",
}
]
}