sailfork / t3code-github / .repos/ alchemy-effect/ packages/ aws/ src/ Grafana/ ListVersions.ts

import type * as grafana from "@distilled.cloud/aws/grafana";
import * as Binding from "alchemy/Binding";
import type * as Effect from "effect/Effect";

/**
 * Runtime binding for the `ListVersions` operation (IAM action
 * `grafana:ListVersions`).
 *
 * Lists the Grafana versions available when creating a workspace, or — with
 * a `workspaceId` — the versions an existing workspace can be upgraded to.
 * Provide the implementation with
 * `Effect.provide(AWS.Grafana.ListVersionsHttp)`.
 * ### Managing Configuration
 * **Example:** List the Available Grafana Versions
 * ```typescript
 * const listVersions = yield* Grafana.ListVersions();
 *
 * const { grafanaVersions } = yield* listVersions();
 * // grafanaVersions → ["10.4", "9.4", ...]
 * ```
 *
 * @binding
 */
export interface ListVersions extends Binding.Service<
  ListVersions,
  "AWS.Grafana.ListVersions",
  () => Effect.Effect<
    (
      request?: grafana.ListVersionsRequest,
    ) => Effect.Effect<grafana.ListVersionsResponse, grafana.ListVersionsError>
  >
> {}
export const ListVersions = Binding.Service<ListVersions>("AWS.Grafana.ListVersions");