Search billings
Endpoint
POST https://api.wavespeed.ai/api/v3/billings/search
Description
Search billing records with optional filters such as billing type, related prediction UUIDs, sort order, and time range. Returns paginated results.
Example cURL request:
curl --location 'https://api.wavespeed.ai/api/v3/billings/search' \
--header 'Authorization: Bearer ${WAVESPEED_API_KEY}' \
--header 'Content-Type: application/json' \
--data '{
"billing_type": "deduct",
"prediction_uuids": ["cb54bb552ff94e1ea6a5c2976fe1c0c1"],
"sort": "created_at ASC",
"start_time": "1759317210051",
"end_time": "1759317227408",
"page": 1,
"page_size": 10
}'
The response will be a paginated JSON object of billing records:
{
"code": 200,
"message": "success",
"data": {
"page": 1,
"total": 1,
"items": [
{
"uuid": "d6b45aaa54fb4d12930acc36c9ae639f",
"billing_type": "deduct",
"price": 24300,
"created_at": "2025-10-01T11:13:30.051Z",
"updated_at": "2025-10-01T11:13:30.051Z",
"order": {
"uuid": "2bf7346d433e4b0e9e70bc24e5e24644",
"state": "done",
"price": 24300,
"origin_price": 27000,
"status": "",
"ak_id": 0
},
"prediction": {
"uuid": "cb54bb552ff94e1ea6a5c2976fe1c0c1",
"model_uuid": "bytedance/seedream-v3",
"status": "completed"
},
"access_key_name": ""
}
]
}
}
Query Parameters
Parameter | Type | Required | Default | Range | Description |
---|---|---|---|---|---|
billing_type | string | No | - | - | Filter by billing type (e.g., deduct ). |
prediction_uuids | array[string] | No | - | - | Filter by one or more related prediction UUIDs. |
sort | string | No | - | - | Sort order, e.g., created_at ASC or created_at DESC . |
start_time | string | No | - | - | Start of time range (milliseconds since Unix epoch, as string). |
end_time | string | No | - | - | End of time range (milliseconds since Unix epoch, as string). |
page | integer | Yes | 1 | >=1 | Page number to return. |
page_size | integer | Yes | 10 | 1~100 | Number of items per page. |