1import * as containeranalysis from "@distilled.cloud/gcp/containeranalysis_v1";
2import * as Layer from "effect/Layer";
3import { makeOccurrenceHttpBinding } from "./BindingHttp.ts";
4import { GetOccurrence } from "./GetOccurrence.ts";
5
6/**
7 * HTTP implementation of {@link GetOccurrence}.
8 *
9 * @layer
10 * @provides GCP.ContainerAnalysis.GetOccurrence
11 */
12export const GetOccurrenceHttp = Layer.effect(
13 GetOccurrence,
14 makeOccurrenceHttpBinding({
15 tag: "GCP.ContainerAnalysis.GetOccurrence",
16 // Occurrences have no IAM policy of their own.
17 iam: { role: "roles/containeranalysis.occurrences.viewer" },
18 operation: containeranalysis.getProjectsOccurrences,
19 }),
20);