Skip to content

GetInvestigation

Source: src/AWS/Detective/GetInvestigation.ts

Runtime binding for detective:GetInvestigation.

Reads a single investigation’s detail — entity, scope window, status, severity, and state — so a triage function can poll a running investigation to completion. The graph ARN is injected from the bound Graph. Provide the implementation with Effect.provide(AWS.Detective.GetInvestigationHttp).

// init
const getInvestigation = yield* AWS.Detective.GetInvestigation(graph);
// runtime
const detail = yield* getInvestigation({ InvestigationId: id });
if (detail.Status === "SUCCESSFUL") {
yield* Effect.log(`severity: ${detail.Severity}`);
}