Skip to content

StartQuery

Source: src/AWS/InternetMonitor/StartQuery.ts

Runtime binding for internetmonitor:StartQuery — start a query against the bound Monitor’s measurement data with the Internet Monitor query interface; the monitor name is injected automatically.

Provide InternetMonitor.StartQueryHttp on the hosting Lambda Function to satisfy the requirement.

// init — grants internetmonitor:StartQuery on the monitor
const startQuery = yield* AWS.InternetMonitor.StartQuery(monitor);
// runtime
const { QueryId } = yield* startQuery({
StartTime: new Date(Date.now() - 3_600_000),
EndTime: new Date(),
QueryType: "MEASUREMENTS",
});