GET /billing/invoice/{invoice_number}/export

导出指定发票的详细信息,支持 JSON/CSV 两种格式

计费服务 `bearerAuth` application/json

请求参数

名称位置类型必填默认值示例约束描述
invoice_number path string 是 发票编号
format query string 否 json 导出格式 (json/csv)

响应

状态描述Schema
200发票导出成功service-billing/internal/handler/dto.InvoiceDetailResponse
400请求参数错误object
401未授权object
404发票不存在object
500服务器内部错误object

引用的 Schema

service-billing/internal/handler/dto.InvoiceDetailResponse

字段类型必填示例约束描述
code integer 否
data service-billing/internal/handler/dto.InvoiceResponse 否
message string 否
timestamp string 否

service-billing/internal/handler/dto.InvoiceLineItemResponse

字段类型必填示例约束描述
amount number 否 99
description string 否 专业版月度订阅
quantity integer 否 1
resource_type string 否 subscription
tax_amount number 否 5.94
tax_rate number 否 0.06
unit_price number 否 99

service-billing/internal/handler/dto.InvoiceResponse

字段类型必填示例约束描述
amount number 否 104.94
app_id string 否 app_001
billing_cycle string 否 monthly
currency string 否 CNY
due_date string 否 2026-04-15T00:00:00Z
invoice_number string 否 INV-2026-001
issued_at string 否 2026-04-01T00:00:00Z
line_items array of

参见 service-billing/internal/handler/dto.InvoiceLineItemResponse

否
paid_at string 否 2026-04-10T15:00:00Z
plan string 否 pro
status string 否 issued
tenant_id string 否 tnt_xyz789