Skip to content

GetUsageStatistics

Source: src/AWS/GuardDuty/GetUsageStatistics.ts

Runtime binding for guardduty:GetUsageStatistics.

Reports GuardDuty usage (cost) statistics for the detector, grouped by data source, feature, or member account. The detector id is injected from the bound Detector. Provide the implementation with Effect.provide(AWS.GuardDuty.GetUsageStatisticsHttp).

// init
const getUsageStatistics = yield* AWS.GuardDuty.GetUsageStatistics(detector);
// runtime
const { UsageStatistics } = yield* getUsageStatistics({
UsageStatisticType: "SUM_BY_DATA_SOURCE",
UsageCriteria: { DataSources: ["FLOW_LOGS"] },
});