Events API
Kubecost emits events when certain things happen. Those events are also recorded in an event log in the interest of diagnosing problems.
Events API
Using the Events API
GET http://<your-kubecost-address>/model/etl/log
Accesses the most recent events in the event log.
| Name | Required | Type | Description |
|---|---|---|---|
| window | false | string | Duration of time over which to query. Accepts all standard Kubecost window formats (See our docs on using the window parameter). |
| kind | false | string | Filter query by event kind (see below). |
| Code | Description | Example |
|---|---|---|
| 200 | OK |
|
Event kinds
All event kinds below will appear in the body of the output by default. You can filter for specific event kinds using the kind parameter. For example, to see only AllocationSetSaved in the output, your endpoint will look like:
http://<your-kubecost-address>/model/etl/log?kind=AllocationSetSaved
You can also view all substrings between Allocations or Assets. For example, the following endpoint will retrieve all event kinds beginning with AssetSet:
http://<your-kubecost-address>/model/etl/log?kind=AssetSet
Allocation outputs should be interpreted as:
-
AllocationSetSaveddescribes a saved AllocationSet -
AllocationSetLoadeddescribes a loaded AllocationSet -
AllocationSetAggregateddescribes aggregating an AllocationSet -
AllocationSetTotaleddescribes totaling an AllocationSet -
AllocationSetReconcileddescribes reconciling an AllocationSet -
AllocationSetComputeErrordescribes an error in computation -
AllocationSetReconcileErrordescribes an error in reconciliation
Assets outputs should be interepreted as:
-
AssetSetSaveddescribes a saved AssetSet -
AssetSetLoadeddescribes a loaded AssetSet -
AssetSetAggregateddescribes aggregating an AssetSet -
AssetSetTotaleddescribes totaling an AssetSet -
AssetSetReconcileddescribes reconciling an AssetSet -
AssetSetComputeErrordescribes an error in computation -
AssetSetReconcileErrordescribes an error in reconciliation
Underneath each event kind, you should see size and/or window returned, which are:
* `size`: number of records in the set
* `window`: window of the set
This log will additionally be appended to bug reports.