| 1 | import * as wafv2 from "@distilled.cloud/aws/wafv2"; |
| 2 | import * as Layer from "effect/Layer"; |
| 3 | import { |
| 4 | CreateAPIKey, |
| 5 | DeleteAPIKey, |
| 6 | GetDecryptedAPIKey, |
| 7 | ListAPIKeys, |
| 8 | } from "./APIKeys.ts"; |
| 9 | import { makeWafv2AccountHttpBinding } from "./BindingHttp.ts"; |
| 10 | |
| 11 | export const CreateAPIKeyHttp = Layer.effect( |
| 12 | CreateAPIKey, |
| 13 | makeWafv2AccountHttpBinding({ |
| 14 | tag: "AWS.WAFv2.CreateAPIKey", |
| 15 | operation: wafv2.createAPIKey, |
| 16 | actions: ["wafv2:CreateAPIKey"], |
| 17 | }), |
| 18 | ); |
| 19 | |
| 20 | export const GetDecryptedAPIKeyHttp = Layer.effect( |
| 21 | GetDecryptedAPIKey, |
| 22 | makeWafv2AccountHttpBinding({ |
| 23 | tag: "AWS.WAFv2.GetDecryptedAPIKey", |
| 24 | operation: wafv2.getDecryptedAPIKey, |
| 25 | actions: ["wafv2:GetDecryptedAPIKey"], |
| 26 | }), |
| 27 | ); |
| 28 | |
| 29 | export const ListAPIKeysHttp = Layer.effect( |
| 30 | ListAPIKeys, |
| 31 | makeWafv2AccountHttpBinding({ |
| 32 | tag: "AWS.WAFv2.ListAPIKeys", |
| 33 | operation: wafv2.listAPIKeys, |
| 34 | actions: ["wafv2:ListAPIKeys"], |
| 35 | }), |
| 36 | ); |
| 37 | |
| 38 | export const DeleteAPIKeyHttp = Layer.effect( |
| 39 | DeleteAPIKey, |
| 40 | makeWafv2AccountHttpBinding({ |
| 41 | tag: "AWS.WAFv2.DeleteAPIKey", |
| 42 | operation: wafv2.deleteAPIKey, |
| 43 | actions: ["wafv2:DeleteAPIKey"], |
| 44 | }), |
| 45 | ); |