1import type * as obs from "@distilled.cloud/aws/observabilityadmin";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { TelemetryRule } from "./TelemetryRule.ts";
5
6/**
7 * Runtime binding for `observabilityadmin:GetTelemetryRule` — reads the full
8 * configuration and per-region status of the bound
9 * {@link TelemetryRule}. The rule's name is injected automatically and the
10 * IAM grant is scoped to the rule's ARN.
11 *
12 * Provide `AWS.ObservabilityAdmin.GetTelemetryRuleHttp` on the hosting
13 * Lambda Function to satisfy the requirement.
14 * ### Reading a Telemetry Rule
15 * **Example:** Read the bound rule's configuration
16 * ```typescript
17 * // init — grants observabilityadmin:GetTelemetryRule on the rule
18 * const getTelemetryRule = yield* AWS.ObservabilityAdmin.GetTelemetryRule(rule);
19 *
20 * // runtime
21 * const { TelemetryRule: config, RegionStatuses } = yield* getTelemetryRule();
22 * ```
23 *
24 * @binding
25 */
26export interface GetTelemetryRule extends Binding.Service<
27 GetTelemetryRule,
28 "AWS.ObservabilityAdmin.GetTelemetryRule",
29 (
30 rule: TelemetryRule,
31 ) => Effect.Effect<
32 () => Effect.Effect<obs.GetTelemetryRuleOutput, obs.GetTelemetryRuleError>
33 >
34> {}
35
36export const GetTelemetryRule = Binding.Service<GetTelemetryRule>(
37 "AWS.ObservabilityAdmin.GetTelemetryRule",
38);