1import type * as greengrassv2 from "@distilled.cloud/aws/greengrassv2";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4
5/**
6 * Runtime binding for `greengrass:GetCoreDevice`.
7 *
8 * Reads one core device's metadata — status (`HEALTHY` / `UNHEALTHY`),
9 * nucleus version, platform, and last status-update timestamp. Core devices
10 * register themselves (they are not Alchemy resources), so the caller
11 * supplies the core device thing name at runtime. Provide the implementation
12 * with `Effect.provide(AWS.GreengrassV2.GetCoreDeviceHttp)`.
13 * ### Managing Core Devices
14 * **Example:** Check A Core Device's Health
15 * ```typescript
16 * // init — account-level binding, no resource argument
17 * const getCoreDevice = yield* AWS.GreengrassV2.GetCoreDevice();
18 *
19 * // runtime
20 * const device = yield* getCoreDevice({ coreDeviceThingName: "MyCore" });
21 * yield* Effect.log(`${device.coreDeviceThingName} is ${device.status}`);
22 * ```
23 *
24 * @binding
25 */
26export interface GetCoreDevice extends Binding.Service<
27 GetCoreDevice,
28 "AWS.GreengrassV2.GetCoreDevice",
29 () => Effect.Effect<
30 (
31 request: greengrassv2.GetCoreDeviceRequest,
32 ) => Effect.Effect<
33 greengrassv2.GetCoreDeviceResponse,
34 greengrassv2.GetCoreDeviceError
35 >
36 >
37> {}
38export const GetCoreDevice = Binding.Service<GetCoreDevice>(
39 "AWS.GreengrassV2.GetCoreDevice",
40);