1import type * as NFW from "@distilled.cloud/aws/network-firewall";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { Firewall } from "./Firewall.ts";
5
6export interface StartFlowFlushRequest extends Omit<
7 NFW.StartFlowFlushRequest,
8 "FirewallArn"
9> {}
10
11/**
12 * Runtime binding for `network-firewall:StartFlowFlush` — flush matching
13 * flows from the bound {@link Firewall}'s flow table (impacted flows are
14 * re-evaluated as midstream traffic); the firewall ARN is injected
15 * automatically.
16 *
17 * Provide `NetworkFirewall.StartFlowFlushHttp` on the hosting Lambda
18 * Function to satisfy the requirement.
19 * ### Flow Operations
20 * **Example:** Flush Flows to a Host
21 * ```typescript
22 * // init — grants network-firewall:StartFlowFlush on the firewall
23 * const startFlowFlush = yield* AWS.NetworkFirewall.StartFlowFlush(firewall);
24 *
25 * // runtime
26 * const { FlowOperationId } = yield* startFlowFlush({
27 * FlowFilters: [{ SourceAddress: { AddressDefinition: "10.0.1.10/32" } }],
28 * });
29 * ```
30 *
31 * @binding
32 */
33export interface StartFlowFlush extends Binding.Service<
34 StartFlowFlush,
35 "AWS.NetworkFirewall.StartFlowFlush",
36 (
37 firewall: Firewall,
38 ) => Effect.Effect<
39 (
40 request: StartFlowFlushRequest,
41 ) => Effect.Effect<NFW.StartFlowFlushResponse, NFW.StartFlowFlushError>
42 >
43> {}
44
45export const StartFlowFlush = Binding.Service<StartFlowFlush>(
46 "AWS.NetworkFirewall.StartFlowFlush",
47);