| 1 | import * as privateca from "@distilled.cloud/gcp/privateca_v1"; |
| 2 | import * as Layer from "effect/Layer"; |
| 3 | import { makeCertificateAuthorityHttpBinding } from "./BindingHttp.ts"; |
| 4 | import { GetCertificateAuthority } from "./GetCertificateAuthority.ts"; |
| 5 | |
| 6 | /** |
| 7 | * HTTP implementation of {@link GetCertificateAuthority}. |
| 8 | * |
| 9 | * @layer |
| 10 | * @provides GCP.PrivateCA.GetCertificateAuthority |
| 11 | */ |
| 12 | export const GetCertificateAuthorityHttp = Layer.effect( |
| 13 | GetCertificateAuthority, |
| 14 | makeCertificateAuthorityHttpBinding({ |
| 15 | tag: "GCP.PrivateCA.GetCertificateAuthority", |
| 16 | iam: { role: "roles/privateca.auditor", on: "privateca.caPool" }, |
| 17 | operation: privateca.getProjectsLocationsCaPoolsCertificateAuthorities, |
| 18 | }), |
| 19 | ); |