GET /billing/usage/{tenant_id}/timeline
查询指定天数内的用量变化时间序列数据,按日返回用户数、API调用量、存储和带宽使用量,用于趋势分析图表
计费服务 `bearerAuth` application/json
Request Parameters
| Name | In | Type | Required | Default | Example | Constraints | Description |
tenant_id |
path |
string |
Yes |
|
|
|
租户ID |
app_id |
query |
string |
No |
|
|
|
应用ID(可选) |
days |
query |
integer |
No |
30 |
|
|
统计天数 |
Referenced Schemas
dto.UsageTimelineDetailResponse
| Field | Type | Required | Example | Constraints | Description |
code |
integer |
No |
|
|
|
data |
dto.UsageTimelineResponse |
No |
|
|
|
message |
string |
No |
|
|
|
timestamp |
string |
No |
|
|
|
dto.UsageTimelinePoint
| Field | Type | Required | Example | Constraints | Description |
api_requests |
integer |
No |
15000 |
|
|
bandwidth_gb |
number |
No |
15 |
|
|
date |
string |
No |
2026-05-01 |
|
|
storage_gb |
number |
No |
2.5 |
|
|
users |
integer |
No |
120 |
|
|
dto.UsageTimelineResponse
| Field | Type | Required | Example | Constraints | Description |
app_id |
string |
No |
app_001 |
|
|
days |
integer |
No |
30 |
|
|
tenant_id |
string |
No |
tnt_xyz789 |
|
|
timeline |
array of
See dto.UsageTimelinePoint |
No |
|
|
|