1import type * as emr from "@distilled.cloud/aws/emr-serverless";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { Application } from "./Application.ts";
5
6/**
7 * Request accepted by the {@link GetResourceDashboard} runtime callable. The
8 * `applicationId` is injected from the bound {@link Application}.
9 */
10export type GetResourceDashboardInput = Omit<
11 emr.GetResourceDashboardRequest,
12 "applicationId"
13>;
14
15/**
16 * Runtime binding for `emr-serverless:GetResourceDashboard`.
17 *
18 * Creates a pre-signed dashboard URL for a specific resource (e.g. a
19 * worker) of the bound {@link Application}. Provide the implementation with
20 * `Effect.provide(AWS.EMRServerless.GetResourceDashboardHttp)`.
21 * ### Dashboards
22 * **Example:** Link To A Resource Dashboard
23 * ```typescript
24 * // init
25 * const getResourceDashboard =
26 * yield* AWS.EMRServerless.GetResourceDashboard(app);
27 *
28 * // runtime
29 * const { url } = yield* getResourceDashboard({ resourceId, resourceType });
30 * ```
31 *
32 * @binding
33 */
34export interface GetResourceDashboard extends Binding.Service<
35 GetResourceDashboard,
36 "AWS.EMRServerless.GetResourceDashboard",
37 (
38 application: Application,
39 ) => Effect.Effect<
40 (
41 request: GetResourceDashboardInput,
42 ) => Effect.Effect<
43 emr.GetResourceDashboardResponse,
44 emr.GetResourceDashboardError
45 >
46 >
47> {}
48export const GetResourceDashboard = Binding.Service<GetResourceDashboard>(
49 "AWS.EMRServerless.GetResourceDashboard",
50);