| 1 | import type * as grafana from "@distilled.cloud/aws/grafana"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { Workspace } from "./Workspace.ts"; |
| 5 | |
| 6 | /** |
| 7 | * Runtime binding for the `DisassociateLicense` operation (IAM action |
| 8 | * `grafana:DisassociateLicense`), scoped to one {@link Workspace}. |
| 9 | * |
| 10 | * Removes the Grafana Enterprise license from the workspace, downgrading it |
| 11 | * back to the standard edition. Provide the implementation with |
| 12 | * `Effect.provide(AWS.Grafana.DisassociateLicenseHttp)`. |
| 13 | * ### Managing Licenses |
| 14 | * **Example:** Downgrade from Grafana Enterprise |
| 15 | * ```typescript |
| 16 | * const disassociateLicense = yield* Grafana.DisassociateLicense(workspace); |
| 17 | * |
| 18 | * yield* disassociateLicense({ licenseType: "ENTERPRISE" }); |
| 19 | * ``` |
| 20 | * |
| 21 | * @binding |
| 22 | */ |
| 23 | export interface DisassociateLicense extends Binding.Service< |
| 24 | DisassociateLicense, |
| 25 | "AWS.Grafana.DisassociateLicense", |
| 26 | ( |
| 27 | workspace: Workspace, |
| 28 | ) => Effect.Effect< |
| 29 | ( |
| 30 | request: Omit<grafana.DisassociateLicenseRequest, "workspaceId">, |
| 31 | ) => Effect.Effect< |
| 32 | grafana.DisassociateLicenseResponse, |
| 33 | grafana.DisassociateLicenseError |
| 34 | > |
| 35 | > |
| 36 | > {} |
| 37 | export const DisassociateLicense = Binding.Service<DisassociateLicense>( |
| 38 | "AWS.Grafana.DisassociateLicense", |
| 39 | ); |